Skip to content

Commit

Permalink
[MIG] sale_pricelist_triple_discount: Migration to 17.0
Browse files Browse the repository at this point in the history
  • Loading branch information
david-s73 committed Nov 11, 2024
1 parent 271ea84 commit 01a1aa4
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 55 deletions.
2 changes: 1 addition & 1 deletion sale_pricelist_triple_discount/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
"name": "Sale Pricelist Triple Discount",
"version": "16.0.1.0.0",
"version": "17.0.1.0.0",
"category": "Sale",
"author": "Agile Business Group, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/sale-workflow"
Expand Down
6 changes: 4 additions & 2 deletions sale_pricelist_triple_discount/tests/test_sale_order.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,10 @@ def setUpClass(cls):
super().setUpClass()
# Enable user groups to be able to set advanced fields using Form
pricelist_groups = [
"product.group_discount_per_so_line", # for product.pricelist.discount_policy
"product.group_sale_pricelist", # for product.pricelist.item.compute_price
# for product.pricelist.discount_policy
"product.group_discount_per_so_line",
# for product.pricelist.item.compute_price
"product.group_sale_pricelist",
]
user = cls.env.user
for pricelist_group in pricelist_groups:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,40 +13,18 @@
<label
for="discount2"
string="Discount 2"
attrs="{
'invisible':[
('compute_price', '!=', 'percentage'),
],
}"
invisible=" compute_price != 'percentage'"
/>
<div
class="o_row"
attrs="{
'invisible':[
('compute_price', '!=', 'percentage'),
],
}"
>
<div class="o_row" invisible=" compute_price != 'percentage'">
<field name="discount2" class="oe_inline" />
<span>%</span>
</div>
<label
for="discount3"
string="Discount 3"
attrs="{
'invisible':[
('compute_price', '!=', 'percentage'),
],
}"
invisible=" compute_price != 'percentage'"
/>
<div
class="o_row"
attrs="{
'invisible':[
('compute_price', '!=', 'percentage'),
],
}"
>
<div class="o_row" invisible=" compute_price != 'percentage'">
<field name="discount3" class="oe_inline" />
<span>%</span>
</div>
Expand All @@ -55,40 +33,18 @@
<label
for="discount2"
string="Discount 2"
attrs="{
'invisible':[
('compute_price', '!=', 'formula'),
],
}"
invisible=" compute_price != 'formula'"
/>
<div
class="o_row"
attrs="{
'invisible':[
('compute_price', '!=', 'formula'),
],
}"
>
<div class="o_row" invisible=" compute_price != 'formula'">
<field name="discount2" class="oe_inline" />
<span>%</span>
</div>
<label
for="discount3"
string="Discount 3"
attrs="{
'invisible':[
('compute_price', '!=', 'formula'),
],
}"
invisible=" compute_price != 'formula'"
/>
<div
class="o_row"
attrs="{
'invisible':[
('compute_price', '!=', 'formula'),
],
}"
>
<div class="o_row" invisible=" compute_price != 'formula'">
<field name="discount3" class="oe_inline" />
<span>%</span>
</div>
Expand Down

0 comments on commit 01a1aa4

Please sign in to comment.