updated behaviour

This commit is contained in:
Francesco Mangiacrapa 2023-03-13 17:14:07 +01:00
parent 2797ae5d76
commit b2f93e2167
1 changed files with 10 additions and 7 deletions

View File

@ -210,20 +210,23 @@ public class ConcessioniLifeCycleManager extends Default3PhaseManager implements
}
log.trace("Checking from LAST.. ");
//I'm ignoring the phase, this code is called on
// SUBMIT (DRAFT-> PENDING_APPROVAL)
// APPROVE (PENDING_APPROVAL -> PUBLISH
//
for (int i = 0; i < projects.size(); i++) {
Project p = projects.get(i);
//String phase = p.getLifecycleInformation().getPhase();
String phase = p.getLifecycleInformation().getPhase();
// IS TO DISPLAY EMPTY? Step into only once
// IS TO DISPLAY EMPTY? Step into only once. Indexing the first project that is in PENDING APPROVAL or PUBLISHED
if (toDisplayId.isEmpty()) {
// IF PHASE IS PENDING APPROVAL OR PUBLISHED adding toDisplayId
// if ((phase.equals(Phases.PENDING_APPROVAL) || phase.equals(Phases.PUBLISHED))) {
// toDisplayId.add(p.getId());
// }
toDisplayId.add(p.getId());
if ((phase.equals(Phases.PENDING_APPROVAL) || phase.equals(Phases.PUBLISHED))) {
toDisplayId.add(p.getId());
}
} else {