TACC / Core-CMS-Custom

Customized Core CMS code and builds
5 stars 0 forks source link

Task/WP 6 APCD Make CDL into dropdown on threshold exception form #142

Closed sophia-massie closed 1 year ago

sophia-massie commented 1 year ago

Overview

Only threshold forms use the CDL. Created a dropdown for field codes based on the file type selected in the threshold form. Will refetch the cdls every time a user changes the file type.

Related

Changes

Testing

  1. In exception/views.py, add the following snippet on line 44
cdls = [('CDLME001', 'Data Submitter Code', '100'), ('CDLME004', 'Member\nInsurance/Product\nCategory Code', '90'), ('CDLME005', 'Start Year of\nSubmission ', '100'), ('CDLME006', 'Start Month\nof Submission ', '100'), ('CDLME007', 'Insured Group or Policy Number', '80'), ('CDLME009', 'Medicaid AID Category ', '50'), ('CDLME011', 'Plan Specific Contract Number', '60'), ('CDLME012', 'Subscriber Last Name ', '100'), ('CDLME013', 'Subscriber First Name ', '100'), ('CDLME015', 'Sequence Number ', '100'), ('CDLME017', 'Individual Relationship\nCode', '90'), ('CDLME018', 'Member Gender ', '90'), ('CDLME019', 'Member Date of Birth ', '90'), ('CDLME020', 'Member Last Name ', '100'), ('CDLME021', 'Member First Name ', '100'), ('CDLME023', 'Member Street Address', '60'), ('CDLME024', 'Member City Name ', '60'), ('CDLME025', 'Member State or Province', '80'), ('CDLME026', 'Member ZIP Code ', '80'), ('CDLME036', 'Medical Coverage\nUnder This Plan', '90'), ('CDLME037', 'Pharmacy Coverage\nUnder This Plan', '90'), ('CDLME039', 'Behavioral Health\nCoverage Under This\nPlan', '90'), ('CDLME040', 'Primary Insurance Indicator', '100'), ('CDLME041', 'Coverage Type ', '50'), ('CDLME045', 'Group Name ', '60'), ('CDLME050', 'Plan Effective Date ', '90'), ('CDLME061', 'Carrier Specific Unique\nMember ID', '95'), ('CDLME062', 'Carrier Specific Unique\nSubscriber ID', '95'), ('CDLME064', 'High Deductible Plan Indicator', '50'), ('CDLME899', 'Record Type ', '100')]
  1. Now add the following snippet to the same file on line 37
submitters = [ (2, 'TESTGOLD', 10000001, 'gmunoz1', 'CHCD'), (3, 'TESTGOLD', 10000002, 'gmunoz1', 'CHCD'), (1, 'TESTGOLD', 10000000, 'gmunoz1', 'CHCD') ]
  1. Go to http://localhost:8000/submissions/threshold-exception/
  2. Select a file type
  3. Make sure the Field Code input field has the Names and Codes you put in for line 37 in views.py
  4. Change the File Type field
  5. Check your container logs to make sure that the logger printed the right code for your file type.
  6. Change the File Type a second time. The codes should repopulate and the first code in the list should appear in the drop down. The help text should clear

These are the corresponding codes for each file type:

UI

Drop down field for field codes. WIll populate dynamically based on file type selected when put on QA

Screen Shot 2023-03-13 at 12 21 32 PM

Helper text will dynamically update on Threshold Percentage based on Field Code. Screen Shot 2023-03-14 at 2 28 13 PM