Fixing groups refs #23215
This commit is contained in:
parent
5c1e3bc164
commit
51c91a3878
|
@ -21,8 +21,8 @@ public @interface Group {
|
|||
String condition() default "";
|
||||
|
||||
/**
|
||||
* If this value is set, it is the name of the group (apart the source, i.e. "grsf", "ram", "firms", "fishsource" that will be prepended) to which the
|
||||
* record needs to be put.
|
||||
* If this value is set, it is used as name of the group in place of the filed value.
|
||||
* (apart the source, i.e. "grsf", "ram", "firms", "fishsource" that will be prepended depending on prependSourceToGroupName)
|
||||
* @return
|
||||
*/
|
||||
String groupNameOverValue() default "";
|
||||
|
@ -32,6 +32,6 @@ public @interface Group {
|
|||
* Set to false to avoid source prepending
|
||||
* @return
|
||||
*/
|
||||
boolean prependSourceToGroupName() default true;
|
||||
boolean prependSourceToGroupName() default false;
|
||||
|
||||
}
|
||||
|
|
|
@ -55,7 +55,7 @@ public abstract class Common extends Base {
|
|||
|
||||
@JsonProperty(Constants.SDG_FLAG_JSON_KEY)
|
||||
@CustomField(key=Constants.SDG_FLAG_CUSTOM_KEY)
|
||||
@Group(condition="true", groupNameOverValue=Constants.SDG_FLAG_CUSTOM_KEY, prependSourceToGroupName=true) // record is added to group grsf-sdg-flag if sdg Flag is true
|
||||
@Group(condition="true", groupNameOverValue=Constants.SDG_FLAG_GROUP_NAME, prependSourceToGroupName=false) // record is added to group grsf-sdg-flag if sdg Flag is true
|
||||
private Boolean sdgFlag;
|
||||
|
||||
@JsonProperty(Constants.STATUS_OF_THE_GRSF_RECORD_JSON_KEY)
|
||||
|
|
|
@ -33,7 +33,7 @@ public class FisheryRecord extends Common {
|
|||
|
||||
@JsonProperty(Constants.TRACEABILITY_FLAG_JSON_KEY)
|
||||
@CustomField(key=Constants.TRACEABILITY_FLAG_CUSTOM_KEY)
|
||||
@Group(condition="true", groupNameOverValue=Constants.TRACEABILITY_FLAG_CUSTOM_KEY, prependSourceToGroupName=true) // record is added to group grsf-traceability-flag if Traceability Flag is true
|
||||
@Group(condition="true", groupNameOverValue=Constants.TRACEABILITY_FLAG_GROUP_NAME, prependSourceToGroupName=false) // record is added to group grsf-traceability-flag if Traceability Flag is true
|
||||
private Boolean traceabilityFlag;
|
||||
|
||||
@JsonProperty(Constants.FISHING_AREA_JSON_KEY)
|
||||
|
@ -62,7 +62,6 @@ public class FisheryRecord extends Common {
|
|||
|
||||
@JsonProperty(Constants.GRSF_TYPE_JSON_KEY)
|
||||
@CustomField(key=Constants.GRSF_TYPE_CUSTOM_KEY)
|
||||
@Group(prependSourceToGroupName = false)
|
||||
@Tag
|
||||
private Fishery_Type type;
|
||||
|
||||
|
|
|
@ -109,7 +109,6 @@ public class StockRecord extends Common{
|
|||
|
||||
@JsonProperty(Constants.GRSF_TYPE_JSON_KEY)
|
||||
@CustomField(key=Constants.GRSF_TYPE_CUSTOM_KEY)
|
||||
@Group(prependSourceToGroupName = false)
|
||||
@Tag
|
||||
private Stock_Type type;
|
||||
|
||||
|
|
Loading…
Reference in New Issue