You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
96 lines
3.3 KiB
96 lines
3.3 KiB
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE html>
|
|
<html xmlns:h="http://xmlns.jcp.org/jsf/html"
|
|
xmlns:f="http://xmlns.jcp.org/jsf/core"
|
|
xmlns:ui="http://java.sun.com/jsf/facelets"
|
|
xmlns:p="http://primefaces.org/ui"
|
|
xmlns:c="http://xmlns.jcp.org/jstl"
|
|
>
|
|
<!-- === Edit ingkey/shopcat === -->
|
|
<h:form id="frmIsk">
|
|
<p:panelGrid>
|
|
<p:row>
|
|
<p:column>
|
|
<p:outputLabel for="ctlScSel"
|
|
value="Shopping Category"
|
|
/>
|
|
</p:column>
|
|
<p:column>
|
|
<p:outputLabel for="ctlIngkeySel"
|
|
value="Ingredient Key"
|
|
/>
|
|
</p:column>
|
|
</p:row>
|
|
<p:row style="vertical-align: top">
|
|
<p:column>
|
|
<p:selectOneListbox id="ctlScSel"
|
|
style="width: 240px"
|
|
value="#{shoppingListBean.selectedShopcat}"
|
|
>
|
|
<f:selectItems
|
|
value="#{shoppingListBean.shopcatList}"
|
|
/>
|
|
<p:ajax update="ctlIngkeySel" event="change" />
|
|
</p:selectOneListbox>
|
|
</p:column>
|
|
<p:column>
|
|
<h:selectManyListbox id="ctlIngkeySel"
|
|
style="width: 240px"
|
|
value="#{shoppingListBean.selectedIngkey}"
|
|
label="Ingcat"
|
|
>
|
|
<f:selectItems
|
|
value="#{shoppingListBean.ingkeyList}"
|
|
/>
|
|
<p:ajax event="change" update="ctlChangeCat"/>
|
|
</h:selectManyListbox>
|
|
</p:column>
|
|
</p:row>
|
|
<p:row>
|
|
<p:column>
|
|
<p:outputLabel
|
|
value="Change shopping category to:"
|
|
/>
|
|
</p:column>
|
|
<p:column>
|
|
<p:autoComplete
|
|
value="#{shoppingListBean.newShopcat}"
|
|
autoSelection="false" forceSelection="false"
|
|
maxResults="12"
|
|
completeMethod="#{shoppingListBean.suggestShopcat}"
|
|
/>
|
|
</p:column>
|
|
</p:row>
|
|
<p:row>
|
|
<p:column>
|
|
<p:commandButton id="ctlChangeCat" value="Change..."
|
|
disabled="#{empty shoppingListBean.selectedIngkey}"
|
|
onclick="PF('dlgOkRecat').show()"
|
|
/>
|
|
</p:column>
|
|
<p:column>
|
|
<h:outputText value="" />
|
|
</p:column>
|
|
</p:row>
|
|
</p:panelGrid>
|
|
</h:form>
|
|
<!-- -->
|
|
<h:form id="frmDelete">
|
|
<p:confirmDialog closable="false" id="dlgOkRecat"
|
|
header="Confirm Change - CANNOT UNDO"
|
|
message="OK to CHANGE Shopping Category for these Ingredient Keys?"
|
|
severity="alert" widgetVar="dlgOkRecat"
|
|
style="z-index: 25000"
|
|
>
|
|
<p:commandButton id="dlgOK" value="OK"
|
|
oncomplete="PF('dlgOkRecat').hide()"
|
|
action="#{shoppingListBean.doChangeShopcat}"
|
|
update="@form:@parent:frmIsk:ctlScSel @form:@parent:frmIsk:ctlIngkeySel"
|
|
immediate="true"
|
|
/>
|
|
<p:commandButton id="dlgCancel" value="Cancel"
|
|
onclick="PF('dlgOkRecat').hide()"
|
|
/>
|
|
</p:confirmDialog>
|
|
</h:form>
|
|
</html> |