mirror of
https://github.com/bringout/oca-ocb-sale.git
synced 2026-04-27 06:32:02 +02:00
Initial commit: Sale packages
This commit is contained in:
commit
14e3d26998
6469 changed files with 2479670 additions and 0 deletions
|
|
@ -0,0 +1,17 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from odoo import fields, models
|
||||
from odoo.osv.expression import OR
|
||||
|
||||
|
||||
class PosSession(models.Model):
|
||||
_inherit = 'pos.session'
|
||||
|
||||
crm_team_id = fields.Many2one('crm.team', related='config_id.crm_team_id', string="Sales Team", readonly=True)
|
||||
|
||||
def _loader_params_product_product(self):
|
||||
result = super()._loader_params_product_product()
|
||||
result['search_params']['domain'] = OR([result['search_params']['domain'], [('id', '=', self.config_id.down_payment_product_id.id)]])
|
||||
result['search_params']['fields'].extend(['invoice_policy', 'type'])
|
||||
return result
|
||||
Loading…
Add table
Add a link
Reference in a new issue