[FIX] sale_payment: move method in right module
Commit 8911be11d1 moved code from website_portal_sale to
a new sale_payment module, in order to move code down and ease its use in
variou addons. However a called method was forgotten in the process leading
to some issues when using sale_payment. This commit fixes that.
This commit is contained in:
@@ -9,3 +9,10 @@ class SaleOrder(models.Model):
|
||||
|
||||
payment_tx_id = fields.Many2one('payment.transaction', string='Last Transaction', copy=False)
|
||||
payment_acquirer_id = fields.Many2one('payment.acquirer', string='Payment Acquirer', related='payment_tx_id.acquirer_id', store=True)
|
||||
|
||||
def _force_lines_to_invoice_policy_order(self):
|
||||
for line in self.order_line:
|
||||
if self.state in ['sale', 'done']:
|
||||
line.qty_to_invoice = line.product_uom_qty - line.qty_invoiced
|
||||
else:
|
||||
line.qty_to_invoice = 0
|
||||
|
||||
@@ -56,13 +56,6 @@ class SaleOrder(models.Model):
|
||||
|
||||
return groups
|
||||
|
||||
def _force_lines_to_invoice_policy_order(self):
|
||||
for line in self.order_line:
|
||||
if self.state in ['sale', 'done']:
|
||||
line.qty_to_invoice = line.product_uom_qty - line.qty_invoiced
|
||||
else:
|
||||
line.qty_to_invoice = 0
|
||||
|
||||
@api.multi
|
||||
def get_signup_url(self):
|
||||
self.ensure_one()
|
||||
|
||||
Reference in New Issue
Block a user