Fix bug with unlinking user orders on lists load over active list

This commit is contained in:
2014-08-11 13:40:20 +02:00
parent af45377679
commit 28192f8e39
18 changed files with 66 additions and 62 deletions
@@ -3,6 +3,7 @@ class UserExtendedSupplierSerializer < Qwaiter::Serializer
embed :ids, include: true
attributes :extended_version, :open, :name, :orders_in_process_count, :orders_placed_count
has_many :product_categories
has_many :products
def extended_version
true
+3 -1
View File
@@ -1,6 +1,6 @@
class UserListSerializer < Qwaiter::Serializer
# user ids for facebook pictures
#embed :ids
embed :ids
attributes :state, :needs_help, :needs_payment, :user_requests_closing, :is_paid, :price, :table_id, :table_number, :section_id, :user_ids, :supplier_name, :closed_at, :supplier_id
#def has_active_orders
@@ -9,4 +9,6 @@ class UserListSerializer < Qwaiter::Serializer
def supplier_name
object.supplier.name
end
has_many :users
has_many :orders
end