我想知道在更新ajax
时是否有一个js
事件来调用p:outputPanel
方法?
因为我在代码的许多部分都调用了一种方法。
为了理解,我将title放入rowEditor中,因此当再次更新此p:outputPanel
渲染并释放标题时,因此在许多部分中都将此方法称为createTitlesRowEditor()
。
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition template="/template/common/pagelayout.xhtml"
xmlns="http://www.w3.org/1999/xhtml"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:c="http://java.sun.com/jsp/jstl/core"
xmlns:p="http://primefaces.org/ui"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:ez="http://java.sun.com/jsf/composite">
<ui:define name="content">
<script type="text/javascript">
function disableBtnCorrenteExcluir() {
$('button[id*="tabelaVigenciaCorrente"]').prop('disabled', true).addClass('ui-state-disabled');
}
function enableBtnCorrenteExcluir() {
$('button[id*="tabelaVigenciaCorrente"]').removeClass('ui-state-disabled');
createTitlesRowEditor();
}
function disableBtnProximaExcluir() {
$('button[id*="tabelaVigenciaProxima"]').prop('disabled', true).addClass('ui-state-disabled');
}
function enableBtnProximaExcluir() {
$('button[id*="tabelaVigenciaProxima"]').removeClass('ui-state-disabled');
createTitlesRowEditor();
}
function createTitlesRowEditor() {
$('span[class*="ui-icon-pencil"]').prop('title', 'Editar').addClass('.ui-state-hover');
$('span[class*="ui-icon-close"]').prop('title', 'Cancelar').addClass('.ui-state-hover');
$('span[class*="ui-icon-check"]').prop('title', 'Confirmar').addClass('.ui-state-hover');
}
function inserirMascara() {
$('input[class*="hasDatepicker"]').mask('99/99/9999');
}
</script>
<f:metadata>
<f:event listener="#{tabelaTaxasComissoesEmprestimoBean.load}" type="preRenderView" />
</f:metadata>
<div id="content">
<br />
<br />
<div class="form_title">
<span class="active"><h:outputText
value="#{lbl['TITLE.TABELATAXA.FORM.TABELATAXASECOMISSOES']}" /></span>
</div>
<h:form id="form">
<p:messages id="messages" />
<p:focus/>
<p:remoteCommand autoRun="true" oncomplete=" createTitlesRowEditor();"/>
<p:outputPanel id="vigenciaPanel">
<div style="margin: 0 auto; width: 70%">
<p:dataTable id="tabelaVigenciaCorrente" editable="true"
value="#{tabelaTaxasComissoesEmprestimoBean.pojo.vigenciaCorrente.faixas}"
emptyMessage="#{lbl['LABEL.TABELATAXA.ADICIONEPELOUMAFAIXA.MSG']}"
var="corrente" sortBy="prazoMinimo"
rendered="#{tabelaTaxasComissoesEmprestimoBean.pojo.vigenciaCorrente != null}">
<p:ajax event="rowEditInit" onstart="disableBtnCorrenteExcluir();" />
<p:ajax event="rowEdit" oncomplete="if (args.validationFailed) disableBtnCorrenteExcluir(); else enableBtnCorrenteExcluir();" />
<p:ajax event="rowEditCancel" oncomplete="enableBtnCorrenteExcluir();" />
<f:facet name="header">
<div align="left">
<p:outputLabel
value="#{tabelaTaxasComissoesEmprestimoBean.pojo.vigenciaCorrente} " />
<p:outputLabel
rendered="#{tabelaTaxasComissoesEmprestimoBean.pojo.vigenciaCorrente != null}"
value="#{lbl['LABEL.TABELATAXA.VIGENCIACORRENTE']}" />
</div>
</f:facet>
<p:column headerText="#{lbl['LABEL.TABELATAXA.PRAZOEMMESES']}"
styleClass="columnCenter" style="width:25%">
<p:cellEditor>
<f:facet name="output">
<p:outputLabel
value="#{corrente.prazoMinimo} #{((corrente.prazoMinimo == corrente.prazoMaximo) || (corrente.prazoMaximo == null)) ? '' : ' a '.concat(corrente.prazoMaximo)}" />
</f:facet>
<f:facet name="input">
<p:inputText id="prazoMinimoCorrente"
label="#{lbl['LABEL.TABELATAXA.PRAZOINICIAL']}"
styleClass="columnRight" value="#{corrente.prazoMinimo}"
size="8" maxlength="3" onkeypress="mascara(this, soNumeros)"
required="true"
title="#{lbl['LABEL.TABELATAXA.PARAPRAZOSIMPLESINFORMESOMENTEOPRAZOINICIAL.HELP']}" />
<p:tooltip for="prazoMinimoCorrente" showEvent="focus"
hideEvent="blur" />
<p:outputLabel value=" a " />
<p:inputText label="#{lbl['LABEL.TABELATAXA.PRAZOFINAL']}"
styleClass="columnRight" value="#{corrente.prazoMaximo}"
size="8" maxlength="3" onkeypress="mascara(this, soNumeros)" />
</f:facet>
</p:cellEditor>
</p:column>
<p:column headerText="#{lbl['LABEL.TABELATAXA.TAXAJUROS']}"
styleClass="columnRight">
<p:cellEditor>
<f:facet name="output">
<p:outputLabel value="#{corrente.taxaJuros}">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:outputLabel>
<p:outputLabel value="%" />
</f:facet>
<f:facet name="input">
<p:inputText label="#{lbl['LABEL.TABELATAXA.TAXAJUROS']}"
styleClass="columnRight" value="#{corrente.taxaJuros}"
onkeypress="mascara(this,valorMonetario)" size="11"
maxlength="6" required="true">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:inputText>
</f:facet>
</p:cellEditor>
</p:column>
<p:column
headerText="#{lbl['LABEL.TABELATAXA.TAXADIFERENCIADAOBANCOEMPRESA']}"
styleClass="columnRight">
<p:cellEditor>
<f:facet name="output">
<p:outputLabel value="#{corrente.taxaDiferenciadaParaBanco}">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:outputLabel>
<p:outputLabel
value="#{corrente.taxaDiferenciadaParaBanco == null ? '' : '%'}" />
</f:facet>
<f:facet name="input">
<p:inputText
label="#{lbl['LABEL.TABELATAXA.TAXADIFERENCIADAOBANCOEMPRESA']}"
value="#{corrente.taxaDiferenciadaParaBanco}"
styleClass="columnRight"
required="#{tabelaTaxasComissoesEmprestimoBean.pojo.tabelaExclusivaParaCPGarantia}"
onkeypress="mascara(this,valorMonetario)" size="11"
maxlength="6">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:inputText>
</f:facet>
</p:cellEditor>
</p:column>
<p:column headerText="#{lbl['LABEL.TABELATAXA.COMISSAO']}"
styleClass="columnRight">
<p:cellEditor>
<f:facet name="output">
<p:outputLabel value="#{corrente.comissao}">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:outputLabel>
<p:outputLabel value="%" />
</f:facet>
<f:facet name="input">
<p:inputText label="#{lbl['LABEL.TABELATAXA.COMISSAO']}"
value="#{corrente.comissao}" styleClass="columnRight"
onkeypress="mascara(this,valorMonetario)" size="11"
maxlength="6" required="true">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:inputText>
</f:facet>
</p:cellEditor>
</p:column>
<p:column headerText="#{lbl['LABEL.TABELATAXA.COMPLEMENTO']}"
styleClass="columnRight">
<p:cellEditor>
<f:facet name="output">
<p:outputLabel value="#{corrente.complementoComissao}">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:outputLabel>
<p:outputLabel
value="#{corrente.complementoComissao == null ? '' : '%'}" />
</f:facet>
<f:facet name="input">
<p:inputText label="#{lbl['LABEL.TABELATAXA.COMPLEMENTO']}"
value="#{corrente.complementoComissao}"
styleClass="columnRight"
onkeypress="mascara(this,valorMonetario)" size="11"
maxlength="6">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:inputText>
</f:facet>
</p:cellEditor>
</p:column>
<p:column headerText="#{lbl['LABEL.TABELATAXA.ACAO']}"
styleClass="coluna-acao">
<p:rowEditor />
<p:commandButton process="@this" styleClass="botaoImagem"
icon="botaoExcluir"
title="#{lbl['TITLE.TABELATAXA.FORM.EXCLUIR']}"
oncomplete="confirmationFaixaExclusao.show();">
<f:setPropertyActionListener
target="#{tabelaTaxasComissoesEmprestimoBean.vigenciaTipo}"
value="corrente" />
<f:setPropertyActionListener
target="#{tabelaTaxasComissoesEmprestimoBean.faixa}"
value="#{corrente}" />
</p:commandButton>
</p:column>
<f:facet name="footer">
<div align="right">
<p:commandButton
disabled="#{tabelaTaxasComissoesEmprestimoBean.pojo.vigenciaCorrente == null}"
process="@this"
value="#{lbl['BTN.TABELATAXA.ADICIONARFAIXA']}"
update=":dialogAdicionarFaixa" oncomplete="dlgFaixa.show();"
action="#{tabelaTaxasComissoesEmprestimoBean.criarFaixa()}">
<f:setPropertyActionListener
target="#{tabelaTaxasComissoesEmprestimoBean.vigenciaTipo}"
value="corrente" />
</p:commandButton>
<p:commandButton process="@this" update=":dialogVigencia"
oncomplete="dlgVigencia.show(); createTitlesRowEditor();"
value="#{lbl['BTN.TABELATAXA.EDITARVIGENCIA']}"
action="#{tabelaTaxasComissoesEmprestimoBean.editarVigencia}"
disabled="#{tabelaTaxasComissoesEmprestimoBean.pojo.id ne null}">
<f:setPropertyActionListener
target="#{tabelaTaxasComissoesEmprestimoBean.modoOperacao}"
value="editar" />
<f:setPropertyActionListener
target="#{tabelaTaxasComissoesEmprestimoBean.vigenciaTipo}"
value="corrente" />
</p:commandButton>
<p:commandButton process="@this" update=":dialogVigencia"
oncomplete="confirmationVigenciaExclusao.show();"
value="#{lbl['BTN.TABELATAXA.EXCLUIRVIGENCIA']}"
disabled="#{tabelaTaxasComissoesEmprestimoBean.pojo.id ne null}">
<f:setPropertyActionListener
target="#{tabelaTaxasComissoesEmprestimoBean.vigenciaTipo}"
value="corrente" />
</p:commandButton>
</div>
</f:facet>
</p:dataTable>
<br />
<div align="right">
<p:commandButton id="btnAdicionarNovaVigencia" process="@this" update="messages :dialogVigencia"
actionListener="#{tabelaTaxasComissoesEmprestimoBean.criarVigencia()}"
value="#{lbl['BTN.TABELATAXA.ADICIONARVIGENCIA']}">
<f:setPropertyActionListener target="#{tabelaTaxasComissoesEmprestimoBean.modoOperacao}" value="inserir"/>
</p:commandButton>
<p:commandButton id="btnHistoricoVigencias" type="button"
value="#{lbl['BTN.TABELATAXA.HISTORICODASVIGENCIAS']}"
onclick="blockUIForm.show(); dlgHistoricoVigencias.show(); "
rendered="#{tabelaTaxasComissoesEmprestimoBean.pojo.id != null}" />
</div>
</div>
</p:outputPanel>
</h:form>
</div>
<p:dialog id="dialogVigencia" widgetVar="dlgVigencia"
resizable="false" modal="true" closable="false"
onHide="createTitlesRowEditor();"
header="#{tabelaTaxasComissoesEmprestimoBean.vigencia.id eq null ? lbl['LABEL.TABELATAXA.ADICIONARVIGENCIA.HEADER']
: lbl['LABEL.TABELATAXA.EDITARVIGENCIA.HEADER']}"
width="30%">
<h:form id="vigenciaForm">
<p:messages id="messagesAdicionar" />
<div class="form_title">
<span class="active"><h:outputText
value="#{tabelaTaxasComissoesEmprestimoBean.vigencia.id == null ? lbl['LABEL.TABELATAXA.ADICIONARVIGENCIA.HEADER'] : lbl['LABEL.TABELATAXA.EDITARVIGENCIA.HEADER']}" /></span>
</div>
<p:panelGrid id="gridVigencia"
styleClass="panelGridCenter gridNoBackground noBorders">
<p:row>
<p:column styleClass="columnRight" width="50%">
<p:outputLabel
value="#{lbl['LABEL.TABELATAXA.VIGENCIA.DATAINICIAL']}" />
</p:column>
<p:column width="50%">
<p:calendar
label="#{lbl['LABEL.TABELATAXA.VIGENCIA.DATAINICIAL']}"
value="#{tabelaTaxasComissoesEmprestimoBean.vigencia.dataInicial}"
pattern="dd/MM/yyyy" mode="popup" required="true" locale="pt_BR"
size="16" onfocus="inserirMascara();" />
</p:column>
</p:row>
<p:row
rendered="#{tabelaTaxasComissoesEmprestimoBean.vigencia.dataFinal != null and tabelaTaxasComissoesEmprestimoBean.vigencia.id != null}">
<p:column styleClass="columnRight">
<p:outputLabel
value="#{lbl['LABEL.TABELATAXA.VIGENCIA.DATAFINAL']}" />
</p:column>
<p:column>
<p:calendar label="#{lbl['LABEL.TABELATAXA.VIGENCIA.DATAFINAL']}"
value="#{tabelaTaxasComissoesEmprestimoBean.vigencia.dataFinal}"
pattern="dd/MM/yyyy" mode="popup" disabled="true" locale="pt_BR"
size="16" />
</p:column>
</p:row>
</p:panelGrid>
<div class="form_title" />
<div align="right">
<p:commandButton process="vigenciaForm"
value="#{lbl['BTN.TABELATAXA.CONFIRMAR']}"
actionListener="#{tabelaTaxasComissoesEmprestimoBean.salvarVigencia()}"
oncomplete="createTitlesRowEditor();"
update=":form:vigenciaPanel messagesAdicionar gridVigencia @parent :form:btnAdicionarNovaVigencia" />
<p:commandButton type="button"
value="#{lbl['BTN.TABELATAXA.CANCELAR']}"
onclick="confirmDialogCancelViagencia.show();" />
</div>
</h:form>
</p:dialog>
<p:confirmDialog message="#{lbl['LABEL.TABELATAXA.DESEJAREALMENTECANCELAR.MSG']}"
header="#{lbl['LABEL.TABELATAXA.CONFIRMACAOCANCELAMENTO.HEADER']}" severity="alert"
widgetVar="confirmDialogCancelViagencia">
<p:commandButton process="@this" value="#{lbl['BTN.TABELATAXA.SIM']}"
update=":form:vigenciaPanel"
oncomplete="createTitlesRowEditor();"
onclick="dlgVigencia.hide(); confirmDialogCancelViagencia.hide();">
<p:ajax event="click" listener="#{tabelaTaxasComissoesEmprestimoBean.resetDialog(':dialogVigencia')}" />
</p:commandButton>
<p:commandButton type="button" value="#{lbl['BTN.TABELATAXA.NAO']}"
onclick="confirmDialogCancelViagencia.hide();" />
</p:confirmDialog>
<p:confirmDialog showEffect="false"
message="#{lbl['LABEL.TABELATAXA.DESEJAREALMENTEEXCLUIRESTAVIGENCIA.MSG']}"
header="#{lbl['LABEL.TABELATAXA.CONFIRMACAOEXCLUSAO.HEADER']}"
widgetVar="confirmationVigenciaExclusao">
<p:commandButton process="@this" value="#{lbl['BTN.TABELATAXA.SIM']}"
actionListener="#{tabelaTaxasComissoesEmprestimoBean.removerVigencia()}"
oncomplete="confirmationVigenciaExclusao.hide(); createTitlesRowEditor(); window.scrollTo(0, 0);"
update=":form:vigenciaPanel :form:messages" />
<p:commandButton type="button" value="#{lbl['BTN.TABELATAXA.NAO']}"
onclick="confirmationVigenciaExclusao.hide();" />
</p:confirmDialog>
<p:dialog id="dialogAdicionarFaixa" header="#{lbl['LABEL.TABELATAXA.ADICIONARFAIXA.HEADER']}"
widgetVar="dlgFaixa" resizable="false" modal="true" closable="false">
<h:form id="faixaForm">
<p:messages id="messagesAdicionar" />
<div class="form_title">
<span class="active"><h:outputText value="#{lbl['TITLE.TABELATAXA.FORM.ADICIONARFAIXA']}" /></span>
</div>
<p:panelGrid id="gridFaixa"
styleClass="panelGridCenter noBorders gridNoBackground">
<p:row>
<p:column styleClass="columnRight">
<p:outputLabel value="#{lbl['LABEL.TABELATAXA.PRAZO']}" />
</p:column>
<p:column>
<p:inputText label="#{lbl['LABEL.TABELATAXA.PRAZOINICIAL']}"
styleClass="columnRight"
value="#{tabelaTaxasComissoesEmprestimoBean.faixa.prazoMinimo}"
size="11" maxlength="3" onkeypress="mascara(this, soNumeros)"
required="true" />
<p:outputLabel value="a" />
</p:column>
<p:column style="padding-left: 0">
<p:inputText label="#{lbl['LABEL.TABELATAXA.PRAZOFINAL']}"
styleClass="columnRight"
value="#{tabelaTaxasComissoesEmprestimoBean.faixa.prazoMaximo}"
size="11" maxlength="3" onkeypress="mascara(this, soNumeros)"/>
</p:column>
<p:column styleClass="noPadding">
<p:outputLabel value="#{lbl['LABEL.TABELATAXA.MESES']}" />
</p:column>
<p:column>
<p:graphicImage url="#{resource['images:help-icon.png']}"
title="#{lbl['LABEL.TABELATAXA.PARAPRAZOSIMPLESINFORMESOMENTEOPRAZOINICIAL.HELP']}" />
</p:column>
</p:row>
<p:row>
<p:column styleClass="columnRight">
<p:outputLabel value="#{lbl['LABEL.TABELATAXA.TAXAJUROS']}" />
</p:column>
<p:column>
<p:inputText label="#{lbl['LABEL.TABELATAXA.TAXAJUROS']}"
styleClass="columnRight"
value="#{tabelaTaxasComissoesEmprestimoBean.faixa.taxaJuros}"
onkeypress="mascara(this,valorMonetario)" size="11"
maxlength="6" required="true">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:inputText>
<p:outputLabel value=" %" />
</p:column>
</p:row>
<p:row>
<p:column styleClass="columnRight">
<p:outputLabel value="#{lbl['LABEL.TABELATAXA.TAXADIFERENCIADAOBANCOEMPRESA']}" />
</p:column>
<p:column>
<p:inputText
label="#{lbl['LABEL.TABELATAXA.TAXADIFERENCIADAOBANCOEMPRESA']}"
styleClass="columnRight"
value="#{tabelaTaxasComissoesEmprestimoBean.faixa.taxaDiferenciadaParaBanco}"
required="#{tabelaTaxasComissoesEmprestimoBean.pojo.tabelaExclusivaParaCPGarantia}"
onkeypress="mascara(this,valorMonetario)" size="11"
maxlength="6">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:inputText>
<p:outputLabel value=" %" />
</p:column>
</p:row>
<p:row>
<p:column styleClass="columnRight">
<p:outputLabel value="#{lbl['LABEL.TABELATAXA.COMISSAO']}" />
</p:column>
<p:column>
<p:inputText label="#{lbl['LABEL.TABELATAXA.COMISSAO']}"
styleClass="columnRight"
value="#{tabelaTaxasComissoesEmprestimoBean.faixa.comissao}"
onkeypress="mascara(this,valorMonetario)" size="11"
maxlength="6" required="true">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:inputText>
<p:outputLabel value=" %" />
</p:column>
</p:row>
<p:row>
<p:column styleClass="columnRight">
<p:outputLabel value="#{lbl['LABEL.TABELATAXA.COMPLEMENTO']}" />
</p:column>
<p:column>
<p:inputText label="#{lbl['LABEL.TABELATAXA.COMPLEMENTO']}"
styleClass="columnRight"
value="#{tabelaTaxasComissoesEmprestimoBean.faixa.complementoComissao}"
onkeypress="mascara(this,valorMonetario)" size="11"
maxlength="6">
<f:convertNumber locale="pt_BR" minFractionDigits="2"
maxFractionDigits="2" />
</p:inputText>
<p:outputLabel value=" %" />
</p:column>
</p:row>
</p:panelGrid>
<div class="form_title" />
<div align="right">
<p:commandButton process="faixaForm" value="#{lbl['BTN.TABELATAXA.CONFIRMAR']}"
oncomplete="if (!args.validationFailed) dlgFaixa.hide(); createTitlesRowEditor();"
update=":form:vigenciaPanel messagesAdicionar gridFaixa @parent">
<p:collector unique="false" addTo="#{tabelaTaxasComissoesEmprestimoBean.faixasVigencia}"
value="#{tabelaTaxasComissoesEmprestimoBean.faixa}" />
</p:commandButton>
<p:commandButton type="button" value="#{lbl['BTN.TABELATAXA.CANCELAR']}"
onclick="confirmDialogCancelFaixa.show();" />
</div>
</h:form>
</p:dialog>
<p:confirmDialog message="#{lbl['LABEL.TABELATAXA.DESEJAREALMENTECANCELAR.MSG']}"
header="#{lbl['LABEL.TABELATAXA.CONFIRMACAOCANCELAMENTO.HEADER']}" severity="alert"
widgetVar="confirmDialogCancelFaixa">
<p:commandButton process="@this" type="button" value="#{lbl['BTN.TABELATAXA.SIM']}"
onclick="dlgFaixa.hide(), confirmDialogCancelFaixa.hide();">
<p:ajax event="click" listener="#{tabelaTaxasComissoesEmprestimoBean.resetDialog(':dialogAdicionarFaixa')}" />
</p:commandButton>
<p:commandButton type="button" value="#{lbl['BTN.TABELATAXA.NAO']}"
onclick="confirmDialogCancelFaixa.hide();" />
</p:confirmDialog>
<p:confirmDialog showEffect="false"
message="#{lbl['LABEL.TABELATAXA.DESEJAREALMENTEEXCLUIRESTAFAIXAVIGENCIA.MSG']}"
header="#{lbl['LABEL.TABELATAXA.CONFIRMACAOEXCLUSAO.HEADER']}" widgetVar="confirmationFaixaExclusao">
<p:commandButton process="@this" value="#{lbl['BTN.TABELATAXA.SIM']}"
oncomplete="confirmationFaixaExclusao.hide(); createTitlesRowEditor(); window.scrollTo(0, 0);"
update=":form:vigenciaPanel :form:messages">
<p:collector removeFrom="#{tabelaTaxasComissoesEmprestimoBean.faixasVigencia}"
value="#{tabelaTaxasComissoesEmprestimoBean.faixa}" />
</p:commandButton>
<p:commandButton type="button" value="#{lbl['BTN.TABELATAXA.NAO']}"
onclick="confirmationFaixaExclusao.hide();" />
</p:confirmDialog>
<p:dialog header="#{lbl['LABEL.TABELATAXA.HISTORICODATABELA.HEADER']}"
widgetVar="dlgLog" resizable="false" modal="true" height="450"
onShow="blockUIForm.hide();" width="1000" dynamic="true">
<ui:include src="#{tabelaTaxasComissoesEmprestimoBean.viewLog}" />
</p:dialog>
<p:confirmDialog id="confirmDialogCancelForm"
message="#{lbl['LABEL.TABELATAXA.DESEJAREALMENTECANCELAR.MSG']}"
header="#{lbl['LABEL.TABELATAXA.CONFIRMACAOCANCELAMENTO.HEADER']}" severity="alert"
widgetVar="cancelConfirmationForm">
<p:commandButton process="confirmDialogCancelForm"
value="#{lbl['BTN.TABELATAXA.SIM']}" action="#{tabelaTaxasComissoesEmprestimoBean.cancelar}"
oncomplete="cancelConfirmationForm.hide();" />
<p:commandButton type="button" value="#{lbl['BTN.TABELATAXA.NAO']}"
onclick="cancelConfirmationForm.hide();" />
</p:confirmDialog>
<p:dialog header="#{lbl['LABEL.TABELATAXA.HISTORICODASVIGENCIAS.HEADER']}" widgetVar="dlgHistoricoVigencias"
resizable="false" modal="true" height="500" width="1000" dynamic="true" onShow="blockUIForm.hide()">
<ui:include src="#{tabelaTaxasComissoesEmprestimoBean.getViewVigenciasLog()}" />
</p:dialog>
</ui:define>
</ui:composition>
谢谢
最佳答案
您可以将要执行的JavaScript添加到p:outputPanel
,因此不需要p:remoteCommand
和autoRun="true"
,并且每次outputPanel更新时,JS都将执行:
<p:outputPanel id="vigenciaPanel">
...
<script type="text/javascript">
$(document).ready(createTitlesRowEditor);
</script>
</p:outputPanel>