@planning-inspectorate/data-model 2.20.0 → 2.21.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -8
- package/package.json +4 -2
- package/pins_data_model/models/model_appeal_document.py +1 -1
- package/pins_data_model/models/model_appeal_event.py +1 -1
- package/pins_data_model/models/model_appeal_event_estimate.py +1 -1
- package/pins_data_model/models/model_appeal_has.py +1 -1
- package/pins_data_model/models/model_appeal_representation.py +1 -1
- package/pins_data_model/models/model_appeal_s78.py +1 -1
- package/pins_data_model/models/model_dart_response.py +1 -1
- package/pins_data_model/models/model_entraid.py +1 -1
- package/pins_data_model/models/model_folder.py +1 -1
- package/pins_data_model/models/model_gettimesheets_response.py +1 -1
- package/pins_data_model/models/model_listed_building.py +1 -1
- package/pins_data_model/models/model_listed_buildings.py +1 -1
- package/pins_data_model/models/model_nsip_document.py +1 -1
- package/pins_data_model/models/model_nsip_exam_timetable.py +1 -1
- package/pins_data_model/models/model_nsip_invoice.py +1 -1
- package/pins_data_model/models/model_nsip_meeting.py +1 -1
- package/pins_data_model/models/model_nsip_project.py +1 -1
- package/pins_data_model/models/model_nsip_project_update.py +1 -1
- package/pins_data_model/models/model_nsip_representation.py +1 -1
- package/pins_data_model/models/model_nsip_subscription.py +1 -1
- package/pins_data_model/models/model_pins_inspector.py +1 -1
- package/pins_data_model/models/model_pins_lpa.py +1 -1
- package/pins_data_model/models/model_s51_advice.py +1 -1
- package/pins_data_model/models/model_service_user.py +1 -1
- package/schemas/commands/appeals-components/lpa-questionnaire-enforcement.schema.json +8 -4
- package/src/index.d.ts +2 -2
- package/src/schemas.d.ts +8 -2
package/README.md
CHANGED
|
@@ -164,30 +164,30 @@ The schemas in this repository are written in jsonc (JSON with comments), and ca
|
|
|
164
164
|
|
|
165
165
|
## Node.js Usage
|
|
166
166
|
|
|
167
|
-
To use these schemas in a Node project, add this repo as a dependency
|
|
167
|
+
To use these schemas in a Node project, add this repo as a dependency:
|
|
168
168
|
|
|
169
|
-
`npm i -s
|
|
169
|
+
`npm i -s @planning-inspectorate/data-model`
|
|
170
|
+
|
|
171
|
+
As usual with npm you can optionally specify a version:
|
|
172
|
+
|
|
173
|
+
`npm i -s @planning-inspectorate/data-model@2.20.0`
|
|
170
174
|
|
|
171
175
|
Then import as required:
|
|
172
176
|
|
|
173
177
|
```es6
|
|
174
|
-
import {loadAllSchemas} from '
|
|
178
|
+
import {loadAllSchemas} from '@planning-inspectorate/data-model';
|
|
175
179
|
```
|
|
176
180
|
|
|
177
181
|
or to import enum constants, for example:
|
|
178
182
|
|
|
179
183
|
```es6
|
|
180
|
-
import { APPEAL_CASE_STATUS } from '
|
|
184
|
+
import { APPEAL_CASE_STATUS } from '@planning-inspectorate/data-model';
|
|
181
185
|
|
|
182
186
|
if (someAppeal.status === APPEAL_CASE_STATUS.COMPLETE) {
|
|
183
187
|
console.log(`we're done!`);
|
|
184
188
|
}
|
|
185
189
|
```
|
|
186
190
|
|
|
187
|
-
To upgrade to a different version, simply doing npm command does not seem to get the correct version, so we need to first uninstall and then reinstall. You can do this by running:
|
|
188
|
-
|
|
189
|
-
`npm uninstall pins-data-model && npm prune && npm i -s github:Planning-Inspectorate/data-model#some-tag-or-commit`
|
|
190
|
-
|
|
191
191
|
### Tests
|
|
192
192
|
|
|
193
193
|
We are starting to add js tests to the models using node test runner
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@planning-inspectorate/data-model",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.21.1",
|
|
4
4
|
"description": "JSON Schemas for the Planning Inspectorate's Data Model",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -32,11 +32,13 @@
|
|
|
32
32
|
"@adobe/jsonschema2md": "^8.0.3",
|
|
33
33
|
"@commitlint/cli": "^20.1.0",
|
|
34
34
|
"@commitlint/config-conventional": "^20.0.0",
|
|
35
|
+
"@eslint/js": "^10.0.1",
|
|
35
36
|
"ajv": "^8.17.1",
|
|
36
37
|
"ajv-formats": "^3.0.1",
|
|
37
38
|
"conventional-changelog-conventionalcommits": "^9.1.0",
|
|
38
|
-
"eslint": "^
|
|
39
|
+
"eslint": "^10.0.0",
|
|
39
40
|
"eslint-config-prettier": "^10.1.5",
|
|
41
|
+
"globals": "^17.3.0",
|
|
40
42
|
"husky": "^9.1.7",
|
|
41
43
|
"json-schema-to-typescript": "^15.0.4",
|
|
42
44
|
"lint-staged": "^16.1.2",
|
|
@@ -31,11 +31,15 @@
|
|
|
31
31
|
"examples": [45.7],
|
|
32
32
|
"description": "The site area, in square meters"
|
|
33
33
|
},
|
|
34
|
-
"
|
|
35
|
-
"type": ["
|
|
34
|
+
"areaOfAllegedBreachInSquareMetres": {
|
|
35
|
+
"type": ["number", "null"],
|
|
36
|
+
"examples": [45.7],
|
|
37
|
+
"description": "Area of the alleged breach, in square meters"
|
|
36
38
|
},
|
|
37
|
-
"
|
|
38
|
-
"type": ["
|
|
39
|
+
"floorSpaceCreatedByBreachInSquareMetres": {
|
|
40
|
+
"type": ["number", "null"],
|
|
41
|
+
"examples": [45.7],
|
|
42
|
+
"description": "Floor space created by the breach, in square meters"
|
|
39
43
|
},
|
|
40
44
|
"changeOfUseRefuseOrWaste": {
|
|
41
45
|
"type": ["boolean", "null"]
|
package/src/index.d.ts
CHANGED
package/src/schemas.d.ts
CHANGED
|
@@ -4651,8 +4651,14 @@ export type LPAQEnforcementSubmissionProperties = {
|
|
|
4651
4651
|
* The site area, in square meters
|
|
4652
4652
|
*/
|
|
4653
4653
|
siteAreaSquareMetres?: number | null;
|
|
4654
|
-
|
|
4655
|
-
|
|
4654
|
+
/**
|
|
4655
|
+
* Area of the alleged breach, in square meters
|
|
4656
|
+
*/
|
|
4657
|
+
areaOfAllegedBreachInSquareMetres?: number | null;
|
|
4658
|
+
/**
|
|
4659
|
+
* Floor space created by the breach, in square meters
|
|
4660
|
+
*/
|
|
4661
|
+
floorSpaceCreatedByBreachInSquareMetres?: number | null;
|
|
4656
4662
|
changeOfUseRefuseOrWaste?: boolean | null;
|
|
4657
4663
|
changeOfUseMineralExtraction?: boolean | null;
|
|
4658
4664
|
changeOfUseMineralStorage?: boolean | null;
|