Skip to content

Commit

Permalink
fix: update missing or incorrect enum values (#58)
Browse files Browse the repository at this point in the history
  • Loading branch information
jessicamcinchak authored Oct 20, 2023
1 parent a057db8 commit 9bee7ec
Show file tree
Hide file tree
Showing 9 changed files with 48 additions and 27 deletions.
2 changes: 1 addition & 1 deletion examples/data/ldcE.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1567,7 +1567,7 @@ export const validLDCE: Schema = {
type: [
{
value: 'proposal.drawing.elevation',
description: 'Elevation plan - proposed',
description: 'Elevations - proposed',
},
],
},
Expand Down
4 changes: 2 additions & 2 deletions examples/data/ldcP.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1082,7 +1082,7 @@ export const validLDCP: Schema = {
type: [
{
value: 'property.drawing.elevation',
description: 'Elevation plan - existing',
description: 'Elevations - existing',
},
],
},
Expand All @@ -1100,7 +1100,7 @@ export const validLDCP: Schema = {
type: [
{
value: 'proposal.drawing.elevation',
description: 'Elevation plan - proposed',
description: 'Elevations - proposed',
},
],
},
Expand Down
4 changes: 2 additions & 2 deletions examples/data/planningPermission.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1673,11 +1673,11 @@ export const validPlanningPermission: Schema = {
type: [
{
value: 'property.drawing.elevation',
description: 'Elevation plan - existing',
description: 'Elevations - existing',
},
{
value: 'proposal.drawing.elevation',
description: 'Elevation plan - proposed',
description: 'Elevations - proposed',
},
],
},
Expand Down
2 changes: 1 addition & 1 deletion examples/validLawfulDevelopmentCertificateExisting.json
Original file line number Diff line number Diff line change
Expand Up @@ -1762,7 +1762,7 @@
"type": [
{
"value": "proposal.drawing.elevation",
"description": "Elevation plan - proposed"
"description": "Elevations - proposed"
}
]
},
Expand Down
4 changes: 2 additions & 2 deletions examples/validLawfulDevelopmentCertificateProposed.json
Original file line number Diff line number Diff line change
Expand Up @@ -1144,7 +1144,7 @@
"type": [
{
"value": "property.drawing.elevation",
"description": "Elevation plan - existing"
"description": "Elevations - existing"
}
]
},
Expand All @@ -1162,7 +1162,7 @@
"type": [
{
"value": "proposal.drawing.elevation",
"description": "Elevation plan - proposed"
"description": "Elevations - proposed"
}
]
},
Expand Down
4 changes: 2 additions & 2 deletions examples/validPlanningPermission.json
Original file line number Diff line number Diff line change
Expand Up @@ -1694,11 +1694,11 @@
"type": [
{
"value": "property.drawing.elevation",
"description": "Elevation plan - existing"
"description": "Elevations - existing"
},
{
"value": "proposal.drawing.elevation",
"description": "Elevation plan - proposed"
"description": "Elevations - proposed"
}
]
},
Expand Down
42 changes: 31 additions & 11 deletions schema/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@
"owner.sole",
"owner.co",
"tenant",
"occupier"
"occupier",
"other"
],
"type": "string"
},
Expand Down Expand Up @@ -912,7 +913,8 @@
"owner.sole",
"owner.co",
"tenant",
"occupier"
"occupier",
"other"
],
"type": "string"
},
Expand Down Expand Up @@ -1076,7 +1078,7 @@
"additionalProperties": false,
"properties": {
"description": {
"const": "Elevation plan - existing",
"const": "Elevations - existing",
"type": "string"
},
"value": {
Expand Down Expand Up @@ -1130,7 +1132,7 @@
"additionalProperties": false,
"properties": {
"description": {
"const": "Section - existing",
"const": "Sections - existing",
"type": "string"
},
"value": {
Expand Down Expand Up @@ -1202,11 +1204,11 @@
"additionalProperties": false,
"properties": {
"description": {
"const": "Location plan",
"const": "Elevations - proposed",
"type": "string"
},
"value": {
"const": "property.site.locationPlan",
"const": "proposal.drawing.elevation",
"type": "string"
}
},
Expand All @@ -1220,11 +1222,11 @@
"additionalProperties": false,
"properties": {
"description": {
"const": "Elevation plan - proposed",
"const": "Floor plan - proposed",
"type": "string"
},
"value": {
"const": "proposal.drawing.elevation",
"const": "proposal.drawing.floorPlan",
"type": "string"
}
},
Expand All @@ -1238,11 +1240,11 @@
"additionalProperties": false,
"properties": {
"description": {
"const": "Floor plan - proposed",
"const": "Location plan",
"type": "string"
},
"value": {
"const": "proposal.drawing.floorPlan",
"const": "proposal.drawing.locationPlan",
"type": "string"
}
},
Expand Down Expand Up @@ -1292,7 +1294,7 @@
"additionalProperties": false,
"properties": {
"description": {
"const": "Section - proposed",
"const": "Sections - proposed",
"type": "string"
},
"value": {
Expand Down Expand Up @@ -1702,6 +1704,24 @@
],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"description": {
"const": "Photographs - evidence",
"type": "string"
},
"value": {
"const": "proposal.photograph.evidence",
"type": "string"
}
},
"required": [
"value",
"description"
],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
Expand Down
11 changes: 6 additions & 5 deletions types/enums/FileTypes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@
* Values of `file.type`
*/
export const FileTypes = {
'property.drawing.elevation': 'Elevation plan - existing',
'property.drawing.elevation': 'Elevations - existing',
'property.drawing.floorPlan': 'Floor plan - existing',
'property.drawing.roofPlan': 'Roof plan - existing',
'property.drawing.section': 'Section - existing',
'property.drawing.section': 'Sections - existing',
'property.drawing.sitePlan': 'Site plan - existing',
'property.drawing.usePlan': 'Use plan - existing',
'property.photograph': 'Photographs',
'property.site.locationPlan': 'Location plan',
'proposal.drawing.elevation': 'Elevation plan - proposed',
'proposal.drawing.elevation': 'Elevations - proposed',
'proposal.drawing.floorPlan': 'Floor plan - proposed',
'proposal.drawing.locationPlan': 'Location plan',
'proposal.drawing.other': 'Other - drawing',
'proposal.drawing.roofPlan': 'Roof plan - proposed',
'proposal.drawing.section': 'Section - proposed',
'proposal.drawing.section': 'Sections - proposed',
'proposal.drawing.sitePlan': 'Site plan - proposed',
'proposal.drawing.unitPlan': 'Unit plan - proposed',
'proposal.drawing.usePlan': 'Use plan - proposed',
Expand All @@ -38,5 +38,6 @@ export const FileTypes = {
'proposal.document.transport': 'Transport assessment',
'proposal.document.utility.bill': 'Utility bill',
'proposal.photograph': 'Photographs',
'proposal.photograph.evidence': 'Photographs - evidence',
'proposal.visualisation': 'Visualisations',
};
2 changes: 1 addition & 1 deletion types/schema/data/Applicant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export type Applicant = BaseApplicant | Agent;
*/
export interface BaseApplicant {
type: 'individual' | 'company' | 'charity' | 'public' | 'parishCouncil';
interest?: 'owner.sole' | 'owner.co' | 'tenant' | 'occupier';
interest?: 'owner.sole' | 'owner.co' | 'tenant' | 'occupier' | 'other';
ownership?: {
certificate: 'a' | 'b' | 'c' | 'd';
noticeGiven?: boolean;
Expand Down

0 comments on commit 9bee7ec

Please sign in to comment.