svn commit: r686944 - /ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r686944 - /ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml

hansbak-2
Author: hansbak
Date: Mon Aug 18 19:55:07 2008
New Revision: 686944

URL: http://svn.apache.org/viewvc?rev=686944&view=rev
Log:
small error correction in project permission services: DemoEmployee could create own timesheet

Modified:
    ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml

Modified: ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml?rev=686944&r1=686943&r2=686944&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml Mon Aug 18 19:55:07 2008
@@ -213,6 +213,7 @@
         
         <!-- TIMESHEET -->
         <if-compare field="sec_object" value="TIMESHEET" operator="equals">
+            <entity-one entity-name="Timesheet" value-name="timesheet"/>
             <!-- log level="info" message="======ProjectMGR Security=====  action: ${mainAction} object: ${sec_object} timesheetId: ${timesheet.timesheetId} partyId: ${timesheet.partyId} resourceDescription: ${parameters.resourceDescription}"/-->
             <if>
                 <condition>
@@ -234,7 +235,7 @@
                         </and>
                         <and><!-- can always create ones own timesheet -->
                             <if-compare field="mainAction" value="CREATE" operator="equals"/>
-                            <if-compare-field field="timesheet.partyId" to-field="parameters.userLogin.partyId" operator="equals"/>
+                            <if-compare-field field="parameters.partyId" to-field="parameters.userLogin.partyId" operator="equals"/><!-- timesheet not exist yet -->
                         </and>
                         <and><!-- can always update ones own timesheet -->
                             <if-compare field="mainAction" value="UPDATE" operator="equals"/>
@@ -262,7 +263,7 @@
             <set field="taskId" from-field="parameters.workEffortId"/>
             <set field="partyId" from-field="timesheet.partyId"/>
             <call-simple-method method-name="checkProjectMembership"/>
-            <!-- log level="info" message="======ProjectMGR Security=====  action: ${mainAction} object: ${sec_object} timesheetId: ${timesheetId} from partyId: ${partyId} workEffortId: ${parameters.workEffortId} resourceDescription: ${parameters.resourceDescription}"/-->
+            <log level="info" message="======ProjectMGR Security=====  action: ${mainAction} object: ${sec_object} timesheetId: ${timesheetId} from partyId: ${partyId} workEffortId: ${parameters.workEffortId} resourceDescription: ${parameters.resourceDescription}"/>
             <if>
                 <condition>
                     <or>