Commit f535c1b9 authored by Jérome Perrin's avatar Jérome Perrin

Budget consumption report: support filtering on multiple budget types & budget models

parent 709f2b5a
...@@ -73,7 +73,7 @@ ...@@ -73,7 +73,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>field_id</string> </key> <key> <string>field_id</string> </key>
<value> <string>your_category</string> </value> <value> <string>your_category_list</string> </value>
</item> </item>
<item> <item>
<key> <string>form_id</string> </key> <key> <string>form_id</string> </key>
......
...@@ -81,10 +81,10 @@ else:\n ...@@ -81,10 +81,10 @@ else:\n
validation_state=validation_state)\n validation_state=validation_state)\n
budget_type = request.get(\'budget_type\')\n budget_type = request.get(\'budget_type\')\n
if budget_type:\n if budget_type:\n
search_kw[\'default_budget_type_uid\'] = portal.portal_categories.budget_type.restrictedTraverse(budget_type).getUid()\n search_kw[\'default_budget_type_uid\'] = [portal.portal_categories.budget_type.restrictedTraverse(x).getUid() for x in budget_type]\n
specialise = request.get(\'specialise\')\n specialise = request.get(\'specialise\')\n
if specialise:\n if specialise:\n
search_kw[\'default_specialise_uid\'] = portal.restrictedTraverse(specialise).getUid()\n search_kw[\'default_specialise_uid\'] = [portal.restrictedTraverse(x).getUid() for x in specialise]\n
\n \n
budget_list = portal.portal_catalog.searchResults(**search_kw)\n budget_list = portal.portal_catalog.searchResults(**search_kw)\n
group_filtered_budget_list = []\n group_filtered_budget_list = []\n
......
372 373
\ No newline at end of file \ 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