Class: Gemgento::ProductCategory
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- Gemgento::ProductCategory
- Includes:
- ProductTouches
- Defined in:
- app/models/gemgento/product_category.rb
Overview
Instance Attribute Summary collapse
-
#sync_needed ⇒ Object
Returns the value of attribute sync_needed.
Instance Method Summary collapse
Instance Attribute Details
#sync_needed ⇒ Object
Returns the value of attribute sync_needed.
20 21 22 |
# File 'app/models/gemgento/product_category.rb', line 20 def sync_needed @sync_needed end |
Instance Method Details
#update_magento_category_product ⇒ Object
22 23 24 25 26 27 28 29 30 31 32 |
# File 'app/models/gemgento/product_category.rb', line 22 def update_magento_category_product response = API::SOAP::Catalog::Category.update_product(self) if response.success? self.sync_needed = false return true else errors.add(:base, response.body[:faultstring]) return false end end |