Commit 2021fed7 authored by Jérome Perrin's avatar Jérome Perrin

Custom: Add Donor Analytic Code as an analytic column (hardcoded)

Conflicts:
	bt5/erp5_accounting/SkinTemplateItem/portal_skins/erp5_accounting/AccountModule_getTrialBalanceReportSectionList.xml
parent 76e9e41e
......@@ -697,7 +697,10 @@ for key, data in line_per_account.items():\n
sort_key = (node_string_index, node_title, mirror_section_title)\n
analytic_dict = {}\n
for analytic, uid in zip(group_analytic, analytic_key_list):\n
title = getAnalyticTitleFromUid(uid)\n
if analytic == \'string_index\':\n
title = uid\n
else:\n
title = getAnalyticTitleFromUid(uid)\n
analytic_dict[analytic] = title\n
if analytic == \'section_uid\':\n
analytic_dict[\'Movement_getSectionPriceCurrency\'] = getSectionPriceCurrencyFromSectionUid(uid)\n
......
......@@ -101,6 +101,9 @@ for base_category in \\\n
title = portal.portal_categories.restrictedTraverse(base_category).getTitle()\n
analytic_column_list += ((\'%s_translated_title\' % base_category, title),)\n
\n
# XXX should be based on some preference !\n
analytic_column_list += ((\'string_index\', \'Donor Analytic Code\'),)\n
\n
return analytic_column_list\n
</string> </value>
</item>
......
......@@ -122,6 +122,9 @@ for analytic in group_analytic:\n
elif analytic == \'section\':\n
extra_columns += ((\'section_uid\', \'Section\'), (\'Movement_getSectionPriceCurrency\', \'Accounting Currency\'))\n
group_analytic_uid += (\'section_uid\',)\n
elif analytic == \'string_index\':\n
extra_columns += ((\'string_index\', \'Donor Analytic Code\'),)\n
group_analytic_uid += (\'string_index\',)\n
else:\n
for analytic_column in possible_analytic_column_list:\n
if analytic_column[0] == analytic:\n
......
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