app/helpers/spree/api/api_helpers.rb in spree_api-2.0.13 vs app/helpers/spree/api/api_helpers.rb in spree_api-2.1.0
- old
+ new
@@ -10,31 +10,31 @@
required_fields.map!(&:to_s).delete("permalink")
required_fields
end
def product_attributes
- [:id, :name, :description, :price, :available_on, :permalink, :meta_description, :meta_keywords, :shipping_category_id, :taxon_ids]
+ [:id, :name, :description, :price, :display_price, :available_on, :permalink, :meta_description, :meta_keywords, :shipping_category_id, :taxon_ids]
end
def product_property_attributes
[:id, :product_id, :property_id, :value, :property_name]
end
def variant_attributes
- [:id, :name, :sku, :price, :weight, :height, :width, :depth, :is_master, :cost_price, :permalink]
+ [:id, :name, :sku, :price, :weight, :height, :width, :depth, :is_master, :cost_price, :permalink, :description]
end
def image_attributes
[:id, :position, :attachment_content_type, :attachment_file_name, :type, :attachment_updated_at, :attachment_width, :attachment_height, :alt]
end
def option_value_attributes
- [:id, :name, :presentation, :option_type_name, :option_type_id, :option_type_presentation]
+ [:id, :name, :presentation, :option_type_name, :option_type_id]
end
def order_attributes
- [:id, :number, :item_total, :total, :ship_total, :state, :adjustment_total, :user_id, :created_at, :updated_at, :completed_at, :payment_total, :shipment_state, :payment_state, :email, :special_instructions, :token, :channel, :currency]
+ [:id, :number, :item_total, :total, :state, :adjustment_total, :user_id, :created_at, :updated_at, :completed_at, :payment_total, :shipment_state, :payment_state, :email, :special_instructions]
end
def line_item_attributes
[:id, :quantity, :price, :variant_id]
end
@@ -42,11 +42,11 @@
def option_type_attributes
[:id, :name, :presentation, :position]
end
def payment_attributes
- [:id, :source_type, :source_id, :amount, :display_amount, :payment_method_id, :response_code, :state, :avs_response, :created_at, :updated_at]
+ [:id, :source_type, :source_id, :amount, :payment_method_id, :response_code, :state, :avs_response, :created_at, :updated_at]
end
def payment_method_attributes
[:id, :name, :description]
end
@@ -58,11 +58,11 @@
def taxonomy_attributes
[:id, :name]
end
def taxon_attributes
- [:id, :name, :pretty_name, :permalink, :parent_id, :taxonomy_id]
+ [:id, :name, :pretty_name, :permalink, :position, :parent_id, :taxonomy_id]
end
def inventory_unit_attributes
[:id, :lock_version, :state, :variant_id, :shipment_id, :return_authorization_id]
end
@@ -111,5 +111,6 @@
[:id, :count_on_hand, :backorderable, :lock_version, :stock_location_id, :variant_id]
end
end
end
end
+