Improve stuff and add counters

This commit is contained in:
2014-04-07 10:46:10 +02:00
parent 7915cc6684
commit 19acd26dbc
8 changed files with 64 additions and 6 deletions
@@ -10,8 +10,8 @@ class UserExtendedListSerializer < Qwaiter::Serializer
self.root = :list
embed :ids, include: true
attributes :extended_version, :state, :needs_help, :needs_payment, :is_paid, :price,
:table_id, :table_number, :section_id, :user_ids,
:supplier_orders_in_process_count, :supplier_orders_placed_count, :supplier_id
:table_id, :table_number, :section_id, :user_ids, :supplier_id
#:supplier_orders_in_process_count, :supplier_orders_placed_count
def has_active_orders
object.has_active_orders?
@@ -21,7 +21,7 @@ class UserExtendedListSerializer < Qwaiter::Serializer
has_one :table, serializer: UserExtendedTableSerializer
has_many :join_requests
has_many :users, serializer: UserUserSerializer
#has_one :supplier
#has_one :supplier # added by other resource
def extended_version
true