This is an automated email from the ASF dual-hosted git repository. jleroux pushed a commit to branch trunk in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git
The following commit(s) were added to refs/heads/trunk by this push: new 780e9f77b5 Improved: Move create new BillingAccount trigger to MainActionMenu (OFBIZ-12907) (#702) 780e9f77b5 is described below commit 780e9f77b5b77f12ce76aa301bf585bfe3ce1833 Author: Pierre Smits <pierre.sm...@somonar.com> AuthorDate: Mon Feb 19 18:28:33 2024 +0100 Improved: Move create new BillingAccount trigger to MainActionMenu (OFBIZ-12907) (#702) On CommonBillingAccountDecorator there is a action trigger to create a new Billing Account that is visible to users with only VIEW permissions. Moving the action trigger to the MainActionMenu with a permission condition ensures that is only visible to the appropriate users. modified: - BillingAccountScreens.xml: removed container with action trigger to create a new billing account - AccountingMenus.xml: added menu-item for creating a new billing account --- applications/accounting/widget/AccountingMenus.xml | 8 ++++++++ applications/accounting/widget/BillingAccountScreens.xml | 3 --- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/applications/accounting/widget/AccountingMenus.xml b/applications/accounting/widget/AccountingMenus.xml index d87819f35e..995476a7aa 100644 --- a/applications/accounting/widget/AccountingMenus.xml +++ b/applications/accounting/widget/AccountingMenus.xml @@ -87,6 +87,14 @@ under the License. </condition> <link target="EditPaymentGroup"/> </menu-item> + <menu-item name="NewBillingAccount" title="${uiLabelMap.CommonCreate} ${uiLabelMap.AccountingNewBillingAccount}"> + <condition> + <or> + <if-has-permission permission="ACCOUNTING" action="_CREATE"/> + </or> + </condition> + <link target="EditBillingAccount"/> + </menu-item> </menu> <menu name="AccountingShortcutAppBar" title="${uiLabelMap.AccountingManager}"> diff --git a/applications/accounting/widget/BillingAccountScreens.xml b/applications/accounting/widget/BillingAccountScreens.xml index efc9f3a21e..ba67b8cda3 100644 --- a/applications/accounting/widget/BillingAccountScreens.xml +++ b/applications/accounting/widget/BillingAccountScreens.xml @@ -52,9 +52,6 @@ under the License. <if-service-permission service-name="acctgBasePermissionCheck" main-action="VIEW"/> </condition> <widgets> - <container style="button-bar"> - <link target="EditBillingAccount" text="${uiLabelMap.CommonCreate}" style="buttontext create"/> - </container> <decorator-section-include name="body"/> </widgets> <fail-widgets>