CDCgov / IDWA

Intelligent Data Workflow Automation
Apache License 2.0
1 stars 1 forks source link

Update labels.json structure #106

Open zdeveloper opened 2 months ago

zdeveloper commented 2 months ago

labels.json has been a great start with key/value structure, however, as we look into expanding, we want it to accommodate for more dynamic structure, please update the code base to follow the following format

[
  {
    "label": "nbs_patient_id",
    "type": "text",
    "color": "0,0,255"
  },
  {
    "label": "Race",
    "type": "multi",
    "options": [
      {
        "label": "Asian",
        "type": "checkbox",
        "color": "0,0,1"
      },
      {
        "label": "Black",
        "type": "checkbox",
        "color": "0,0,2"
      },
      {
        "label": "White",
        "type": "checkbox",
        "color": "0,0,3"
      },
      {
        "label": "Native",
        "type": "checkbox",
        "color": "0,0,4"
      },
      {
        "label": "Other",
        "type": "text",
        "color": "0,0,5"
      }
    ]
  },
  {
    "label": "Date of Birth",
    "type": "date",
    "options": [
      {
        "label": "Month",
        "type": "text",
        "color": "8,0,0"
      },
      {
        "label": "Day",
        "type": "text",
        "color": "16,0,0"
      },
      {
        "label": "Year",
        "type": "text",
        "color": "32,0,0"
      }
    ]
  },
  {
    "label": "Cough",
    "type": "multi",
    "options": [
      {
        "label": "Yes",
        "type": "checkbox",
        "color": "5,0,0"
      },
      {
        "label": "No",
        "type": "checkbox",
        "color": "10,0,0"
      }
    ]
  }
]

Acceptance Criteria