Merge pull request 'fixes bug#AL-4204' (!569) from AL-4204 into master
Reviewed-on: adm/VentaBoletosAdm#569 Reviewed-by: Julio Heredia <julio@rjconsultores.com.br>master 1.95.0
commit
f331c58ae0
6
pom.xml
6
pom.xml
|
@ -4,12 +4,12 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>br.com.rjconsultores</groupId>
|
||||
<artifactId>ventaboletosadm</artifactId>
|
||||
<version>1.94.1</version>
|
||||
<version>1.95.0</version>
|
||||
<packaging>war</packaging>
|
||||
|
||||
<properties>
|
||||
<modelWeb.version>1.70.0</modelWeb.version>
|
||||
<flyway.version>1.53.0</flyway.version>
|
||||
<modelWeb.version>1.71.0</modelWeb.version>
|
||||
<flyway.version>1.54.0</flyway.version>
|
||||
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
||||
</properties>
|
||||
|
||||
|
|
|
@ -81,6 +81,7 @@ public class EditarConfiguracionCategoriaDatosCategoriaController extends MyGene
|
|||
private Radio rdNuncaLiberar;
|
||||
private Combobox cmbIndGeneraFeriado;
|
||||
private Combobox cmbTipoIdentifacionDoc2;
|
||||
private Combobox cmbTipoIdentifacionDoc1;
|
||||
private Label lblMsgTiempo;
|
||||
private Spinner spnHora;
|
||||
private Spinner spnMinuto;
|
||||
|
@ -148,6 +149,7 @@ public class EditarConfiguracionCategoriaDatosCategoriaController extends MyGene
|
|||
private Row rowTempoVendaAntecipadaSemKM;
|
||||
private Row rowVendaAntecipadaSemKM;
|
||||
private Row rowDocumentoPreSelecionadoDOC2;
|
||||
private Row rowDocumentoPreSelecionadoDOC1;
|
||||
|
||||
private Timebox tbTempoAteKM;
|
||||
private Timebox tbTempoMaiorKM;
|
||||
|
@ -409,6 +411,7 @@ public class EditarConfiguracionCategoriaDatosCategoriaController extends MyGene
|
|||
}
|
||||
|
||||
configurarTipoIdenticacionDoc2();
|
||||
configurarTipoIdenticacionDoc1();
|
||||
|
||||
}
|
||||
/**
|
||||
|
@ -673,17 +676,11 @@ public class EditarConfiguracionCategoriaDatosCategoriaController extends MyGene
|
|||
categoriaDescuento.setQtdeViasCupomEmbarque(qtdeViasCupomEmbarque.getValue());
|
||||
categoriaDescuento.setIndClientePcd(chkIndClientePcd.isChecked());
|
||||
categoriaDescuento.setQtdeLimiteNaoEmbarque(qtdeLimiteNaoEmbarque.getValue());
|
||||
if(chkExigedoc2pasajero.isChecked()) {
|
||||
if( cmbTipoIdentifacionDoc2.getSelectedItem() != null ) {
|
||||
TipoIdentificacionDoc tipoIdentificacionDoc2 = (TipoIdentificacionDoc) cmbTipoIdentifacionDoc2.getSelectedItem().getValue();
|
||||
if(tipoIdentificacionDoc2 != null) {
|
||||
categoriaDescuento.setTipoIdentificacionDoc2(tipoIdentificacionDoc2.getId());
|
||||
}
|
||||
}
|
||||
|
||||
setTipoDocumentoPreSelecionado(chkExigedocpasajero, cmbTipoIdentifacionDoc1, 1);
|
||||
setTipoDocumentoPreSelecionado(chkExigedoc2pasajero, cmbTipoIdentifacionDoc2, 2);
|
||||
|
||||
|
||||
}else {
|
||||
categoriaDescuento.setTipoIdentificacionDoc2(null);
|
||||
}
|
||||
|
||||
if(chkTipoCategoriaInteragem.isChecked()) {
|
||||
if(cmbCategoriasInteragem.getSelectedItem() != null && cmbCategoriasInteragem.getSelectedItem().getValue()!=null) {
|
||||
|
@ -716,6 +713,29 @@ public class EditarConfiguracionCategoriaDatosCategoriaController extends MyGene
|
|||
categoriaDescuentoList.updateItem(categoriaDescuento);
|
||||
this.closeWindow();
|
||||
}
|
||||
|
||||
private void setTipoDocumentoPreSelecionado(Checkbox chkTipoDocumento, Combobox cmbTipoIdentifacionDoc, int documento) {
|
||||
|
||||
if(chkTipoDocumento.isChecked()) {
|
||||
if( cmbTipoIdentifacionDoc.getSelectedItem() != null ) {
|
||||
TipoIdentificacionDoc tipoIdentificacionDoc = (TipoIdentificacionDoc) cmbTipoIdentifacionDoc.getSelectedItem().getValue();
|
||||
if(tipoIdentificacionDoc != null) {
|
||||
if(documento == 1) {
|
||||
categoriaDescuento.setTipoIdentificacionDoc1(tipoIdentificacionDoc.getId());
|
||||
}else if(documento == 2) {
|
||||
categoriaDescuento.setTipoIdentificacionDoc2(tipoIdentificacionDoc.getId());
|
||||
}
|
||||
}
|
||||
}
|
||||
}else {
|
||||
if(documento == 1) {
|
||||
categoriaDescuento.setTipoIdentificacionDoc1(null);
|
||||
}else if(documento == 2) {
|
||||
categoriaDescuento.setTipoIdentificacionDoc2(null);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
private Boolean validarCampoAssentosReservados() throws InterruptedException{
|
||||
//Verifica se o campo possui numeros separados por ponto e virgula.
|
||||
|
@ -865,6 +885,19 @@ public class EditarConfiguracionCategoriaDatosCategoriaController extends MyGene
|
|||
configurarTipoIdenticacionDoc2();
|
||||
}
|
||||
|
||||
public void onClick$chkExigedocpasajero(Event ev) {
|
||||
configurarTipoIdenticacionDoc2();
|
||||
}
|
||||
|
||||
public void onChange$cmbTipoIdentifacionDoc1(Event ev) {
|
||||
if(cmbTipoIdentifacionDoc1.getSelectedItem() != null && cmbTipoIdentifacionDoc1.getSelectedItem().getValue() != null) {
|
||||
TipoIdentificacionDoc tipoIdentificacionDoc = (TipoIdentificacionDoc) cmbTipoIdentifacionDoc1.getSelectedItem().getValue();
|
||||
cmbTipoIdentifacionDoc2.setValue("");;
|
||||
cmbTipoIdentifacionDoc2.setModel(new BindingListModelList(Arrays.asList(TipoIdentificacionDoc.buscarComboSegundoTipoDocumentoRemovendoDocumentoSelecionadoTipoIdentificacionDoc(tipoIdentificacionDoc)), false));
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
private void configurarTipoIdenticacionDoc2() {
|
||||
|
||||
cmbTipoIdentifacionDoc2.setModel(new BindingListModelList(Arrays.asList(TipoIdentificacionDoc.getTodos()), false));
|
||||
|
@ -880,6 +913,21 @@ public class EditarConfiguracionCategoriaDatosCategoriaController extends MyGene
|
|||
}
|
||||
}
|
||||
|
||||
private void configurarTipoIdenticacionDoc1() {
|
||||
|
||||
cmbTipoIdentifacionDoc1.setModel(new BindingListModelList(Arrays.asList(TipoIdentificacionDoc.getTodos()), false));
|
||||
|
||||
if(categoriaDescuento.getTipoIdentificacionDoc1() != null) {
|
||||
cmbTipoIdentifacionDoc1.setValue(TipoIdentificacionDoc.getDescricao(categoriaDescuento.getTipoIdentificacionDoc1().byteValue()));
|
||||
}
|
||||
|
||||
if(chkExigedocpasajero.isChecked()) {
|
||||
rowDocumentoPreSelecionadoDOC1.setVisible(true);
|
||||
}else {
|
||||
rowDocumentoPreSelecionadoDOC1.setVisible(false);
|
||||
}
|
||||
}
|
||||
|
||||
public Row getLinhaLiberarPoltronasQuandoOnibus() {
|
||||
return linhaLiberarPoltronasQuandoOnibus;
|
||||
}
|
||||
|
|
|
@ -3572,7 +3572,8 @@ editarConfiguracionCategoriaController.lblTiempoValido.ajuda = Tiempo antes de l
|
|||
editarConfiguracionCategoriaController.lblTiempoValido.value = Tiempo Válido
|
||||
editarConfiguracionCategoriaController.lblTipoCota.value = Tipo de cota
|
||||
editarConfiguracionCategoriaController.lblTipoDescuentoCompPreco.value = Tipo Descuento Componentes del Precio
|
||||
editarConfiguracionCategoriaController.lblTipoIdentifacionDoc2.value = Tipo de Documento 2 pré selecionado
|
||||
editarConfiguracionCategoriaController.lblTipoIdentifacionDoc2.value = Tipo de Documento 2 pré seleccionado
|
||||
editarConfiguracionCategoriaController.lblTipoIdentifacionDoc1.value = Tipo de Documento 1 pré seleccionado
|
||||
editarConfiguracionCategoriaController.lblTipoOcupacao.ajuda = Si se elige, el sistema validará la ocupación del cliente utilizado en la venta. (Opcional)
|
||||
editarConfiguracionCategoriaController.lblTipoOcupacao.value = ocupación
|
||||
editarConfiguracionCategoriaController.lblTiposCategoriasInteragem.value = Tipo Categoria Interagem
|
||||
|
|
|
@ -3570,6 +3570,7 @@ editarConfiguracionCategoriaController.lblTiempoValido.value = Heure valide
|
|||
editarConfiguracionCategoriaController.lblTipoCota.value = Type de quota
|
||||
editarConfiguracionCategoriaController.lblTipoDescuentoCompPreco.value = Type Composants de prix réduit
|
||||
editarConfiguracionCategoriaController.lblTipoIdentifacionDoc2.value = Type de document 2 présélectionné
|
||||
editarConfiguracionCategoriaController.lblTipoIdentifacionDoc1.value = Type de document 1 présélectionné
|
||||
editarConfiguracionCategoriaController.lblTipoOcupacao.ajuda = Si choisi, le système commence à valider l'occupation du client utilisé dans la vente. (Facultatif)
|
||||
editarConfiguracionCategoriaController.lblTipoOcupacao.value = Profession
|
||||
editarConfiguracionCategoriaController.lblTiposCategoriasInteragem.value = Interaction de catégorie de type
|
||||
|
|
|
@ -3570,6 +3570,7 @@ editarConfiguracionCategoriaController.lblTiempoValido.value = Tempo Válido
|
|||
editarConfiguracionCategoriaController.lblTipoCota.value = Tipo de Cota
|
||||
editarConfiguracionCategoriaController.lblTipoDescuentoCompPreco.value = Tipo Desconto Componentes do Preço
|
||||
editarConfiguracionCategoriaController.lblTipoIdentifacionDoc2.value = Tipo de Documento 2 pré selecionado
|
||||
editarConfiguracionCategoriaController.lblTipoIdentifacionDoc1.value = Tipo de Documento 1 pré selecionado
|
||||
editarConfiguracionCategoriaController.lblTipoOcupacao.ajuda = Se escolhido o sistema passa a validar a ocupação do cliente utilizado na venda. (Opcional)
|
||||
editarConfiguracionCategoriaController.lblTipoOcupacao.value = Ocupação
|
||||
editarConfiguracionCategoriaController.lblTiposCategoriasInteragem.value = Tipo Categoria Interagem
|
||||
|
|
|
@ -387,6 +387,13 @@
|
|||
checked="false" />
|
||||
</hbox>
|
||||
</row>
|
||||
<row id="rowDocumentoPreSelecionadoDOC1"
|
||||
visible="false">
|
||||
<label value="${c:l('editarConfiguracionCategoriaController.lblTipoIdentifacionDoc1.value')}" />
|
||||
<combobox id="cmbTipoIdentifacionDoc1"
|
||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
|
||||
mold="rounded" width="50%" />
|
||||
</row>
|
||||
<row id="rowDocumentoPreSelecionadoDOC2"
|
||||
visible="false">
|
||||
<label value="${c:l('editarConfiguracionCategoriaController.lblTipoIdentifacionDoc2.value')}" />
|
||||
|
|
Loading…
Reference in New Issue