This is an automated email from the ASF dual-hosted git repository.

mridulpathak 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 d9ed965ac6 Fixed: Add missing permission checks to GL account mapping, 
invoice and payment-group services (OFBIZ-13713)
d9ed965ac6 is described below

commit d9ed965ac6a78d9dd48cdb1989e839db02a637ee
Author: Mridul Pathak <[email protected]>
AuthorDate: Thu Oct 22 19:40:35 2026 +0530

    Fixed: Add missing permission checks to GL account mapping, invoice and 
payment-group services (OFBIZ-13713)
    
    - CreditCardTypeGlAccount, GlAccountCategory, GlAccountCategoryMember, 
FinAccountTypeGlAccount and VarianceReasonGlAccount services now require the 
existing basicGeneralLedgerPermissionCheck, matching the 
GlAccount/GlAccountOrganization services already protected by it.
    - createInvoiceAttribute and updateInvoiceItemType now require the existing 
acctgInvoicePermissionCheck.
    - createPaymentGroup, updatePaymentGroup, updatePaymentGroupMember and 
updatePaymentMethodType now require the existing acctgPaymentPermissionCheck.
---
 applications/accounting/servicedef/services_invoice.xml       | 2 ++
 applications/accounting/servicedef/services_ledger.xml        | 9 +++++++++
 applications/accounting/servicedef/services_paymentmethod.xml | 7 +++++++
 3 files changed, 18 insertions(+)

diff --git a/applications/accounting/servicedef/services_invoice.xml 
b/applications/accounting/servicedef/services_invoice.xml
index 43e1fc0309..315f832653 100644
--- a/applications/accounting/servicedef/services_invoice.xml
+++ b/applications/accounting/servicedef/services_invoice.xml
@@ -318,6 +318,7 @@ under the License.
 
     <service name="updateInvoiceItemType" 
default-entity-name="InvoiceItemType" engine="entity-auto" invoke="update">
         <description>Update Invoice Item Type Record</description>
+        <permission-service service-name="acctgInvoicePermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes mode="IN" include="pk"/>
         <auto-attributes mode="IN" include="nonpk" optional="true"/>
     </service>
@@ -503,6 +504,7 @@ under the License.
     <!-- InvoiceAttribute services -->
     <service name="createInvoiceAttribute" 
default-entity-name="InvoiceAttribute" engine="entity-auto" invoke="create" 
auth="true">
         <description>Create a InvoiceAttribute</description>
+        <permission-service service-name="acctgInvoicePermissionCheck" 
main-action="CREATE"/>
         <auto-attributes include="nonpk" mode="IN" optional="true"/>
         <auto-attributes include="pk" mode="INOUT"/>
     </service>
diff --git a/applications/accounting/servicedef/services_ledger.xml 
b/applications/accounting/servicedef/services_ledger.xml
index 182b3147fb..af6e099199 100644
--- a/applications/accounting/servicedef/services_ledger.xml
+++ b/applications/accounting/servicedef/services_ledger.xml
@@ -382,11 +382,13 @@ under the License.
     </service>
     <service name="updateFinAccountTypeGlAccount" 
default-entity-name="FinAccountTypeGlAccount" engine="entity-auto" 
invoke="update" auth="true">
         <description>Update a FinAccountTypeGlAccount</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="false"/>
     </service>
     <service name="deleteFinAccountTypeGlAccount" 
default-entity-name="FinAccountTypeGlAccount" engine="entity-auto" 
invoke="delete" auth="true">
         <description>Delete a FinAccountTypeGlAccount</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="DELETE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
     </service>
 
@@ -398,11 +400,13 @@ under the License.
     </service>
     <service name="updateVarianceReasonGlAccount" 
default-entity-name="VarianceReasonGlAccount" engine="entity-auto" 
invoke="update" auth="true">
         <description>Update a Variance Reason Gl Account</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="false"/>
     </service>
     <service name="deleteVarianceReasonGlAccount" 
default-entity-name="VarianceReasonGlAccount" engine="entity-auto" 
invoke="delete" auth="true">
         <description>delete a Variance Reason Gl Account</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="DELETE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
     </service>
 
@@ -602,27 +606,32 @@ under the License.
 
     <service name="createGlAccountCategory" engine="entity-auto" 
default-entity-name="GlAccountCategory" invoke="create" auth="true">
         <description>Create GL Account Category</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="CREATE"/>
         <auto-attributes mode="OUT" include="pk" optional="false"/>
         <auto-attributes mode="IN" include="nonpk" optional="true"/>
     </service>
     <service name="updateGlAccountCategory" engine="entity-auto" 
default-entity-name="GlAccountCategory" invoke="update" auth="true">
         <description>Update GL Account Category</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes mode="IN" include="pk" optional="false" />
         <auto-attributes mode="IN" include="nonpk" optional="true"/>
     </service>
     <service name="createGlAccountCategoryMember" engine="entity-auto" 
default-entity-name="GlAccountCategoryMember" invoke="create" auth="true">
         <description>Create GL Account Category Member</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="CREATE"/>
         <auto-attributes mode="IN" include="pk" optional="false"/>
         <auto-attributes mode="IN" include="nonpk" optional="true"/>
         <override name="fromDate" optional="true"/>
     </service>
     <service name="deleteGlAccountCategoryMember" engine="entity-auto" 
default-entity-name="GlAccountCategoryMember" invoke="delete" auth="true">
         <description>Delete GL Account Category Member</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="DELETE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
     </service>
     <service name="updateGlAccountCategoryMember" engine="simple" 
default-entity-name="GlAccountCategoryMember"
         
location="component://accounting/minilang/ledger/GeneralLedgerServices.xml" 
invoke="updateGlAccountCategoryMember" auth="true">
         <description>Update GL Account Category Member</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="true"/>
     </service>
diff --git a/applications/accounting/servicedef/services_paymentmethod.xml 
b/applications/accounting/servicedef/services_paymentmethod.xml
index f55af43632..1a7e5c92e5 100644
--- a/applications/accounting/servicedef/services_paymentmethod.xml
+++ b/applications/accounting/servicedef/services_paymentmethod.xml
@@ -805,16 +805,19 @@ under the License.
     <!-- CreditCardTypeGlAccount Services -->
     <service name="createCreditCardTypeGlAccount" 
default-entity-name="CreditCardTypeGlAccount" engine="entity-auto" 
invoke="create" auth="true">
         <description>create a Credit Card Gl Account</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="CREATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="false"/>
     </service>
     <service name="updateCreditCardTypeGlAccount" 
default-entity-name="CreditCardTypeGlAccount" engine="entity-auto" 
invoke="update" auth="true">
         <description>Update a Credit Card Gl Account </description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="false"/>
     </service>
     <service name="deleteCreditCardTypeGlAccount" 
default-entity-name="CreditCardTypeGlAccount" engine="entity-auto" 
invoke="delete" auth="true">
         <description>delete a Credit Card Gl Account</description>
+        <permission-service service-name="basicGeneralLedgerPermissionCheck" 
main-action="DELETE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
     </service>
 
@@ -826,6 +829,7 @@ under the License.
     </service>
     <service name="updatePaymentMethodType" 
default-entity-name="PaymentMethodType" engine="entity-auto" invoke="update" 
auth="true">
         <description>Update a Payment Method Type</description>
+        <permission-service service-name="acctgPaymentPermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="true"/>
     </service>
@@ -837,6 +841,7 @@ under the License.
     <!-- Payment Group -->
     <service name="createPaymentGroup" default-entity-name="PaymentGroup" 
engine="entity-auto" invoke="create" auth="true">
         <description>Create a Payment Group</description>
+        <permission-service service-name="acctgPaymentPermissionCheck" 
main-action="CREATE"/>
         <auto-attributes include="pk" mode="OUT" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="true"/>
         <override name="paymentGroupTypeId" optional="false"/>
@@ -844,6 +849,7 @@ under the License.
     </service>
     <service name="updatePaymentGroup" default-entity-name="PaymentGroup" 
engine="entity-auto" invoke="update" auth="true">
         <description>Update a Payment Group</description>
+        <permission-service service-name="acctgPaymentPermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="true"/>
     </service>
@@ -862,6 +868,7 @@ under the License.
     </service>
     <service name="updatePaymentGroupMember" 
default-entity-name="PaymentGroupMember" engine="entity-auto" invoke="update" 
auth="true">
         <description>Update a Payment Group Member</description>
+        <permission-service service-name="acctgPaymentPermissionCheck" 
main-action="UPDATE"/>
         <auto-attributes include="pk" mode="IN" optional="false"/>
         <auto-attributes include="nonpk" mode="IN" optional="true"/>
     </service>

Reply via email to