fixed bug #8979
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@68654 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
55e50bd2da
commit
5936f2ce79
|
@ -76,6 +76,7 @@ import com.rjconsultores.ventaboletos.entidad.EmpresaContaBancaria;
|
|||
import com.rjconsultores.ventaboletos.entidad.FechamentoParamptovta;
|
||||
import com.rjconsultores.ventaboletos.entidad.FormaPago;
|
||||
import com.rjconsultores.ventaboletos.entidad.FormaPagoDet;
|
||||
import com.rjconsultores.ventaboletos.entidad.HistoricoPuntoVenta;
|
||||
import com.rjconsultores.ventaboletos.entidad.InstiFinanceira;
|
||||
import com.rjconsultores.ventaboletos.entidad.Moneda;
|
||||
import com.rjconsultores.ventaboletos.entidad.Nodo;
|
||||
|
@ -126,6 +127,7 @@ import com.rjconsultores.ventaboletos.utilerias.ApplicationProperties;
|
|||
import com.rjconsultores.ventaboletos.utilerias.DateUtil;
|
||||
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
|
||||
import com.rjconsultores.ventaboletos.web.gui.controladores.configuracioneccomerciales.FechamentoParamptovtaListItemRenderer;
|
||||
import com.rjconsultores.ventaboletos.web.gui.controladores.configuracioneccomerciales.PuntoVendaHistoricoBloqueioListItemRenderer;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.ConstraintNoEmpty;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.MyComboboxPuntoVenta;
|
||||
|
@ -219,6 +221,7 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
private MyListbox ptovtaCatIndList;
|
||||
private MyListbox fechamentoParamptovtaList;
|
||||
private MyTextbox txtDiasemtransito;
|
||||
private MyListbox ptovtaHistoricoList;
|
||||
|
||||
private List<Categoria> lsCategoriaBloquear;
|
||||
|
||||
|
@ -243,6 +246,7 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
private List<PtovtaEstoque> lsEstoque;
|
||||
private List<PtovtaComissao> lsPtovtaComissao;
|
||||
private List<String> lsLogFiles;
|
||||
private List<HistoricoPuntoVenta> lsHistoricoPuntoVenda;
|
||||
private Radio radDatosTarjetaSi;
|
||||
private Radio radDatosTarjetaNo;
|
||||
private Radio radAprobacionAutorizado;
|
||||
|
@ -386,6 +390,7 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
private Row rowDateFechamento;
|
||||
private String logFileSelected;
|
||||
private Textbox descCorreo;
|
||||
private String statusAprobacionInicial = "";
|
||||
|
||||
private static final String EMAIL_PATTERN =
|
||||
"^[_A-Za-z0-9-\\+]+(\\.[_A-Za-z0-9-]+)*@"
|
||||
|
@ -446,6 +451,8 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
lsLogFiles = getLogFiles();
|
||||
puntoVenta = (PuntoVenta) Executions.getCurrent().getArg().get("puntoVenta");
|
||||
|
||||
statusAprobacionInicial = puntoVenta.getStatusaprobacion();
|
||||
|
||||
super.doAfterCompose(comp);
|
||||
|
||||
cmbBanco.addEventListener("onAfterRender", new org.zkoss.zk.ui.event.EventListener() {
|
||||
|
@ -462,6 +469,7 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
ptovtaPtoVtaCheckinList.setItemRenderer(new RenderParadaPtoVtaCheckin());
|
||||
ptovtaPtoVtaSeguroList.setItemRenderer(new RenderPtoVtaSeguro());
|
||||
ptovtaCatIndList.setItemRenderer(new RenderPtovtaCatInd());
|
||||
ptovtaHistoricoList.setItemRenderer(new PuntoVendaHistoricoBloqueioListItemRenderer());
|
||||
|
||||
ptovtaComissaoList.setItemRenderer(new RenderPtovtaComissao());
|
||||
ptovtaComissaoList.addEventListener("onDoubleClick", new EventListener() {
|
||||
|
@ -489,6 +497,7 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
ptovtaPtoVtaCheckinList.setData(puntoVenta.getPtovtaCheckinList());
|
||||
ptovtaPtoVtaSeguroList.setData(puntoVenta.getPtovtaSeguroList());
|
||||
ptovtaCatIndList.setData(puntoVenta.getPtovtaCatIndList());
|
||||
ptovtaHistoricoList.setData(puntoVenta.getHistoricoPuntoVentaList());
|
||||
|
||||
if (puntoVenta.getColonia() != null) {
|
||||
cmbCiudad.setText(puntoVenta.getColonia().getCiudad().getNombciudad());
|
||||
|
@ -747,6 +756,8 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
puntoVenta.setLsPtovtaUsuarioBancario(new ArrayList<PtoVtaUsuarioBancario>());
|
||||
}
|
||||
|
||||
|
||||
|
||||
lsPtovtaUsuarioBancario = puntoVenta.getLsPtovtaUsuarioBancario();
|
||||
ptovtaUsuarioBancarioList.setData(lsPtovtaUsuarioBancario);
|
||||
|
||||
|
@ -1538,6 +1549,19 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
puntoVenta.setStatusaprobacion("L");
|
||||
}
|
||||
|
||||
if(!puntoVenta.getStatusaprobacion().equals(statusAprobacionInicial)){
|
||||
HistoricoPuntoVenta h = new HistoricoPuntoVenta();
|
||||
h.setPuntoVenta(puntoVenta);
|
||||
|
||||
h.setIndBloqueio(!puntoVenta.getStatusaprobacion().equals("A"));
|
||||
h.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
|
||||
h.setActivo(true);
|
||||
h.setFecmodif(new Date());
|
||||
h.setFecBloqueio(new Date());
|
||||
|
||||
puntoVenta.getHistoricoPuntoVentaList().add(h);
|
||||
}
|
||||
|
||||
if (puntoVenta.getIndIntegracion() == null) {
|
||||
puntoVenta.setIndIntegracion(TipoRetorno.PENDENTE.getValor());
|
||||
}
|
||||
|
@ -3209,4 +3233,12 @@ public class EditarPuntoVentaController extends MyGenericForwardComposer {
|
|||
this.ckValidarTempoParaImpressao = ckValidarTempoParaImpressao;
|
||||
}
|
||||
|
||||
public MyListbox getPtovtaHistoricoList() {
|
||||
return ptovtaHistoricoList;
|
||||
}
|
||||
|
||||
public void setPtovtaHistoricoList(MyListbox ptovtaHistoricoList) {
|
||||
this.ptovtaHistoricoList = ptovtaHistoricoList;
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,29 @@
|
|||
package com.rjconsultores.ventaboletos.web.gui.controladores.configuracioneccomerciales;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
|
||||
import org.zkoss.zul.Listcell;
|
||||
import org.zkoss.zul.Listitem;
|
||||
import org.zkoss.zul.ListitemRenderer;
|
||||
|
||||
import com.rjconsultores.ventaboletos.entidad.HistoricoPuntoVenta;
|
||||
|
||||
public class PuntoVendaHistoricoBloqueioListItemRenderer implements ListitemRenderer {
|
||||
|
||||
@Override
|
||||
public void render(Listitem lstm, Object o) throws Exception {
|
||||
|
||||
HistoricoPuntoVenta h = (HistoricoPuntoVenta) o;
|
||||
|
||||
Listcell lc = new Listcell(h.getIndBloqueio() ? "Bloqueio" : "Desbloqueio");
|
||||
lc.setParent(lstm);
|
||||
|
||||
SimpleDateFormat formato = new SimpleDateFormat("dd/MM/yyyy");
|
||||
|
||||
lc = new Listcell(formato.format(h.getFecBloqueio()));
|
||||
lc.setParent(lstm);
|
||||
|
||||
lstm.setAttribute("data", lc);
|
||||
}
|
||||
|
||||
}
|
|
@ -445,6 +445,7 @@
|
|||
<value>com.rjconsultores.ventaboletos.entidad.NotaCreditoVendaPacote</value>
|
||||
<value>com.rjconsultores.ventaboletos.entidad.OCDDatosPagamento</value>
|
||||
<value>com.rjconsultores.ventaboletos.entidad.Boleto</value>
|
||||
<value>com.rjconsultores.ventaboletos.entidad.HistoricoPuntoVenta</value>
|
||||
</list>
|
||||
</property>
|
||||
|
||||
|
|
|
@ -1110,6 +1110,7 @@ editarPuntoVentaController.lbNumEdirecion.value = Dirección
|
|||
editarPuntoVentaController.lbIndDatosTarjeta.value = Base de datos
|
||||
editarPuntoVentaController.lbNodo.value = Servidor
|
||||
editarPuntoVentaController.lbEmpresa.value = Empresa
|
||||
editarPuntoVentaController.lbDataBloqueio.value = Data Bloqueio
|
||||
editarPuntoVentaController.lbEmpresaContaBancaria.value = Conta Bancária
|
||||
editarPuntoVentaController.lbEmpresaBloqueada.value = Bloqueada
|
||||
editarPuntoVentaController.lbMostrarCaja.value = Mostrar Caja en el Cierre
|
||||
|
@ -1119,12 +1120,15 @@ editarPuntoVentaController.lbparada.value = Parada
|
|||
editarPuntoVentaController.lbdataAbertura.value = Data de Apertura
|
||||
editarPuntoVentaController.lbdataFechamento.value = Data de Cerramiento
|
||||
editarPuntoVentaController.lbTpoPtoVta.value = Canal de venta
|
||||
editarPuntoVentaController.lbTipoBloqueio = Tipo
|
||||
editarPuntoVentaController.lbMoneda.value = Moneda
|
||||
editarPuntoVentaController.lbCiudad.value = Ciudad
|
||||
editarPuntoVentaController.lblInicial.value = Inicial
|
||||
editarPuntoVentaController.lblMaxCancelacion = Tiempo max. cancelación pos venta(min)
|
||||
editarPuntoVentaController.lblAdicional.value = Adicional
|
||||
editarPuntoVentaController.lbImpCompCartao.value = Imprimir el Comprobante de la Tarjeta
|
||||
editarPuntoVentaController.lbTipoBloqueio.value = Tipo
|
||||
editarPuntoVentaController.lbDataBloqueio.value = Data Bloqueio
|
||||
editarPuntoVentaController.RadSi.value.value = Si
|
||||
editarPuntoVentaController.RadNo.value = No
|
||||
editarPuntoVentaController.MSG.suscribirOK = Punto de venta se registró exitosamente
|
||||
|
@ -1198,6 +1202,7 @@ editarPuntoVentaController.erro.cpfCnpj= CPF ou CNPJ incorrecto
|
|||
editarPuntoVentaController.label.fecIntegracion=Fecha
|
||||
editarPuntoVentaController.tab.label.integracao=Integración
|
||||
editarPuntoVentaController.tab.label.integracaoag = Integración AG
|
||||
editarPuntoVentaController.tab.label.historico = Histórico Bloqueio
|
||||
editarPuntoVentaController.lbCheckSimulaIntegracion.value=Simula Integracion
|
||||
editarPuntoVentaController.lbCheckTodosPuntoVenta.value=Todos Puntos Venta
|
||||
editarPuntoVentaController.MSG.estacionVinculadaAgenciaOnDelete = Existen una o mas estaciones vinculadas a esta agencia
|
||||
|
|
|
@ -1153,6 +1153,7 @@ editarPuntoVentaController.lbNumEdirecion.value = Endereço
|
|||
editarPuntoVentaController.lbIndDatosTarjeta.value = Base de dados
|
||||
editarPuntoVentaController.lbNodo.value = Servidor
|
||||
editarPuntoVentaController.lbEmpresa.value = Empresa
|
||||
editarPuntoVentaController.lbDataBloqueio.value = Data Bloqueio
|
||||
editarPuntoVentaController.lbEmpresaContaBancaria.value = Conta Bancária
|
||||
editarPuntoVentaController.lbEmpresaBloqueada.value = Bloqueada
|
||||
editarPuntoVentaController.lbMostrarCaja.value = Exibir Caixa no Fechamento
|
||||
|
@ -1162,6 +1163,7 @@ editarPuntoVentaController.lbparada.value = Localidade
|
|||
editarPuntoVentaController.lbdataAbertura.value = Data de Abertura
|
||||
editarPuntoVentaController.lbdataFechamento.value = Data de Fechamento
|
||||
editarPuntoVentaController.lbTpoPtoVta.value = Canal de Venda
|
||||
editarPuntoVentaController.lbTipoBloqueio.value = Tipo
|
||||
editarPuntoVentaController.lbMoneda.value = Moeda
|
||||
editarPuntoVentaController.lbCiudad.value = Cidade
|
||||
editarPuntoVentaController.lblInicial.value = Inicial
|
||||
|
@ -1239,6 +1241,7 @@ editarPuntoVentaController.erro.cpfCnpj= CPF ou CNPJ incorreto
|
|||
editarPuntoVentaController.label.fecIntegracion=Data
|
||||
editarPuntoVentaController.tab.label.integracao=Integracao
|
||||
editarPuntoVentaController.tab.label.integracaoag = Integração AG
|
||||
editarPuntoVentaController.tab.label.historico = Histórico Bloqueio
|
||||
editarPuntoVentaController.lbCheckSimulaIntegracion.value=Simula Integração
|
||||
editarPuntoVentaController.lbCheckTodosPuntoVenta.value=Todas as agências
|
||||
editarPuntoVentaController.MSG.estacionVinculadaAgenciaOnDelete = Existem uma ou mais estações vinculadas à esta agência
|
||||
|
|
|
@ -76,6 +76,9 @@
|
|||
<tab
|
||||
label="${c:l('editarPuntoVentaController.tab.label.integracaoag')}"
|
||||
visible="@{winEditarPuntoVenta$composer.integracionAG}" />
|
||||
<tab
|
||||
label="${c:l('editarPuntoVentaController.tab.label.historico')}"
|
||||
/>
|
||||
|
||||
</tabs>
|
||||
|
||||
|
@ -1682,6 +1685,23 @@
|
|||
|
||||
<textbox width="100%" rows="18" id="logResultAG"/>
|
||||
</tabpanel>
|
||||
|
||||
<!-- DADOS HISTORICO -->
|
||||
<tabpanel>
|
||||
<listbox id="ptovtaHistoricoList"
|
||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyListbox"
|
||||
vflex="true" multiple="false">
|
||||
<listhead sizable="true">
|
||||
<listheader id="lhHistorico"
|
||||
image="/gui/img/create_doc.gif"
|
||||
label="${c:l('editarPuntoVentaController.lbTipoBloqueio.value')}" />
|
||||
<listheader id="lhDataAbertura"
|
||||
image="/gui/img/create_doc.gif"
|
||||
label="${c:l('editarPuntoVentaController.lbDataBloqueio.value')}" />
|
||||
</listhead>
|
||||
</listbox>
|
||||
</tabpanel>
|
||||
|
||||
</tabpanels>
|
||||
</tabbox>
|
||||
</window>
|
||||
|
|
Loading…
Reference in New Issue