fixed bug #7837: Corrigido o filtro que mostra bilhetes agrupados
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Model/trunk/modelWeb@59646 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
2f2319b53d
commit
a14b4d6be3
File diff suppressed because it is too large
Load Diff
|
@ -3,9 +3,7 @@ package com.rjconsultores.ventaboletos.vo.comissao;
|
|||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.Set;
|
||||
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
|
||||
import com.rjconsultores.ventaboletos.constantes.Constantes;
|
||||
import com.rjconsultores.ventaboletos.constantes.DescricaoTipoVenta;
|
||||
import com.rjconsultores.ventaboletos.enums.IndStatusBoleto;
|
||||
|
@ -15,12 +13,15 @@ import com.rjconsultores.ventaboletos.utilerias.DateUtil;
|
|||
public class BoletoComissao {
|
||||
|
||||
private Long boletoId;
|
||||
private Long boletoOriginalId;
|
||||
private Integer empresaId;
|
||||
private Integer puntoVentaId;
|
||||
private String datavenda;
|
||||
private Integer tipoVenta;
|
||||
private String indstatusboleto;
|
||||
private Integer motivoCancelacionId;
|
||||
private Integer motivoCancelacionOriginal1;
|
||||
private Integer motivoCancelacionOriginal2;
|
||||
private String descmotivocancelacion;
|
||||
private BigDecimal valorpagado;
|
||||
private BigDecimal seguro;
|
||||
|
@ -65,6 +66,7 @@ public class BoletoComissao {
|
|||
private boolean conferido;
|
||||
|
||||
private Date feccorrida;
|
||||
|
||||
private Integer corridaId;
|
||||
|
||||
public Integer getEmpresaId() {
|
||||
|
@ -187,6 +189,14 @@ public class BoletoComissao {
|
|||
this.boletoId = boletoId;
|
||||
}
|
||||
|
||||
public void setBoletoOriginalId(Long boletoOriginalId) {
|
||||
this.boletoOriginalId = boletoOriginalId;
|
||||
}
|
||||
|
||||
public Long getBoletoOriginalId() {
|
||||
return boletoOriginalId;
|
||||
}
|
||||
|
||||
public String getNumAsiento() {
|
||||
return numAsiento;
|
||||
}
|
||||
|
@ -285,7 +295,8 @@ public class BoletoComissao {
|
|||
if (getBoletoId() == null) {
|
||||
if (other.getBoletoId() != null)
|
||||
return false;
|
||||
} else if (!getBoletoId().equals(other.getBoletoId()))
|
||||
}
|
||||
else if (!getBoletoId().equals(other.getBoletoId()))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
@ -355,14 +366,12 @@ public class BoletoComissao {
|
|||
}
|
||||
|
||||
public BigDecimal getTotal() {
|
||||
BigDecimal total = BigDecimal.ZERO;
|
||||
total = total.add(getValorpagado())
|
||||
.add(getEmbarque())
|
||||
.add(getSeguro())
|
||||
.add(getPedagio())
|
||||
.add(getSeguro());
|
||||
|
||||
return total;
|
||||
return BigDecimal.ZERO
|
||||
.add(getValorpagado())
|
||||
.add(getEmbarque())
|
||||
.add(getSeguro())
|
||||
.add(getPedagio())
|
||||
.add(getSeguro());
|
||||
}
|
||||
|
||||
public String getDescTipoVenta() {
|
||||
|
@ -370,22 +379,30 @@ public class BoletoComissao {
|
|||
}
|
||||
|
||||
public String getSituacaoBilhete() {
|
||||
if(isOcd()) {
|
||||
if (isOcd()) {
|
||||
return "OCD";
|
||||
} else if((isStatusCancelado()) && (isMotivocancelacionDevolvido() || isMotivocancelacionCancelado()) && StringUtils.isNotBlank(getDescmotivocancelacion())) {
|
||||
}
|
||||
else if ((isStatusCancelado()) && (isMotivocancelacionDevolvido() || isMotivocancelacionCancelado())
|
||||
&& StringUtils.isNotBlank(getDescmotivocancelacion())) {
|
||||
return getDescmotivocancelacion();
|
||||
} else if((isStatusVendido() || isStatusCancelado()) && !isMotivocancelacionDevolvido() && !isMotivocancelacionCancelado()) {
|
||||
}
|
||||
else if ((isStatusVendido() || isStatusCancelado())
|
||||
&& !isMotivocancelacionDevolvido() && !isMotivocancelacionCancelado()) {
|
||||
if (isStatusCancelado() && isMotivocancelacionTrocado()) {
|
||||
return "B. VENDIDO TROCADO";
|
||||
} else if (isStatusVendido() && isMotivocancelacionTransferido()) {
|
||||
}
|
||||
else if (isStatusVendido() && isMotivocancelacionTransferido()) {
|
||||
return "B. VENDIDO TRANSFERIDO";
|
||||
}
|
||||
} else if(isStatusTroca()) {
|
||||
}
|
||||
else if (isStatusTroca()) {
|
||||
if (isVendaBilheteTroca(getTipoVenta()) || isVendaGap(getTipoVenta())) {
|
||||
return "B. DA TROCA";
|
||||
} else if (isVendaBilheteTransferencia(getTipoVenta()) || isVendaGap(getTipoVenta())) {
|
||||
}
|
||||
else if (isVendaBilheteTransferencia(getTipoVenta()) || isVendaGap(getTipoVenta())) {
|
||||
return "B. DA TRANSFERENCIA";
|
||||
} else if (isVendaBilheteConfirmaAberto(getTipoVenta())) {
|
||||
}
|
||||
else if (isVendaBilheteConfirmaAberto(getTipoVenta())) {
|
||||
return "CONFIRMAÇÃO ABERTO";
|
||||
}
|
||||
}
|
||||
|
@ -463,7 +480,8 @@ public class BoletoComissao {
|
|||
}
|
||||
|
||||
public Integer getTipoVentaOriginal() {
|
||||
return tipoVentaOriginal2 != null ? tipoVentaOriginal2 : tipoVentaOriginal1 != null ? tipoVentaOriginal1 : tipoVenta;
|
||||
return tipoVentaOriginal2 != null ? tipoVentaOriginal2
|
||||
: tipoVentaOriginal1 != null ? tipoVentaOriginal1 : tipoVenta;
|
||||
}
|
||||
|
||||
public Integer getTipoVentaOriginal1() {
|
||||
|
@ -490,14 +508,40 @@ public class BoletoComissao {
|
|||
this.ocdId = ocdId;
|
||||
}
|
||||
|
||||
private boolean isBoletoOriginal() {
|
||||
return boletoOriginalId == null
|
||||
&& getMotivoCancelacionOriginal() != null
|
||||
&& getMotivoCancelacionOriginal() == Constantes.MVO_CANCEL_BOLETO_AGRUPAMENTO.intValue();
|
||||
}
|
||||
|
||||
public Integer getMotivoCancelacionOriginal() {
|
||||
return motivoCancelacionOriginal2 != null ? motivoCancelacionOriginal2 : motivoCancelacionOriginal1;
|
||||
}
|
||||
|
||||
public Integer getMotivoCancelacionOriginal1() {
|
||||
return motivoCancelacionOriginal1;
|
||||
}
|
||||
|
||||
public void setMotivoCancelacionOriginal1(Integer motivoCancelacionOriginal1) {
|
||||
this.motivoCancelacionOriginal1 = motivoCancelacionOriginal1;
|
||||
}
|
||||
|
||||
public Integer getMotivoCancelacionOriginal2() {
|
||||
return motivoCancelacionOriginal2;
|
||||
}
|
||||
|
||||
public void setMotivoCancelacionOriginal2(Integer motivoCancelacionOriginal2) {
|
||||
this.motivoCancelacionOriginal2 = motivoCancelacionOriginal2;
|
||||
}
|
||||
|
||||
public boolean isVendaManual(Integer tipoVenta) {
|
||||
return tipoVenta == Constantes.TPV_MANUAL.intValue();
|
||||
}
|
||||
|
||||
public boolean isVendaGap(Integer tipoVenta) {
|
||||
return tipoVenta == Constantes.TPV_BOLETO_REMOTO.intValue() ||
|
||||
tipoVenta == Constantes.TPV_CALL_CENTER.intValue() ||
|
||||
tipoVenta == Constantes.TPV_POR_INTERNET.intValue();
|
||||
return tipoVenta == Constantes.TPV_BOLETO_REMOTO.intValue()
|
||||
|| tipoVenta == Constantes.TPV_CALL_CENTER.intValue()
|
||||
|| tipoVenta == Constantes.TPV_POR_INTERNET.intValue();
|
||||
}
|
||||
|
||||
public boolean isVendaBilheteNormal(Integer tipoVenta) {
|
||||
|
@ -541,25 +585,29 @@ public class BoletoComissao {
|
|||
}
|
||||
|
||||
public boolean isMotivocancelacionDevolvido() {
|
||||
return !isSemMotivocancelacion() && (getMotivoCancelacionId() == Constantes.MVO_CANCEL_DEVOLUCAO.intValue() ||
|
||||
getMotivoCancelacionId() == Constantes.MVO_CANCEL_DEVOLUCAO_CONTIGENCIA_50.intValue() ||
|
||||
getMotivoCancelacionId() == Constantes.MVO_CANCEL_DEVOLUCAO_CONTIGENCIA_100.intValue());
|
||||
return !isSemMotivocancelacion() && (getMotivoCancelacionId() == Constantes.MVO_CANCEL_DEVOLUCAO.intValue()
|
||||
|| getMotivoCancelacionId() == Constantes.MVO_CANCEL_DEVOLUCAO_CONTIGENCIA_50.intValue()
|
||||
|| getMotivoCancelacionId() == Constantes.MVO_CANCEL_DEVOLUCAO_CONTIGENCIA_100.intValue());
|
||||
}
|
||||
|
||||
public boolean isMotivocancelacionEntregaGap() {
|
||||
return !isSemMotivocancelacion() && getMotivoCancelacionId() == Constantes.MVO_CANCEL_BOLETO_ENTREGADO.intValue();
|
||||
return !isSemMotivocancelacion()
|
||||
&& getMotivoCancelacionId() == Constantes.MVO_CANCEL_BOLETO_ENTREGADO.intValue();
|
||||
}
|
||||
|
||||
public boolean isMotivocancelacionTransferido() {
|
||||
return !isSemMotivocancelacion() && getMotivoCancelacionId() == Constantes.MVO_CANCEL_TRANSFERENCIA.intValue();
|
||||
return !isSemMotivocancelacion()
|
||||
&& getMotivoCancelacionId() == Constantes.MVO_CANCEL_TRANSFERENCIA.intValue();
|
||||
}
|
||||
|
||||
public boolean isMotivocancelacionTrocado() {
|
||||
return !isSemMotivocancelacion() && getMotivoCancelacionId() == Constantes.MVO_CANCEL_TROCA.intValue();
|
||||
return !isSemMotivocancelacion()
|
||||
&& getMotivoCancelacionId() == Constantes.MVO_CANCEL_TROCA.intValue();
|
||||
}
|
||||
|
||||
public boolean isMotivocancelacionCheckin() {
|
||||
return !isSemMotivocancelacion() && getMotivoCancelacionId() == Constantes.MVO_CANCEL_CHECKIN.intValue();
|
||||
return !isSemMotivocancelacion()
|
||||
&& getMotivoCancelacionId() == Constantes.MVO_CANCEL_CHECKIN.intValue();
|
||||
}
|
||||
|
||||
/** ABA BILHETE MANUAL */
|
||||
|
@ -569,27 +617,32 @@ public class BoletoComissao {
|
|||
|
||||
/** ABA BILHETE VENDIDO */
|
||||
public boolean isBilheteNormalVendido() {
|
||||
return (isVendaBilheteNormal(getTipoVenta()) && isSemMotivocancelacion() && isStatusVendido()) || // Venda sem alteração
|
||||
(isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTrocado()) || // Venda trocada
|
||||
(isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTransferido()) || // Venda transferida
|
||||
(isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCancelado()) || // Venda cancelada
|
||||
(isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionDevolvido()) || // Venda devolvida
|
||||
(isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionAgrupamento()) || // Agrupamento de corrida
|
||||
(isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCheckin()) || // Venda normal Checkin
|
||||
(isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCheckin()) || // Venda troca Checkin
|
||||
(isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCheckin()) || // Venda transferencia Checkin
|
||||
(isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isSemMotivocancelacion()) || // Novo bilhete da troca
|
||||
(isVendaBilheteTroca(getTipoVenta()) && isStatusVendido() && isSemMotivocancelacion()) || // Novo bilhete de agrupamento de corrida
|
||||
(isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido()) || // Novo bilhete da troca devolvido
|
||||
(isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado()) || // Novo bilhete transferido devolvido
|
||||
(isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido()) || // Novo bilhete da troca cancelado
|
||||
(isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado()) || // Novo bilhete transferido cancelado
|
||||
(isVendaBilheteTransferencia(getTipoVenta()) && isStatusEntregue() && isSemMotivocancelacion()); // bilhete transferido entregue
|
||||
if (nombpasajero.startsWith("ABILIO"))
|
||||
System.out.println("break point");
|
||||
|
||||
return (isVendaBilheteNormal(getTipoVenta()) && isSemMotivocancelacion()
|
||||
&& isStatusVendido()) // Venda sem alteração
|
||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTrocado()) // Venda trocada
|
||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTransferido()) // Venda transferida
|
||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCancelado()) // Venda cancelada
|
||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionDevolvido()) // Venda devolvida
|
||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionAgrupamento() && isBoletoOriginal()) // Agrupamento de corrida
|
||||
|| (isVendaBilheteNormal(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCheckin()) // Venda normal Checkin
|
||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCheckin()) // Venda troca Checkin
|
||||
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCheckin()) // Venda transferencia Checkin
|
||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isSemMotivocancelacion()) // Novo bilhete da troca
|
||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusVendido() && isSemMotivocancelacion()) // Novo bilhete de agrupamento de corrida
|
||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido()) // Novo bilhete da troca devolvido
|
||||
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado()) // Novo bilhete transferido devolvido
|
||||
|| (isVendaBilheteTroca(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido()) // Novo bilhete da troca cancelado
|
||||
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado()) // Novo bilhete transferido cancelado
|
||||
|| (isVendaBilheteTransferencia(getTipoVenta()) && isStatusEntregue() && isSemMotivocancelacion()); // bilhete transferido entregue
|
||||
}
|
||||
|
||||
/** ABA BILHETE DEVOLVIDO */
|
||||
public boolean isBilheteNormalTrocado() {
|
||||
return isVendaBilheteNormal(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado();
|
||||
return isVendaBilheteNormal(getTipoVenta()) && isStatusCancelado()
|
||||
&& isMotivocancelacionTrocado();
|
||||
}
|
||||
|
||||
/** ABA BILHETE VENDIDO */
|
||||
|
@ -659,43 +712,49 @@ public class BoletoComissao {
|
|||
|
||||
/** ABA GAP VENDIDA */
|
||||
public boolean isBilheteGapVendido() {
|
||||
return (isVendaGap(getTipoVenta()) && isSemMotivocancelacion() && isStatusVendido() && isSemNumFolioSistema()) || // Gap sem alteração
|
||||
(isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionEntregaGap() && isSemNumFolioSistema()) || // Gap entregue
|
||||
(isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionEntregaGap() && isSemNumFolioSistema()) || // Gap entregue
|
||||
(isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTrocado() && isSemNumFolioSistema()) || // Gap trocada
|
||||
(isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTransferido() && isSemNumFolioSistema()) || // Gap transferida
|
||||
(isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCancelado() && isSemNumFolioSistema()) || // Gap cancelada
|
||||
(isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionDevolvido() && isSemNumFolioSistema()) || // Gap devolvida
|
||||
(isVendaGap(getTipoVenta()) && isStatusTroca() && isSemMotivocancelacion() && isSemNumFolioSistema()) || // Gap Novo bilhete da troca
|
||||
(isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido() && isSemNumFolioSistema()) || // Gap Novo bilhete da troca devolvido
|
||||
(isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado() && isSemNumFolioSistema()) || // Gap Novo bilhete transferido devolvido
|
||||
(isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido() && isSemNumFolioSistema()) || // Gap Novo bilhete da troca cancelado
|
||||
(isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado() && isSemNumFolioSistema()); // Gap Novo bilhete transferido cancelado
|
||||
return (isVendaGap(getTipoVenta()) && isSemMotivocancelacion() && isStatusVendido()
|
||||
&& isSemNumFolioSistema()) // Gap sem alteração
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionEntregaGap() && isSemNumFolioSistema()) // Gap entregue
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionEntregaGap() && isSemNumFolioSistema()) // Gap entregue
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTrocado() && isSemNumFolioSistema()) // Gap trocada
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionTransferido() && isSemNumFolioSistema()) // Gap transferida
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionCancelado() && isSemNumFolioSistema()) // Gap cancelada
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusVendido() && isMotivocancelacionDevolvido() && isSemNumFolioSistema()) // Gap devolvida
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusTroca() && isSemMotivocancelacion() && isSemNumFolioSistema()) // Gap Novo bilhete da troca
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido() && isSemNumFolioSistema()) // Gap Novo bilhete da troca devolvido
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado() && isSemNumFolioSistema()) // Gap Novo bilhete transferido devolvido
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionDevolvido() && isSemNumFolioSistema()) // Gap Novo bilhete da troca cancelado
|
||||
|| (isVendaGap(getTipoVenta()) && isStatusTroca() && isMotivocancelacionCancelado() && isSemNumFolioSistema()); // Gap Novo bilhete transferido cancelado
|
||||
}
|
||||
|
||||
/** ABA GAP DEVOLVIDO */
|
||||
public boolean isBilheteGapTrocado() {
|
||||
return isVendaGap(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado() && isSemNumFolioSistema();
|
||||
return isVendaGap(getTipoVenta()) && isStatusCancelado()
|
||||
&& isMotivocancelacionTrocado() && isSemNumFolioSistema();
|
||||
}
|
||||
|
||||
/** ABA GAP DEVOLVIDO */
|
||||
public boolean isBilheteGapTrocadoDevolvido() {
|
||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionTrocado() && isStatusCancelado() && isSemNumFolioSistema();
|
||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionTrocado()
|
||||
&& isStatusCancelado() && isSemNumFolioSistema();
|
||||
}
|
||||
|
||||
/** ABA GAP CANCELADO */
|
||||
public boolean isBilheteGapTrocadoCancelado() {
|
||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionCancelado() && isStatusCancelado() && isSemNumFolioSistema();
|
||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionCancelado()
|
||||
&& isStatusCancelado() && isSemNumFolioSistema();
|
||||
}
|
||||
|
||||
/** ABA GAP CANCELADO */
|
||||
public boolean isBilheteGapCancelado() {
|
||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionCancelado() && isStatusCancelado() && isSemNumFolioSistema();
|
||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionCancelado()
|
||||
&& isStatusCancelado() && isSemNumFolioSistema();
|
||||
}
|
||||
|
||||
/** ABA GAP DEVOLVIDO */
|
||||
public boolean isBilheteGapDevolvido() {
|
||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionDevolvido() && isStatusCancelado() && isSemNumFolioSistema();
|
||||
return isVendaGap(getTipoVenta()) && isMotivocancelacionDevolvido()
|
||||
&& isStatusCancelado() && isSemNumFolioSistema();
|
||||
}
|
||||
|
||||
/** ABA BILHETE VENDIDO */
|
||||
|
@ -705,17 +764,20 @@ public class BoletoComissao {
|
|||
|
||||
/** ABA BILHETE DEVOLVIDO */
|
||||
public boolean isBilheteEntregaGapTrocado() {
|
||||
return isVendaGap(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionTrocado() && isComNumFolioSistema();
|
||||
return isVendaGap(getTipoVenta()) && isStatusCancelado()
|
||||
&& isMotivocancelacionTrocado() && isComNumFolioSistema();
|
||||
}
|
||||
|
||||
/** ABA BILHETE DEVOLVIDO */
|
||||
public boolean isBilheteEntregaGapDevolvido() {
|
||||
return isVendaGap(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionDevolvido() && isComNumFolioSistema();
|
||||
return isVendaGap(getTipoVenta()) && isStatusCancelado()
|
||||
&& isMotivocancelacionDevolvido() && isComNumFolioSistema();
|
||||
}
|
||||
|
||||
/** ABA BILHETE CANCELADO */
|
||||
public boolean isBilheteEntregaGapCancelado() {
|
||||
return isVendaGap(getTipoVenta()) && isStatusCancelado() && isMotivocancelacionCancelado() && isComNumFolioSistema();
|
||||
return isVendaGap(getTipoVenta()) && isStatusCancelado()
|
||||
&& isMotivocancelacionCancelado() && isComNumFolioSistema();
|
||||
}
|
||||
|
||||
public boolean isStatusVendido() {
|
||||
|
@ -804,15 +866,13 @@ public class BoletoComissao {
|
|||
|
||||
public String getFeccorridaServico() {
|
||||
StringBuilder str = new StringBuilder();
|
||||
if(getFeccorrida() != null) {
|
||||
if (getFeccorrida() != null) {
|
||||
str.append(DateUtil.getStringDate(getFeccorrida(), "dd/MM"));
|
||||
}
|
||||
|
||||
if(getCorridaId() != null) {
|
||||
if(str.length() > 0) {
|
||||
if (getCorridaId() != null) {
|
||||
if (str.length() > 0) {
|
||||
str.append(" - ");
|
||||
}
|
||||
|
||||
str.append(getCorridaId());
|
||||
}
|
||||
|
||||
|
@ -820,36 +880,34 @@ public class BoletoComissao {
|
|||
}
|
||||
|
||||
public boolean isBilheteGap() {
|
||||
return isBilheteGapVendido() ||
|
||||
isBilheteGapCancelado() ||
|
||||
isBilheteGapTrocado() ||
|
||||
isBilheteGapTrocadoCancelado() ||
|
||||
isBilheteGapTrocadoDevolvido();
|
||||
return isBilheteGapVendido()
|
||||
|| isBilheteGapCancelado()
|
||||
|| isBilheteGapTrocado()
|
||||
|| isBilheteGapTrocadoCancelado()
|
||||
|| isBilheteGapTrocadoDevolvido();
|
||||
}
|
||||
|
||||
public boolean isTotalizarFormapago() {
|
||||
boolean totalizar = isTotalizarTipovenda();
|
||||
if(totalizar) {
|
||||
if (totalizar) {
|
||||
totalizar = !isOcd();
|
||||
}
|
||||
return totalizar;
|
||||
}
|
||||
|
||||
private boolean isTotalizarTipovenda() {
|
||||
return isBilhetesManualVendido() ||
|
||||
isBilheteNormalVendido() ||
|
||||
isBilheteNormalTrocado() ||
|
||||
isBilheteNormalTrocadoCancelado() ||
|
||||
isBilheteNormalTrocadoDevolvido() ||
|
||||
isBilheteNormalCancelado() ||
|
||||
isBilheteNormalDevolvido() ||
|
||||
isBilheteAberto() ||
|
||||
isBilheteGapCancelado() ||
|
||||
isBilheteGapDevolvido() ||
|
||||
isBilheteGapVendido() ||
|
||||
isBilheteGapTrocadoCancelado() ||
|
||||
isBilheteGapTrocadoDevolvido();
|
||||
|
||||
return isBilhetesManualVendido()
|
||||
|| isBilheteNormalVendido()
|
||||
|| isBilheteNormalTrocado()
|
||||
|| isBilheteNormalTrocadoCancelado()
|
||||
|| isBilheteNormalTrocadoDevolvido()
|
||||
|| isBilheteNormalCancelado()
|
||||
|| isBilheteNormalDevolvido()
|
||||
|| isBilheteAberto()
|
||||
|| isBilheteGapCancelado()
|
||||
|| isBilheteGapDevolvido()
|
||||
|| isBilheteGapVendido()
|
||||
|| isBilheteGapTrocadoCancelado()
|
||||
|| isBilheteGapTrocadoDevolvido();
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in New Issue