fixes bug #8046
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Model/trunk/modelWeb@61823 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
7c5ea938e5
commit
c0395c22f6
|
@ -12,6 +12,7 @@ public class Constantes {
|
||||||
public static final Long FORMA_PAGO_NOTA_CREDITO = new Long(93);
|
public static final Long FORMA_PAGO_NOTA_CREDITO = new Long(93);
|
||||||
public static final Long FORMA_PAGO_CREDITO = new Long(2);
|
public static final Long FORMA_PAGO_CREDITO = new Long(2);
|
||||||
public static final Long FORMA_PAGO_DEBITO = new Long(3);
|
public static final Long FORMA_PAGO_DEBITO = new Long(3);
|
||||||
|
public static final Long FORMA_PAGO_GERACAO_OCD = new Long(35);
|
||||||
|
|
||||||
public static final Long MVO_CANCEL_CANCELACION = new Long(31);
|
public static final Long MVO_CANCEL_CANCELACION = new Long(31);
|
||||||
public static final Long MVO_CANCEL_DEVOLUCAO = new Long(32);
|
public static final Long MVO_CANCEL_DEVOLUCAO = new Long(32);
|
||||||
|
@ -22,6 +23,7 @@ public class Constantes {
|
||||||
public static final Long MVO_CANCEL_TRANSFERENCIA = new Long(23);
|
public static final Long MVO_CANCEL_TRANSFERENCIA = new Long(23);
|
||||||
public static final Long MVO_CANCEL_BOLETO_ENTREGADO = new Long(16);
|
public static final Long MVO_CANCEL_BOLETO_ENTREGADO = new Long(16);
|
||||||
public static final Long MVO_CANCEL_BOLETO_AGRUPAMENTO = new Long(17);
|
public static final Long MVO_CANCEL_BOLETO_AGRUPAMENTO = new Long(17);
|
||||||
|
public static final Long MVO_CANCEL_GERACAO_OCD = new Long(99);
|
||||||
|
|
||||||
public static Long TPV_DIRECTO_NORMAL = new Long(1);
|
public static Long TPV_DIRECTO_NORMAL = new Long(1);
|
||||||
public static Long TPV_MANUAL = new Long(3);
|
public static Long TPV_MANUAL = new Long(3);
|
||||||
|
|
|
@ -229,6 +229,11 @@ public class Ruta implements Serializable, Comparable<Ruta> {
|
||||||
return numSecuencia;
|
return numSecuencia;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Ruta(Integer rutaId) {
|
||||||
|
this();
|
||||||
|
this.rutaId = rutaId;
|
||||||
|
}
|
||||||
|
|
||||||
public Integer getRutaId() {
|
public Integer getRutaId() {
|
||||||
return rutaId;
|
return rutaId;
|
||||||
}
|
}
|
||||||
|
|
|
@ -268,7 +268,13 @@ public class ConferenciaComissaoServiceImpl implements ConferenciaComissaoServic
|
||||||
boletoComissao.isBilheteAbertoDevolvido() ||
|
boletoComissao.isBilheteAbertoDevolvido() ||
|
||||||
boletoComissao.isBilheteAbertoDevolvidoTrocado() ||
|
boletoComissao.isBilheteAbertoDevolvidoTrocado() ||
|
||||||
boletoComissao.isBilheteEntregaGapDevolvido() ||
|
boletoComissao.isBilheteEntregaGapDevolvido() ||
|
||||||
boletoComissao.isBilheteEntregaGapTrocado()) {
|
boletoComissao.isBilheteEntregaGapTrocado() ||
|
||||||
|
boletoComissao.isBilheteAbertoDevolvidoComOcd() ||
|
||||||
|
boletoComissao.isBilheteEntregaGapDevolvidoComOcd() ||
|
||||||
|
boletoComissao.isBilheteNormalDevolvidoComOcd() ||
|
||||||
|
boletoComissao.isBilheteNormalTransferidoDevolvidoComOcd() ||
|
||||||
|
boletoComissao.isBilheteNormalTrocadoDevolvidoComOcd() ||
|
||||||
|
boletoComissao.isBilheteTrocadoDevolvidoComOcd()) {
|
||||||
|
|
||||||
boletoComissao.setExigeConferenciaDevolvido(boletoComissao.getIndcarboletosdevolvidosconf() != null && !boletoComissao.getIndcarboletosdevolvidosconf());
|
boletoComissao.setExigeConferenciaDevolvido(boletoComissao.getIndcarboletosdevolvidosconf() != null && !boletoComissao.getIndcarboletosdevolvidosconf());
|
||||||
|
|
||||||
|
@ -321,7 +327,9 @@ public class ConferenciaComissaoServiceImpl implements ConferenciaComissaoServic
|
||||||
Set<BoletoComissao> boletos = new HashSet<BoletoComissao>();
|
Set<BoletoComissao> boletos = new HashSet<BoletoComissao>();
|
||||||
for (BoletoComissao boletoComissao : boletoComissaos) {
|
for (BoletoComissao boletoComissao : boletoComissaos) {
|
||||||
if (boletoComissao.isBilheteGapDevolvido() ||
|
if (boletoComissao.isBilheteGapDevolvido() ||
|
||||||
boletoComissao.isBilheteGapTrocado()) {
|
boletoComissao.isBilheteGapTrocado() ||
|
||||||
|
boletoComissao.isBilheteGapDevolvidoComOcd() ||
|
||||||
|
boletoComissao.isBilheteGapTrocadoDevolvidoComOcd()) {
|
||||||
|
|
||||||
if (comEmpConferencia != null) {
|
if (comEmpConferencia != null) {
|
||||||
boletoComissao.setExigeConferenciaAba(comEmpConferencia.getIndgapdevolvido());
|
boletoComissao.setExigeConferenciaAba(comEmpConferencia.getIndgapdevolvido());
|
||||||
|
|
|
@ -413,7 +413,7 @@ public class BoletoComissao {
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isOcd() {
|
public boolean isOcd() {
|
||||||
return getOcdId() != null && isStatusCancelado() && isMotivocancelacionDevolvido();
|
return getOcdId() != null && isStatusCancelado();
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getNombusuario() {
|
public String getNombusuario() {
|
||||||
|
@ -611,6 +611,11 @@ public class BoletoComissao {
|
||||||
&& getMotivoCancelacionId() == Constantes.MVO_CANCEL_CHECKIN.intValue();
|
&& getMotivoCancelacionId() == Constantes.MVO_CANCEL_CHECKIN.intValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isMotivocancelacionGeracaoOcd() {
|
||||||
|
return !isSemMotivocancelacion()
|
||||||
|
&& getMotivoCancelacionId() == Constantes.MVO_CANCEL_GERACAO_OCD.intValue();
|
||||||
|
}
|
||||||
|
|
||||||
/** ABA BILHETE MANUAL */
|
/** ABA BILHETE MANUAL */
|
||||||
public boolean isBilhetesManualVendido() {
|
public boolean isBilhetesManualVendido() {
|
||||||
return isVendaBilheteManual(getTipoVenta()) && isStatusVendido();
|
return isVendaBilheteManual(getTipoVenta()) && isStatusVendido();
|
||||||
|
@ -625,6 +630,7 @@ public class BoletoComissao {
|
||||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTransferido()) // Venda transferida
|
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTransferido()) // Venda transferida
|
||||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCancelado()) // Venda cancelada
|
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCancelado()) // Venda cancelada
|
||||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionDevolvido()) // Venda devolvida
|
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionDevolvido()) // Venda devolvida
|
||||||
|
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionGeracaoOcd()) // Venda devolvida com OCD
|
||||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionAgrupamento() && isBoletoOriginal()) // Agrupamento de corrida
|
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionAgrupamento() && isBoletoOriginal()) // Agrupamento de corrida
|
||||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCheckin()) // Venda normal Checkin
|
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCheckin()) // Venda normal Checkin
|
||||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCheckin()) // Venda troca Checkin
|
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCheckin()) // Venda troca Checkin
|
||||||
|
@ -632,7 +638,9 @@ public class BoletoComissao {
|
||||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isSemMotivocancelacion()) // Novo bilhete da troca
|
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isSemMotivocancelacion()) // Novo bilhete da troca
|
||||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusVendido() && isSemMotivocancelacion()) // Novo bilhete de agrupamento de corrida
|
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusVendido() && isSemMotivocancelacion()) // Novo bilhete de agrupamento de corrida
|
||||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido()) // Novo bilhete da troca devolvido
|
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido()) // Novo bilhete da troca devolvido
|
||||||
|
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionGeracaoOcd()) // Novo bilhete da troca devolvido com OCD
|
||||||
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado()) // Novo bilhete transferido devolvido
|
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado()) // Novo bilhete transferido devolvido
|
||||||
|
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionGeracaoOcd()) // Novo bilhete transferido devolvido com OCD
|
||||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido()) // Novo bilhete da troca cancelado
|
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido()) // Novo bilhete da troca cancelado
|
||||||
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado()) // Novo bilhete transferido cancelado
|
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado()) // Novo bilhete transferido cancelado
|
||||||
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusEntregue() && isSemMotivocancelacion()); // bilhete transferido entregue
|
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusEntregue() && isSemMotivocancelacion()); // bilhete transferido entregue
|
||||||
|
@ -679,11 +687,21 @@ public class BoletoComissao {
|
||||||
return isVendaBilheteAberto(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado();
|
return isVendaBilheteAberto(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** ABA BILHETE DEVOLVIDO */
|
||||||
|
public boolean isBilheteAbertoDevolvidoComOcd() {
|
||||||
|
return isVendaBilheteConfirmaAberto(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionGeracaoOcd();
|
||||||
|
}
|
||||||
|
|
||||||
/** ABA BILHETE DEVOLVIDO */
|
/** ABA BILHETE DEVOLVIDO */
|
||||||
public boolean isBilheteNormalDevolvido() {
|
public boolean isBilheteNormalDevolvido() {
|
||||||
return isVendaBilheteNormal(getTipoVenta()) && isMotivocancelacionDevolvido() && isStatusCancelado();
|
return isVendaBilheteNormal(getTipoVenta()) && isMotivocancelacionDevolvido() && isStatusCancelado();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** ABA BILHETE DEVOLVIDO */
|
||||||
|
public boolean isBilheteNormalDevolvidoComOcd() {
|
||||||
|
return isVendaBilheteNormal(getTipoVenta()) && isMotivocancelacionGeracaoOcd() && isStatusCancelado();
|
||||||
|
}
|
||||||
|
|
||||||
/** ABA BILHETE CANCELADO */
|
/** ABA BILHETE CANCELADO */
|
||||||
public boolean isBilheteNormalCancelado() {
|
public boolean isBilheteNormalCancelado() {
|
||||||
return isVendaBilheteNormal(getTipoVenta()) && isMotivocancelacionCancelado() && isStatusCancelado();
|
return isVendaBilheteNormal(getTipoVenta()) && isMotivocancelacionCancelado() && isStatusCancelado();
|
||||||
|
@ -699,6 +717,16 @@ public class BoletoComissao {
|
||||||
return isVendaBilheteTroca(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado();
|
return isVendaBilheteTroca(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** ABA BILHETE DEVOLVIDO */
|
||||||
|
public boolean isBilheteNormalTrocadoDevolvidoComOcd() {
|
||||||
|
return isVendaBilheteTroca(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionGeracaoOcd();
|
||||||
|
}
|
||||||
|
|
||||||
|
/** ABA BILHETE DEVOLVIDO */
|
||||||
|
public boolean isBilheteTrocadoDevolvidoComOcd() {
|
||||||
|
return isVendaBilheteTroca(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionGeracaoOcd();
|
||||||
|
}
|
||||||
|
|
||||||
/** ABA BILHETE DEVOLVIDO */
|
/** ABA BILHETE DEVOLVIDO */
|
||||||
public boolean isBilheteNormalTransferidoDevolvido() {
|
public boolean isBilheteNormalTransferidoDevolvido() {
|
||||||
return isVendaBilheteTransferencia(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionDevolvido();
|
return isVendaBilheteTransferencia(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionDevolvido();
|
||||||
|
@ -709,6 +737,11 @@ public class BoletoComissao {
|
||||||
return isVendaBilheteTransferencia(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado();
|
return isVendaBilheteTransferencia(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** ABA BILHETE DEVOLVIDO */
|
||||||
|
public boolean isBilheteNormalTransferidoDevolvidoComOcd() {
|
||||||
|
return isVendaBilheteTransferencia(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionGeracaoOcd();
|
||||||
|
}
|
||||||
|
|
||||||
/** ABA BILHETE CANCELADO */
|
/** ABA BILHETE CANCELADO */
|
||||||
public boolean isBilheteNormalTrocadoCancelado() {
|
public boolean isBilheteNormalTrocadoCancelado() {
|
||||||
return isVendaBilheteTroca(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionCancelado();
|
return isVendaBilheteTroca(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionCancelado();
|
||||||
|
@ -743,6 +776,12 @@ public class BoletoComissao {
|
||||||
&& isStatusCancelado() && isSemNumFolioSistema();
|
&& isStatusCancelado() && isSemNumFolioSistema();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** ABA GAP DEVOLVIDO */
|
||||||
|
public boolean isBilheteGapTrocadoDevolvidoComOcd() {
|
||||||
|
return isVendaGap(getTipoVenta()) && isMotivocancelacionGeracaoOcd()
|
||||||
|
&& isStatusCancelado() && isSemNumFolioSistema();
|
||||||
|
}
|
||||||
|
|
||||||
/** ABA GAP CANCELADO */
|
/** ABA GAP CANCELADO */
|
||||||
public boolean isBilheteGapTrocadoCancelado() {
|
public boolean isBilheteGapTrocadoCancelado() {
|
||||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionCancelado()
|
return isVendaGap(getTipoVenta()) && isMotivocancelacionCancelado()
|
||||||
|
@ -761,6 +800,12 @@ public class BoletoComissao {
|
||||||
&& isStatusCancelado() && isSemNumFolioSistema();
|
&& isStatusCancelado() && isSemNumFolioSistema();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** ABA GAP DEVOLVIDO */
|
||||||
|
public boolean isBilheteGapDevolvidoComOcd() {
|
||||||
|
return isVendaGap(getTipoVenta()) && isMotivocancelacionGeracaoOcd()
|
||||||
|
&& isStatusCancelado() && isSemNumFolioSistema();
|
||||||
|
}
|
||||||
|
|
||||||
/** ABA BILHETE VENDIDO */
|
/** ABA BILHETE VENDIDO */
|
||||||
public boolean isBilheteEntregaGap() {
|
public boolean isBilheteEntregaGap() {
|
||||||
return isVendaGap(getTipoVenta()) && isStatusEntregue() && isComNumFolioSistema();
|
return isVendaGap(getTipoVenta()) && isStatusEntregue() && isComNumFolioSistema();
|
||||||
|
@ -778,6 +823,12 @@ public class BoletoComissao {
|
||||||
&& isMotivocancelacionDevolvido() && isComNumFolioSistema();
|
&& isMotivocancelacionDevolvido() && isComNumFolioSistema();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** ABA BILHETE DEVOLVIDO */
|
||||||
|
public boolean isBilheteEntregaGapDevolvidoComOcd() {
|
||||||
|
return isVendaGap(getTipoVenta()) && isStatusCancelado()
|
||||||
|
&& isMotivocancelacionGeracaoOcd() && isComNumFolioSistema();
|
||||||
|
}
|
||||||
|
|
||||||
/** ABA BILHETE CANCELADO */
|
/** ABA BILHETE CANCELADO */
|
||||||
public boolean isBilheteEntregaGapCancelado() {
|
public boolean isBilheteEntregaGapCancelado() {
|
||||||
return isVendaGap(getTipoVenta()) && isStatusCancelado()
|
return isVendaGap(getTipoVenta()) && isStatusCancelado()
|
||||||
|
|
Loading…
Reference in New Issue