Fixed grid join map bug.

This commit is contained in:
Lance Edgar 2013-09-20 15:49:48 -07:00
parent 685b391dd2
commit 23e08d0bb0
2 changed files with 4 additions and 9 deletions

View file

@ -73,11 +73,6 @@ class ProductsGrid(SearchableAlchemyGridView):
# q = q.outerjoin(Vendor)
# return q
def join_vendor_any(q):
return q.outerjoin(ProductCost,
ProductCost.product_uuid == Product.uuid)\
.outerjoin(Vendor)
return {
'brand':
lambda q: q.outerjoin(Brand),
@ -96,7 +91,7 @@ class ProductsGrid(SearchableAlchemyGridView):
# 'vendor':
# join_vendor,
'vendor_any':
join_vendor_any,
lambda q: q.outerjoin(ProductCost, ProductCost.product_uuid == Product.uuid).outerjoin(Vendor),
'code':
lambda q: q.outerjoin(ProductCode),
}