diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToDay.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToDay.xml index 1ef079dd16cf76320015461feff32d7db4435400..d07cf030a8f35359653b734e32b82c855e140d7c 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToDay.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToDay.xml @@ -3,11 +3,8 @@ <record id="1" aka="AAAAAAAAAAE="> <pickle> <tuple> - <tuple> - <string>Products.PythonScripts.PythonScript</string> - <string>PythonScript</string> - </tuple> - <none/> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> </tuple> </pickle> <pickle> @@ -74,11 +71,18 @@ Script used by PlanningBox validator to round the bound dates to the\n closest full day.\n """\n +if axis == \'begin\':\n + if full_date.hour() > 12: \n + return DateTime(full_date.Date()) + 1\n + else:\n + return DateTime(full_date.Date())\n \n -if full_date.hour() > 12:\n - return DateTime(full_date.Date()) + 1\n -else:\n - return DateTime(full_date.Date())\n +if axis == \'end\':\n + # round to 23:59:59\n + if full_date.hour() > 12:\n + return DateTime(full_date.Date()) + 1 - (1.0/(24*3600))\n + else:\n + return DateTime(full_date.Date()) - (1.0/(24*3600))\n ]]></string> </value> @@ -103,7 +107,7 @@ else:\n </item> <item> <key> <string>_params</string> </key> - <value> <string>full_date</string> </value> + <value> <string>full_date, axis=\'begin\'</string> </value> </item> <item> <key> <string>errors</string> </key> @@ -123,13 +127,14 @@ else:\n <dictionary> <item> <key> <string>co_argcount</string> </key> - <value> <int>1</int> </value> + <value> <int>2</int> </value> </item> <item> <key> <string>co_varnames</string> </key> <value> <tuple> <string>full_date</string> + <string>axis</string> <string>_getattr_</string> <string>DateTime</string> </tuple> @@ -143,13 +148,19 @@ else:\n <item> <key> <string>func_defaults</string> </key> <value> - <none/> + <tuple> + <string>begin</string> + </tuple> </value> </item> <item> <key> <string>id</string> </key> <value> <string>Planning_roundBoundToDay</string> </value> </item> + <item> + <key> <string>isIndexable</string> </key> + <value> <int>0</int> </value> + </item> <item> <key> <string>warnings</string> </key> <value> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToInt.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToInt.xml index 99a89097bf100baf3c9aeeca77deb5dbb8c0bd0c..3f97cefee8381ecde6f4ec043c262381edc64590 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToInt.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToInt.xml @@ -3,11 +3,8 @@ <record id="1" aka="AAAAAAAAAAE="> <pickle> <tuple> - <tuple> - <string>Products.PythonScripts.PythonScript</string> - <string>PythonScript</string> - </tuple> - <none/> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> </tuple> </pickle> <pickle> @@ -95,7 +92,7 @@ return int(value + 0.5)\n </item> <item> <key> <string>_params</string> </key> - <value> <string>value</string> </value> + <value> <string>value, axis=\'begin\'</string> </value> </item> <item> <key> <string>errors</string> </key> @@ -115,13 +112,14 @@ return int(value + 0.5)\n <dictionary> <item> <key> <string>co_argcount</string> </key> - <value> <int>1</int> </value> + <value> <int>2</int> </value> </item> <item> <key> <string>co_varnames</string> </key> <value> <tuple> <string>value</string> + <string>axis</string> <string>int</string> </tuple> </value> @@ -134,13 +132,19 @@ return int(value + 0.5)\n <item> <key> <string>func_defaults</string> </key> <value> - <none/> + <tuple> + <string>begin</string> + </tuple> </value> </item> <item> <key> <string>id</string> </key> <value> <string>Planning_roundBoundToInt</string> </value> </item> + <item> + <key> <string>isIndexable</string> </key> + <value> <int>0</int> </value> + </item> <item> <key> <string>warnings</string> </key> <value> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToMinute.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToMinute.xml index 47dc71e76b1da826e23268ceea97959dea7217fa..5b517b79e3109c6ffe3141e73ba6e67e479de712 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToMinute.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Planning_roundBoundToMinute.xml @@ -3,11 +3,8 @@ <record id="1" aka="AAAAAAAAAAE="> <pickle> <tuple> - <tuple> - <string>Products.PythonScripts.PythonScript</string> - <string>PythonScript</string> - </tuple> - <none/> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> </tuple> </pickle> <pickle> @@ -104,7 +101,7 @@ else:\n </item> <item> <key> <string>_params</string> </key> - <value> <string>full_date</string> </value> + <value> <string>full_date, axis=\'begin\'</string> </value> </item> <item> <key> <string>errors</string> </key> @@ -124,13 +121,14 @@ else:\n <dictionary> <item> <key> <string>co_argcount</string> </key> - <value> <int>1</int> </value> + <value> <int>2</int> </value> </item> <item> <key> <string>co_varnames</string> </key> <value> <tuple> <string>full_date</string> + <string>axis</string> <string>_getattr_</string> <string>DateTime</string> </tuple> @@ -144,13 +142,19 @@ else:\n <item> <key> <string>func_defaults</string> </key> <value> - <none/> + <tuple> + <string>begin</string> + </tuple> </value> </item> <item> <key> <string>id</string> </key> <value> <string>Planning_roundBoundToMinute</string> </value> </item> + <item> + <key> <string>isIndexable</string> </key> + <value> <int>0</int> </value> + </item> <item> <key> <string>warnings</string> </key> <value> diff --git a/product/ERP5/bootstrap/erp5_core/bt/revision b/product/ERP5/bootstrap/erp5_core/bt/revision index c04091d820b33abba9eddf8c08de3e91f52478c3..3430d414900cb16a8d9c5aa5e1834fc8f5917d6a 100644 --- a/product/ERP5/bootstrap/erp5_core/bt/revision +++ b/product/ERP5/bootstrap/erp5_core/bt/revision @@ -1 +1 @@ -790 \ No newline at end of file +792 \ No newline at end of file