Commit 57a2077c authored by Mame Coumba Sall's avatar Mame Coumba Sall

2008-12-18 mame

*modify script so that report can hide positive and negative stock at the same time, or positive and zero stock or negative and zero stock

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@24939 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 86952248
......@@ -79,12 +79,18 @@ for x in context.portal_simulation.getCurrentInventoryList(\n
# XXX resourceType= uses movement table.\n
# resource_portal_type= does not work with cells (because resource is acquired from line)\n
resourceType=context.getPortalProductTypeList(), **kw):\n
if x.inventory <=0 and positive_stock:\n
if positive_stock and negative_stock and not zero_stock and x.inventory == 0:\n
result_list.append(x)\n
if x.inventory>=0 and negative_stock:\n
if positive_stock and not negative_stock and zero_stock and x.inventory <0:\n
result_list.append(x)\n
if negative_stock and zero_stock and not positive_stock and x.inventory >0:\n
result_list.append(x)\n
if positive_stock and not negative_stock and not zero_stock and x.inventory <=0:\n
result_list.append(x)\n
if negative_stock and not positive_stock and not zero_stock and x.inventory >=0:\n
result_list.append(x)\n
if zero_stock and not positive_stock and not negative_stock and x.inventory!=0:\n
result_list.append(x)\n
if x.inventory!=0 and zero_stock:\n
result_list.append(x) \n
if not positive_stock and not negative_stock and not zero_stock:\n
result_list.append(x)\n
\n
......
551
\ No newline at end of file
552
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment