Merge tag 'Biolevante_MRP_AggiuntaPriorita' into develop
Finish Biolevante_MRP_AggiuntaPriorita
This commit is contained in:
1
.idea/runConfigurations/Tomcat.xml
generated
1
.idea/runConfigurations/Tomcat.xml
generated
@@ -1,6 +1,7 @@
|
|||||||
<component name="ProjectRunConfigurationManager">
|
<component name="ProjectRunConfigurationManager">
|
||||||
<configuration default="false" name="Tomcat" type="#com.intellij.j2ee.web.tomcat.TomcatRunConfigurationFactory" factoryName="Local" APPLICATION_SERVER_NAME="Tomcat" ALTERNATIVE_JRE_ENABLED="false" ALTERNATIVE_JRE_PATH="1.8" nameIsGenerated="true">
|
<configuration default="false" name="Tomcat" type="#com.intellij.j2ee.web.tomcat.TomcatRunConfigurationFactory" factoryName="Local" APPLICATION_SERVER_NAME="Tomcat" ALTERNATIVE_JRE_ENABLED="false" ALTERNATIVE_JRE_PATH="1.8" nameIsGenerated="true">
|
||||||
<option name="COMMON_VM_ARGUMENTS" value="-Xms512m -Xmx2048m" />
|
<option name="COMMON_VM_ARGUMENTS" value="-Xms512m -Xmx2048m" />
|
||||||
|
<option name="UPDATING_POLICY" value="restart-server" />
|
||||||
<deployment>
|
<deployment>
|
||||||
<artifact name="ems-engine:war exploded">
|
<artifact name="ems-engine:war exploded">
|
||||||
<settings>
|
<settings>
|
||||||
|
|||||||
@@ -12,43 +12,64 @@ import java.util.Date;
|
|||||||
public class MrpDailyMaterialReqDetDTO {
|
public class MrpDailyMaterialReqDetDTO {
|
||||||
@JsonProperty("causale")
|
@JsonProperty("causale")
|
||||||
private String causale;
|
private String causale;
|
||||||
|
|
||||||
@JsonProperty("data_mrp")
|
@JsonProperty("data_mrp")
|
||||||
private Date dataMrp;
|
private Date dataMrp;
|
||||||
|
|
||||||
@JsonProperty("colli")
|
@JsonProperty("colli")
|
||||||
private BigDecimal colli;
|
private BigDecimal colli;
|
||||||
|
|
||||||
@JsonProperty("pedane")
|
@JsonProperty("pedane")
|
||||||
private BigDecimal pedane;
|
private BigDecimal pedane;
|
||||||
|
|
||||||
@JsonProperty("qta")
|
@JsonProperty("qta")
|
||||||
private BigDecimal qta;
|
private BigDecimal qta;
|
||||||
|
|
||||||
@JsonProperty("unt_mis")
|
@JsonProperty("unt_mis")
|
||||||
private String untMis;
|
private String untMis;
|
||||||
|
|
||||||
@JsonProperty("partita_mag")
|
@JsonProperty("partita_mag")
|
||||||
private String partitaMag;
|
private String partitaMag;
|
||||||
|
|
||||||
@JsonProperty("gestione")
|
@JsonProperty("gestione")
|
||||||
private String gestione;
|
private String gestione;
|
||||||
|
|
||||||
@JsonProperty("data_ord")
|
@JsonProperty("data_ord")
|
||||||
private Date dataOrd;
|
private Date dataOrd;
|
||||||
|
|
||||||
@JsonProperty("num_ord")
|
@JsonProperty("num_ord")
|
||||||
private Integer numOrd;
|
private Integer numOrd;
|
||||||
|
|
||||||
@JsonProperty("cod_jcom")
|
@JsonProperty("cod_jcom")
|
||||||
private String codJcom;
|
private String codJcom;
|
||||||
|
|
||||||
@JsonProperty("cod_mdep")
|
@JsonProperty("cod_mdep")
|
||||||
private String codMdep;
|
private String codMdep;
|
||||||
|
|
||||||
@JsonProperty("cod_mart")
|
@JsonProperty("cod_mart")
|
||||||
private String codMart;
|
private String codMart;
|
||||||
|
|
||||||
@JsonProperty(value = "is_ord_trasf")
|
@JsonProperty(value = "is_ord_trasf")
|
||||||
private boolean isOrdTrasf;
|
private boolean isOrdTrasf;
|
||||||
|
|
||||||
@JsonProperty(value = "flag_sospeso")
|
@JsonProperty(value = "flag_sospeso")
|
||||||
private boolean flagSospeso;
|
private boolean flagSospeso;
|
||||||
|
|
||||||
@JsonProperty("stato_partita")
|
@JsonProperty("stato_partita")
|
||||||
private String statoPartita;
|
private String statoPartita;
|
||||||
|
|
||||||
@JsonProperty("colli_pedana")
|
@JsonProperty("colli_pedana")
|
||||||
private BigDecimal colliPedana;
|
private BigDecimal colliPedana;
|
||||||
|
|
||||||
@JsonProperty("cod_tcol_UL")
|
@JsonProperty("cod_tcol_UL")
|
||||||
private String codTcolUL;
|
private String codTcolUL;
|
||||||
|
|
||||||
@JsonProperty("tipo_pedana")
|
@JsonProperty("tipo_pedana")
|
||||||
private String tipoPedana;
|
private String tipoPedana;
|
||||||
|
|
||||||
|
@JsonProperty("priorita")
|
||||||
|
private Integer Priorita = 1;
|
||||||
|
|
||||||
public String getCausale() {
|
public String getCausale() {
|
||||||
return causale;
|
return causale;
|
||||||
}
|
}
|
||||||
@@ -367,4 +388,11 @@ public class MrpDailyMaterialReqDetDTO {
|
|||||||
return getImpClie().add(getImpLav());
|
return getImpClie().add(getImpLav());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Integer getPriorita() {
|
||||||
|
return Priorita;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPriorita(Integer priorita) {
|
||||||
|
Priorita = priorita;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -64,15 +64,6 @@ public class MrpDailyMaterialReqService {
|
|||||||
List<MrpDailyMaterialReqDetDTO> mrpDailyMaterialReqDetDTO = getGiacenza(depositi, articoli, tableNameColli);
|
List<MrpDailyMaterialReqDetDTO> mrpDailyMaterialReqDetDTO = getGiacenza(depositi, articoli, tableNameColli);
|
||||||
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getGiacenza: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getGiacenza: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
||||||
|
|
||||||
mrpDailyMaterialReqDetDTO.addAll(getFabbProxOrdv(depositi, articoli));
|
|
||||||
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getFabbProxOrdv: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
|
||||||
|
|
||||||
mrpDailyMaterialReqDetDTO.addAll(getFabbProxContratti(depositi, articoli));
|
|
||||||
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getFabbProxContratti: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
|
||||||
|
|
||||||
mrpDailyMaterialReqDetDTO.addAll(getFabbProxBudget(depositi, articoli));
|
|
||||||
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getFabbProxBudget: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
|
||||||
|
|
||||||
mrpDailyMaterialReqDetDTO.addAll(getOrdiniVendita(depositi, articoli, tableNameColli));
|
mrpDailyMaterialReqDetDTO.addAll(getOrdiniVendita(depositi, articoli, tableNameColli));
|
||||||
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getOrdiniV: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getOrdiniV: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
||||||
|
|
||||||
@@ -85,6 +76,15 @@ public class MrpDailyMaterialReqService {
|
|||||||
mrpDailyMaterialReqDetDTO.addAll(getOrdiniProd(depositi, articoli, includiArrivi));
|
mrpDailyMaterialReqDetDTO.addAll(getOrdiniProd(depositi, articoli, includiArrivi));
|
||||||
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getOrdiniProd: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getOrdiniProd: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
||||||
|
|
||||||
|
mrpDailyMaterialReqDetDTO.addAll(getFabbProxOrdv(depositi, articoli));
|
||||||
|
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getFabbProxOrdv: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
||||||
|
|
||||||
|
mrpDailyMaterialReqDetDTO.addAll(getFabbProxContratti(depositi, articoli));
|
||||||
|
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getFabbProxContratti: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
||||||
|
|
||||||
|
mrpDailyMaterialReqDetDTO.addAll(getFabbProxBudget(depositi, articoli));
|
||||||
|
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getFabbProxBudget: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
||||||
|
|
||||||
mrpDailyMaterialReqDetDTO.addAll(getContrattiV(depositi, articoli));
|
mrpDailyMaterialReqDetDTO.addAll(getContrattiV(depositi, articoli));
|
||||||
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getContrattiV: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
logger.debug(MrpDailyMaterialReqService.class.getSimpleName() + " - getContrattiV: Timing " + ((new Date().getTime() - startDate.getTime()) / 1000) + " secs");
|
||||||
|
|
||||||
@@ -113,7 +113,9 @@ public class MrpDailyMaterialReqService {
|
|||||||
if (dettagliArt == null) continue;
|
if (dettagliArt == null) continue;
|
||||||
|
|
||||||
dettagliArt = Stream
|
dettagliArt = Stream
|
||||||
.of(dettagliArt).sorted(Comparator.comparing(MrpDailyMaterialReqDetDTO::isFlagSospeso)
|
.of(dettagliArt)
|
||||||
|
.sorted(Comparator.comparing(MrpDailyMaterialReqDetDTO::isFlagSospeso)
|
||||||
|
.thenComparing(MrpDailyMaterialReqDetDTO::getPriorita)
|
||||||
.thenComparing(MrpDailyMaterialReqDetDTO::getDataMrp)
|
.thenComparing(MrpDailyMaterialReqDetDTO::getDataMrp)
|
||||||
.thenComparing(MrpDailyMaterialReqDetDTO::getGestione, Comparator.nullsFirst(Comparator.naturalOrder())))
|
.thenComparing(MrpDailyMaterialReqDetDTO::getGestione, Comparator.nullsFirst(Comparator.naturalOrder())))
|
||||||
.toList();
|
.toList();
|
||||||
@@ -555,7 +557,8 @@ public class MrpDailyMaterialReqService {
|
|||||||
" Cast(getDate() as date) AS data_mrp,\n" +
|
" Cast(getDate() as date) AS data_mrp,\n" +
|
||||||
" -(mtb_part.qta_imp_prox) AS qta,\n" +
|
" -(mtb_part.qta_imp_prox) AS qta,\n" +
|
||||||
" 'NP' AS gestione,\n" +
|
" 'NP' AS gestione,\n" +
|
||||||
" mtb_part.cod_mdep\n" +
|
" mtb_part.cod_mdep,\n" +
|
||||||
|
" 2 as priorita\n" +
|
||||||
" FROM mtb_part \n" +
|
" FROM mtb_part \n" +
|
||||||
" WHERE mtb_part.qta_imp_prox IS NOT NULL\n" +
|
" WHERE mtb_part.qta_imp_prox IS NOT NULL\n" +
|
||||||
" AND mtb_part.qta_imp_prox <> 0" +
|
" AND mtb_part.qta_imp_prox <> 0" +
|
||||||
@@ -572,7 +575,8 @@ public class MrpDailyMaterialReqService {
|
|||||||
" Cast(getDate() as date) AS data_mrp,\n" +
|
" Cast(getDate() as date) AS data_mrp,\n" +
|
||||||
" -(mtb_part.qta_imp_prox_contr) AS qta,\n" +
|
" -(mtb_part.qta_imp_prox_contr) AS qta,\n" +
|
||||||
" 'CV' AS gestione,\n" +
|
" 'CV' AS gestione,\n" +
|
||||||
" mtb_part.cod_mdep\n" +
|
" mtb_part.cod_mdep,\n" +
|
||||||
|
" 3 as priorita\n" +
|
||||||
" FROM mtb_part \n" +
|
" FROM mtb_part \n" +
|
||||||
" WHERE mtb_part.qta_imp_prox_contr IS NOT NULL\n" +
|
" WHERE mtb_part.qta_imp_prox_contr IS NOT NULL\n" +
|
||||||
" AND mtb_part.qta_imp_prox_contr <> 0" +
|
" AND mtb_part.qta_imp_prox_contr <> 0" +
|
||||||
@@ -589,7 +593,8 @@ public class MrpDailyMaterialReqService {
|
|||||||
" Cast(getDate() as date) AS data_mrp,\n" +
|
" Cast(getDate() as date) AS data_mrp,\n" +
|
||||||
" -(mtb_part.qta_imp_prox_bdg) AS qta,\n" +
|
" -(mtb_part.qta_imp_prox_bdg) AS qta,\n" +
|
||||||
" 'BV' AS gestione,\n" +
|
" 'BV' AS gestione,\n" +
|
||||||
" mtb_part.cod_mdep\n" +
|
" mtb_part.cod_mdep,\n" +
|
||||||
|
" 4 as priorita\n" +
|
||||||
" FROM mtb_part \n" +
|
" FROM mtb_part \n" +
|
||||||
" WHERE mtb_part.qta_imp_prox_bdg IS NOT NULL\n" +
|
" WHERE mtb_part.qta_imp_prox_bdg IS NOT NULL\n" +
|
||||||
" AND mtb_part.qta_imp_prox_bdg <> 0" +
|
" AND mtb_part.qta_imp_prox_bdg <> 0" +
|
||||||
|
|||||||
Reference in New Issue
Block a user