Commit fc63f45d authored by Nicolas Dumazet's avatar Nicolas Dumazet

filter validation state directly in catalog query


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@32198 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 73ee3a45
......@@ -56,13 +56,12 @@
<value> <string>def getUniversalQuantityUnitDefinitionDict():\n
\n
kw = dict(portal_type="Quantity Unit Conversion Definition",\n
grand_parent_portal_type="Quantity Unit Conversion Module")\n
grand_parent_portal_type="Quantity Unit Conversion Module",\n
validation_state="validated")\n
\n
result = {}\n
for definition in context.portal_catalog(**kw):\n
definition = definition.getObject()\n
if definition.getValidationState() != "validated":\n
continue\n
\n
definition_group = definition.getParentValue()\n
if definition_group.getValidationState() != "validated":\n
......
442
\ No newline at end of file
443
\ 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