diff --git a/modules/web_shop/CHANGELOG b/modules/web_shop/CHANGELOG index 4e6601b794..50a402c6b6 100644 --- a/modules/web_shop/CHANGELOG +++ b/modules/web_shop/CHANGELOG @@ -1,3 +1,4 @@ +* Add an URL to sales Version 7.8.0 - 2025-12-15 -------------------------- diff --git a/modules/web_shop/sale.py b/modules/web_shop/sale.py index 9136f68131..751cb05593 100644 --- a/modules/web_shop/sale.py +++ b/modules/web_shop/sale.py @@ -23,6 +23,14 @@ class Sale(metaclass=PoolMeta): 'required': Bool(Eval('web_shop')), 'readonly': ~Eval('web_id'), }) + web_url = fields.Function( + fields.Char( + "Web URL", + states={ + 'invisible': ~Eval('web_url'), + }, + help="The URL of the order on the web shop."), + 'get_web_url') web_status_url = fields.Function( fields.Char( "Web Status URL", @@ -64,6 +72,9 @@ class Sale(metaclass=PoolMeta): if self.web_shop and not self.web_id: self.web_id = token_hex(nbytes) + def get_web_url(self, name): + pass + def get_web_status_url(self, name): pass diff --git a/modules/web_shop/view/sale_form.xml b/modules/web_shop/view/sale_form.xml index 661fefc54b..376a45c60f 100644 --- a/modules/web_shop/view/sale_form.xml +++ b/modules/web_shop/view/sale_form.xml @@ -8,6 +8,8 @@ this repository contains the full copyright notices and license terms. -->