updates based on F5 testing

This commit is contained in:
2020-03-06 08:35:12 -05:00
parent 8288595b3f
commit f1ef618dae
18 changed files with 66 additions and 32 deletions
+14 -2
View File
@@ -15,8 +15,20 @@ module Users
#EMBER
def current
@list = current_user.active_list
params[:id] = @list.try(:id) # serializer determines collection or not based on the presence of this
show
render json: {}, status: :not_found and return unless @list.present? && Array.wrap(@list.user_ids).include?(current_user.id)
include_config = %w[
supplier
supplier.product_categories
supplier.product_categories.products
supplier.product_categories.products.product_variants
join_requests
join_requests.user
table
orders
orders.product_orders
]
include_config << 'users' if @list.user_ids.size > 1
render json: @list, include: include_config, serializer: Users::ListSerializer, is_collection: false
end
def table