frozensheep / rightmoveADF

PHP library for the Rightmove Real Time Property Datafeed (ADF).
MIT License
17 stars 20 forks source link

Added support for commercial property sizing attributes (RightmoveADF v1.3) #6

Open darrylfriend opened 7 years ago

darrylfriend commented 7 years ago

RightMove ADF 1.3 specifies that commercial property sizing is its own object on the details object. This PR adds a sizing group, which attaches to the details group.

Usage:

$request->property->details->sizing->minimum = 100;
$request->property->details->sizing->maximum = 200;
$request->property->details->sizing->area_unit = 2;

---- Below is the Rightmove spec for sizing ---


"sizing":{
     "type":"object",
     "id":"sizing",
     "required":false,
     "description":"The size details about the property being be sent",
     "properties": {
          "minimum":{
               "type":["number", "null"],
               "id":"minimum",
               "required":false,
               "minimum":0,
               "description":"The minimum size of the property being sent"
          },
          "maximum":{
               "type":["number", "null"],
               "id":"maximum",
               "required":false,
               "minimum":0,
               "description":"The maximum size of the property being sent"
          },
          "area_unit":{
               "type":["integer", "null"],
               "id":"area_unit",
               "required":false,
               "enum":[1, 2, 3, 4, null],
               "description":"Units which the property size is sent in: 1 sq ft 2 sq m 3 acre 4 hectares"
          }
     }
}```
coveralls commented 7 years ago

Coverage Status

Coverage remained the same at 0.0% when pulling 3e22b82e97e80a67fa7b2b813fd672399a9bae75 on darrylfriend:commercial-property-sizing into 28f9fdd031a4a8f3200811f9791f5ea355604c9a on frozensheep:master.