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

XXX: all local changes before doing more changes

parent 33e9f862

Too many changes to show.

To preserve performance only 1000 of 1000+ files are displayed.

......@@ -71,7 +71,7 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/MovementGroup_view</string> </value>
<value> <string>string:${object_url}/AccountingRuleCellLine_view</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -54,7 +54,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>View</string> </value>
<value> <string>View Source</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
......@@ -71,7 +71,7 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/ConfiguratorItem_view</string> </value>
<value> <string>string:${object_url}/AccountingRuleCell_viewSource</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -38,7 +38,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>view</string> </value>
<value> <string>view_destination</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
......@@ -50,11 +50,11 @@
</item>
<item>
<key> <string>priority</string> </key>
<value> <float>1.0</float> </value>
<value> <float>2.0</float> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>View</string> </value>
<value> <string>View Destination</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
......@@ -71,7 +71,7 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/ConfiguratorItem_view</string> </value>
<value> <string>string:${object_url}/AccountingRuleCell_viewDestination</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -30,9 +30,7 @@
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
<value> <string></string> </value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -75,7 +73,7 @@
<key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[
string:${object_url}/AccountModule_viewAccountStatementReportDialog?your_portal_skin=ODS&your_format=&field_your_export:int=1
string:${object_url}/AccountModule_viewAccountStatementReportDialog?your_portal_skin=ODS&your_format=
]]></string> </value>
</item>
......
......@@ -30,9 +30,7 @@
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
<value> <string></string> </value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -75,7 +73,7 @@
<key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[
string:${object_url}/AccountModule_viewGeneralLedgerReportDialog?your_portal_skin=ODS&your_format=&your_export:int=1
string:${object_url}/AccountModule_viewGeneralLedgerReportDialog?your_portal_skin=ODS&your_format=
]]></string> </value>
</item>
......
......@@ -30,9 +30,7 @@
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
<value> <string></string> </value>
</item>
<item>
<key> <string>icon</string> </key>
......
......@@ -77,7 +77,7 @@
<key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[
string:${object_url}/accounting_module/AccountModule_viewAccountStatementReportDialog?mirror_section=${object/getRelativeUrl}&your_portal_skin=ODS&your_format=&field_your_export:int=1
string:${object_url}/accounting_module/AccountModule_viewAccountStatementReportDialog?mirror_section=${object/getRelativeUrl}&your_portal_skin=ODS&your_format=
]]></string> </value>
</item>
......
......@@ -77,7 +77,7 @@
<key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[
string:${object_url}/accounting_module/AccountModule_viewGeneralLedgerReportDialog?mirror_section=${object/getRelativeUrl}&your_portal_skin=ODS&your_format=&field_your_export:int=1
string:${object_url}/accounting_module/AccountModule_viewGeneralLedgerReportDialog?mirror_section=${object/getRelativeUrl}&your_portal_skin=ODS&your_format=
]]></string> </value>
</item>
......
......@@ -77,7 +77,7 @@
<key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[
string:${object_url}/accounting_module/AccountModule_viewAccountStatementReportDialog?mirror_section=${object/getRelativeUrl}&your_portal_skin=ODS&your_format=&field_your_export:int=1
string:${object_url}/accounting_module/AccountModule_viewAccountStatementReportDialog?mirror_section=${object/getRelativeUrl}&your_portal_skin=ODS&your_format=
]]></string> </value>
</item>
......
......@@ -77,7 +77,7 @@
<key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[
string:${object_url}/accounting_module/AccountModule_viewGeneralLedgerReportDialog?mirror_section=${object/getRelativeUrl}&your_portal_skin=ODS&your_format=&field_your_export:int=1
string:${object_url}/accounting_module/AccountModule_viewGeneralLedgerReportDialog?mirror_section=${object/getRelativeUrl}&your_portal_skin=ODS&your_format=
]]></string> </value>
</item>
......
......@@ -6,6 +6,53 @@
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_folders_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Copy_or_Move_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Delete_objects_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_count</string> </key>
<value>
......
<module>
<category_list>
<category>business_application/accounting</category>
</category_list>
<id>account_module</id>
<permission_list>
<permission type='tuple'>
......
<module>
<category_list>
<category>business_application/accounting</category>
</category_list>
<id>accounting_module</id>
<permission_list>
<permission type='tuple'>
......
......@@ -6,6 +6,53 @@
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_folders_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Copy_or_Move_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Delete_objects_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_count</string> </key>
<value>
......@@ -42,9 +89,13 @@
<key> <string>portal_type</string> </key>
<value> <string>Category</string> </value>
</item>
<item>
<key> <string>short_title</string> </key>
<value> <string>Assets</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Asset</string> </value>
<value> <string>Assets</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -6,6 +6,53 @@
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_folders_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Copy_or_Move_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Delete_objects_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_count</string> </key>
<value>
......@@ -42,6 +89,10 @@
<key> <string>portal_type</string> </key>
<value> <string>Category</string> </value>
</item>
<item>
<key> <string>short_title</string> </key>
<value> <string>Equity</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Equity</string> </value>
......
......@@ -6,6 +6,53 @@
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_folders_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Copy_or_Move_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Delete_objects_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_count</string> </key>
<value>
......@@ -42,6 +89,10 @@
<key> <string>portal_type</string> </key>
<value> <string>Category</string> </value>
</item>
<item>
<key> <string>short_title</string> </key>
<value> <string>Expense</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Expense</string> </value>
......
......@@ -6,6 +6,53 @@
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_folders_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Copy_or_Move_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Delete_objects_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_count</string> </key>
<value>
......@@ -42,6 +89,10 @@
<key> <string>portal_type</string> </key>
<value> <string>Category</string> </value>
</item>
<item>
<key> <string>short_title</string> </key>
<value> <string>Income</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Income</string> </value>
......
......@@ -6,6 +6,53 @@
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_folders_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Copy_or_Move_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Delete_objects_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_count</string> </key>
<value>
......@@ -42,6 +89,10 @@
<key> <string>portal_type</string> </key>
<value> <string>Category</string> </value>
</item>
<item>
<key> <string>short_title</string> </key>
<value> <string>Liability</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Liability</string> </value>
......
......@@ -5,6 +5,10 @@
<portal_type id="Accounting Period">
<item>Accounting Period</item>
</portal_type>
<portal_type id="Accounting Rule Cell">
<item>Accounting Rule Cell Line</item>
<item>Accounting Transaction Line</item>
</portal_type>
<portal_type id="Accounting Transaction">
<item>Accounting Transaction Line</item>
<item>Embedded File</item>
......@@ -44,6 +48,7 @@
<item>Cash Register</item>
</portal_type>
<portal_type id="Payment Simulation Rule">
<item>Accounting Rule Cell</item>
<item>Category Membership Divergence Tester</item>
<item>DateTime Divergence Tester</item>
<item>Float Divergence Tester</item>
......
<hidden_content_type_list>
<portal_type id="Accounting Rule Cell">
<item>Accounting Transaction Line</item>
</portal_type>
<portal_type id="Accounting Transaction">
<item>Embedded File</item>
</portal_type>
......
<property_sheet_list>
<portal_type id="Accounting Rule Cell Line">
<item>AccountingRuleCellLine</item>
</portal_type>
<portal_type id="Accounting Transaction">
<item>AccountingTransactionConstraint</item>
</portal_type>
......
......@@ -25,72 +25,57 @@
</dictionary>
</value>
</item>
<item>
<key> <string>acquire_local_roles</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>content_icon</string> </key>
<value>
<none/>
</value>
<value> <string></string> </value>
</item>
<item>
<key> <string>content_meta_type</string> </key>
<value> <string>ERP5 Accounting Transaction Line</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
<value> <string>A line inside an accounting rule cell</string> </value>
</item>
<item>
<key> <string>factory</string> </key>
<value> <string>addXMLObject</string> </value>
<value> <string>addAccountingTransactionLine</string> </value>
</item>
<item>
<key> <string>filter_content_types</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>group_list</string> </key>
<value>
<tuple>
<string>delivery_movement</string>
<string>movement_group</string>
<string>accounting_movement</string>
</tuple>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Implicit Item Movement</string> </value>
<value> <string>Accounting Rule Cell Line</string> </value>
</item>
<item>
<key> <string>init_script</string> </key>
<value>
<none/>
</value>
<value> <string></string> </value>
</item>
<item>
<key> <string>permission</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Base Type</string> </value>
<value> <string></string> </value>
</item>
<item>
<key> <string>searchable_text_property_id</string> </key>
<value>
<tuple/>
</value>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>type_class</string> </key>
<value> <string>ImplicitItemMovement</string> </value>
</item>
<item>
<key> <string>type_interface</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>type_mixin</string> </key>
<value>
<tuple/>
</value>
<value> <string>AccountingTransactionLine</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -25,33 +25,52 @@
</dictionary>
</value>
</item>
<item>
<key> <string>acquire_local_roles</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>content_icon</string> </key>
<value> <string>folder_icon.gif</string> </value>
<value> <string>document.gif</string> </value>
</item>
<item>
<key> <string>content_meta_type</string> </key>
<value> <string>ERP5 Accounting Rule Cell</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string>An AccountingRuleCell object allows to add SaleInvoiceTransactionLines into a Matrix\n
</string> </value>
</item>
<item>
<key> <string>factory</string> </key>
<value> <string>addFolder</string> </value>
<value> <string>addAccountingRuleCell</string> </value>
</item>
<item>
<key> <string>filter_content_types</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>group_list</string> </key>
<value>
<tuple>
<string>module</string>
</tuple>
<tuple/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Implicit Item Movement Module</string> </value>
<value> <string>Accounting Rule Cell</string> </value>
</item>
<item>
<key> <string>init_script</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Base Type</string> </value>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>type_class</string> </key>
<value> <string>Folder</string> </value>
<value> <string>AccountingRuleCell</string> </value>
</item>
</dictionary>
</pickle>
......@@ -64,7 +83,9 @@
<dictionary>
<item>
<key> <string>domain_name</string> </key>
<value> <string>erp5_ui</string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>property_name</string> </key>
......@@ -81,7 +102,9 @@
<dictionary>
<item>
<key> <string>domain_name</string> </key>
<value> <string>erp5_ui</string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>property_name</string> </key>
......
......@@ -54,6 +54,10 @@
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>type_class</string> </key>
<value> <string>InvoiceRootSimulationRule</string> </value>
</item>
</dictionary>
</pickle>
</record>
......
......@@ -54,6 +54,10 @@
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>type_class</string> </key>
<value> <string>PaymentSimulationRule</string> </value>
</item>
</dictionary>
</pickle>
</record>
......
......@@ -59,6 +59,7 @@ from ZTUtils import LazyFilter\n
request = container.REQUEST\n
portal = context.getPortalObject()\n
getInventoryList = portal.portal_simulation.getInventoryList\n
getInventory = portal.portal_simulation.getInventoryAssetPrice\n
traverse = context.getPortalObject().restrictedTraverse\n
getObject = context.getPortalObject().portal_catalog.getObject\n
Base_translateString = portal.Base_translateString\n
......@@ -185,19 +186,6 @@ def getAnalyticTitleFromUid(uid):\n
title = \'%s - %s\' % (reference, title)\n
return analytic_title_dict.setdefault(uid, title)\n
\n
section_price_currency_dict = {None: \'\'}\n
def getSectionPriceCurrencyFromSectionUid(uid):\n
if uid is MARKER:\n
return \'\'\n
try:\n
return section_price_currency_dict[uid]\n
except KeyError:\n
section = getObject(uid)\n
price_currency = \'\'\n
if section is not None:\n
price_currency = section.getProperty(\'price_currency_reference\')\n
return section_price_currency_dict.setdefault(uid, price_currency)\n
\n
# standards accounts {{{\n
for node in getInventoryList(\n
node_category_strict_membership=account_type_to_group_by_node,\n
......@@ -374,8 +362,6 @@ for node in getInventoryList(\n
**inventory_params):\n
account_props = line_per_account.setdefault(getKey(node), dict(debit=0, credit=0))\n
total_price = node[\'total_price\'] or 0\n
account_props[\'initial_balance\'] = account_props.get(\n
\'initial_balance\', 0) + total_price\n
account_props[\'initial_debit_balance\'] = account_props.get(\n
\'initial_debit_balance\', 0) + max(total_price, 0)\n
account_props[\'initial_credit_balance\'] = account_props.get(\n
......@@ -393,8 +379,6 @@ for node in getInventoryList(\n
**inventory_params):\n
account_props = line_per_account.setdefault(getKey(node), dict(debit=0, credit=0))\n
total_price = node[\'total_price\'] or 0\n
account_props[\'initial_balance\'] = account_props.get(\n
\'initial_balance\', 0) + total_price\n
account_props[\'initial_debit_balance\'] = account_props.get(\n
\'initial_debit_balance\', 0) + max(total_price, 0)\n
account_props[\'initial_credit_balance\'] = account_props.get(\n
......@@ -678,17 +662,16 @@ for key, data in line_per_account.items():\n
total_final_balance_if_debit += round(max(closing_balance, 0), precision)\n
total_final_balance_if_credit += round(max(-closing_balance, 0) or 0, precision)\n
\n
\n
line = Object(uid=\'new_\',\n
node_id=node_id,\n
node_title=node_title,\n
mirror_section_title=mirror_section_title,\n
node_relative_url=node_relative_url,\n
initial_balance=initial_debit_balance - initial_credit_balance,\n
initial_debit_balance=initial_debit_balance,\n
initial_credit_balance=initial_credit_balance,\n
debit=data[\'debit\'],\n
credit=data[\'credit\'],\n
final_balance=final_debit_balance - final_credit_balance,\n
final_debit_balance=final_debit_balance,\n
final_credit_balance=final_credit_balance,\n
final_balance_if_debit=max(closing_balance, 0),\n
......@@ -699,14 +682,11 @@ for key, data in line_per_account.items():\n
for analytic, uid in zip(group_analytic, analytic_key_list):\n
title = getAnalyticTitleFromUid(uid)\n
analytic_dict[analytic] = title\n
if analytic == \'section_uid\':\n
analytic_dict[\'Movement_getSectionPriceCurrency\'] = getSectionPriceCurrencyFromSectionUid(uid)\n
# We sort on section title first\n
sort_key = (title, ) + sort_key\n
sort_key += (title, )\n
\n
\n
analytic_dict[\'sort_key\'] = sort_key\n
line.update(analytic_dict)\n
\n
line_list.append(line)\n
\n
\n
......@@ -740,10 +720,10 @@ def getAccountClass(account_relative_url):\n
account = traverse(account_relative_url)\n
for gap in account.getGapList():\n
if gap.startswith(current_gap):\n
gap_part_list = gap.split(\'/\')\n
# country / accounting principle / ${class}\n
if len(gap_part_list) > 2:\n
return gap_part_list[2]\n
gap_part_list = gap.split(\'/\')\n
# country / accounting principle / ${class}\n
if len(gap_part_list) > 2:\n
return gap_part_list[2]\n
return None # this account has no class on the current GAP \n
\n
new_line_list = []\n
......@@ -776,11 +756,10 @@ for account_class in account_class_list:\n
final_balance_if_debit += account.final_balance_if_debit\n
final_balance_if_credit += account.final_balance_if_credit\n
add_line(account)\n
\n
\n
# summary\n
add_line(Object(node_title=Base_translateString(\'Total for class ${account_class}\',\n
mapping=dict(account_class=account_class or \'???\')),\n
initial_balance=round(initial_debit_balance - initial_credit_balance, precision),\n
initial_debit_balance=round(initial_debit_balance, precision),\n
debit=round(debit, precision),\n
final_debit_balance=round(final_debit_balance, precision),\n
......@@ -788,8 +767,7 @@ for account_class in account_class_list:\n
credit=round(credit, precision),\n
final_credit_balance=round(final_credit_balance, precision),\n
final_balance_if_debit=round(final_balance_if_debit, precision),\n
final_balance_if_credit=round(final_balance_if_credit, precision),\n
final_balance=round(final_debit_balance - final_credit_balance, precision),))\n
final_balance_if_credit=round(final_balance_if_credit, precision),))\n
\n
add_line(Object(node_title=\' \'))\n
\n
......
......@@ -90,8 +90,6 @@ period_start_date = context\\\n
section_category=request[\'section_category\'],\n
date=from_date or at_date)\n
\n
export = request[\'export\']\n
\n
# Also get the currency, to know the precision\n
currency = context.Base_getCurrencyForSection(request[\'section_category\'])\n
precision = context.account_module.getQuantityPrecisionFromResource(currency)\n
......@@ -146,27 +144,21 @@ if hide_analytic:\n
else:\n
analytic_column_list = context.AccountModule_getAnalyticColumnList()\n
params[\'analytic_column_list\'] = analytic_column_list\n
request.set(\'analytic_column_list\', analytic_column_list) # for Movement_getExplanationTitleAndAnalytics\n
\n
selection_columns = (\n
(\'date\', \'Operation Date\'),\n
(\'Movement_getSpecificReference\', \'Transaction Reference\'),\n
(\'Movement_getExplanationTitleAndAnalytics\', \'Title\\nReference and Analytics\' if analytic_column_list else \'Title\\nReference\'),\n
)\n
(\'date\', \'Date\'),\n
(\'Movement_getExplanationTitle\', \'Accounting Transaction Title\'), )\n
if len(section_uid) > 1:\n
selection_columns += ((\'section_title\', \'Section\'),)\n
selection_columns += ( (\'section_title\', \'Section\'), )\n
selection_columns += analytic_column_list\n
if not mirror_section:\n
selection_columns += ( (\'Movement_getMirrorSectionTitle\', \'Third Party\'), )\n
selection_columns += (\n
(\'Movement_getExplanationReference\', \'Document Reference\'),\n
(\'debit_price\', \'Debit\'),\n
(\'credit_price\', \'Credit\'),\n
(\'running_total_price\', \'Running Balance\'),\n
(\'grouping_reference\', \'Grouping Reference\'),\n
(\'grouping_date\', \'Grouping Date\'),\n
(\'modification_date\', \'Modification Date\'),\n
(\'getTranslatedSimulationStateTitle\', \'State\'),\n
)\n
\n
if export:\n
selection_columns = context.AccountModule_getGeneralLedgerColumnItemList()\n
(\'running_total_price\', \'Net\'),)\n
\n
report_section_list = []\n
if from_date and detailed_from_date_summary:\n
......@@ -193,7 +185,7 @@ if from_date and detailed_from_date_summary:\n
report_section_list.append(\n
ReportSection(\n
path=node,\n
form_id=\'Account_viewAccountingTransactionListExport\' if export else \'Account_viewAccountingTransactionList\',\n
form_id=\'Account_viewAccountingTransactionList\',\n
selection_name=\'account_preference_selection\',\n
selection_params=params,\n
selection_columns=selection_columns,\n
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>return (\n
(\'Movement_getNodeGapId\', \'Account Code\'),\n
(\'node_translated_title\', \'Account Name\'),\n
(\'section_title\', \'Section\'),\n
(\'mirror_section_title\', \'Third Party\'),\n
(\'date\', \'Operation Date\'),\n
(\'modification_date\', \'Modification Date\'),\n
(\'Movement_getSpecificReference\', \'Transaction Reference\'),\n
(\'Movement_getExplanationTranslatedPortalType\', \'Type\'),\n
(\'Movement_getExplanationTitle\', \'Title\'),\n
(\'Movement_getExplanationReference\', \'Document Reference\'),\n
) + context.accounting_module.AccountModule_getAnalyticColumnList() + (\n
(\'debit_price\', \'Debit\'),\n
(\'credit_price\', \'Credit\'),\n
(\'total_price\', \'Balance\'),\n
(\'Movement_getSectionPriceCurrency\', \'Accounting Currency\'),\n
\n
(\'debit\', \'Transaction Currency Debit\'),\n
(\'credit\', \'Transaction Currency Credit\'),\n
(\'total_quantity\', \'Transaction Currency Balance\'),\n
(\'resource_reference\', \'Transaction Currency\'),\n
\n
(\'Movement_getPaymentTitle\', \'Section Bank Account\',),\n
(\'payment_mode_translated_title\', \'Payment Mode\',),\n
\n
(\'grouping_reference\', \'Grouping Reference\'),\n
(\'grouping_date\', \'Grouping Date\'),\n
(\'getTranslatedSimulationStateTitle\', \'State\'),\n
)\n
</string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>AccountModule_getGeneralLedgerColumnItemList</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -56,6 +56,7 @@ from Products.ERP5Form.Report import ReportSection\n
\n
request = context.REQUEST\n
portal = context.portal_url.getPortalObject()\n
N_ = portal.Base_translateString\n
\n
at_date = request[\'at_date\']\n
from_date = request.get(\'from_date\', None)\n
......@@ -69,7 +70,6 @@ show_empty_accounts = request[\'show_empty_accounts\']\n
per_account_class_summary = request[\'per_account_class_summary\']\n
gap_root = request.get(\'gap_root\', None)\n
mirror_section_category = request.get(\'mirror_section_category_list\', None)\n
show_detailed_balance_columns = request[\'show_detailed_balance_columns\']\n
section_uid = portal.Base_getSectionUidListForSectionCategory(\n
request[\'section_category\'],\n
request[\'section_category_strict\'])\n
......@@ -119,9 +119,6 @@ for analytic in group_analytic:\n
extra_columns += ((\'funding_uid\',\n
context.AccountingTransactionLine_getFundingBaseCategoryTitle()),)\n
group_analytic_uid += (\'funding_uid\',)\n
elif analytic == \'section\':\n
extra_columns += ((\'section_uid\', \'Section\'), (\'Movement_getSectionPriceCurrency\', \'Accounting Currency\'))\n
group_analytic_uid += (\'section_uid\',)\n
else:\n
for analytic_column in possible_analytic_column_list:\n
if analytic_column[0] == analytic:\n
......@@ -130,33 +127,19 @@ for analytic in group_analytic:\n
extra_columns += ((uid_key, analytic_column[1]),)\n
\n
\n
if show_detailed_balance_columns:\n
selection_columns = (\n
(\'node_id\', \'GAP Account ID\'),\n
(\'node_title\', \'Account Name\'),\n
selection_columns = (\n
(\'node_id\', \'GAP Account ID\'),\n
(\'node_title\', \'Account Name\'),\n
) + extra_columns + (\n
(\'initial_debit_balance\', \'Initial Debit Balance\'),\n
(\'initial_credit_balance\', \'Initial Credit Balance\'),\n
(\'initial_balance\', \'Initial Balance\'),\n
(\'debit\', \'Debit Transactions\'),\n
(\'credit\', \'Credit Transactions\'),\n
(\'final_debit_balance\', \'Final Debit Balance\'),\n
(\'final_credit_balance\', \'Final Credit Balance\'),\n
(\'final_balance\', \'Final Balance\'),\n
(\'final_balance_if_debit\', \'Final Balance (Debit)\'),\n
(\'final_balance_if_credit\', \'Final Balance (Credit)\'),\n
)\n
else:\n
selection_columns = (\n
(\'node_id\', \'GAP Account ID\'),\n
(\'node_title\', \'Account Name\'),\n
) + extra_columns + (\n
(\'initial_balance\', \'Initial Balance\'),\n
(\'debit\', \'Debit Transactions\'),\n
(\'credit\', \'Credit Transactions\'),\n
(\'final_balance\', \'Final Balance\'),\n
)\n
\n
(\'initial_debit_balance\', \'Initial Debit Balance\'),\n
(\'initial_credit_balance\', \'Initial Credit Balance\'),\n
(\'debit\', \'Debit Transactions\'),\n
(\'credit\', \'Credit Transactions\'),\n
(\'final_debit_balance\', \'Final Debit Balance\'),\n
(\'final_credit_balance\', \'Final Credit Balance\'),\n
(\'final_balance_if_debit\', \'Final Balance (Debit)\'),\n
(\'final_balance_if_credit\', \'Final Balance (Credit)\'),\n
)\n
return [ ReportSection(\n
path=portal.account_module.getPhysicalPath(),\n
form_id=\'AccountModule_viewAccountListForTrialBalance\',\n
......
......@@ -62,10 +62,8 @@ final_balance_if_credit = request[\'TrialBalance.final_balance_if_credit\']\n
\n
return [ Object( initial_debit_balance=initial_debit_balance,\n
initial_credit_balance=initial_credit_balance,\n
initial_balance=initial_debit_balance-initial_credit_balance,\n
debit=debit,\n
credit=credit,\n
final_balance=(initial_debit_balance + debit) - (initial_credit_balance + credit),\n
final_debit_balance=initial_debit_balance + debit,\n
final_credit_balance=initial_credit_balance + credit,\n
final_balance_if_debit=final_balance_if_debit,\n
......
......@@ -88,8 +88,6 @@
<string>listbox_final_debit_balance</string>
<string>listbox_final_balance_if_credit</string>
<string>listbox_final_balance_if_debit</string>
<string>listbox_final_balance</string>
<string>listbox_initial_balance</string>
</list>
</value>
</item>
......
......@@ -323,10 +323,6 @@
<key> <string>alternate_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>anchor</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>columns</string> </key>
<value>
......@@ -339,10 +335,6 @@
<string>node_title</string>
<string>Account Name</string>
</tuple>
<tuple>
<string>initial_balance</string>
<string>Initial Balance</string>
</tuple>
<tuple>
<string>initial_debit_balance</string>
<string>Initial Debit Balance</string>
......@@ -359,10 +351,6 @@
<string>credit</string>
<string>Credit Transactions</string>
</tuple>
<tuple>
<string>final_balance</string>
<string>Final Balance</string>
</tuple>
<tuple>
<string>final_debit_balance</string>
<string>Final Debit Balance</string>
......@@ -394,10 +382,6 @@
<key> <string>default</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>default_display_style</string> </key>
<value> <string>table</string> </value>
</item>
<item>
<key> <string>default_params</string> </key>
<value>
......@@ -408,12 +392,6 @@
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>display_style_list</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>domain_root_list</string> </key>
<value>
......@@ -432,10 +410,6 @@
<key> <string>editable_columns</string> </key>
<value>
<list>
<tuple>
<string>initial_balance</string>
<string>Initial Balance</string>
</tuple>
<tuple>
<string>initial_debit_balance</string>
<string>Initial Debit Balance</string>
......@@ -452,10 +426,6 @@
<string>credit</string>
<string>Credit Transactions</string>
</tuple>
<tuple>
<string>final_balance</string>
<string>Final Balance</string>
</tuple>
<tuple>
<string>final_debit_balance</string>
<string>Final Debit Balance</string>
......@@ -489,18 +459,10 @@
<list/>
</value>
</item>
<item>
<key> <string>global_search_column</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>hide_rows_on_no_search_criterion</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>lines</string> </key>
<value> <int>25</int> </value>
......@@ -521,10 +483,6 @@
<list/>
</value>
</item>
<item>
<key> <string>page_navigation_template</string> </key>
<value> <string>ListBox_viewSliderPageNavigationRenderer</string> </value>
</item>
<item>
<key> <string>page_template</string> </key>
<value> <string></string> </value>
......@@ -545,10 +503,6 @@
<key> <string>report_tree</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>row_css_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>search</string> </key>
<value> <int>0</int> </value>
......@@ -591,22 +545,10 @@
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>style_columns</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Accounts</string> </value>
</item>
<item>
<key> <string>untranslatable_columns</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>url_columns</string> </key>
<value>
......
......@@ -102,7 +102,6 @@
<string>your_node</string>
<string>your_portal_type</string>
<string>your_simulation_state</string>
<string>your_report_date</string>
</list>
</value>
</item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>your_report_date</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>your_report_date</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>AccountModule_viewReportFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -112,7 +112,6 @@
<list>
<string>your_simulation_state</string>
<string>your_portal_type</string>
<string>your_export</string>
</list>
</value>
</item>
......
......@@ -102,7 +102,6 @@
<string>your_gap_list</string>
<string>your_gap_root</string>
<string>your_simulation_state</string>
<string>your_report_date</string>
</list>
</value>
</item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>your_report_date</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>your_report_date</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>AccountModule_viewReportFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -112,7 +112,6 @@
<list>
<string>your_simulation_state</string>
<string>your_mirror_section_category_list</string>
<string>your_export</string>
</list>
</value>
</item>
......
......@@ -98,7 +98,6 @@
<string>your_mirror_section_category_list</string>
<string>your_gap_root</string>
<string>your_simulation_state</string>
<string>your_report_date</string>
</list>
</value>
</item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>your_report_date</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>your_report_date</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>AccountModule_viewReportFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -92,7 +92,6 @@
<string>your_project</string>
<string>your_mirror_section_category_list</string>
<string>your_funding</string>
<string>your_report_date</string>
</list>
</value>
</item>
......
......@@ -101,7 +101,6 @@
<string>your_gap_root</string>
<string>your_portal_type</string>
<string>your_simulation_state</string>
<string>your_report_date</string>
</list>
</value>
</item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>your_report_date</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>your_report_date</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>AccountModule_viewReportFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -93,7 +93,6 @@
<string>your_group_analytic</string>
<string>your_show_empty_accounts</string>
<string>your_per_account_class_summary</string>
<string>your_show_detailed_balance_columns</string>
<string>your_portal_skin</string>
<string>your_format</string>
<string>your_deferred_style</string>
......
......@@ -266,7 +266,7 @@
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: [(context.Base_translateString(x[1]), x[0]) for x in (context.AccountModule_getAnalyticColumnList() + ((\'section\', \'Section\'), )) ]</string> </value>
<value> <string>python: [(context.Base_translateString(x[1]), x[0]) for x in context.AccountModule_getAnalyticColumnList()]</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -51,9 +51,12 @@
<item>
<key> <string>_body</string> </key>
<value> <string>from Products.PythonScripts.standard import Object\n
from Products.ERP5Type.Document import newTempBase\n
from Products.ERP5Type.Message import Message\n
portal = context.getPortalObject()\n
getObject = portal.portal_catalog.getObject\n
params = portal.ERP5Accounting_getParams(selection_name)\n
N_ = lambda msg: Message(\'erp5_ui\', msg)\n
\n
# this also prevents to be called directly\n
assert \'node_uid\' in kw\n
......@@ -83,70 +86,87 @@ for brain in portal.Base_zGetNotGroupedMovementList(\n
portal_type=portal.getPortalAccountingMovementTypeList(),\n
section_uid=params[\'section_uid\']):\n
\n
# manually filter out not interesting lines\n
# XXX this is because Base_zGetNotGroupedMovementList is really\n
# minimalistic\n
if mirror_section_relative_url and \\\n
brain.mirror_section_relative_url != mirror_section_relative_url:\n
continue\n
\n
mvt = brain.getObject()\n
transaction = mvt.getParentValue()\n
\n
if portal_type_filter and \\\n
transaction.getPortalType() not in portal_type_list:\n
continue\n
\n
is_source = (brain.mirror_section_relative_url == mvt.getDestinationSection())\n
if is_source:\n
if payment_uid and mvt.getSourcePaymentUid() != payment_uid:\n
continue\n
if project_uid and mvt.getSourceProjectUid() != project_uid:\n
continue\n
if function and not (mvt.getSourceFunction() or \'\').startswith(function):\n
continue\n
specific_reference = transaction.getSourceReference()\n
mirror_section_title = mvt.getDestinationSectionTitle()\n
section_title = mvt.getSourceSectionTitle()\n
else:\n
if payment_uid and mvt.getDestinationPaymentUid() != payment_uid:\n
continue\n
if project_uid and mvt.getDestinationProjectUid() != project_uid:\n
# manually filter out not interesting lines\n
# XXX this is because Base_zGetNotGroupedMovementList is really\n
# minimalistic\n
if mirror_section_relative_url and \\\n
brain.mirror_section_relative_url != mirror_section_relative_url:\n
continue\n
if function and not (mvt.getDestinationFunction() or \'\').startswith(function):\n
\n
mvt = brain.getObject()\n
transaction = mvt.getParentValue()\n
\n
if portal_type_filter and \\\n
transaction.getPortalType() not in portal_type_list:\n
continue\n
specific_reference = transaction.getDestinationReference()\n
mirror_section_title = mvt.getSourceSectionTitle()\n
section_title = mvt.getDestinationSectionTitle()\n
\n
\n
debit = max(brain.total_quantity, 0)\n
total_debit += debit\n
credit = max(-brain.total_quantity, 0)\n
total_credit += credit\n
is_source = (brain.mirror_section_relative_url == mvt.getDestinationSection())\n
if is_source:\n
if payment_uid and mvt.getSourcePaymentUid() != payment_uid:\n
continue\n
if project_uid and mvt.getSourceProjectUid() != project_uid:\n
continue\n
if function and not (mvt.getSourceFunction() or \'\').startswith(function):\n
continue\n
specific_reference = transaction.getSourceReference()\n
mirror_section_title = mvt.getDestinationSectionTitle()\n
section_title = mvt.getSourceSectionTitle()\n
else:\n
if payment_uid and mvt.getDestinationPaymentUid() != payment_uid:\n
continue\n
if project_uid and mvt.getDestinationProjectUid() != project_uid:\n
continue\n
if function and not (mvt.getDestinationFunction() or \'\').startswith(function):\n
continue\n
specific_reference = transaction.getDestinationReference()\n
mirror_section_title = mvt.getSourceSectionTitle()\n
section_title = mvt.getDestinationSectionTitle()\n
\n
\n
debit = max(brain.total_quantity, 0)\n
total_debit += debit\n
credit = max(-brain.total_quantity, 0)\n
total_credit += credit\n
\n
debit_price = max(brain.total_price, 0)\n
total_debit_price += debit_price\n
credit_price = max(-brain.total_price, 0)\n
total_credit_price += credit_price\n
\n
debit_price = max(brain.total_price, 0)\n
total_debit_price += debit_price\n
credit_price = max(-brain.total_price, 0)\n
total_credit_price += credit_price\n
brain_date = brain.date\n
if mvt.getStartDate():\n
brain_date = brain_date.toZone(mvt.getStartDate().timezone())\n
\n
line = Object(uid=\'new_000\',\n
total_price=brain.total_price,\n
date=brain.date,\n
Movement_getSpecificReference=specific_reference,\n
Movement_getMirrorSectionTitle=mirror_section_title,\n
section_title=section_title,\n
debit=debit,\n
credit=credit,\n
debit_price=debit_price,\n
credit_price=credit_price,\n
Movement_getExplanationTitle=\n
mvt.hasTitle() and mvt.getTitle() or transaction.getTitle())\n
\n
brain_date = brain.date\n
if mvt.getStartDate():\n
brain_date = brain_date.toZone(mvt.getStartDate().timezone())\n
\n
line = Object(uid=\'new_000\',\n
total_price=brain.total_price,\n
date=brain.date,\n
Movement_getSpecificReference=specific_reference,\n
mirror_section_title=mirror_section_title,\n
section_title=section_title,\n
debit=debit,\n
credit=credit,\n
debit_price=debit_price,\n
credit_price=credit_price,\n
Movement_getExplanationTitleAndAnalytics=brain.Movement_getExplanationTitleAndAnalytics(brain))\n
analytic_info = {}\n
for analytic_column, analytic_column_title in analytic_column_list:\n
if analytic_column == \'project\':\n
if is_source:\n
analytic_info[\'project\'] = mvt.asContext(project_uid=mvt.getSourceProjectUid()).Movement_getProjectTitle()\n
else:\n
analytic_info[\'project\'] = mvt.asContext(project_uid=mvt.getDestinationProjectUid()).Movement_getProjectTitle()\n
elif analytic_column == \'function\':\n
if is_source:\n
analytic_info[\'function\'] = mvt.asContext(function_uid=mvt.getDestinationFunctionUid()).Movement_getFunctionTitle()\n
else:\n
analytic_info[\'function\'] = mvt.asContext(function_uid=mvt.getDestinationFunctionUid()).Movement_getFunctionTitle()\n
else:\n
analytic_info[analytic_column] = mvt.getProperty(analytic_column)\n
\n
line_list.append(line)\n
line.update(analytic_info)\n
line_list.append(line)\n
\n
\n
context.REQUEST.set(\n
......
......@@ -101,8 +101,6 @@
<string>listbox_function</string>
<string>listbox_project</string>
<string>listbox_funding</string>
<string>listbox_modification_date</string>
<string>listbox_grouping_date</string>
</list>
</value>
</item>
......
......@@ -10,7 +10,6 @@
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>all_columns</string>
<string>columns</string>
<string>domain_root_list</string>
<string>domain_tree</string>
......@@ -96,37 +95,6 @@
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>all_columns</string> </key>
<value>
<list>
<tuple>
<string>grouping_reference</string>
<string>Grouping Reference</string>
</tuple>
<tuple>
<string>grouping_date</string>
<string>Grouping Date</string>
</tuple>
<tuple>
<string>resource_reference</string>
<string>Currency</string>
</tuple>
<tuple>
<string>debit</string>
<string>Transaction Currency Debit</string>
</tuple>
<tuple>
<string>credit</string>
<string>Transaction Currency Credit</string>
</tuple>
<tuple>
<string>quantity</string>
<string>Transaction Currency Balance</string>
</tuple>
</list>
</value>
</item>
<item>
<key> <string>columns</string> </key>
<value>
......@@ -213,14 +181,6 @@
<string>date</string>
<string>date</string>
</tuple>
<tuple>
<string>modification_date</string>
<string>date</string>
</tuple>
<tuple>
<string>grouping_date</string>
<string>date</string>
</tuple>
<tuple>
<string>debit_price</string>
<string>debit</string>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>selection_name</string>
<string>stat_columns</string>
<string>stat_method</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>listbox</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Account_viewAccountingTransactionList</string> </value>
</item>
<item>
<key> <string>selection_name</string> </key>
<value> <string>account_history_export_selection</string> </value>
</item>
<item>
<key> <string>stat_columns</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>stat_method</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -167,7 +167,6 @@ for section in section_list:\n
**inventory_param_dict)\n
selected_profit_and_loss_account_balance = portal.portal_simulation.getInventoryAssetPrice(\n
node=profit_and_loss_account,\n
resource=section_currency,\n
**inventory_param_dict)\n
\n
section_currency_uid = context.getParentValue().getPriceCurrencyUid()\n
......@@ -190,8 +189,10 @@ for section in section_list:\n
\n
line_count += 1\n
if inventory.resource_uid != section_currency_uid:\n
if inventory.node_relative_url == profit_and_loss_account:\n
raise ValueError(\'Using multiple currencies on profit and loss account \'\n
\'is not supported\')\n
profit_and_loss_quantity += total_price\n
\n
if balance_transaction is None:\n
balance_transaction = createBalanceTransaction(section)\n
balance_transaction.newContent(\n
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5 Form" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>action</string> </key>
<value> <string>Base_edit</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>edit_order</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>enctype</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>group_list</string> </key>
<value>
<list>
<string>left</string>
<string>right</string>
<string>center</string>
<string>bottom</string>
</list>
</value>
</item>
<item>
<key> <string>groups</string> </key>
<value>
<dictionary>
<item>
<key> <string>bottom</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>center</string> </key>
<value>
<list>
<string>my_description</string>
</list>
</value>
</item>
<item>
<key> <string>left</string> </key>
<value>
<list>
<string>my_title</string>
<string>my_resource</string>
<string>my_generate_prevision_script_id</string>
</list>
</value>
</item>
<item>
<key> <string>right</string> </key>
<value>
<list>
<string>my_destination_title</string>
<string>my_source_title</string>
<string>my_source_debit</string>
<string>my_source_credit</string>
</list>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>AccountingRuleCellLine_view</string> </value>
</item>
<item>
<key> <string>method</string> </key>
<value> <string>POST</string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string>accounting_transaction_list</string> </value>
</item>
<item>
<key> <string>pt</string> </key>
<value> <string>form_view</string> </value>
</item>
<item>
<key> <string>row_length</string> </key>
<value> <int>4</int> </value>
</item>
<item>
<key> <string>stored_encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Accounting Rule Cell Line</string> </value>
</item>
<item>
<key> <string>unicode_mode</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>update_action</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -9,15 +9,12 @@
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>required</string>
<string>title</string>
</list>
<list/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_delivery_start_date</string> </value>
<value> <string>my_description</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
......@@ -73,16 +70,16 @@
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_view_mode_listbox_read_only_start_date</string> </value>
<key> <string>description</string> </key>
<value> <string>General description which may be printed out on official documents and read by suppliers and clients.</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewTradeFieldLibrary</string> </value>
<key> <string>field_id</string> </key>
<value> <string>my_description</string> </value>
</item>
<item>
<key> <string>required</string> </key>
<value> <int>1</int> </value>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
......@@ -90,7 +87,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>listbox_delivery_start_date</string> </value>
<value> <string>Description</string> </value>
</item>
</dictionary>
</value>
......
......@@ -10,14 +10,14 @@
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>required</string>
<string>title</string>
<string>description</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_delivery_stop_date</string> </value>
<value> <string>my_generate_prevision_script_id</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
......@@ -73,16 +73,16 @@
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_view_mode_listbox_read_only_stop_date</string> </value>
<key> <string>description</string> </key>
<value> <string>Id of a script used to generate prevision in simulation.</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewTradeFieldLibrary</string> </value>
<key> <string>field_id</string> </key>
<value> <string>my_string_field</string> </value>
</item>
<item>
<key> <string>required</string> </key>
<value> <int>1</int> </value>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
......@@ -90,7 +90,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>listbox_delivery_stop_date</string> </value>
<value> <string>Generate Prevision Script ID</string> </value>
</item>
</dictionary>
</value>
......
......@@ -71,11 +71,11 @@
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_view_mode_title</string> </value>
<value> <string>my_title</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewTradeFieldLibrary</string> </value>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
......
......@@ -8,7 +8,7 @@
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_final_balance</string> </value>
<value> <string>listbox_destination_credit</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
......@@ -154,9 +154,7 @@
</item>
<item>
<key> <string>precision</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
<value> <string></string> </value>
</item>
<item>
<key> <string>required</string> </key>
......@@ -183,7 +181,7 @@
</item>
<item>
<key> <string>css_class</string> </key>
<value> <string>figure</string> </value>
<value> <string></string> </value>
</item>
<item>
<key> <string>default</string> </key>
......@@ -199,11 +197,11 @@
</item>
<item>
<key> <string>display_width</string> </key>
<value> <int>20</int> </value>
<value> <int>7</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>enabled</string> </key>
......@@ -223,7 +221,7 @@
</item>
<item>
<key> <string>input_style</string> </key>
<value> <string>-1 234.5</string> </value>
<value> <string>-12.3%</string> </value>
</item>
<item>
<key> <string>precision</string> </key>
......@@ -235,7 +233,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Final Balance</string> </value>
<value> <string>listbox_source_credit</string> </value>
</item>
<item>
<key> <string>whitespace_preserve</string> </key>
......@@ -247,23 +245,4 @@
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<tuple>
<string>Products.Formulator.TALESField</string>
<string>TALESMethod</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>request/precision | python: 2</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -52,14 +52,10 @@
<key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[
"""Reset reconciliation after a copy & paste.\n
\n
"""Reset the grouping reference after a copy & paste.\n
"""\n
context.setGroupingReference(None)\n
context.setGroupingDate(None)\n
\n
context.setAggregate(None, portal_type=\'Bank Reconciliation\')\n
context.setAggregate(None, portal_type=\'Payment Transaction Group\')\n
]]></string> </value>
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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