public function testProductResource() { $product = BigCommerce_Api::getProduct(1); $this->assertEquals(1, $product->id); }
/** * Internal method to wrap items in a collection to resource classes. * * @param string $resource name of the resource class * @param array $object object collection * @return array */ private static function mapCollection($resource, $object) { if ($object == false || is_string($object)) { return $object; } self::$resource = $resource; return array_map(array('self', 'mapCollectionObject'), $object); }
public function update() { return BigCommerce_Api::updateBrand($this->id, $this->getUpdateFields()); }