소스 검색

Merge pull request #63 from Shopify/feature/expose_smartcollection#order

add order to ShopifyAPI::SmartCollection
Neil Costford 11 년 전
부모
커밋
c9a53d6157
1개의 변경된 파일5개의 추가작업 그리고 0개의 파일을 삭제
  1. 5 0
      lib/shopify_api/resources/smart_collection.rb

+ 5 - 0
lib/shopify_api/resources/smart_collection.rb

@@ -6,5 +6,10 @@ module ShopifyAPI
     def products
       Product.find(:all, :params => {:collection_id => self.id})
     end
+
+    def order(options={})
+      load_attributes_from_response(put(:order, options, only_id))
+    end
+
   end
 end