specification icon indicating copy to clipboard operation
specification copied to clipboard

Documentation Does Not List Acceptable Values For Enum Fields

Open AtticusRains opened this issue 5 years ago • 1 comments

The HSDS objects and fields reference documentation currently does not list acceptable values for enum fields (or denote that these fields are enums at all) as described in the datapackage.json

For example, the eligibility.eligibility field is described in the datapackage.json as follows:

{
    "name": "eligibility",
    "description": "The rules or guidelines that determine who can receive the service.",
    "type": "string",
    "constraints": {
        "enum": ["adult","child","teen","family","female","male",
            "Transgender", "Transgender - M to F", "Transgender - F to M" ]
    }
}

The documentation makes this field seem more like an open text field and does not list the acceptable values.

Field Name Type (Format) Description Required? Unique?
eligibility string The rules or guidelines that determine who can receive the service. False False

AtticusRains avatar Feb 18 '20 17:02 AtticusRains

Yes it is currently defined just as a text field. In the UK we're proposing an extension so that eligibility can come from a taxonomy/vocabulary. See issue 208.

MikeThacker1 avatar Feb 18 '20 17:02 MikeThacker1

Closing this as we no longer have eligibility modelled in this way. However I'm noting that there's been several other issues discussing how enums in the standard are not rendered properly.

Usually this is handled separately, via a codelists page. I am noting this down in our project docs as being related to this.

mrshll1001 avatar Nov 16 '23 14:11 mrshll1001