mirror of
https://gitlab.com/hibou-io/hibou-odoo/suite.git
synced 2025-01-20 12:37:31 +02:00
FIX connector_opencart refactor the coupon naming that overwrote the local variable named values
This commit is contained in:
@@ -81,12 +81,11 @@ class SaleOrderImportMapper(Component):
|
|||||||
line_builder.price_unit = -float(coupon.get('amount', 0.0))
|
line_builder.price_unit = -float(coupon.get('amount', 0.0))
|
||||||
line_builder.product = coupon_product
|
line_builder.product = coupon_product
|
||||||
# `order.line.builder` does not allow naming.
|
# `order.line.builder` does not allow naming.
|
||||||
values = line_builder.get_line()
|
line_values = line_builder.get_line()
|
||||||
code = coupon.get('code')
|
code = coupon.get('code')
|
||||||
if code:
|
if code:
|
||||||
values['name'] = '%s Code: %s' % (coupon_product.name, code)
|
line_values['name'] = '%s Code: %s' % (coupon_product.name, code)
|
||||||
line = (0, 0, values)
|
values['order_line'].append((0, 0, line_values))
|
||||||
values['order_line'].append(line)
|
|
||||||
return values
|
return values
|
||||||
|
|
||||||
def _add_shipping_line(self, map_record, values):
|
def _add_shipping_line(self, map_record, values):
|
||||||
|
|||||||
Reference in New Issue
Block a user