blob: d4bfae1572f8df8cefd473c4bd38151174e0ad34 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
# -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from odoo import api, fields, models
class PosConfig(models.Model):
_inherit = 'pos.payment'
def _update_payment_line_for_tip(self, tip_amount):
"""Inherit this method to perform reauthorization or capture on electronic payment."""
self.ensure_one()
self.write({
"amount": self.amount + tip_amount,
})
|