diff options
| author | Florent de Labarre <florent.mirieu@gmail.com> | 2021-05-21 15:55:33 +0000 |
|---|---|---|
| committer | Florent de Labarre <florent.mirieu@gmail.com> | 2021-05-22 08:19:00 +0000 |
| commit | f5f64536171d1bc2e4d89e1b5c5356763ffb8a87 (patch) | |
| tree | f65f0fb2df49ebab3632d71db305ad4e9bdbd4f9 | |
| parent | 36a9e761c8d6c1c6e9611cc410ecca82ff2b1659 (diff) | |
[FIX] l10n_fr_pos_cert: hash doesn't appear in ticket during reprint
- Create a pos order, pay and valide
- Close Pos
- reopen pos
- search this order
- click print ticket
--> Issue the hash doesn't appear on the ticket
closes odoo/odoo#71172
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
| -rw-r--r-- | addons/l10n_fr_pos_cert/models/pos.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/addons/l10n_fr_pos_cert/models/pos.py b/addons/l10n_fr_pos_cert/models/pos.py index 792224a8dea..ec67ad812f8 100644 --- a/addons/l10n_fr_pos_cert/models/pos.py +++ b/addons/l10n_fr_pos_cert/models/pos.py @@ -127,6 +127,11 @@ class pos_order(models.Model): if order.company_id._is_accounting_unalterable(): raise UserError(_("According to French law, you cannot delet a point of sale order.")) return super(pos_order, self).unlink() + + def _export_for_ui(self, order): + res = super()._export_for_ui(order) + res['l10n_fr_hash'] = order.l10n_fr_hash + return res class PosOrderLine(models.Model): |
