Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html
- xmlns="http://www.w3.org/1999/xhtml"
- xmlns:ui="http://java.sun.com/jsf/facelets"
- xmlns:f="http://java.sun.com/jsf/core"
- xmlns:h="http://java.sun.com/jsf/html"
- xmlns:p="http://primefaces.org/ui" xmlns:j="http://jleaf.org/faces"
- xmlns:jl="http://java.sun.com/jsf/composite/jlcomponents"
- xmlns:c="http://java.sun.com/jsp/jstl/core"
- xmlns:autonum="http://java.sun.com/jsf/composite/autonum">
- <ui:composition template="/WEB-INF/layouts/input.xhtml">
- <ui:define name="headPart">
- <script type="text/javascript"
- src="${request.contextPath}/jleaf.resource/org/jleaf/erp/sls/web/resources/js/reportPopUpViewer.js" />
- <j:lang id="lang" prefix="org.jleaf.erp.sls.web" />
- <link
- href="${request.contextPath}/jleaf.resource/org/jleaf/erp/sls/web/resources/css/style.css"
- type="text/css" rel="stylesheet" />
- <title>#{piece['inputSalesQuotation']}</title>
- </ui:define>
- <ui:define name="pageTitle">
- <span>#{piece['inputSalesQuotation']}</span>
- </ui:define>
- <ui:define name="userActions">
- <j:authorize task="createSalesQuotation,removeSalesQuotation,submitSalesQuotation,cancelApproveSalesQuotation">
- <jl:userActions controller="#{inputSalesQuotationController}"
- addTaskName="createSalesQuotation"
- editTaskName="createSalesQuotation"
- removeTaskName="removeSalesQuotation"
- submitTaskName="submitSalesQuotation"
- downloadTaskName="downloadPdfSalesQuotation"
- cancelApproveTaskName="cancelApproveSalesQuotation"
- saveUpdate=":rootform">
- <f:facet name="reportParameters">
- <f:param name="FormSalesQuotation" value="salesQuotationSignature" />
- </f:facet>
- <f:facet name="reportLabels">
- <f:param name="FormSalesQuotation" value="#{piece['salesQuotationSignature']}" />
- </f:facet>
- </jl:userActions>
- </j:authorize>
- </ui:define>
- <ui:define name="userActionsBottom">
- <j:authorize task="createSalesQuotation,removeSalesQuotation,submitSalesQuotation,cancelApproveSalesQuotation">
- <jl:userActions controller="#{inputSalesQuotationController}"
- addTaskName="createSalesQuotation"
- editTaskName="createSalesQuotation"
- removeTaskName="removeSalesQuotation"
- submitTaskName="submitSalesQuotation"
- downloadTaskName="downloadPdfSalesQuotation"
- cancelApproveTaskName="cancelApproveSalesQuotation"
- saveUpdate=":rootform"
- renderUpload="false" renderDownloadReport="false" />
- </j:authorize>
- </ui:define>
- <ui:define name="content">
- <j:authorize
- task="createSalesQuotation,removeSalesQuotation,submitSalesQuotation,cancelApproveSalesQuotation"
- forbidden="true">
- <h:inputHidden id="printPreviewReportUrl"
- value="#{inputSalesQuotationController.printPreviewReportUrl}" />
- <p:remoteCommand name="updateCurrency"
- process=":rootform:comboCurrency" />
- #{remarkController.setUpdateList(':rootform')}
- <p:messages id="messages" autoUpdate="true" />
- <j:error />
- <p:panelGrid id="headerPanel" style="width: 100%">
- <p:row>
- <p:column>
- <h:outputText value="#{piece['ouBuOrBranch']}" />
- </p:column>
- <p:column colspan="3">
- <p:inputText id="ouName" readonly="true"
- value="#{inputSalesQuotationController.header['ouCode']} - #{inputSalesQuotationController.header['ouName']}"
- styleClass="md" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['salesQuotationNo']}" />
- </p:column>
- <p:column>
- <p:inputText id="soNo" label="#{piece['salesOrderNo']}"
- value="#{inputSalesQuotationController.header['docNo']}"
- readonly="true" styleClass="md" />
- <autonum:infoUnused module="erpjleafsales"
- serviceName="getSalesOrderUnusedAutonumList"
- yearMonth="#{inputSalesQuotationController.header['docDate'].toString().substring(0,6)}"
- target="rootform:soNo"
- rendered="#{not inputSalesQuotationController.editMode}" />
- </p:column>
- <p:column>
- <h:outputText value="#{piece['salesQuotationDate']}" />
- </p:column>
- <p:column>
- <jl:datePicker
- value="#{inputSalesQuotationController.header['docDate']}"
- required="true" label="#{piece['salesOrderDate']}"
- rendered="#{not inputSalesQuotationController.editMode}" />
- <p:inputText
- value="#{inputSalesQuotationController.header['docDate']}"
- converter="#{dateConverter}" readonly="true" styleClass="md"
- rendered="#{inputSalesQuotationController.editMode}" />
- </p:column>
- </p:row>
- <p:row rendered="#{inputSalesQuotationController.header['refId'] != -99 and inputSalesQuotationController.header['refId'] != null}">
- <p:column>
- <h:outputText value="#{piece['refSalesQuotationNo']}" />
- </p:column>
- <p:column>
- <p:inputText label="#{piece['customerPONo']}" id="refDocNo"
- rendered="#{inputSalesQuotationController.editMode}"
- readonly="true"
- value="#{inputSalesQuotationController.header['refDocNo']}"
- disabled="#{inputSalesQuotationController.readOnlyMode}"
- styleClass="md" />
- </p:column>
- <p:column>
- <h:outputText value="#{piece['refSalesQuotationDate']}" />
- </p:column>
- <p:column>
- <p:inputText
- value="#{inputSalesQuotationController.header['refDocDate']}"
- converter="#{dateConverter}" readonly="true" styleClass="md"
- rendered="#{inputSalesQuotationController.editMode}" id="refDocDate" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['extDocNo']}" />
- </p:column>
- <p:column>
- <p:inputText label="#{piece['customerPONo']}" id="extDocNo"
- value="#{inputSalesQuotationController.header['extDocNo']}"
- rendered="#{inputSalesQuotationController.header['flgFromWebpos'] == 'N'}"
- disabled="#{inputSalesQuotationController.readOnlyMode}"
- styleClass="md" />
- <p:inputText label="#{piece['customerPONo']}"
- value="#{inputSalesQuotationController.header['extDocNo']}"
- rendered="#{inputSalesQuotationController.header['flgFromWebpos'] == 'Y'}"
- disabled="true"
- styleClass="md" />
- </p:column>
- <p:column>
- <h:outputText value="#{piece['extDocDate']}" />
- </p:column>
- <p:column rendered="#{inputSalesQuotationController.header['flgFromWebpos'] == 'N'}">
- <jl:datePicker
- value="#{inputSalesQuotationController.header['extDocDate']}"
- label="#{piece['extDocDate']}"
- rendered="#{not inputSalesQuotationController.editMode}" />
- <p:inputText
- value="#{inputSalesQuotationController.header['extDocDate']}"
- converter="#{dateConverter}" readonly="true" styleClass="md"
- rendered="#{inputSalesQuotationController.editMode}" />
- </p:column>
- <p:column rendered="#{inputSalesQuotationController.header['flgFromWebpos'] == 'Y'}">
- <p:inputText
- value="#{inputSalesQuotationController.header['extDocDate']}"
- converter="#{dateConverter}" readonly="true" styleClass="md" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['partner']}" />
- </p:column>
- <p:column>
- <p:panelGrid id="customerPanel" columns="2">
- <p:outputPanel id="iconCustomer">
- <p:inputText value="#{inputSalesQuotationController.header['partnerCode']}" size="25" styleClass="md"
- disabled="true"/>
- <p:commandLink id="btnAddPartner"
- title="#{piece['partnerInfo']}"
- update=":rootform:messages"
- oncomplete="selectPartnerDlg.show()"
- rendered="#{not inputSalesQuotationController.readOnlyMode and inputSalesQuotationController.header['flgFromWebpos'] != 'Y'}">
- <i class="fa fa-plus-circle fa-icon"></i>
- </p:commandLink>
- <p:commandLink id="btnInfoCustomer"
- title="#{piece['partnerPhoneInfo']}"
- process="@this"
- update=":rootform:messages :rootform:customerPanel :rootform:customer1 :rootform:customer2 :rootform:customer3
- :rootform:customer4 :rootform:customerCpPanel :rootform:Cp1 :rootform:Cp2 :rootform:Cp3 :rootform:Cp4 :rootform:Cp5
- :rootform:Cp6 :rootform:Cp7"
- actionListener="#{inputSalesQuotationController.clearPartner()}"
- rendered="#{not inputSalesQuotationController.readOnlyMode and inputSalesQuotationController.header['flgFromWebpos'] != 'Y'}">
- <i class="fa fa-minus-circle fa-icon"></i>
- </p:commandLink>
- </p:outputPanel>
- </p:panelGrid>
- </p:column>
- <p:column>
- <h:outputText value="#{piece['customerCP']}" />
- </p:column>
- <p:column colspan="3">
- <p:panelGrid id="customerCpPanel" columns="3">
- <p:inputText id="customerCpDummy" value="#{inputSalesQuotationController.header['partnerCpName']}" styleClass="md"
- disabled="#{inputSalesQuotationController.header['partnerCpId'] != -99}" />
- <p:commandLink id="btnSearchCpPartner"
- oncomplete="selectPartnerCpDlg.show()"
- process="@this"
- update=":rootform:messages :selectPartnerCP"
- actionListener="#{inputSalesQuotationController.doSearchPartnerCP()}"
- rendered="#{not inputSalesQuotationController.readOnlyMode}">
- <i class="fa fa-plus-circle fa-icon"></i>
- </p:commandLink>
- <p:outputPanel>
- <p:commandLink id="btnClearCpPartner"
- title="#{piece['clear']}"
- update=":rootform:customerCpPanel :rootform:Cp1 :rootform:Cp2 :rootform:Cp3 :rootform:Cp4 :rootform:Cp5
- :rootform:Cp6 :rootform:Cp7"
- actionListener="#{inputSalesQuotationController.clearPartnerCp()}"
- rendered="#{not inputSalesQuotationController.readOnlyMode}">
- <i class="fa fa-minus-circle fa-icon"></i>
- </p:commandLink>
- <p:spacer width="5px"
- rendered="#{inputSalesQuotationController.readOnlyMode}"></p:spacer>
- </p:outputPanel>
- </p:panelGrid>
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['partnerName']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerName']}" size="25" styleClass="md"
- id="customer1" disabled="#{inputSalesQuotationController.header['partnerId'] != -99}" />
- </p:column>
- <p:column>
- <h:outputText value="#{piece['customerCpPhone']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerCpPhone1']}" size="25" styleClass="md"
- id="Cp1" disabled="#{inputSalesQuotationController.header['partnerCpId'] != -99}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['customerAddress']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerAddress1']}" size="25" styleClass="md"
- id="customer2" disabled="#{inputSalesQuotationController.header['partnerAddressId'] != -99}" />
- <p:commandLink id="btnSearchPartnerAddress"
- title="#{piece['partnerAddress']}"
- update=":rootform:messages :selectPartnerAddress1:grid :selectPartnerAddress"
- oncomplete="selectPartnerAddressDlg.show()"
- actionListener="#{inputSalesQuotationController.loadPartnerAddress()}"
- rendered="#{not inputSalesQuotationController.readOnlyMode}">
- <i class="fa fa-plus-circle fa-icon"></i>
- </p:commandLink>
- <p:commandLink id="btnclearCustomer"
- title="#{piece['partnerPhoneInfo']}"
- process="@this"
- update=":rootform:messages :rootform:customer2 :rootform:customer3 :rootform:customer4"
- actionListener="#{inputSalesQuotationController.clearPartnerAddress()}"
- rendered="#{not inputSalesQuotationController.readOnlyMode}">
- <i class="fa fa-minus-circle fa-icon"></i>
- </p:commandLink>
- </p:column>
- <p:column>
- <h:outputText />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerCpPhone2']}" size="25" styleClass="md"
- id="Cp2" disabled="#{inputSalesQuotationController.header['partnerCpId'] != -99}" />
- </p:column>
- </p:row>
- <p:row >
- <p:column>
- <h:outputText />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerAddress2']}" size="25" styleClass="md"
- id="customer3" disabled="#{inputSalesQuotationController.header['partnerAddressId'] != -99}" />
- </p:column>
- <p:column>
- <h:outputText value="#{piece['customerCpFax']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerCpFax1']}" size="25" styleClass="md"
- id="Cp3" disabled="#{inputSalesQuotationController.header['partnerCpId'] != -99}" />
- </p:column>
- </p:row>
- <p:row >
- <p:column>
- <h:outputText />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerAddress3']}" size="25" styleClass="md"
- id="customer4" disabled="#{inputSalesQuotationController.header['partnerAddressId'] != -99}" />
- </p:column>
- <p:column>
- <h:outputText />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerCpFax2']}" size="25" styleClass="md"
- id="Cp4" disabled="#{inputSalesQuotationController.header['partnerCpId'] != -99}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column colspan="2">
- <h:outputText />
- </p:column>
- <p:column>
- <h:outputText value="#{piece['customerCpEmail']}"/>
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerCpEmail']}" size="25" styleClass="md"
- id="Cp5" disabled="#{inputSalesQuotationController.header['partnerCpId'] != -99}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column colspan="2">
- <h:outputText />
- </p:column>
- <p:column>
- <h:outputText value="#{piece['mobilePhone']}"/>
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerCpMobilePhone1']}" size="25" styleClass="md"
- id="Cp6" disabled="#{inputSalesQuotationController.header['partnerCpId'] != -99}" />
- </p:column>
- </p:row>
- <p:row >
- <p:column colspan="3">
- <h:outputText />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.header['partnerCpMobilePhone2']}" size="25" styleClass="md"
- id="Cp7" disabled="#{inputSalesQuotationController.header['partnerCpId'] != -99}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['salesman']}" />
- </p:column>
- <p:column>
- <jl:autoComplete id="comboSalesman"
- value="#{inputSalesQuotationController.header['salesman']}"
- comboName="authorizedActiveSalesman"
- args=",#{inputSalesQuotationController.header['ouId']},Y"
- itemLabel="#{not empty item['code'] and not empty item['name'] ? item['code'].concat(' - ').concat(item['name']) : ''}"
- label="code, name"
- disabled="#{inputSalesQuotationController.readOnlyMode}"
- styleClass="md" />
- </p:column>
- <p:column>
- <h:outputText value="#{piece['currency']}" />
- </p:column>
- <p:column colspan="3">
- <jl:comboBox id="comboCurrency"
- value="#{inputSalesQuotationController.header['currency']}"
- comboName="currency" update=":rootform:details"
- disabled="#{inputSalesQuotationController.readOnlyMode}" args=""
- itemLabel="#{item['code']}" ajax="true"
- listener="#{inputSalesQuotationController.onCurrencyChanged}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['includeTax']}" />
- </p:column>
- <p:column>
- <p:selectOneButton id="flgIncludeTax"
- value="#{inputSalesQuotationController.header['flgTax']}"
- disabled="#{inputSalesQuotationController.readOnlyMode}">
- <f:selectItem itemValue="Y" itemLabel="#{piece['yes']}" />
- <f:selectItem itemValue="N" itemLabel="#{piece['no']}" />
- <p:ajax process="@this" />
- </p:selectOneButton>
- </p:column>
- <p:column>
- <h:outputText value="#{piece['tax']} #{inputSalesQuotationController.header['tax']}" />
- </p:column>
- <p:column>
- <p:panelGrid columns="2">
- <!-- <jl:comboBoxWithNone id="comboTax"
- value="#{inputSalesQuotationController.header['tax']}" taskName="system"
- disabled="#{inputSalesQuotationController.readOnlyMode}"
- comboName="tax" args="Y"
- noneLabel="none"
- itemLabel="#{item['name']} #{inputSalesQuotationController.header['tax']}"
- /> -->
- <p:selectOneMenu rendered="{inputSalesQuotationController.header['flgPkp'] == 'Y'}"
- value="#{inputSalesQuotationController.header['tax']}"
- disabled="#{inputSalesQuotationController.readOnlyMode}">
- <f:selectItems value="#{inputSalesQuotationController.taxList}"
- var="item" itemLabel="#{item.name}" itemValue="#{item.id}" />
- <f:selectItem itemLabel="#{piece['none']}" itemValue="-99" />
- </p:selectOneMenu>
- <p:selectOneMenu rendered="{inputSalesQuotationController.header['flgPkp'] == 'N'}"
- value="#{inputSalesQuotationController.header['tax']}"
- disabled="#{inputSalesQuotationController.readOnlyMode}">
- <f:selectItem itemLabel="#{piece['none']}" itemValue="-99" />
- <f:selectItems value="#{inputSalesQuotationController.taxList}"
- var="item" itemLabel="#{item.name}" itemValue="#{item.id}" />
- </p:selectOneMenu>
- </p:panelGrid>
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['remark']}" />
- </p:column>
- <p:column colspan="3">
- <p:inputTextarea id="remark"
- value="#{inputSalesQuotationController.header['remark']}" cols="100"
- rows="5" readonly="#{inputSalesQuotationController.readOnlyMode}" />
- </p:column>
- </p:row>
- </p:panelGrid>
- <p:fieldset id="detailItemsFieldset" legend="#{piece['productItems']}">
- <p:commandButton value="#{piece['addNewProduct']}" process="@this :rootform:headerPanel"
- oncomplete="addMoreItemsDlg.show()" icon="ui-icon ui-icon-plus" update=":addMoreItemsDialog :addMoreItemsForm"
- actionListener="#{inputSalesQuotationController.prepareAddMoreItems()}" ajax="true"
- rendered="#{not inputSalesQuotationController.readOnlyMode and inputSalesQuotationController.header['flgFromWebpos'] != 'Y'}" />
- <p:commandButton value="#{piece['addNewProductExisting']}" process="@this :rootform:headerPanel"
- oncomplete="addNewProductExistingDlg.show()" icon="ui-icon ui-icon-plus" update=":addMoreItemsForm:addMoreItemsPanel"
- rendered="#{not inputSalesQuotationController.readOnlyMode and inputSalesQuotationController.header['flgFromWebpos'] != 'Y'}" />
- <p:dataTable id="details" value="#{inputSalesQuotationController.details}" var="quotationItem">
- <p:column style="width:160px" headerText="#{piece['action']}" rendered="#{not inputSalesQuotationController.readOnlyMode}">
- <p:commandLink id="btnEdit" process="@this :rootform:comboCurrency :rootform:headerPanel"
- oncomplete="editMoreItemsDlg.show()" update=":editMoreItemsForm:editMoreItemsPanel"
- actionListener="#{inputSalesQuotationController.prepareEditItem(quotationItem)}"
- rendered="#{inputSalesQuotationController.editMode}" >
- <h:graphicImage library="images" name="common/edit.png" title="#{piece['view']}" />
- </p:commandLink>
- <p:spacer width="5px" />
- <p:commandLink id="btnRemove" onclick="deleteItemDlg.show()" process="@this :rootform:headerPanel"
- rendered="#{inputSalesQuotationController.header['flgFromWebpos'] != 'Y'}"
- actionListener="#{inputSalesQuotationController.prepareRemoveItem(quotationItem)}">
- <h:graphicImage library="images" name="common/delete.png" title="#{piece['remove']}" />
- </p:commandLink>
- </p:column>
- <p:column headerText="#{piece['lineNo']}">
- <h:outputText value="#{quotationItem['lineNo']}" />
- </p:column>
- <p:column headerText="#{piece['product']}">
- <h:outputText value="#{quotationItem['productCode']} - #{quotationItem['productDesc']}" />
- </p:column>
- <p:column headerText="#{piece['flgStock']}">
- <h:outputText value="#{quotationItem['flgStock'] == 'Y' ? 'Yes' : 'No'}" />
- </p:column>
- <p:column headerText="#{piece['indentDays']}">
- <h:outputText value="#{quotationItem['indentDays']}" />
- <p:spacer width="5px" />
- <h:outputText value="#{piece['days']}" />
- </p:column>
- <p:column headerText="#{piece['qty']}">
- <h:outputText value="#{quotationItem['qty']}" converter="#{numericConverter}" />
- <h:outputText value=" #{quotationItem['uomName']}" />
- </p:column>
- <p:column headerText="#{piece['sellPrice']}">
- <h:outputText value="#{quotationItem['currCode']} " />
- <p:inputText value="#{quotationItem['sellPrice']}" converter="#{numericConverter}"
- styleClass="sm amount-dec" rendered="#{not inputSalesQuotationController.editMode}" required="true"/>
- <h:outputText value="#{quotationItem['sellPrice']}" converter="#{numericConverter}"
- styleClass="sm amount-dec" rendered="#{inputSalesQuotationController.editMode}"/>
- </p:column>
- <p:column headerText="#{piece['amount']}">
- <h:outputText value="#{quotationItem['currCode']} " />
- <h:outputText value="#{quotationItem['amount']}" converter="#{numericConverter}"
- styleClass="sm amount-dec" />
- </p:column>
- <p:column headerText="#{piece['remark']}">
- <h:outputText value="#{quotationItem['remark']}" />
- </p:column>
- </p:dataTable>
- </p:fieldset>
- <p:spacer height="10px" />
- <p:fieldset id="detailTermsAndCondition" legend="#{piece['termsAndCondition']}" rendered="#{inputSalesQuotationController.editMode}">
- <p:commandButton value="#{piece['addMoreTermCondition']}" process="@this :rootform:headerPanel"
- oncomplete="addMoreTermCondition.show()" icon="ui-icon ui-icon-plus" update="@this :addMoreTermConditionSQ"
- rendered="#{not inputSalesQuotationController.readOnlyMode}"/>
- <p:spacer height="10px" />
- <p:dataTable id="termsAndCondition"
- value="#{inputSalesQuotationController.tcList}"
- var="item">
- <p:column style="width:160px" headerText="#{piece['action']}" rendered="#{not inputSalesQuotationController.readOnlyMode}">
- <p:commandLink id="btnRemove" onclick="deleteTcDlg.show()" process="@this :rootform:headerPanel"
- rendered="#{not inputSalesQuotationController.readOnlyMode}"
- actionListener="#{inputSalesQuotationController.prepareRemoveItem(item)}">
- <h:graphicImage library="images" name="common/delete.png" title="#{piece['remove']}" />
- </p:commandLink>
- </p:column>
- <p:column headerText="#{piece['lineNo']}">
- <h:outputText value="#{item['lineNo']}" />
- </p:column>
- <p:column headerText="#{piece['termCondition']}">
- <h:outputText value="#{item['termCondition']}" />
- </p:column>
- </p:dataTable>
- </p:fieldset>
- <p:confirmDialog id="deleteItemDialog"
- message="#{piece['areYouSure']}" widgetVar="deleteItemDlg"
- header="#{piece['removeItem']}" severity="alert">
- <p:commandButton
- actionListener="#{inputSalesQuotationController.doRemoveItem()}"
- process="@this" update=":rootform:detailItemsFieldset"
- value="#{piece['yes']}" oncomplete="deleteItemDlg.hide()" />
- <p:commandButton type="button" value="#{piece['no']}"
- onclick="deleteItemDlg.hide()" />
- </p:confirmDialog>
- <p:confirmDialog id="deleteTcDialog"
- message="#{piece['areYouSure']}" widgetVar="deleteTcDlg"
- header="#{piece['removeItem']}" severity="alert">
- <p:commandButton
- actionListener="#{inputSalesQuotationController.doRemoveTc()}"
- process="@this" update=":rootform:detailTermsAndCondition"
- value="#{piece['yes']}" oncomplete="deleteTcDlg.hide()" />
- <p:commandButton type="button" value="#{piece['no']}"
- onclick="deleteItemDlg.hide()" />
- </p:confirmDialog>
- </j:authorize>
- </ui:define>
- <ui:define name="outsidePart">
- <p:dialog id="addMoreItemsDialog" widgetVar="addMoreItemsDlg"
- appendToBody="true" header="#{piece['addMoreItem']}" modal="true"
- height="auto" width="auto">
- <h:form id="addMoreItemsForm">
- <p:messages id="messages" autoUpdate="true" />
- <p:panelGrid id="addMoreItemsPanel" style="width: 100%">
- <p:row>
- <p:column>
- <h:outputText value="#{piece['productCode']}" />
- </p:column>
- <p:column>
- <p:inputText
- value="#{inputSalesQuotationController.filterAddMoreItems['productCode']}" styleClass="md" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['productName']}" />
- </p:column>
- <p:column>
- <p:inputText
- value="#{inputSalesQuotationController.filterAddMoreItems['productDesc']}" styleClass="md" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['brand']}" />
- </p:column>
- <p:column>
- <p:inputText
- value="#{inputSalesQuotationController.filterAddMoreItems['brandName']}" styleClass="md" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['flgStock']}" />
- </p:column>
- <p:column>
- <p:selectOneButton id="flgStock"
- value="#{inputSalesQuotationController.filterAddMoreItems['flgStock']}">
- <f:selectItem itemValue="Y" itemLabel="#{piece['yes']}" />
- <f:selectItem itemValue="N" itemLabel="#{piece['no']}" />
- </p:selectOneButton>
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['indentDays']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.filterAddMoreItems['indentDays']}"
- styleClass="xs" />
- <p:spacer width="5px" />
- <h:outputText value="#{piece['days']}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['qty']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.filterAddMoreItems['qty']}"
- converter="#{numericConverter}" styleClass="sm amount-dec" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['nettSellPrice']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.filterAddMoreItems['nettSellPrice']}"
- converter="#{numericConverter}" styleClass="sm amount-dec" required="true"/>
- <h:outputText value="#{inputSalesQuotationController.filterAddMoreItems['currCode']}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['nettAmount']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.filterAddMoreItems['nettAmount']}"
- converter="#{numericConverter}" styleClass="sm amount-dec" disabled="true"/>
- <h:outputText value="#{inputSalesQuotationController.filterAddMoreItems['currCode']}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['remark']}" />
- </p:column>
- <p:column>
- <p:inputTextarea id="remark" value="#{inputSalesQuotationController.filterAddMoreItems['remark']}" cols="50" rows="5" />
- </p:column>
- </p:row>
- </p:panelGrid>
- <h:panelGrid columns="1" style="width: 100%">
- <h:panelGroup>
- <p:commandButton value="#{piece['save']}"
- update=":rootform:detailItemsFieldset :rootform:details :addMoreItemsForm:messages" ajax="true"
- oncomplete="(!args.success)? addMoreItemsDlg.show() : addMoreItemsDlg.hide() "
- actionListener="#{inputSalesQuotationController.doAddMoreItems()}"/>
- </h:panelGroup>
- </h:panelGrid>
- </h:form>
- </p:dialog>
- <p:dialog id="addNewProductExisting" widgetVar="addNewProductExistingDlg"
- appendToBody="true" header="#{piece['addNewProductExisting']}" modal="true"
- width="auto" height="600px">
- <h:form id="addNewProductExistingForm">
- <p:panelGrid id="addNewProductExistingPanel" style="width: 100%">
- <p:row>
- <p:column>
- <h:outputText value="#{piece['subCategoryProductOrCategoryProduct']}" />
- </p:column>
- <p:column>
- <jl:comboBoxWithNone id="comboSubCtgr"
- value="#{inputSalesQuotationController.dataProduct['subCtgrProduct']}" taskName="system"
- comboName="authorizedSubCtgrProduct" args="-99,,,Y"
- itemLabel="#{item['name']} - #{item['ctgrProductName']}"
- noneLabel="all" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['productName']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.dataProduct['productCodeName']}" styleClass="md" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['brandCodeName']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.dataProduct['brandCodeName']}" styleClass="md" />
- </p:column>
- </p:row>
- </p:panelGrid>
- <p:commandButton id="btnSearch"
- icon="ui-icon ui-icon-search" update=":addNewProductExistingForm:grid"
- actionListener="#{inputSalesQuotationController.doSearchProduct()}"
- value="#{piece['search']}" process="addNewProductExistingPanel,@this" />
- <p:defaultCommand target="btnSearch" />
- <p:dataTable id="grid" value="#{inputSalesQuotationController.model}" var="item" paginator="true" rows="25" lazy="true"
- paginatorTemplate="{CurrentPageReport} {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}"
- rowsPerPageTemplate="25,50,100"
- selection="#{inputSalesQuotationController.selectedList}"
- rowKey="#{item['productId']}">
- <f:facet name="header">
- #{piece['pleasePickItemsBelow']}
- </f:facet>
- <p:column headerText="#{piece['action']}">
- <p:commandLink value="#{piece['selectItem']}"
- oncomplete="addNewProductExistingDlg.hide()"
- process="@this"
- update=":rootform:details,@this"
- actionListener="#{inputSalesQuotationController.addProductExisting(item)}" ajax="true"
- />
- </p:column>
- <p:column headerText="#{piece['product']}">
- <h:outputText value="#{item['productCode']} - #{item['productName']}" />
- </p:column>
- <p:column headerText="#{piece['brand']}">
- <h:outputText value="#{item['brandName']}" />
- </p:column>
- <p:column headerText="#{piece['balanceQty']}">
- <h:outputText value="#{item['qty']} #{item['baseUomName']}" />
- </p:column>
- </p:dataTable>
- </h:form>
- </p:dialog>
- <p:dialog id="editMoreItemsDialog" widgetVar="editMoreItemsDlg"
- appendToBody="true" header="#{piece['editItem']}" modal="true">
- <h:form id="editMoreItemsForm">
- <p:messages id="messages" autoUpdate="true" />
- <p:panelGrid id="editMoreItemsPanel" style="width: 100%">
- <p:row>
- <p:column>
- <h:outputText value="#{piece['productCode']}" />
- </p:column>
- <p:column>
- <p:inputText
- value="#{inputSalesQuotationController.filterAddMoreItems['productCode']}" styleClass="md"
- readonly="#{inputSalesQuotationController.filterAddMoreItems['productId'] != -99}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['productName']}" />
- </p:column>
- <p:column>
- <p:inputText
- value="#{inputSalesQuotationController.filterAddMoreItems['productDesc']}" styleClass="md"
- readonly="#{inputSalesQuotationController.filterAddMoreItems['productId'] != -99}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['brand']}" />
- </p:column>
- <p:column>
- <p:inputText
- value="#{inputSalesQuotationController.filterAddMoreItems['brandName']}" styleClass="md"
- readonly="#{inputSalesQuotationController.filterAddMoreItems['productId'] != -99}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['flgStock']}" />
- </p:column>
- <p:column>
- <p:selectOneButton id="flgStock"
- value="#{inputSalesQuotationController.filterAddMoreItems['flgStock']}">
- <f:selectItem itemValue="Y" itemLabel="#{piece['yes']}" />
- <f:selectItem itemValue="N" itemLabel="#{piece['no']}" />
- </p:selectOneButton>
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['indentDays']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.filterAddMoreItems['indentDays']}"
- styleClass="xs" />
- <p:spacer width="5px" />
- <h:outputText value="#{piece['days']}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['qty']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.filterAddMoreItems['qty']}"
- converter="#{numericConverter}" styleClass="sm amount-dec" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['nettSellPrice']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.filterAddMoreItems['nettSellPrice']}"
- converter="#{numericConverter}" styleClass="sm amount-dec" required="true"/>
- <h:outputText value="#{inputSalesQuotationController.filterAddMoreItems['currCode']}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['nettAmount']}" />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.filterAddMoreItems['nettAmount']}"
- converter="#{numericConverter}" styleClass="sm amount-dec" disabled="true"/>
- <h:outputText value="#{inputSalesQuotationController.filterAddMoreItems['currCode']}" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <h:outputText value="#{piece['remark']}" />
- </p:column>
- <p:column>
- <p:inputTextarea id="remark" value="#{inputSalesQuotationController.filterAddMoreItems['remark']}" cols="50" rows="5" />
- </p:column>
- </p:row>
- </p:panelGrid>
- <h:panelGrid columns="1" style="width: 100%">
- <h:panelGroup>
- <p:commandButton value="#{piece['save']}"
- update=":rootform:detailItemsFieldset :rootform:details" ajax="true"
- oncomplete="args.success ? editMoreItemsDlg.hide() : editMoreItemsDlg.show()"
- actionListener="#{inputSalesQuotationController.doEditItem()}"/>
- </h:panelGroup>
- </h:panelGrid>
- </h:form>
- </p:dialog>
- <p:dialog id="addMoreTermConditionSQ" widgetVar="addMoreTermCondition"
- appendToBody="true" header="#{piece['addMoreItem']}" modal="true" >
- <h:form id="addMoreTermConditionForm">
- <p:panelGrid id="addMoreTermConditionPanel" style="width: 100%">
- <p:row>
- <p:column>
- <h:outputText value="#{piece['termCondition']}" />
- </p:column>
- <p:column>
- <p:inputTextarea id="termCondition"
- value="#{inputSalesQuotationController.filterAddMoreItems['termCondition']}" cols="80"
- rows="5" />
- </p:column>
- </p:row>
- </p:panelGrid>
- <h:panelGrid columns="1" style="width: 100%">
- <h:panelGroup>
- <p:commandButton value="#{piece['save']}"
- update=":rootform:termsAndCondition" ajax="true"
- oncomplete="addMoreTermCondition.hide()"
- actionListener="#{inputSalesQuotationController.doAddTCItems()}"/>
- </h:panelGroup>
- </h:panelGrid>
- </h:form>
- </p:dialog>
- <p:dialog id="selectPartner" widgetVar="selectPartnerDlg"
- appendToBody="true" header="#{piece['selectCustomer']}" modal="true"
- width="auto" height="600px">
- <p:ajax event="close" process="@none" update=":rootform:messages" />
- <h:form id="selectPartner1" legend="#{piece['productItems']}">
- <p:panelGrid columns="2">
- <p:row>
- <p:column>
- <h:outputText value="#{piece['name']} / #{piece['code']} " />
- </p:column>
- <p:column>
- <p:inputText value="#{inputSalesQuotationController.dataPartner}" styleClass="md" />
- </p:column>
- </p:row>
- <p:row>
- <p:column>
- <p:commandButton id="btnSearch"
- icon="ui-icon ui-icon-search" update=":selectPartner1:grid"
- actionListener="#{inputSalesQuotationController.doSearchPartner()}"
- value="#{piece['search']}" process=":selectPartner1" />
- <p:defaultCommand target="btnSearch" />
- </p:column>
- </p:row>
- </p:panelGrid>
- <p:dataTable id="grid" value="#{inputSalesQuotationController.partnerList}" var="item" paginator="true" rows="25"
- rowKey="#{item['productId']}">
- <f:facet name="header">
- #{piece['pleasePickItemsBelow']}
- </f:facet>
- <p:column headerText="#{piece['action']}" width="100">
- <p:commandLink value="#{piece['selectItem']}"
- oncomplete="selectPartnerDlg.hide()"
- process="@this"
- update=":rootform:customerPanel :rootform:customer1 :rootform:customer2 :rootform:customer3
- :rootform:customer4 :rootform:customerCpPanel :rootform:Cp1 :rootform:Cp2 :rootform:Cp3 :rootform:Cp4 :rootform:Cp5
- :rootform:Cp6 :rootform:Cp7"
- actionListener="#{inputSalesQuotationController.chooseCustomer(item)}" ajax="true"
- />
- </p:column>
- <p:column headerText="#{piece['code']}">
- <h:outputText value="#{item['code']}" />
- </p:column>
- <p:column headerText="#{piece['name']}">
- <h:outputText value="#{item['name']}" />
- </p:column>
- </p:dataTable>
- </h:form>
- </p:dialog>
- <p:dialog id="selectPartnerCP" widgetVar="selectPartnerCpDlg"
- appendToBody="true" header="#{piece['selectCustomerCP']}" modal="true"
- width="auto">
- <p:ajax event="close" process="@none" update=":rootform:messages" />
- <h:form id="selectPartnerCP1" legend="#{piece['productItems']}">
- <p:dataTable id="grid" value="#{inputSalesQuotationController.cpList}" var="item" paginator="true" rows="25"
- rowKey="#{item['productId']}">
- <f:facet name="header">
- #{piece['pleasePickItemsBelow']}
- </f:facet>
- <p:column headerText="#{piece['action']}">
- <p:commandLink value="#{piece['selectItem']}"
- oncomplete="selectPartnerCpDlg.hide()"
- process="@this"
- update=":rootform:customerCpPanel :rootform:Cp1 :rootform:Cp2 :rootform:Cp3 :rootform:Cp4 :rootform:Cp5
- :rootform:Cp6 :rootform:Cp7"
- actionListener="#{inputSalesQuotationController.chooseCustomerCP(item)}" ajax="true"
- />
- </p:column>
- <p:column headerText="#{piece['name']}">
- <h:outputText value="#{item['cpName']}" />
- </p:column>
- <p:column headerText="#{piece['job']}">
- <h:outputText value="#{item['cpJob']}" />
- </p:column>
- <p:column headerText="#{piece['phone']}">
- <h:outputText value="#{item['phone1']}" />
- <h:outputText value="#{item['phone2']}" />
- </p:column>
- <p:column headerText="#{piece['email']}">
- <h:outputText value="#{item['email']}" />
- </p:column>
- </p:dataTable>
- </h:form>
- </p:dialog>
- <p:dialog id="selectPartnerAddress" widgetVar="selectPartnerAddressDlg"
- appendToBody="true" header="#{piece['selectCustomerAddress']}" modal="true"
- width="auto">
- <p:ajax event="close" process="@none" update=":rootform:messages" />
- <h:form id="selectPartnerAddress1" legend="#{piece['partnerAddress']}">
- <p:dataTable id="grid" value="#{inputSalesQuotationController.partnerAddressList}" var="item" paginator="true" rows="25"
- rowKey="#{item['partnerAddressId']}">
- <f:facet name="header">
- #{piece['pleasePickItemsBelow']}
- </f:facet>
- <p:column headerText="#{piece['action']}">
- <p:commandLink value="#{piece['selectItem']}"
- oncomplete="selectPartnerAddressDlg.hide()"
- process="@this"
- update=":rootform:customerPanel :rootform:customer1 :rootform:customer2 :rootform:customer3 :rootform:customer4"
- actionListener="#{inputSalesQuotationController.chooseCustomerAddress(item)}" ajax="true"
- />
- </p:column>
- <p:column headerText="#{piece['address']}">
- <h:outputText value="#{item['address1']}" /> -
- <h:outputText value="#{item['address2']}" /> -
- <h:outputText value="#{item['address3']}" />
- </p:column>
- </p:dataTable>
- </h:form>
- </p:dialog>
- </ui:define>
- </ui:composition>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement