Finish Hotfix-100
All checks were successful
IntegryManagementSystem_Multi/pipeline/head This commit looks good
All checks were successful
IntegryManagementSystem_Multi/pipeline/head This commit looks good
This commit is contained in:
@@ -116,11 +116,11 @@ public class SalesRules extends QueryRules {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (vtbListData.getCheckDataFine() != null && vtbListData.getCheckDataFine()) {
|
if (vtbListData.getCheckDataFine() != null && vtbListData.getCheckDataFine()) {
|
||||||
LocalDate dataFineOld = UtilityDB.executeSimpleQueryOnlyFirstRowFirstColumn(
|
Date dataFineOld = UtilityDB.executeSimpleQueryOnlyFirstRowFirstColumn(
|
||||||
conn,
|
conn,
|
||||||
Query.format("SELECT data_fine FROM vtb_list_data WHERE cod_vlis = %s AND versione = %S", vtbListData.getCodVlis(), vtbListData.getVersione()));
|
Query.format("SELECT data_fine FROM vtb_list_data WHERE cod_vlis = %s AND versione = %S", vtbListData.getCodVlis(), vtbListData.getVersione()));
|
||||||
|
|
||||||
if (dataFineOld != null && dataFine.isAfter(dataFineOld))
|
if (dataFineOld != null && dataFine.isAfter(UtilityLocalDate.localDateFromDate(dataFineOld)))
|
||||||
throw new Exception("Impossibile posticipare la data fine di una promozione.");
|
throw new Exception("Impossibile posticipare la data fine di una promozione.");
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user