int app-odoo 17, paid

This commit is contained in:
Ivan Office
2023-09-30 10:58:00 +08:00
parent e346c360a2
commit 72c740dd76
355 changed files with 14784 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
# -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from odoo import api, fields, models, tools, _
class ResPartner(models.Model):
_inherit = 'res.partner'
def get_related_user_id(self):
self.ensure_one()
user = self.env['res.users'].sudo().with_context(active_test=False).search([('partner_id', '=', self.id)], limit=1)
return user