Skip to content

Commit

Permalink
patch(cb2-13786): improve logic for multiple array items on ADR body …
Browse files Browse the repository at this point in the history
…dec (#181)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
naathanbrown and github-actions[bot] authored Oct 28, 2024
1 parent c544068 commit 9087e9a
Show file tree
Hide file tree
Showing 35 changed files with 897 additions and 291 deletions.
36 changes: 27 additions & 9 deletions json-definitions/v3/tech-record/get/hgv/complete/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -1090,24 +1090,42 @@
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"type": "string",
"not": {
"enum": [
"Explosives (type 3)"
]
}
"const": "Explosives (type 3)"
}
}
},
"required": [
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"else": {
"if": {
"properties": {
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"enum": [
"FP <61 (FL)",
"AT",
"Class 5.1 Hydrogen Peroxide (OX)",
"MEMU",
"Carbon Disulphide",
"Hydrogen",
"Explosives (type 2)"
]
}
}
},
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
]
}
}
}
},
Expand Down
36 changes: 27 additions & 9 deletions json-definitions/v3/tech-record/get/hgv/skeleton/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -1171,24 +1171,42 @@
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"type": "string",
"not": {
"enum": [
"Explosives (type 3)"
]
}
"const": "Explosives (type 3)"
}
}
},
"required": [
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"else": {
"if": {
"properties": {
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"enum": [
"FP <61 (FL)",
"AT",
"Class 5.1 Hydrogen Peroxide (OX)",
"MEMU",
"Carbon Disulphide",
"Hydrogen",
"Explosives (type 2)"
]
}
}
},
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
]
}
}
}
},
Expand Down
36 changes: 27 additions & 9 deletions json-definitions/v3/tech-record/get/hgv/testable/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -1162,24 +1162,42 @@
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"type": "string",
"not": {
"enum": [
"Explosives (type 3)"
]
}
"const": "Explosives (type 3)"
}
}
},
"required": [
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"else": {
"if": {
"properties": {
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"enum": [
"FP <61 (FL)",
"AT",
"Class 5.1 Hydrogen Peroxide (OX)",
"MEMU",
"Carbon Disulphide",
"Hydrogen",
"Explosives (type 2)"
]
}
}
},
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
]
}
}
}
},
Expand Down
36 changes: 27 additions & 9 deletions json-definitions/v3/tech-record/get/lgv/complete/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -670,24 +670,42 @@
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"type": "string",
"not": {
"enum": [
"Explosives (type 3)"
]
}
"const": "Explosives (type 3)"
}
}
},
"required": [
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"else": {
"if": {
"properties": {
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"enum": [
"FP <61 (FL)",
"AT",
"Class 5.1 Hydrogen Peroxide (OX)",
"MEMU",
"Carbon Disulphide",
"Hydrogen",
"Explosives (type 2)"
]
}
}
},
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
]
}
}
}
},
Expand Down
36 changes: 27 additions & 9 deletions json-definitions/v3/tech-record/get/lgv/skeleton/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -677,24 +677,42 @@
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"type": "string",
"not": {
"enum": [
"Explosives (type 3)"
]
}
"const": "Explosives (type 3)"
}
}
},
"required": [
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"else": {
"if": {
"properties": {
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"enum": [
"FP <61 (FL)",
"AT",
"Class 5.1 Hydrogen Peroxide (OX)",
"MEMU",
"Carbon Disulphide",
"Hydrogen",
"Explosives (type 2)"
]
}
}
},
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
]
}
}
}
},
Expand Down
36 changes: 27 additions & 9 deletions json-definitions/v3/tech-record/get/trl/complete/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -1295,24 +1295,42 @@
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"type": "string",
"not": {
"enum": [
"Explosives (type 3)"
]
}
"const": "Explosives (type 3)"
}
}
},
"required": [
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"else": {
"if": {
"properties": {
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"enum": [
"FP <61 (FL)",
"AT",
"Class 5.1 Hydrogen Peroxide (OX)",
"MEMU",
"Carbon Disulphide",
"Hydrogen",
"Explosives (type 2)"
]
}
}
},
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
]
}
}
}
},
Expand Down
36 changes: 27 additions & 9 deletions json-definitions/v3/tech-record/get/trl/skeleton/index.json
Original file line number Diff line number Diff line change
Expand Up @@ -1370,24 +1370,42 @@
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"type": "string",
"not": {
"enum": [
"Explosives (type 3)"
]
}
"const": "Explosives (type 3)"
}
}
},
"required": [
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"else": {
"if": {
"properties": {
"techRecord_adrDetails_permittedDangerousGoods": {
"type": "array",
"contains": {
"enum": [
"FP <61 (FL)",
"AT",
"Class 5.1 Hydrogen Peroxide (OX)",
"MEMU",
"Carbon Disulphide",
"Hydrogen",
"Explosives (type 2)"
]
}
}
},
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
"techRecord_adrDetails_permittedDangerousGoods"
]
},
"then": {
"not": {
"required": [
"techRecord_adrDetails_bodyDeclaration_type"
]
}
}
}
},
Expand Down
Loading

0 comments on commit 9087e9a

Please sign in to comment.