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
Łukasz Nowak
slapos.core
Commits
55107998
Commit
55107998
authored
Feb 23, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Set price_currency on deliveries.
parent
02ac0896
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
7 deletions
+16
-7
master/bt5/vifib_upgrader/ExtensionTemplateItem/VifibUpgrader.py
...bt5/vifib_upgrader/ExtensionTemplateItem/VifibUpgrader.py
+9
-4
master/bt5/vifib_upgrader/SkinTemplateItem/portal_skins/vifib_upgrader/SaleOrderLine_setPriceToZeroAndOrUpdateAppliedRule.xml
...er/SaleOrderLine_setPriceToZeroAndOrUpdateAppliedRule.xml
+6
-2
master/bt5/vifib_upgrader/bt/revision
master/bt5/vifib_upgrader/bt/revision
+1
-1
No files found.
master/bt5/vifib_upgrader/ExtensionTemplateItem/VifibUpgrader.py
View file @
55107998
...
@@ -5,10 +5,15 @@ def DeliveryLineSetZeroPriceAndOrUpdateAppliedRule(self):
...
@@ -5,10 +5,15 @@ def DeliveryLineSetZeroPriceAndOrUpdateAppliedRule(self):
portal_type
=
self
.
getPortalType
()
portal_type
=
self
.
getPortalType
()
assert
(
portal_type
in
self
.
getPortalDeliveryMovementTypeList
())
assert
(
portal_type
in
self
.
getPortalDeliveryMovementTypeList
())
common_specialise
=
'sale_trade_condition_module/vifib_trade_condition'
common_specialise
=
'sale_trade_condition_module/vifib_trade_condition'
specialise
=
self
.
getParentValue
().
getSpecialise
()
delivery
=
self
.
getParentValue
()
price_currency
=
'currency_module/EUR'
if
delivery
.
getPortalType
()
in
[
'Purchase Packing List'
,
'Sale Packing List'
]:
specialise
=
delivery
.
getSpecialise
()
if
common_specialise
!=
specialise
:
if
common_specialise
!=
specialise
:
self
.
getParentValue
().
setSpecialise
(
common_specialise
)
self
.
getParentValue
().
setSpecialise
(
common_specialise
)
self
.
getParentValue
().
SalePackingList_setArrow
()
delivery
.
SalePackingList_setArrow
()
if
delivery
.
getPriceCurrency
()
!=
price_currency
:
delivery
.
setPriceCurrency
(
price_currency
)
self
.
setPrice
(
0.0
)
self
.
setPrice
(
0.0
)
if
self
.
getSimulationState
()
==
'cancelled'
:
if
self
.
getSimulationState
()
==
'cancelled'
:
# force no simulation
# force no simulation
...
...
master/bt5/vifib_upgrader/SkinTemplateItem/portal_skins/vifib_upgrader/SaleOrderLine_setPriceToZeroAndOrUpdateAppliedRule.xml
View file @
55107998
...
@@ -55,9 +55,13 @@
...
@@ -55,9 +55,13 @@
context.setPrice(0.0)\n
context.setPrice(0.0)\n
context.setQuantity(1.0)\n
context.setQuantity(1.0)\n
common_specialise = \'sale_trade_condition_module/vifib_trade_condition\'\n
common_specialise = \'sale_trade_condition_module/vifib_trade_condition\'\n
specialise = context.getParentValue().getSpecialise()\n
sale_order = context.getParentValue()\n
specialise = sale.getSpecialise()\n
if common_specialise != specialise:\n
if common_specialise != specialise:\n
context.getParentValue().setSpecialise(common_specialise)\n
sale_order.setSpecialise(common_specialise)\n
price_currency = \'currency_module/EUR\'\n
if sale_order.getPriceCurrency() != price_currency:\n
sale_order.setPriceCurrency(price_currency)\n
</string>
</value>
</string>
</value>
</item>
</item>
<item>
<item>
...
...
master/bt5/vifib_upgrader/bt/revision
View file @
55107998
52
53
\ 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