@pdtf/schemas 0.6.6 → 0.6.9

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/index.js CHANGED
@@ -40,6 +40,16 @@ const getSubschema = (path) => {
40
40
  return transactionSchema;
41
41
  }
42
42
  return pathArray.reduce((schema, pathElement) => {
43
+ const dependencies = schema.dependencies;
44
+ if (dependencies) {
45
+ // only single dependency discriminator, oneOf keyword is supported
46
+ const dependencyDiscriminator = Object.keys(dependencies)[0];
47
+ const oneOfs = dependencies[dependencyDiscriminator].oneOf;
48
+ const matchingOneOf = oneOfs.find(
49
+ (oneOf) => oneOf["properties"][pathElement]
50
+ );
51
+ if (matchingOneOf) return matchingOneOf["properties"][pathElement];
52
+ }
43
53
  if (schema.type === "array") return schema.items;
44
54
  return schema.properties[pathElement];
45
55
  }, transactionSchema);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pdtf/schemas",
3
- "version": "0.6.6",
3
+ "version": "0.6.9",
4
4
  "description": "Property Data Trust Framework Schemas and Utilities",
5
5
  "main": "index.js",
6
6
  "directories": {
@@ -381,6 +381,63 @@
381
381
  "consumerProtectionRegulationsResponse": true
382
382
  }
383
383
  },
384
+ "additionalLegalInfo": {
385
+ "namesOfLegalOwners": [
386
+ {
387
+ "firstName": "Peter",
388
+ "lastName": "Hetherington-Smythe"
389
+ }
390
+ ],
391
+ "sellersConveyancer": {
392
+ "firstName": "John",
393
+ "lastName": "Lawson",
394
+ "address": { "line1": "66 Railway Ave", "postcode": "SL12 1AA" },
395
+ "email": "john@bodgit.co.uk",
396
+ "organisation": "Bodgit, Leggit and Run Partners",
397
+ "reference": "12345"
398
+ },
399
+ "sellersCapacity": { "capacity": "Legal Owner" },
400
+ "legalBoundaries": {
401
+ "left": "Seller",
402
+ "right": "Seller",
403
+ "rear": "Next-door neighbour",
404
+ "front": "Next-door neighbour",
405
+ "areBoundariesUniform": { "yesNo": "Yes" },
406
+ "haveBoundaryFeaturesMoved": { "yesNo": "No" },
407
+ "adjacentLandIncluded": { "yesNo": "No" },
408
+ "titlePlanAccurate": { "yesNo": "Yes" },
409
+ "flyingFreehold": { "yesNo": "No" }
410
+ },
411
+ "servicesCrossing": {
412
+ "pipesWiresCablesDrainsToProperty": { "yesNo": "No" },
413
+ "pipesWiresCablesDrainsFromProperty": { "yesNo": "No" },
414
+ "formalOrInformalAgreements": { "yesNo": "No" }
415
+ },
416
+ "energyAndMeters": {
417
+ "testedByQualifiedElectrician": { "yesNo": "Yes", "details": "2015" },
418
+ "electricalWorkSince2005": { "yesNo": "No" },
419
+ "solarPanels": { "hasSolarPanels": "No" }
420
+ },
421
+ "smartHomeSystems": { "hasSmartHomeSystems": "No" },
422
+ "guaranteesWarrantiesAndIndemnityInsurances": {
423
+ "hasValidGuaranteesOrWarranties": "No"
424
+ },
425
+ "occupiers": {
426
+ "sellerLivesAtProperty": { "yesNo": "Yes" },
427
+ "otherOver17sAtProperty": [],
428
+ "over17sWillSignToConfirmWillVacate": { "yesNo": "Yes" }
429
+ },
430
+ "completionAndMoving": {
431
+ "willRemoveAllRubbish": true,
432
+ "otherPropertyInChain": { "yesNo": "No" },
433
+ "moveRestrictionDates": { "yesNo": "No" },
434
+ "digitalPropertyLogbook": { "yesNo": "No" }
435
+ },
436
+ "confirmationOfAccuracyByOwners": {
437
+ "confirmWillProvideAdditionalDocumentation": true,
438
+ "confirmInformationIsAccurate": true
439
+ }
440
+ },
384
441
  "energyPerformanceCertificate": {
385
442
  "certificate": { "currentEnergyRating": "B" }
386
443
  },
@@ -655,7 +712,7 @@
655
712
  "RegisterEntry": [
656
713
  {
657
714
  "EntryDate": "2020-11-24",
658
- "EntryText": "PROPRIETOR: PETER RONALD HETHERINGTON-SMYTH and CLARISSA JANE HETHERINGTON-SMYTH of 47 Park Mount, Harpenden AL3 5AF.",
715
+ "EntryText": "PROPRIETOR: PETER RONALD HETHERINGTON-SMYTH and CLARISSA JANE HETHERINGTON-SMYTH of 47 Park Road, Harpenden AL3 5AF.",
659
716
  "EntryType": "Proprietor",
660
717
  "EntryNumber": "1"
661
718
  },