Skip to content

Commit

Permalink
- Updated DOB fields to make a little more sense
Browse files Browse the repository at this point in the history
  • Loading branch information
elipe17 committed Oct 19, 2023
1 parent e7e7ce3 commit 51512ad
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion tdrs-backend/tdpservice/parsers/schema_defs/ssp/m5.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
Field(item="13", name='FAMILY_AFFILIATION', type='number', startIndex=19, endIndex=20,
required=True, validators=[validators.isInLimits(1, 5)]),
Field(item="14", name='DATE_OF_BIRTH', type='string', startIndex=20, endIndex=28,
required=True, validators=[validators.dateYearIsLargerThan(1998),
required=True, validators=[validators.dateYearIsLargerThan(1900),
validators.dateMonthIsValid(),]),
TransformField(transform_func=ssp_ssn_decryption_func, item="15", name='SSN', type='string',
startIndex=28, endIndex=37, required=True, validators=[validators.validateSSN()],
Expand Down
2 changes: 1 addition & 1 deletion tdrs-backend/tdpservice/parsers/schema_defs/tanf/t2.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@
Field(item="31", name='NONCUSTODIAL_PARENT', type='number', startIndex=20, endIndex=21, required=True,
validators=[validators.oneOf([1, 2])]),
Field(item="32", name='DATE_OF_BIRTH', type='number', startIndex=21, endIndex=29, required=True,
validators=[validators.isLargerThan(0),]),
validators=[validators.dateYearIsLargerThan(1900), validators.dateMonthIsValid(),]),
TransformField(transform_func=tanf_ssn_decryption_func, item="33", name='SSN', type='string', startIndex=29,
endIndex=38, required=True,
validators=[validators.validateSSN()], is_encrypted=False),
Expand Down
4 changes: 2 additions & 2 deletions tdrs-backend/tdpservice/parsers/schema_defs/tanf/t3.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
]),
Field(item="68", name='DATE_OF_BIRTH', type='number', startIndex=20, endIndex=28,
required=True, validators=[
validators.dateYearIsLargerThan(1998),
validators.dateYearIsLargerThan(1950),
validators.dateMonthIsValid(),
]),
TransformField(transform_func=tanf_ssn_decryption_func, item="69", name='SSN', type='string', startIndex=28,
Expand Down Expand Up @@ -206,7 +206,7 @@
]),
Field(item="68", name='DATE_OF_BIRTH', type='number', startIndex=61, endIndex=69,
required=True, validators=[
validators.dateYearIsLargerThan(1998),
validators.dateYearIsLargerThan(1950),
validators.dateMonthIsValid(),
]),
TransformField(transform_func=tanf_ssn_decryption_func, item="69", name='SSN', type='string', startIndex=69,
Expand Down
3 changes: 2 additions & 1 deletion tdrs-backend/tdpservice/parsers/schema_defs/tanf/t5.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,8 @@
Field(item="14", name='FAMILY_AFFILIATION', type='number', startIndex=19, endIndex=20,
required=True, validators=[validators.isInLimits(1, 5)]),
Field(item="15", name='DATE_OF_BIRTH', type='number', startIndex=20, endIndex=28,
required=True, validators=[validators.isLargerThan(0)]),
required=True, validators=[validators.dateYearIsLargerThan(1900),
validators.dateMonthIsValid(),]),
TransformField(transform_func=tanf_ssn_decryption_func, item="16", name='SSN', type='string',
startIndex=28, endIndex=37, required=True, validators=[validators.isNumber()],
is_encrypted=False),
Expand Down

0 comments on commit 51512ad

Please sign in to comment.