Juliana
3 years ago
4 changed files with 132 additions and 2 deletions
@ -0,0 +1,44 @@ |
|||||
|
# Copyright 2021 Le Filament (<http://www.le-filament.com>) |
||||
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). |
||||
|
|
||||
|
from odoo import fields, models, api |
||||
|
|
||||
|
|
||||
|
class PosOrder(models.Model): |
||||
|
_inherit = 'pos.order' |
||||
|
|
||||
|
# ------------------------------------------------------ |
||||
|
# Fields declaration |
||||
|
# ------------------------------------------------------ |
||||
|
|
||||
|
# ------------------------------------------------------ |
||||
|
# SQL Constraints |
||||
|
# ------------------------------------------------------ |
||||
|
|
||||
|
# ------------------------------------------------------ |
||||
|
# Default methods |
||||
|
# ------------------------------------------------------ |
||||
|
|
||||
|
# ------------------------------------------------------ |
||||
|
# Computed fields / Search Fields |
||||
|
# ------------------------------------------------------ |
||||
|
|
||||
|
# ------------------------------------------------------ |
||||
|
# Onchange / Constraints |
||||
|
# ------------------------------------------------------ |
||||
|
|
||||
|
# ------------------------------------------------------ |
||||
|
# CRUD methods (ORM overrides) |
||||
|
# ------------------------------------------------------ |
||||
|
def test_paid(self): |
||||
|
for order in self: |
||||
|
if order.config_id.is_balance_free: |
||||
|
return True |
||||
|
return super(PosOrder, self).test_paid() |
||||
|
# ------------------------------------------------------ |
||||
|
# Actions |
||||
|
# ------------------------------------------------------ |
||||
|
|
||||
|
# ------------------------------------------------------ |
||||
|
# Business methods |
||||
|
# ------------------------------------------------------ |
Write
Preview
Loading…
Cancel
Save
Reference in new issue