Update nesting level to depth 2 when returning lots not UiTree

This commit is contained in:
yiorgos marinellis 2020-04-29 20:41:32 +02:00
parent 2851d4112f
commit e021702e0c
1 changed files with 1 additions and 1 deletions

View File

@ -93,7 +93,7 @@ class LotView(View):
query = query.filter(Lot.name.ilike(args['search'] + '%')) query = query.filter(Lot.name.ilike(args['search'] + '%'))
lots = query.paginate(per_page=6 if args['search'] else 30) lots = query.paginate(per_page=6 if args['search'] else 30)
return things_response( return things_response(
self.schema.dump(lots.items, many=True, nested=0), self.schema.dump(lots.items, many=True, nested=2),
lots.page, lots.per_page, lots.total, lots.prev_num, lots.next_num lots.page, lots.per_page, lots.total, lots.prev_num, lots.next_num
) )
return jsonify(ret) return jsonify(ret)