Totvs - WS Fornecedor / WS Cliente / WS Pedido Compra (fixes bug #6127)
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@42651 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
0ced0a9bb3
commit
fcb053e48d
|
@ -292,6 +292,8 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
private Checkbox checkOfpsTerceiros;
|
private Checkbox checkOfpsTerceiros;
|
||||||
private Checkbox checkStock;
|
private Checkbox checkStock;
|
||||||
private Checkbox checkPermisoTasaEmbarque;
|
private Checkbox checkPermisoTasaEmbarque;
|
||||||
|
private Checkbox ckIsento;
|
||||||
|
private MyTextbox txtNumIEPuntoVenta;
|
||||||
|
|
||||||
public static final int INTERVALO_FECHAMENTO_SEMANAL = 7;
|
public static final int INTERVALO_FECHAMENTO_SEMANAL = 7;
|
||||||
public static final int INTERVALO_FECHAMENTO_DECENDIAL = 10;
|
public static final int INTERVALO_FECHAMENTO_DECENDIAL = 10;
|
||||||
|
@ -701,7 +703,19 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
public void onSelect$cmbBanco() {
|
public void onSelect$cmbBanco() {
|
||||||
InstiFinanceira banco = (InstiFinanceira) cmbBanco.getSelectedItem().getValue();
|
InstiFinanceira banco = (InstiFinanceira) cmbBanco.getSelectedItem().getValue();
|
||||||
txtNomeBanco.setValue(banco.getNome());
|
txtNomeBanco.setValue(banco.getNome());
|
||||||
|
}
|
||||||
|
|
||||||
|
public void onClick$ckIsento(Event ev) {
|
||||||
|
if (ckIsento.isChecked()) {
|
||||||
|
puntoVenta.setNumIEPuntoVenta("ISENTO");
|
||||||
|
txtNumIEPuntoVenta.setValue("ISENTO");
|
||||||
|
txtNumIEPuntoVenta.setDisabled(true);
|
||||||
|
|
||||||
|
} else {
|
||||||
|
puntoVenta.setNumIEPuntoVenta("");
|
||||||
|
txtNumIEPuntoVenta.setValue("");
|
||||||
|
txtNumIEPuntoVenta.setDisabled(false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void onChange$cmbCiudad(Event ev) {
|
public void onChange$cmbCiudad(Event ev) {
|
||||||
|
@ -2276,6 +2290,7 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
log.error(ex.toString());
|
log.error(ex.toString());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void onClick$btnAdicionarFechamentoParamptovta(Event ev) {
|
public void onClick$btnAdicionarFechamentoParamptovta(Event ev) {
|
||||||
if (cmbEmpresaFechamentoParamptovta.getSelectedItem() != null &&
|
if (cmbEmpresaFechamentoParamptovta.getSelectedItem() != null &&
|
||||||
(StringUtils.isNotEmpty(txtIntervalofechamento.getValue()) ||
|
(StringUtils.isNotEmpty(txtIntervalofechamento.getValue()) ||
|
||||||
|
@ -2284,7 +2299,7 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
|| radIntervalofechamentoQuinzenal.isChecked()
|
|| radIntervalofechamentoQuinzenal.isChecked()
|
||||||
|| radIntervalofechamentoMensal.isChecked()
|
|| radIntervalofechamentoMensal.isChecked()
|
||||||
)
|
)
|
||||||
) ) {
|
)) {
|
||||||
Empresa empresa = (Empresa) cmbEmpresaFechamentoParamptovta.getSelectedItem().getValue();
|
Empresa empresa = (Empresa) cmbEmpresaFechamentoParamptovta.getSelectedItem().getValue();
|
||||||
|
|
||||||
FechamentoParamptovta fechamentoParamptovta = new FechamentoParamptovta();
|
FechamentoParamptovta fechamentoParamptovta = new FechamentoParamptovta();
|
||||||
|
@ -2292,19 +2307,19 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
fechamentoParamptovta.setPuntoventa(puntoVenta);
|
fechamentoParamptovta.setPuntoventa(puntoVenta);
|
||||||
Integer intervalofechamento = 0;
|
Integer intervalofechamento = 0;
|
||||||
|
|
||||||
if(radIntervalofechamentoSemanal.isChecked()){
|
if (radIntervalofechamentoSemanal.isChecked()) {
|
||||||
intervalofechamento = INTERVALO_FECHAMENTO_SEMANAL;
|
intervalofechamento = INTERVALO_FECHAMENTO_SEMANAL;
|
||||||
|
|
||||||
} else if(radIntervalofechamentoDecendial.isChecked()){
|
} else if (radIntervalofechamentoDecendial.isChecked()) {
|
||||||
intervalofechamento = INTERVALO_FECHAMENTO_DECENDIAL;
|
intervalofechamento = INTERVALO_FECHAMENTO_DECENDIAL;
|
||||||
|
|
||||||
} else if(radIntervalofechamentoQuinzenal.isChecked()){
|
} else if (radIntervalofechamentoQuinzenal.isChecked()) {
|
||||||
intervalofechamento = INTERVALO_FECHAMENTO_QUINZENAL;
|
intervalofechamento = INTERVALO_FECHAMENTO_QUINZENAL;
|
||||||
|
|
||||||
} else if(radIntervalofechamentoMensal.isChecked()){
|
} else if (radIntervalofechamentoMensal.isChecked()) {
|
||||||
intervalofechamento = INTERVALO_FECHAMENTO_MENSAL;
|
intervalofechamento = INTERVALO_FECHAMENTO_MENSAL;
|
||||||
|
|
||||||
}else{
|
} else {
|
||||||
intervalofechamento = Integer.valueOf(txtIntervalofechamento.getValue());
|
intervalofechamento = Integer.valueOf(txtIntervalofechamento.getValue());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2316,14 +2331,14 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
|
|
||||||
boolean validado = validaFechamentoParamptovta(fechamentoParamptovta);
|
boolean validado = validaFechamentoParamptovta(fechamentoParamptovta);
|
||||||
|
|
||||||
if(validado){
|
if (validado) {
|
||||||
fechamentoParamptovtaService.suscribir(fechamentoParamptovta);
|
fechamentoParamptovtaService.suscribir(fechamentoParamptovta);
|
||||||
|
|
||||||
List<FechamentoParamptovta> params = fechamentoParamptovtaService.buscaParametrosPorPuntoventa(puntoVenta);
|
List<FechamentoParamptovta> params = fechamentoParamptovtaService.buscaParametrosPorPuntoventa(puntoVenta);
|
||||||
fechamentoParamptovtaList.setData(params);
|
fechamentoParamptovtaList.setData(params);
|
||||||
|
|
||||||
resetDadosFechamentoParamptovta();
|
resetDadosFechamentoParamptovta();
|
||||||
} else{
|
} else {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
@ -2339,7 +2354,7 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void resetDadosFechamentoParamptovta(){
|
private void resetDadosFechamentoParamptovta() {
|
||||||
|
|
||||||
cmbEmpresaFechamentoParamptovta.setSelectedItem(null);
|
cmbEmpresaFechamentoParamptovta.setSelectedItem(null);
|
||||||
|
|
||||||
|
@ -2350,15 +2365,15 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
txtIntervalofechamento.setValue(null);
|
txtIntervalofechamento.setValue(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean validaFechamentoParamptovta(FechamentoParamptovta fechamentoParamptovta){
|
private boolean validaFechamentoParamptovta(FechamentoParamptovta fechamentoParamptovta) {
|
||||||
boolean validado = true;
|
boolean validado = true;
|
||||||
|
|
||||||
Object[] params = fechamentoParamptovtaList.getData();
|
Object[] params = fechamentoParamptovtaList.getData();
|
||||||
|
|
||||||
for(Object objectData : params){
|
for (Object objectData : params) {
|
||||||
|
|
||||||
FechamentoParamptovta param = (FechamentoParamptovta) objectData;
|
FechamentoParamptovta param = (FechamentoParamptovta) objectData;
|
||||||
if(fechamentoParamptovta.getEmpresa().getEmpresaId() == param.getEmpresa().getEmpresaId()){
|
if (fechamentoParamptovta.getEmpresa().getEmpresaId() == param.getEmpresa().getEmpresaId()) {
|
||||||
validado = false;
|
validado = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2382,5 +2397,4 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
||||||
this.cmbEmpresaFechamentoParamptovta = cmbEmpresaFechamentoParamptovta;
|
this.cmbEmpresaFechamentoParamptovta = cmbEmpresaFechamentoParamptovta;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -60,7 +60,8 @@
|
||||||
label="${c:l('editarPuntoVentaController.tab.label.localidades')}" />
|
label="${c:l('editarPuntoVentaController.tab.label.localidades')}" />
|
||||||
<tab
|
<tab
|
||||||
label="${c:l('editarPuntoVentaController.tab.label.seguro')}" />
|
label="${c:l('editarPuntoVentaController.tab.label.seguro')}" />
|
||||||
<tab visible="@{winEditarPuntoVenta$composer.validaFuncionTipoBoletoBloqueado}"
|
<tab
|
||||||
|
visible="@{winEditarPuntoVenta$composer.validaFuncionTipoBoletoBloqueado}"
|
||||||
label="${c:l('editarPuntoVentaController.tab.label.tipoPassageiroBloqueio')}" />
|
label="${c:l('editarPuntoVentaController.tab.label.tipoPassageiroBloqueio')}" />
|
||||||
<tab
|
<tab
|
||||||
label="${c:l('editarPuntoVentaController.tab.label.fechamentocntcorrente')}" />
|
label="${c:l('editarPuntoVentaController.tab.label.fechamentocntcorrente')}" />
|
||||||
|
@ -275,19 +276,24 @@
|
||||||
</row>
|
</row>
|
||||||
<row>
|
<row>
|
||||||
<!-- Inscrição Estadual -->
|
<!-- Inscrição Estadual -->
|
||||||
<label
|
<label value="${c:l('editarPuntoVentaController.lbIE.value')}" />
|
||||||
value="${c:l('editarPuntoVentaController.lbIE.value')}" />
|
<hbox>
|
||||||
<textbox width="70%"
|
|
||||||
maxlength="20"
|
<textbox id="txtNumIEPuntoVenta" width="100%" maxlength="20"
|
||||||
value="@{winEditarPuntoVenta$composer.puntoVenta.numIEPuntoVenta}"
|
value="@{winEditarPuntoVenta$composer.puntoVenta.numIEPuntoVenta}"
|
||||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
|
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
|
||||||
|
|
||||||
|
<checkbox id="ckIsento"
|
||||||
|
checked="@{winEditarPuntoVenta$composer.puntoVenta.incProgConcessaoCredito}" />
|
||||||
|
<label value="ISENTO" />
|
||||||
|
</hbox>
|
||||||
</row>
|
</row>
|
||||||
<row>
|
<row>
|
||||||
<!-- Inscrição Programa concessão de Crédito -->
|
<!-- Inscrição Programa concessão de Crédito -->
|
||||||
<label
|
<label
|
||||||
value="${c:l('editarPuntoVentaController.lbProgConcessao.value')}" />
|
value="${c:l('editarPuntoVentaController.lbProgConcessao.value')}" />
|
||||||
<checkbox
|
<checkbox
|
||||||
checked="@{winEditarPuntoVenta$composer.puntoVenta.incProgConcessaoCredito}"/>
|
checked="@{winEditarPuntoVenta$composer.puntoVenta.incProgConcessaoCredito}" />
|
||||||
</row>
|
</row>
|
||||||
<row>
|
<row>
|
||||||
<!-- Comentarios -->
|
<!-- Comentarios -->
|
||||||
|
@ -1227,29 +1233,37 @@
|
||||||
</columns>
|
</columns>
|
||||||
<rows>
|
<rows>
|
||||||
<row>
|
<row>
|
||||||
<label value="${c:l('editarPuntoVentaController.lbEmpresa.value')}" />
|
<label
|
||||||
<combobox id="cmbEmpresaFechamentoParamptovta"
|
value="${c:l('editarPuntoVentaController.lbEmpresa.value')}" />
|
||||||
|
<combobox
|
||||||
|
id="cmbEmpresaFechamentoParamptovta"
|
||||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
|
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
|
||||||
mold="rounded"
|
mold="rounded" buttonVisible="true"
|
||||||
buttonVisible="true"
|
|
||||||
model="@{winEditarPuntoVenta$composer.lsEmpresas}"
|
model="@{winEditarPuntoVenta$composer.lsEmpresas}"
|
||||||
constraint="no empty" />
|
constraint="no empty" />
|
||||||
</row>
|
</row>
|
||||||
<row>
|
<row>
|
||||||
<label value="${c:l('editarPuntoVentaController.intervalofechamento.label')}" />
|
<label
|
||||||
<radiogroup Id="radIntervalofechamento">
|
value="${c:l('editarPuntoVentaController.intervalofechamento.label')}" />
|
||||||
<radio id="radIntervalofechamentoSemanal"
|
<radiogroup
|
||||||
|
Id="radIntervalofechamento">
|
||||||
|
<radio
|
||||||
|
id="radIntervalofechamentoSemanal"
|
||||||
label="${c:l('editarPuntoVentaController.radIntervalofechamentoSemanal.value')}" />
|
label="${c:l('editarPuntoVentaController.radIntervalofechamentoSemanal.value')}" />
|
||||||
<radio id="radIntervalofechamentoDecendial"
|
<radio
|
||||||
|
id="radIntervalofechamentoDecendial"
|
||||||
label="${c:l('editarPuntoVentaController.radIntervalofechamentoDecendial.value')}" />
|
label="${c:l('editarPuntoVentaController.radIntervalofechamentoDecendial.value')}" />
|
||||||
<radio id="radIntervalofechamentoQuinzenal"
|
<radio
|
||||||
|
id="radIntervalofechamentoQuinzenal"
|
||||||
label="${c:l('editarPuntoVentaController.radIntervalofechamentoQuinzenal.value')}" />
|
label="${c:l('editarPuntoVentaController.radIntervalofechamentoQuinzenal.value')}" />
|
||||||
<radio id="radIntervalofechamentoMensal"
|
<radio
|
||||||
|
id="radIntervalofechamentoMensal"
|
||||||
label="${c:l('editarPuntoVentaController.radIntervalofechamentoMensal.value')}" />
|
label="${c:l('editarPuntoVentaController.radIntervalofechamentoMensal.value')}" />
|
||||||
</radiogroup>
|
</radiogroup>
|
||||||
</row>
|
</row>
|
||||||
<row>
|
<row>
|
||||||
<label value="${c:l('editarPuntoVentaController.intervalofechamento.label')}" />
|
<label
|
||||||
|
value="${c:l('editarPuntoVentaController.intervalofechamento.label')}" />
|
||||||
<textbox id="txtIntervalofechamento"
|
<textbox id="txtIntervalofechamento"
|
||||||
width="50px"
|
width="50px"
|
||||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
|
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox" />
|
||||||
|
@ -1271,11 +1285,15 @@
|
||||||
vflex="true" multiple="false">
|
vflex="true" multiple="false">
|
||||||
|
|
||||||
<listhead sizable="true">
|
<listhead sizable="true">
|
||||||
<listheader image="/gui/img/create_doc.gif" align="right"
|
<listheader image="/gui/img/create_doc.gif"
|
||||||
label="${c:l('editarPuntoVentaController.lbEmpresa.value')}" sort="auto(empresa)"/>
|
align="right"
|
||||||
|
label="${c:l('editarPuntoVentaController.lbEmpresa.value')}"
|
||||||
|
sort="auto(empresa)" />
|
||||||
|
|
||||||
<listheader image="/gui/img/create_doc.gif" align="right"
|
<listheader image="/gui/img/create_doc.gif"
|
||||||
label="${c:l('editarPuntoVentaController.intervalofechamento.label')}" sort="auto(intervalofechamento)"/>
|
align="right"
|
||||||
|
label="${c:l('editarPuntoVentaController.intervalofechamento.label')}"
|
||||||
|
sort="auto(intervalofechamento)" />
|
||||||
|
|
||||||
</listhead>
|
</listhead>
|
||||||
</listbox>
|
</listbox>
|
||||||
|
|
Loading…
Reference in New Issue