Enhancement - Configure requirements for patrol attributes
Request from Martin Mwaniki at Ol Pejeta Conservancy. They would like the ability to control which patrol attributes are required. Currently, only certain patrol attributes are required (transport type, mandate, etc.), and they would like the ability to determine whether others (such as Team and Station) are required as well to enforce consistency in the data that's collected, as users can easily skip over those fields. This should apply to the custom patrol attributes available in SMART 7 as well.
Leave a comment
@matt.hron Good idea. Indeed - this would be important and should be - I hope - easy to configure. Could we add a tick box for required yes/no, just like you can tick them for including them in the patrol package. Strongly supported from our end.
Restriction for backwards compatibility:
The patrol attributes that are currently required cannot become
optional, however the ones that are optional can become required.
Some open questions on this one at this point:
1) Is this targeted at SMART Mobile enforcement with the settings applied to individual
packages only (in which case the Desktop data entry UI won't enforce
these settings)?
2) Or is it specified once for all patrol packages?
3) if #2, do we want to enforce the settings in the desktop UI as well?
4) Does this extend to mission attributes in the ecological records plugin?
The patrol attributes that are currently required cannot become
optional, however the ones that are optional can become required.
Some open questions on this one at this point:
1) Is this targeted at SMART Mobile enforcement with the settings applied to individual
packages only (in which case the Desktop data entry UI won't enforce
these settings)?
2) Or is it specified once for all patrol packages?
3) if #2, do we want to enforce the settings in the desktop UI as well?
4) Does this extend to mission attributes in the ecological records plugin?
Good for @matt.hron to weigh in here with his thoughts, but here are mine:
- Backwards compatibility - OK
1) Best case is that mobile and desktop will align. Increasingly though, I think most data are collected on mobile and that manual data entry is the niche case (ie, so more important to focus efforts on mobile).
2) I think this will be specified for individual patrol packages.
3) See answer to #1.
4) Depending on the lift, yes, it probably should. For our sites, enforcing required/not required for patrol metadata and custom patrol attributes is the priority.
- Backwards compatibility - OK
1) Best case is that mobile and desktop will align. Increasingly though, I think most data are collected on mobile and that manual data entry is the niche case (ie, so more important to focus efforts on mobile).
2) I think this will be specified for individual patrol packages.
3) See answer to #1.
4) Depending on the lift, yes, it probably should. For our sites, enforcing required/not required for patrol metadata and custom patrol attributes is the priority.
I generally agree. This is targeted at SMART Mobile with the ability to specify requirements per package. It wouldn't apply to manual data entry.
The priority and specific context for this request was for patrols, so that is the priority here. It would be good to have in ER as well for consistency, but if that significantly adds to the effort I'm fine with that being split out as a separate request.
The priority and specific context for this request was for patrols, so that is the priority here. It would be good to have in ER as well for consistency, but if that significantly adds to the effort I'm fine with that being split out as a separate request.
In smart-cs:8796 re: #3291 add required options for metadata fields for smart mobile packages; ui code updates
Justin: The only update required for SMART Mobile is for the "default value" for custom patrol date attributes to come be included in the sightings JSON. All the other requirements of this ticket (required options) work with the updates I made.
When the package includes a default value for a custom patrol date attribute the package patrol_metadata.json will include the attribute similar to this:
Currently the default value is not included in the sighting data generated by SMART Mobile. All other attribute types (number, list etc.) work as expected.
Image not found...
When the package includes a default value for a custom patrol date attribute the package patrol_metadata.json will include the attribute similar to this:
...
{
"SMART_98c0243cc8714aeca81f523c75372bdd": {
"isRequired": true,
"default": "2023\\/11\\/01",
"label_default": "Date Patrol Attribute",
"isVisible": false,
"type": "DATE",
"label_en": "Date Patrol Attribute",
"isFixed": false
}
},
...
Currently the default value is not included in the sighting data generated by SMART Mobile. All other attribute types (number, list etc.) work as expected.
Image not found...