From 50122462ed99fde8e476f439fd130dd8837abfa7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 27 Aug 2024 00:11:50 +0200 Subject: [PATCH] Display favorite users on menu form --- trytond/trytond/ir/ui/menu.py | 2 ++ trytond/trytond/ir/view/ui_menu_form.xml | 14 +++++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/trytond/trytond/ir/ui/menu.py b/trytond/trytond/ir/ui/menu.py index 8afb5f92e1..c21f416f3e 100644 --- a/trytond/trytond/ir/ui/menu.py +++ b/trytond/trytond/ir/ui/menu.py @@ -107,6 +107,8 @@ class UIMenu( ('keyword', '=', 'tree_open'), ]) favorite = fields.Function(fields.Boolean('Favorite'), 'get_favorite') + favorites = fields.Many2Many( + 'ir.ui.menu.favorite', 'menu', 'user', "Favorites") @classmethod def order_complete_name(cls, tables): diff --git a/trytond/trytond/ir/view/ui_menu_form.xml b/trytond/trytond/ir/view/ui_menu_form.xml index 540028dc82..4ed92f5357 100644 --- a/trytond/trytond/ir/view/ui_menu_form.xml +++ b/trytond/trytond/ir/view/ui_menu_form.xml @@ -16,7 +16,15 @@ this repository contains the full copyright notices and license terms. -->