Skip to content

Commit

Permalink
Update Models for Core v2.90
Browse files Browse the repository at this point in the history
  • Loading branch information
calcinai committed Mar 5, 2015
1 parent 0d9dafa commit baa7d66
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 2 deletions.
28 changes: 27 additions & 1 deletion src/XeroPHP/Models/Accounting/Currency.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@

class Currency extends Remote\Object {

/**
* A UTC timestamp (YYYYMMDDHHMMSS) . Only currencies created or modified since this timestamp will be
* returned e.g. 20090901000000
*
* @property \DateTime ModifiedAfter
*/

/**
* 3 letter alpha code for the currency – see list of currency codes
*
Expand All @@ -27,7 +34,7 @@ class Currency extends Remote\Object {
* @return string
*/
public static function getResourceURI(){
return null;
return 'Currencies';
}


Expand Down Expand Up @@ -66,6 +73,7 @@ public static function getAPIStem(){
*/
public static function getSupportedMethods(){
return array(
Remote\Request::METHOD_GET
);
}

Expand All @@ -81,12 +89,30 @@ public static function getSupportedMethods(){
*/
public static function getProperties(){
return array(
'ModifiedAfter' => array (false, self::PROPERTY_TYPE_DATE, '\\DateTime', false),
'Code' => array (false, self::PROPERTY_TYPE_STRING, null, false),
'Description' => array (false, self::PROPERTY_TYPE_STRING, null, false)
);
}


/**
* @return \DateTime
*/
public function getModifiedAfter(){
return $this->_data['ModifiedAfter'];
}

/**
* @param \DateTime $value
* @return Currency
*/
public function setModifiedAfter(\DateTime $value){
$this->propertyUpdated('ModifiedAfter', $value);
$this->_data['ModifiedAfter'] = $value;
return $this;
}

/**
* @return string
*/
Expand Down
3 changes: 2 additions & 1 deletion src/XeroPHP/Models/Accounting/Organisation.php
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ class Organisation extends Remote\Object {
* @return string
*/
public static function getResourceURI(){
return null;
return 'Organisation';
}


Expand Down Expand Up @@ -234,6 +234,7 @@ public static function getAPIStem(){
*/
public static function getSupportedMethods(){
return array(
Remote\Request::METHOD_GET
);
}

Expand Down

0 comments on commit baa7d66

Please sign in to comment.