Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Gabriel Monnerat
slapos.core
Commits
d7dbe101
Commit
d7dbe101
authored
Oct 17, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Follow merge changes.
updateSimulation replaces Delivery_updateAppliedRule
parent
63e43dbd
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
4 additions
and
119 deletions
+4
-119
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/DeliveryLine_updateAppliedRule.xml
...skins/vifib_simulation/DeliveryLine_updateAppliedRule.xml
+1
-1
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/Delivery_updateAppliedRule.xml
...tal_skins/vifib_simulation/Delivery_updateAppliedRule.xml
+0
-115
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/VifibSalePackingList_postGeneration.xml
.../vifib_simulation/VifibSalePackingList_postGeneration.xml
+1
-1
master/bt5/vifib_base/bt/dependency_list
master/bt5/vifib_base/bt/dependency_list
+1
-1
master/bt5/vifib_base/bt/revision
master/bt5/vifib_base/bt/revision
+1
-1
No files found.
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/DeliveryLine_updateAppliedRule.xml
View file @
d7dbe101
...
@@ -53,7 +53,7 @@
...
@@ -53,7 +53,7 @@
<value>
<string>
delivery = context.getParentValue()\n
<value>
<string>
delivery = context.getParentValue()\n
if context.getPortalObject().portal_activities.countMessage(path=delivery.getPath()) == 0:\n
if context.getPortalObject().portal_activities.countMessage(path=delivery.getPath()) == 0:\n
delivery.serialize()\n
delivery.serialize()\n
delivery.
Delivery_updateAppliedRule(activate_kw=activate_kw, **kw
)\n
delivery.
updateSimulation(
)\n
</string>
</value>
</string>
</value>
</item>
</item>
<item>
<item>
...
...
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/Delivery_updateAppliedRule.xml
deleted
100644 → 0
View file @
63e43dbd
<?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>
from Products.ERP5Type.Errors import SimulationError\n
\n
delivery = context\n
delivery_type = context.getPortalType()\n
\n
# XXX The following dict is only for backward compatibility.\n
applied_rule_dict = {\n
\'Pay Sheet Transaction\': \'default_invoice_rule\',\n
\'Payment Transaction\': \'default_invoice_rule\',\n
\n
\'Purchase Packing List\': \'default_delivery_rule\',\n
\'Purchase Invoice Transaction\': \'default_invoice_rule\',\n
\n
\'Sale Order\': \'default_order_rule\',\n
\'Sale Packing List\': \'default_delivery_rule\',\n
# XXX-Romain: no need for root applied rule for sale invoice\n
# \'Sale Invoice Transaction\': \'default_invoice_rule\',\n
\'Sale Invoice Transaction\': None,\n
\n
\'Internal Packing List\': None,\n
\'Returned Sale Packing List\': None,\n
\n
\'Accounting Rule Cell\': None,\n
\'Accounting Transaction\': None,\n
\'Production Packing List\': None,\n
\'Production Report\': None,\n
\'Pay Sheet Model\': None,\n
\n
\'Amortisation Transaction\' : None,\n
\'Task Report\': \'default_delivery_rule\',\n
}\n
\n
try:\n
applied_rule = delivery.getRuleReference()\n
except SimulationError:\n
marker = []\n
applied_rule = applied_rule_dict.get(delivery_type, marker)\n
if applied_rule is marker:\n
raise\n
\n
if applied_rule is None:\n
# No need to add a rule, but still we need to expand the delivery\n
# if at least one of its movements is simulated.\n
for m in delivery.getMovementList():\n
if m.isSimulated():\n
delivery.activate(activate_kw=activate_kw).expand(**kw)\n
return\n
elif applied_rule:\n
delivery.updateAppliedRule(rule_reference=applied_rule, activate_kw=activate_kw, **kw)\n
</string>
</value>
</item>
<item>
<key>
<string>
_params
</string>
</key>
<value>
<string>
activate_kw=None, **kw
</string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
Delivery_updateAppliedRule
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
master/bt5/vifib_base/SkinTemplateItem/portal_skins/vifib_simulation/VifibSalePackingList_postGeneration.xml
View file @
d7dbe101
...
@@ -68,7 +68,7 @@ line = packing_list.contentValues(portal_type=\'Sale Packing List Line\')[0]\n
...
@@ -68,7 +68,7 @@ line = packing_list.contentValues(portal_type=\'Sale Packing List Line\')[0]\n
portal = packing_list.getPortalObject()\n
portal = packing_list.getPortalObject()\n
\n
\n
if line.getResource() == portal.portal_preferences.getPreferredInstanceSetupResource():\n
if line.getResource() == portal.portal_preferences.getPreferredInstanceSetupResource():\n
packing_list.activate(after_path_and_method_id=(
related_simulation_movement_path_list
,\n
packing_list.activate(after_path_and_method_id=(
packing_list.getPath()
,\n
(\'immediateReindexObject\', \'recursiveImmediateReindexObject\'))).SalePackingList_deliverInstanceSetup()\n
(\'immediateReindexObject\', \'recursiveImmediateReindexObject\'))).SalePackingList_deliverInstanceSetup()\n
\n
\n
# First set the packing_list in the building state\n
# First set the packing_list in the building state\n
...
...
master/bt5/vifib_base/bt/dependency_list
View file @
d7dbe101
...
@@ -42,4 +42,4 @@ erp5_trade
...
@@ -42,4 +42,4 @@ erp5_trade
erp5_web
erp5_web
erp5_web_download_theme
erp5_web_download_theme
erp5_xhtml_jquery_style
erp5_xhtml_jquery_style
vifib_slapos_core
vifib_slapos_core
\ No newline at end of file
master/bt5/vifib_base/bt/revision
View file @
d7dbe101
498
499
\ No newline at end of file
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment