Tony CHEMIT pushed to branch develop at ultreiaio / ird-observe Commits: 46dcf544 by Tony Chemit at 2024-04-26T17:59:14+02:00 Encore une borne de poids à augmenter, sur PS localmarket batch - Closes #2874 - - - - - bb506c43 by Tony Chemit at 2024-04-26T17:59:14+02:00 update VesselType public api doc - - - - - 18 changed files: - core/api/validation/src/main/filtered-resources/META-INF/validators/validation.json - core/api/validation/src/main/resources/fr/ird/observe/dto/data/ps/localmarket/BatchDto-create-error-validation.xml - core/api/validation/src/main/resources/fr/ird/observe/dto/data/ps/localmarket/BatchDto-update-error-validation.xml - core/persistence/resources/src/main/resources/fr/ird/observe/entities/data/ps/localmarket/Batch/validation-create.json - core/persistence/resources/src/main/resources/fr/ird/observe/entities/data/ps/localmarket/Batch/validation-update.json - model/src/main/models/Observe/dto/attribute/boundNumber.properties - server/runner/src/main/webResources/doc/api/public/data/ps/localmarket/Batch/validation-create-error.xml - server/runner/src/main/webResources/doc/api/public/data/ps/localmarket/Batch/validation-create.json - server/runner/src/main/webResources/doc/api/public/data/ps/localmarket/Batch/validation-update-error.xml - server/runner/src/main/webResources/doc/api/public/data/ps/localmarket/Batch/validation-update.json - server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/GetSome/index.html - server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/definition.json - server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-create-error.xml - server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-create-warning.xml - server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-create.json - server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-update-error.xml - server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-update-warning.xml - server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-update.json Changes: ===================================== core/api/validation/src/main/filtered-resources/META-INF/validators/validation.json ===================================== @@ -9087,7 +9087,7 @@ { "name": "weight", "comments": [ - "0.0001 <= weight <= 100.0 except if !countOrWeightValid", + "0.0001 <= weight <= 1500.0 except if !countOrWeightValid", "weight is a strictly positive number", "weight is mandatory except if countOrWeightValid" ] @@ -9186,7 +9186,7 @@ { "name": "weight", "comments": [ - "0.0001 <= weight <= 100.0 except if !countOrWeightValid", + "0.0001 <= weight <= 1500.0 except if !countOrWeightValid", "weight is a strictly positive number", "weight is mandatory except if countOrWeightValid" ] ===================================== core/api/validation/src/main/resources/fr/ird/observe/dto/data/ps/localmarket/BatchDto-create-error-validation.xml ===================================== @@ -116,11 +116,11 @@ <message/> </field-validator> - <!-- 0.0001 <= weight <= 100.0 except if !countOrWeightValid --> + <!-- 0.0001 <= weight <= 1500.0 except if !countOrWeightValid --> <field-validator type="boundNumber"> <param name="skip"><![CDATA[ !countOrWeightValid ]]></param> <param name="min">0.0001</param> - <param name="max">100.0</param> + <param name="max">1500.0</param> <message/> </field-validator> </field> ===================================== core/api/validation/src/main/resources/fr/ird/observe/dto/data/ps/localmarket/BatchDto-update-error-validation.xml ===================================== @@ -116,11 +116,11 @@ <message/> </field-validator> - <!-- 0.0001 <= weight <= 100.0 except if !countOrWeightValid --> + <!-- 0.0001 <= weight <= 1500.0 except if !countOrWeightValid --> <field-validator type="boundNumber"> <param name="skip"><![CDATA[ !countOrWeightValid ]]></param> <param name="min">0.0001</param> - <param name="max">100.0</param> + <param name="max">1500.0</param> <message/> </field-validator> </field> ===================================== core/persistence/resources/src/main/resources/fr/ird/observe/entities/data/ps/localmarket/Batch/validation-create.json ===================================== @@ -58,7 +58,7 @@ }, "weight": { "errors": [ - "0.0001 <= weight <= 100.0 except if !countOrWeightValid", + "0.0001 <= weight <= 1500.0 except if !countOrWeightValid", "weight is a strictly positive number", "weight is mandatory except if countOrWeightValid" ] ===================================== core/persistence/resources/src/main/resources/fr/ird/observe/entities/data/ps/localmarket/Batch/validation-update.json ===================================== @@ -58,7 +58,7 @@ }, "weight": { "errors": [ - "0.0001 <= weight <= 100.0 except if !countOrWeightValid", + "0.0001 <= weight <= 1500.0 except if !countOrWeightValid", "weight is a strictly positive number", "weight is mandatory except if countOrWeightValid" ] ===================================== model/src/main/models/Observe/dto/attribute/boundNumber.properties ===================================== @@ -61,7 +61,7 @@ data.ps.common.Trip.attribute.landingTotalWeight=0.0:2000.0:!targetWellsSampling data.ps.common.Trip.attribute.localMarketTotalWeight=0.0:1500.0:!localmarketWellsSamplingEnabled && !localmarketSurveySamplingEnabled data.ps.common.Trip.attribute.timeAtSea=10:2400:!logbookEnabled data.ps.landing.Landing.attribute.weight=0.0:2000.0 -data.ps.localmarket.Batch.attribute.weight=0.0001:100.0:!countOrWeightValid +data.ps.localmarket.Batch.attribute.weight=0.0001:1500.0:!countOrWeightValid data.ps.localmarket.SurveyPart.attribute.proportion=0.0:100.0 data.ps.logbook.Activity.attribute.currentDirection=0:359 data.ps.logbook.Activity.attribute.currentSpeed=0.0:40.0 ===================================== server/runner/src/main/webResources/doc/api/public/data/ps/localmarket/Batch/validation-create-error.xml ===================================== @@ -116,11 +116,11 @@ <message/> </field-validator> - <!-- 0.0001 <= weight <= 100.0 except if !countOrWeightValid --> + <!-- 0.0001 <= weight <= 1500.0 except if !countOrWeightValid --> <field-validator type="boundNumber"> <param name="skip"><![CDATA[ !countOrWeightValid ]]></param> <param name="min">0.0001</param> - <param name="max">100.0</param> + <param name="max">1500.0</param> <message/> </field-validator> </field> ===================================== server/runner/src/main/webResources/doc/api/public/data/ps/localmarket/Batch/validation-create.json ===================================== @@ -58,7 +58,7 @@ }, "weight": { "errors": [ - "0.0001 <= weight <= 100.0 except if !countOrWeightValid", + "0.0001 <= weight <= 1500.0 except if !countOrWeightValid", "weight is a strictly positive number", "weight is mandatory except if countOrWeightValid" ] ===================================== server/runner/src/main/webResources/doc/api/public/data/ps/localmarket/Batch/validation-update-error.xml ===================================== @@ -116,11 +116,11 @@ <message/> </field-validator> - <!-- 0.0001 <= weight <= 100.0 except if !countOrWeightValid --> + <!-- 0.0001 <= weight <= 1500.0 except if !countOrWeightValid --> <field-validator type="boundNumber"> <param name="skip"><![CDATA[ !countOrWeightValid ]]></param> <param name="min">0.0001</param> - <param name="max">100.0</param> + <param name="max">1500.0</param> <message/> </field-validator> </field> ===================================== server/runner/src/main/webResources/doc/api/public/data/ps/localmarket/Batch/validation-update.json ===================================== @@ -58,7 +58,7 @@ }, "weight": { "errors": [ - "0.0001 <= weight <= 100.0 except if !countOrWeightValid", + "0.0001 <= weight <= 1500.0 except if !countOrWeightValid", "weight is a strictly positive number", "weight is mandatory except if countOrWeightValid" ] ===================================== server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/GetSome/index.html ===================================== @@ -269,6 +269,13 @@ <td>[equals, not_equals, null, not_null, min, max]</td> <td>See documentation for filter type: <code>Timestamp</code>.</td> </tr> + <tr> + <td>longline</td> + <td>boolean</td> + <td><code>false|true</code></td> + <td>[equals, not_equals]</td> + <td>See documentation for filter type: <code>boolean</code>.</td> + </tr> <tr> <td>needComment</td> <td>boolean</td> @@ -276,6 +283,13 @@ <td>[equals, not_equals]</td> <td>See documentation for filter type: <code>boolean</code>.</td> </tr> + <tr> + <td>seine</td> + <td>boolean</td> + <td><code>false|true</code></td> + <td>[equals, not_equals]</td> + <td>See documentation for filter type: <code>boolean</code>.</td> + </tr> <tr> <td>status</td> <td>ReferenceStatus</td> ===================================== server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/definition.json ===================================== @@ -11,5 +11,7 @@ "label5": "String", "label6": "String", "label7": "String", - "label8": "String" + "label8": "String", + "longline": "boolean", + "seine": "boolean" } \ No newline at end of file ===================================== server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-create-error.xml ===================================== @@ -124,6 +124,20 @@ </field-validator> </field> + <field name="longline"> + <!-- longline is mandatory --> + <field-validator type="mandatory" short-circuit="true"> + <message/> + </field-validator> + </field> + + <field name="seine"> + <!-- seine is mandatory --> + <field-validator type="mandatory" short-circuit="true"> + <message/> + </field-validator> + </field> + <field name="uri"> <!-- uri (if not null) is not a blank string --> <field-validator type="notBlankString" short-circuit="true"> ===================================== server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-create-warning.xml ===================================== @@ -24,6 +24,14 @@ "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd"> <validators> + <field name="atLeastOneSelected"> + <!-- At least one of the following properties must be selected (longline,seine) --> + <field-validator type="fieldexpression" short-circuit="true"> + <param name="expression"> <![CDATA[ atLeastOneSelected ]]> </param> + <message>observe.referential.common.VesselType.validation.atLeastOneSelected</message> + </field-validator> + </field> + <field name="label1"> <!-- label1 is not translated --> <field-validator type="fieldexpression"> ===================================== server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-create.json ===================================== @@ -1,4 +1,9 @@ { + "atLeastOneSelected": { + "warnings": [ + "At least one of the following properties must be selected (longline,seine)" + ] + }, "code": { "errors": [ "code (if not null) is not a blank string", @@ -64,6 +69,16 @@ "label8 (if not null) is not a blank string" ] }, + "longline": { + "errors": [ + "longline is mandatory" + ] + }, + "seine": { + "errors": [ + "seine is mandatory" + ] + }, "status": { "warnings": [ "referential is enabled" ===================================== server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-update-error.xml ===================================== @@ -124,6 +124,20 @@ </field-validator> </field> + <field name="longline"> + <!-- longline is mandatory --> + <field-validator type="mandatory" short-circuit="true"> + <message/> + </field-validator> + </field> + + <field name="seine"> + <!-- seine is mandatory --> + <field-validator type="mandatory" short-circuit="true"> + <message/> + </field-validator> + </field> + <field name="uri"> <!-- uri (if not null) is not a blank string --> <field-validator type="notBlankString" short-circuit="true"> ===================================== server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-update-warning.xml ===================================== @@ -24,6 +24,14 @@ "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd"> <validators> + <field name="atLeastOneSelected"> + <!-- At least one of the following properties must be selected (longline,seine) --> + <field-validator type="fieldexpression" short-circuit="true"> + <param name="expression"> <![CDATA[ atLeastOneSelected ]]> </param> + <message>observe.referential.common.VesselType.validation.atLeastOneSelected</message> + </field-validator> + </field> + <field name="label1"> <!-- label1 is not translated --> <field-validator type="fieldexpression"> ===================================== server/runner/src/main/webResources/doc/api/public/referential/common/common/VesselType/validation-update.json ===================================== @@ -1,4 +1,9 @@ { + "atLeastOneSelected": { + "warnings": [ + "At least one of the following properties must be selected (longline,seine)" + ] + }, "code": { "errors": [ "code (if not null) is not a blank string", @@ -64,6 +69,16 @@ "label8 (if not null) is not a blank string" ] }, + "longline": { + "errors": [ + "longline is mandatory" + ] + }, + "seine": { + "errors": [ + "seine is mandatory" + ] + }, "status": { "warnings": [ "referential is enabled" View it on GitLab: https://gitlab.com/ultreiaio/ird-observe/-/compare/463453dd9e4660e0741d5e456... -- View it on GitLab: https://gitlab.com/ultreiaio/ird-observe/-/compare/463453dd9e4660e0741d5e456... You're receiving this email because of your account on gitlab.com.
participants (1)
-
Tony CHEMIT (@tchemit)