feat: extend sale.order, stock.picking, account.move, res.partner with WooCommerce fields

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
gsinghpal
2026-03-31 20:10:08 -04:00
parent fdd67c9e51
commit 7b085a87a1
5 changed files with 57 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
from odoo import models, fields, api
class ResPartner(models.Model):
_inherit = 'res.partner'
woo_customer_ids = fields.One2many('woo.customer', 'partner_id', string='WooCommerce Links')
is_woo_customer = fields.Boolean(compute='_compute_is_woo_customer', string='Is WC Customer', store=True)
@api.depends('woo_customer_ids')
def _compute_is_woo_customer(self):
for partner in self:
partner.is_woo_customer = bool(partner.woo_customer_ids)