Tony CHEMIT pushed to branch develop at ultreiaio / ird-t3
Commits:
-
1c264668
by Tony CHEMIT at 2018-03-08T10:28:09Z
3 changed files:
- t3-web/src/main/java/fr/ird/t3/web/actions/data/level3/ConfigureLevel3Step2Action.java
- t3-web/src/main/java/fr/ird/t3/web/actions/data/level3/Level3ConfigureAction.java
- t3-web/src/main/java/fr/ird/t3/web/actions/data/level3/Level3RunAction.java
Changes:
| ... | ... | @@ -25,6 +25,7 @@ import fr.ird.t3.actions.stratum.SchoolTypeIndeterminate; |
| 25 | 25 |
import fr.ird.t3.actions.stratum.StratumMinimumSampleCount;
|
| 26 | 26 |
import fr.ird.t3.entities.reference.Country;
|
| 27 | 27 |
import fr.ird.t3.entities.reference.CountryTopiaDao;
|
| 28 |
+import fr.ird.t3.entities.reference.SchoolTypeTopiaDao;
|
|
| 28 | 29 |
import fr.ird.t3.entities.reference.Species;
|
| 29 | 30 |
import fr.ird.t3.services.ioc.InjectDAO;
|
| 30 | 31 |
import fr.ird.t3.services.ioc.InjectDecoratedBeans;
|
| ... | ... | @@ -86,6 +87,8 @@ public class ConfigureLevel3Step2Action extends AbstractConfigureAction<Level3Co |
| 86 | 87 |
Level3Configuration configuration = getConfiguration();
|
| 87 | 88 |
log.info(String.format("Prepare with configuration %s", configuration));
|
| 88 | 89 |
injectExcept(InjectDecoratedBeans.class);
|
| 90 |
+ // on level 3, can't treat Indeterminate school type
|
|
| 91 |
+ schoolTypeIndeterminate.remove(SchoolTypeTopiaDao.SCHOOL_TYPE_INDETERMINATE_ID);
|
|
| 89 | 92 |
missingData = false;
|
| 90 | 93 |
Set<Country> sampleFlags = new LinkedHashSet<>();
|
| 91 | 94 |
Set<Country> sampleFleets = new LinkedHashSet<>();
|
| ... | ... | @@ -25,6 +25,7 @@ import fr.ird.t3.actions.stratum.SchoolTypeIndeterminate; |
| 25 | 25 |
import fr.ird.t3.actions.stratum.StratumMinimumSampleCount;
|
| 26 | 26 |
import fr.ird.t3.entities.reference.Country;
|
| 27 | 27 |
import fr.ird.t3.entities.reference.Ocean;
|
| 28 |
+import fr.ird.t3.entities.reference.SchoolTypeTopiaDao;
|
|
| 28 | 29 |
import fr.ird.t3.entities.reference.Species;
|
| 29 | 30 |
import fr.ird.t3.entities.reference.zone.ZoneStratumAwareMeta;
|
| 30 | 31 |
import fr.ird.t3.entities.reference.zone.ZoneVersion;
|
| ... | ... | @@ -85,10 +86,13 @@ public class Level3ConfigureAction extends AbstractConfigureAction<Level3Configu |
| 85 | 86 |
log.info(String.format("Prepare with configuration %s", getConfiguration()));
|
| 86 | 87 |
useSamplesOrNot = createLevel3UseSamplesOrNotMap();
|
| 87 | 88 |
useWeightCategoriesOrNot = createLevel3UseWeightCategoriesOrNotMap();
|
| 89 |
+ useWeightCategoriesInStratumOrNot = createUseWeightCategoriesInStratumOrNot();
|
|
| 88 | 90 |
// load configuration
|
| 89 | 91 |
getConfiguration();
|
| 90 | 92 |
// load decorated beans
|
| 91 | 93 |
injectOnly(InjectDecoratedBeans.class);
|
| 94 |
+ // on level 3, can't treat Indeterminate school type
|
|
| 95 |
+ schoolTypeIndeterminate.remove(SchoolTypeTopiaDao.SCHOOL_TYPE_INDETERMINATE_ID);
|
|
| 92 | 96 |
}
|
| 93 | 97 |
|
| 94 | 98 |
@Override
|
| ... | ... | @@ -161,10 +165,12 @@ public class Level3ConfigureAction extends AbstractConfigureAction<Level3Configu |
| 161 | 165 |
public Map<String, String> getUseWeightCategoriesOrNot() {
|
| 162 | 166 |
return useWeightCategoriesOrNot;
|
| 163 | 167 |
}
|
| 168 |
+ |
|
| 164 | 169 |
@SuppressWarnings("unused")
|
| 165 | 170 |
public Map<String, String> getUseWeightCategoriesInStratumOrNot() {
|
| 166 | 171 |
return useWeightCategoriesInStratumOrNot;
|
| 167 | 172 |
}
|
| 173 |
+ |
|
| 168 | 174 |
@SuppressWarnings("unused")
|
| 169 | 175 |
public Map<String, String> getSchoolTypeIndeterminate() {
|
| 170 | 176 |
return schoolTypeIndeterminate;
|
| ... | ... | @@ -26,6 +26,7 @@ import fr.ird.t3.actions.stratum.SchoolTypeIndeterminate; |
| 26 | 26 |
import fr.ird.t3.actions.stratum.StratumMinimumSampleCount;
|
| 27 | 27 |
import fr.ird.t3.entities.reference.Country;
|
| 28 | 28 |
import fr.ird.t3.entities.reference.Ocean;
|
| 29 |
+import fr.ird.t3.entities.reference.SchoolTypeTopiaDao;
|
|
| 29 | 30 |
import fr.ird.t3.entities.reference.Species;
|
| 30 | 31 |
import fr.ird.t3.entities.reference.zone.ZoneStratumAwareMeta;
|
| 31 | 32 |
import fr.ird.t3.entities.reference.zone.ZoneVersion;
|
| ... | ... | @@ -159,6 +160,8 @@ public class Level3RunAction extends AbstractRunAction<Level3Configuration, Leve |
| 159 | 160 |
useWeightCategoriesOrNot = createLevel3UseWeightCategoriesOrNotMap();
|
| 160 | 161 |
useWeightCategoriesInStratumOrNot = createUseWeightCategoriesInStratumOrNot();
|
| 161 | 162 |
super.prepare();
|
| 163 |
+ // on level 3, can't treat Indeterminate school type
|
|
| 164 |
+ schoolTypeIndeterminate.remove(SchoolTypeTopiaDao.SCHOOL_TYPE_INDETERMINATE_ID);
|
|
| 162 | 165 |
}
|
| 163 | 166 |
|
| 164 | 167 |
@Override
|