Merge remote-tracking branch 'origin/develop' into develop
This commit is contained in:
@@ -508,14 +508,18 @@ public class GiacenzaService {
|
||||
}
|
||||
|
||||
public List<GiacenzaDTO> retrieveGiacenza(String codMdep) throws Exception {
|
||||
String codMdepNew = setupGest.getSetupDepo("DATI_AZIENDA", "GIACENZA_DA_INV", "REPLACE_DEPO", codMdep);
|
||||
|
||||
String sql = Query.format(
|
||||
"SELECT cod_mdep FROM stb_gest_setup_depo WHERE gest_name = %s AND section = %s AND key_section = %S AND value = %S",
|
||||
"DATI_AZIENDA", "GIACENZA_DA_INV", "REPLACE_DEPO", codMdep);
|
||||
String codMdepNew = UtilityDB.executeSimpleQueryOnlyFirstRowFirstColumn(multiDBTransactionManager.getPrimaryConnection(), sql);
|
||||
String whereCond = UtilityDB.valueToString(codMdep);
|
||||
|
||||
if (codMdepNew != null) {
|
||||
whereCond += ", " + UtilityDB.valueToString(codMdepNew);
|
||||
}
|
||||
|
||||
String sql = "WITH art AS (SELECT mtb_aart.cod_mart AS cod_mart,\n" +
|
||||
sql = "WITH art AS (SELECT mtb_aart.cod_mart AS cod_mart,\n" +
|
||||
" IIF(mtb_aart.articolo_composto = 'S'\n" +
|
||||
" AND mtb_comp.cod_comp IS NOT NULL, mtb_comp.cod_comp, mtb_aart.cod_mart) AS cod_mart_mov,\n" +
|
||||
" ISNULL(mtb_comp.qta_std, 1) AS qta_std\n" +
|
||||
|
||||
Reference in New Issue
Block a user