You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by jl...@apache.org on 2009/09/24 06:53:43 UTC

svn commit: r818370 - in /ofbiz/trunk/applications: accounting/data/AccountingSecurityData.xml accounting/data/AccountingUserDemoData.xml accounting/ofbiz-component.xml party/data/PartyTypeData.xml

Author: jleroux
Date: Thu Sep 24 04:53:43 2009
New Revision: 818370

URL: http://svn.apache.org/viewvc?rev=818370&view=rev
Log:
A patch from Sumit Pandit "Setup a new SecurityGroup specific for Accounting component." (https://issues.apache.org/jira/browse/OFBIZ-2606) - OFBIZ-2606

To setup of a new SecurityGroup which is dedicated to Accounting component only. It will assigned by all SecurityPermission which are required to handle variuos accounting operations.
Purpose of this will be to be able to create a UserLogin, who will have restricted access to Accounting component only.

Added:
    ofbiz/trunk/applications/accounting/data/AccountingUserDemoData.xml
Modified:
    ofbiz/trunk/applications/accounting/data/AccountingSecurityData.xml
    ofbiz/trunk/applications/accounting/ofbiz-component.xml
    ofbiz/trunk/applications/party/data/PartyTypeData.xml

Modified: ofbiz/trunk/applications/accounting/data/AccountingSecurityData.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/data/AccountingSecurityData.xml?rev=818370&r1=818369&r2=818370&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/data/AccountingSecurityData.xml (original)
+++ ofbiz/trunk/applications/accounting/data/AccountingSecurityData.xml Thu Sep 24 04:53:43 2009
@@ -111,5 +111,23 @@
     <SecurityGroupPermission groupId="BIZADMIN" permissionId="ACCTG_ATX_CREATE"/>
     <SecurityGroupPermission groupId="BIZADMIN" permissionId="ACCTG_ATX_UPDATE"/>
     <SecurityGroupPermission groupId="BIZADMIN" permissionId="ACCTG_ATX_DELETE"/>
+    
+    <!-- Security Group to manage all Accounting operations -->
+    <SecurityGroup description="Accounting permission for all accounting functions." groupId="ACCTG_FUNCTNL_ADMIN"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCOUNTING_ADMIN"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="OFBTOOLS_VIEW"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCTG_ATX_ADMIN"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCTG_FX_UPDATE"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCTG_PREF_ADMIN"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCOUNTING_PRINT_CHECKS"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCOUNTING_COMM_VIEW"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="MANUAL_PAYMENT"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="PAY_INFO_ADMIN"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="PAYPROC_ADMIN"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ASSETMAINT_VIEW"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCOUNTING_CREATE"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCOUNTING_DELETE"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCOUNTING_UPDATE"/>
+    <SecurityGroupPermission groupId="ACCTG_FUNCTNL_ADMIN" permissionId="ACCOUNTING_VIEW"/>
 
 </entity-engine-xml>

Added: ofbiz/trunk/applications/accounting/data/AccountingUserDemoData.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/data/AccountingUserDemoData.xml?rev=818370&view=auto
==============================================================================
--- ofbiz/trunk/applications/accounting/data/AccountingUserDemoData.xml (added)
+++ ofbiz/trunk/applications/accounting/data/AccountingUserDemoData.xml Thu Sep 24 04:53:43 2009
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<entity-engine-xml>
+    <Party partyId="accountant_group" partyTypeId="PARTY_GROUP"/>
+    <PartyGroup partyId="accountant_group" groupName="Accountant Group"/>
+    <PartyRole partyId="accountant_group" roleTypeId="ORGANIZATION_ROLE"/>
+    <PartyRole partyId="accountant_group" roleTypeId="_NA_"/>
+    <PartyRelationship partyIdFrom="Company" partyIdTo="accountant_group" partyRelationshipTypeId="GROUP_ROLLUP" roleTypeIdFrom="_NA_" roleTypeIdTo="_NA_" fromDate="2001-01-01 12:00:00.0"/>
+
+    <Party partyId="accountingadmin" partyTypeId="PERSON"/>
+    <Person partyId="accountingadmin" firstName="Accounting" lastName="Administrator"/>
+    <PartyRole partyId="accountingadmin" roleTypeId="ACCOUNTANT"/>
+    <PartyRole partyId="accountingadmin" roleTypeId="EMPLOYEE"/>
+    <PartyRole partyId="accountingadmin" roleTypeId="_NA_"/>
+    <UserLogin userLoginId="accountingadmin" currentPassword="{SHA}47ca69ebb4bdc9ae0adec130880165d2cc05db1a" partyId="accountingadmin" passwordHint=""/>
+    <UserLoginSecurityGroup groupId="ACCTG_FUNCTNL_ADMIN" userLoginId="accountingadmin" fromDate="2001-01-01 12:00:00.0"/>    
+
+    <PartyRelationship partyIdFrom="Company" partyIdTo="accountingadmin" partyRelationshipTypeId="EMPLOYMENT" roleTypeIdFrom="INTERNAL_ORGANIZATIO" roleTypeIdTo="EMPLOYEE" fromDate="2001-01-01 12:00:00.0"/>
+    <PartyRelationship partyIdFrom="accountant_group" partyIdTo="accountingadmin" partyRelationshipTypeId="GROUP_ROLLUP" roleTypeIdFrom="ORGANIZATION_ROLE" roleTypeIdTo="ACCOUNTANT" fromDate="2001-01-01 12:00:00.0"/>
+    
+</entity-engine-xml>

Modified: ofbiz/trunk/applications/accounting/ofbiz-component.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/ofbiz-component.xml?rev=818370&r1=818369&r2=818370&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/ofbiz-component.xml (original)
+++ ofbiz/trunk/applications/accounting/ofbiz-component.xml Thu Sep 24 04:53:43 2009
@@ -49,6 +49,8 @@
     <entity-resource type="data" reader-name="demo" loader="main" location="data/DemoFinAccountData.xml"/>
     <entity-resource type="data" reader-name="demo" loader="main" location="data/DemoTaxAuthority.xml"/>
     
+    <entity-resource type="data" reader-name="demo" loader="main" location="data/AccountingUserDemoData.xml"/>
+
     <!-- General Payment Service Definitions -->
     <service-resource type="model" loader="main" location="servicedef/services_agreement.xml"/>
     <service-resource type="model" loader="main" location="servicedef/services_admin.xml"/>

Modified: ofbiz/trunk/applications/party/data/PartyTypeData.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/data/PartyTypeData.xml?rev=818370&r1=818369&r2=818370&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/data/PartyTypeData.xml (original)
+++ ofbiz/trunk/applications/party/data/PartyTypeData.xml Thu Sep 24 04:53:43 2009
@@ -183,6 +183,7 @@
     <RoleType description="Visitor" hasTable="N" parentTypeId="" roleTypeId="VISITOR"/>
     <RoleType description="Web Master" hasTable="N" parentTypeId="" roleTypeId="WEB_MASTER"/>
     <RoleType description="Workflow" hasTable="N" parentTypeId="" roleTypeId="WORKFLOW_ROLE"/>
+    <RoleType description="Accountant" hasTable="N" parentTypeId="" roleTypeId="ACCOUNTANT"/>
 
     <!-- second level role types -->
     <RoleType description="Account" hasTable="N" parentTypeId="SFA_ROLE" roleTypeId="ACCOUNT"/>