[Erp5-report] r27441 - in /erp5/trunk/bt5/erp5_payroll: SkinTemplateItem/portal_skins/erp5_...
nobody at svn.erp5.org
nobody at svn.erp5.org
Mon Jun 8 17:32:48 CEST 2009
Author: fabien
Date: Mon Jun 8 17:32:46 2009
New Revision: 27441
URL: http://svn.erp5.org?rev=27441&view=rev
Log:
now model lines can be in the Paysheet. So model is not necessary the parent, it could be the specialise value.
Modified:
erp5/trunk/bt5/erp5_payroll/SkinTemplateItem/portal_skins/erp5_payroll/PaySheetModelLine_asCellRange.xml
erp5/trunk/bt5/erp5_payroll/bt/revision
Modified: erp5/trunk/bt5/erp5_payroll/SkinTemplateItem/portal_skins/erp5_payroll/PaySheetModelLine_asCellRange.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_payroll/SkinTemplateItem/portal_skins/erp5_payroll/PaySheetModelLine_asCellRange.xml?rev=27441&r1=27440&r2=27441&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_payroll/SkinTemplateItem/portal_skins/erp5_payroll/PaySheetModelLine_asCellRange.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_payroll/SkinTemplateItem/portal_skins/erp5_payroll/PaySheetModelLine_asCellRange.xml [utf8] Mon Jun 8 17:32:46 2009
@@ -60,6 +60,11 @@
\'\'\'\n
translateString = context.Base_translateString\n
\n
+# get the model the related model (usefull to get slice values). This script\n
+# can be called on paysheet model line or on paysheet.\n
+model = context.getParentValue().getPortalType()==\'Pay Sheet Model\' and\\\n
+ context.getParentValue() or context.getSpecialiseValue()\n
+\n
def framing(cell, name):\n
\'\'\'\n
this function return a string corresponding to the framing of the slice \n
@@ -89,10 +94,10 @@
for category_item in category_item_list:\n
if base_category == \'salary_range\':\n
category_cell_range.append((category_item[1],\\\n
- framing(context.getParentValue().getCell(category_item[1]), \n
+ framing(model.getCell(category_item[1]),\n
category_item[0])))\n
elif base_category == \'tax_category\':\n
- category_cell_range.append((category_item[1], \n
+ category_cell_range.append((category_item[1],\n
translateString(\'${tax_category_title} (Amount or Percent)\',\n
mapping=dict(tax_category_title=category_item[0]))))\n
else:\n
@@ -155,6 +160,7 @@
<string>_getattr_</string>
<string>context</string>
<string>translateString</string>
+ <string>model</string>
<string>framing</string>
<string>resource</string>
<string>cell_range</string>
Modified: erp5/trunk/bt5/erp5_payroll/bt/revision
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_payroll/bt/revision?rev=27441&r1=27440&r2=27441&view=diff
==============================================================================
--- erp5/trunk/bt5/erp5_payroll/bt/revision [utf8] (original)
+++ erp5/trunk/bt5/erp5_payroll/bt/revision [utf8] Mon Jun 8 17:32:46 2009
@@ -1,1 +1,1 @@
-446
+448
More information about the Erp5-report
mailing list