Commit 30475f1f by Tuomas Riihimäki

rnd

1 parent e29088ce
......@@ -55,6 +55,8 @@ public class VipFacade extends IntegerPkGenericFacade<Vip> {
LanEvent event = eventBean.getCurrentEvent();
cq.where(cb.equal(root.get(Vip_.event), event));
cq.orderBy(cb.asc(root.get(Vip_.id)));
return getEm().createQuery(cq).getResultList();
}
......
......@@ -25,10 +25,14 @@
<f:selectItem itemLabel="#{i18n['bill.isNotPaid']}" itemValue="false"/>
</p:selectOneButton>
</f:facet>
<p:link outcome="/bill/edit" value="#{line.bill.id} (#{line.bill.paid?i18n['bill.isPaid']:i18n['bill.isNotPaid']})">
<p:link outcome="/bill/edit"
value="#{line.bill.id} (#{line.bill.paid ? i18n['bill.isPaid'] : i18n['bill.isNotPaid']})">
<f:param name="billid" value="#{line.bill.id}"/>
</p:link>
</p:column>
<p:column headerText="#{i18n['bill.notes']}">
<h:outputText value="#{line.bill.notes}"/>
</p:column>
<p:column sortable="true" sortBy="#{line.bill.paidDate}" headerText="#{i18n['bill.paidDate']}">
<h:outputText value="#{line.bill.paidDate}">
......
......@@ -64,7 +64,7 @@
</p:column>
<p:column style="width: 90px; text-align: center;">
<p:commandButton id="delivebtn" rendered="#{not empty vip.id}" value="#{i18n['vip.deliver']}" actionListener="#{vipListView.deliverDialog(vip)}" >
<p:commandButton id="delivebtn" rendered="#{not empty vip.id}" value="#{i18n['vip.deliver']}" actionListener="#{vipListView.deliverDialog(vip.id)}" >
<p:ajax event="dialogReturn" listener="#{vipListView.updateViplist()}" update="products" />
</p:commandButton>
</p:column>
......
......@@ -57,10 +57,12 @@ public class VipListView extends PaginationView<Vip> {
initView();
}
public void deliverDialog(Vip item) {
public void deliverDialog(Integer vipId) {
//getDeliverView().setVip(viplist.getRowData());
getDeliverView().setVip(item);
Vip vip = vipBean.find(vipId);
getDeliverView().setVip(vip);
logger.info("Set vip in deliverView to {}", deliverView.getVip());
Map<String, Object> options = new HashMap<>();
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!