Author: hansbak
Date: Mon Dec 31 18:45:50 2007 New Revision: 607794 URL: http://svn.apache.org/viewvc?rev=607794&view=rev Log: first part of the security implementation on the 'mytask' screen, added demo data, mytask screen fieldlayout modified, services organisation changed because of security, some part probably not working, will try to fix that today... Added: ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml Modified: ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrDemoData.xml ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrSecurityData.xml ofbiz/trunk/specialpurpose/projectmgr/ofbiz-component.xml ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml ofbiz/trunk/specialpurpose/projectmgr/servicedef/secas.xml ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/actions/EditWeekTimesheet.bsh ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/controller.xml ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml Modified: ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrDemoData.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrDemoData.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrDemoData.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrDemoData.xml Mon Dec 31 18:45:50 2007 @@ -5,29 +5,63 @@ <!-- Demo Employee1 --> <Party partyId="DemoEmployee1" partyTypeId="PERSON" statusId="PARTY_ENABLED" /> <Person partyId="DemoEmployee1" firstName="Peter" lastName="Manager" /> - <UserLogin userLoginId="DemoEmployee1" partyId="DemoEmployee1" currentPassword="47ca69ebb4bdc9ae0adec130880165d2cc05db1a"/> + <UserLogin userLoginId="DemoEmployee1" partyId="DemoEmployee1" currentPassword="47ca69ebb4bdc9ae0adec130880165d2cc05db1a" enabled="Y" hasLoggedOut="Y"/> <PartyRole partyId="DemoEmployee1" roleTypeId="EMPLOYEE"/> <PartyContactMech partyId="DemoEmployee1" contactMechId="9020" fromDate="2000-01-01 10:01:48.933" roleTypeId="EMPLOYEE" /> <PartyContactMech partyId="DemoEmployee1" contactMechId="9001" fromDate="2000-01-01 10:01:48.933" roleTypeId="EMPLOYEE" /> <PartyContactMech partyId="DemoEmployee1" contactMechId="9023" fromDate="2000-01-01 10:01:48.933" roleTypeId="EMPLOYEE" /> <PartyRole partyId="DemoEmployee1" roleTypeId="PROJECT_TEAM"/> + <!-- Demo Employee2 --> <Party partyId="DemoEmployee2" partyTypeId="PERSON" statusId="PARTY_ENABLED" /> <Person partyId="DemoEmployee2" firstName="Jo" lastName="Analist" /> - <UserLogin userLoginId="DemoEmployee2" partyId="DemoEmployee2" currentPassword="47ca69ebb4bdc9ae0adec130880165d2cc05db1a"/> + <UserLogin userLoginId="DemoEmployee2" partyId="DemoEmployee2" currentPassword="47ca69ebb4bdc9ae0adec130880165d2cc05db1a" enabled="Y" hasLoggedOut="Y"/> <PartyRole partyId="DemoEmployee2" roleTypeId="EMPLOYEE"/> <PartyContactMech partyId="DemoEmployee2" contactMechId="9020" fromDate="2000-01-01 10:01:48.933" roleTypeId="EMPLOYEE" /> <PartyContactMech partyId="DemoEmployee2" contactMechId="9001" fromDate="2000-01-01 10:01:48.933" roleTypeId="EMPLOYEE" /> <PartyContactMech partyId="DemoEmployee2" contactMechId="9023" fromDate="2000-01-01 10:01:48.933" roleTypeId="EMPLOYEE" /> <PartyRole partyId="DemoEmployee2" roleTypeId="PROJECT_TEAM"/> - <!-- make sure they show up as resources --> - <PartyRole partyId="DemoCustomer" roleTypeId="PROJECT_TEAM"/> + + <!-- Demo Customer1 --> + <Party partyId="DemoCustomer1" partyTypeId="PERSON" statusId="PARTY_ENABLED" /> + <Person partyId="DemoCustomer1" firstName="Sam" lastName="Customer 1" /> + <UserLogin userLoginId="DemoCustomer1" partyId="DemoCustomer1" currentPassword="47ca69ebb4bdc9ae0adec130880165d2cc05db1a" enabled="Y" hasLoggedOut="Y"/> + <PartyRole partyId="DemoCustomer1" roleTypeId="CUSTOMER"/> + <PartyContactMech partyId="DemoCustomer1" contactMechId="9020" fromDate="2000-01-01 10:01:48.933" roleTypeId="CUSTOMER" /> + <PartyContactMech partyId="DemoCustomer1" contactMechId="9001" fromDate="2000-01-01 10:01:48.933" roleTypeId="CUSTOMER" /> + <PartyContactMech partyId="DemoCustomer" contactMechId="9023" fromDate="2000-01-01 10:01:48.933" roleTypeId="CUSTOMER" /> + <PartyRole partyId="DemoCustomer1" roleTypeId="PROJECT_TEAM"/> + + <!-- Demo Customer2 --> + <Party partyId="DemoCustomer2" partyTypeId="PERSON" statusId="PARTY_ENABLED" /> + <Person partyId="DemoCustomer2" firstName="John" lastName="Customer 2"/> + <UserLogin userLoginId="DemoCustomer2" partyId="DemoCustomer2" currentPassword="47ca69ebb4bdc9ae0adec130880165d2cc05db1a" enabled="Y" hasLoggedOut="Y"/> + <PartyRole partyId="DemoCustomer2" roleTypeId="CUSTOMER"/> + <PartyContactMech partyId="DemoCustomer2" contactMechId="9020" fromDate="2000-01-01 10:01:48.933" roleTypeId="CUSTOMER" /> + <PartyContactMech partyId="DemoCustomer2" contactMechId="9001" fromDate="2000-01-01 10:01:48.933" roleTypeId="CUSTOMER" /> + <PartyContactMech partyId="DemoCustomer2" contactMechId="9023" fromDate="2000-01-01 10:01:48.933" roleTypeId="CUSTOMER" /> + <PartyRole partyId="DemoCustomer2" roleTypeId="PROJECT_TEAM"/> + + <!-- make sure admin show up as resources --> <PartyRole partyId="admin" roleTypeId="PROJECT_TEAM"/> - - <!-- Demo project, phases and tasks with estimated time--> - <WorkEffort workEffortId="9000" workEffortTypeId="PROJECT" currentStatusId="_NA_" lastStatusUpdate="2007-12-14 15:07:52.901" scopeEnumId="WES_PUBLIC" workEffortName="Demo Project" revisionNumber="1"/> + + <!-- security demo data --> + <SecurityGroupPermission groupId="FLEXADMIN" permissionId="PROJECTMGR_VIEW"/> + <SecurityGroupPermission groupId="VIEWADMIN" permissionId="PROJECTMGR_VIEW"/> + <SecurityGroupPermission groupId="BIZADMIN" permissionId="PROJECTMGR_VIEW"/> + <SecurityGroupPermission groupId="FULLADMIN" permissionId="PROJECTMGR_ADMIN"/> + + <UserLoginAndSecurityGroup groupId="PROJECTUSER" userLoginId="DemoCustomer1" fromDate="2000-01-01 00:00:00.0"/> + <UserLoginAndSecurityGroup groupId="PROJECTUSER" userLoginId="DemoCustomer2" fromDate="2000-01-01 00:00:00.0"/> + <UserLoginAndSecurityGroup groupId="PROJECTUSER" userLoginId="DemoEmployee1" fromDate="2000-01-01 00:00:00.0"/> + <UserLoginAndSecurityGroup groupId="PROJECTUSER" userLoginId="DemoEmployee2" fromDate="2000-01-01 00:00:00.0"/> + + <!-- First Demo project from customer 1, phases and tasks with estimated time--> + <WorkEffort workEffortId="9000" workEffortTypeId="PROJECT" currentStatusId="_NA_" lastStatusUpdate="2007-12-14 15:07:52.901" scopeEnumId="WES_PUBLIC" workEffortName="Demo Project Cust1" revisionNumber="1"/> <WorkEffortPartyAssignment workEffortId="9000" partyId="admin" statusId="PAS_ASSIGNED" roleTypeId="PROVIDER_MANAGER" fromDate="2007-12-14 16:45:21.831"/> - <WorkEffortPartyAssignment workEffortId="9000" partyId="DemoCustomer" statusId="PAS_ASSIGNED" roleTypeId="CLIENT_MANAGER" fromDate="2007-12-14 16:45:21.831"/> + <WorkEffortPartyAssignment workEffortId="9000" partyId="DemoCustomer1" statusId="PAS_ASSIGNED" roleTypeId="CLIENT_MANAGER" fromDate="2007-12-14 16:45:21.831"/> + <WorkEffortPartyAssignment workEffortId="9000" partyId="DemoEmployee1" statusId="PAS_ASSIGNED" roleTypeId="PROVIDER_MANAGER" fromDate="2007-12-14 16:45:21.831"/> + <WorkEffortPartyAssignment workEffortId="9000" partyId="DemoEmployee2" statusId="PAS_ASSIGNED" roleTypeId="PROVIDER_ANALYST" fromDate="2007-12-14 16:45:21.831"/> <WorkEffort workEffortId="9001" workEffortTypeId="PHASE" currentStatusId="_NA_" lastStatusUpdate="2007-12-14 16:45:14.226" workEffortParentId="9000" workEffortName="phase1" revisionNumber="1" /> <WorkEffort workEffortId="9002" workEffortTypeId="TASK" currentStatusId="PTS_CREATED" lastStatusUpdate="2007-12-14 16:45:21.831" workEffortParentId="9001" scopeEnumId="WES_PUBLIC" workEffortName="task1" estimatedStartDate="2007-12-03 00:00:00.0" estimatedCompletionDate="2007-12-05 00:00:00.0" revisionNumber="1" /> <WorkEffortSkillStandard workEffortId="9002" skillTypeId="9000" estimatedDuration="16.0"/> @@ -44,4 +78,26 @@ <WorkEffortAssoc workEffortIdFrom="9003" workEffortIdTo="9005" workEffortAssocTypeId="WORK_EFF_DEPENDENCY" sequenceNum="0" fromDate="2000-01-01 00:00:00.0"/> <WorkEffortAssoc workEffortIdFrom="9005" workEffortIdTo="9006" workEffortAssocTypeId="WORK_EFF_DEPENDENCY" sequenceNum="0" fromDate="2000-01-01 00:00:00.0"/> + <!-- Second Demo project for customer 2, phases and tasks with estimated time--> + <WorkEffort workEffortId="9100" workEffortTypeId="PROJECT" currentStatusId="_NA_" lastStatusUpdate="2007-12-14 15:07:52.911" scopeEnumId="WES_PUBLIC" workEffortName="Demo Project Cust 2" revisionNumber="1"/> + <WorkEffortPartyAssignment workEffortId="9100" partyId="admin" statusId="PAS_ASSIGNED" roleTypeId="PROVIDER_MANAGER" fromDate="2007-12-14 16:45:21.831"/> + <WorkEffortPartyAssignment workEffortId="9100" partyId="DemoCustomer2" statusId="PAS_ASSIGNED" roleTypeId="CLIENT_MANAGER" fromDate="2007-12-14 16:45:21.831"/> + <WorkEffortPartyAssignment workEffortId="9100" partyId="DemoEmployee1" statusId="PAS_ASSIGNED" roleTypeId="PROVIDER_MANAGER" fromDate="2007-12-14 16:45:21.831"/> + <WorkEffortPartyAssignment workEffortId="9100" partyId="DemoEmployee2" statusId="PAS_ASSIGNED" roleTypeId="PROVIDER_ANALYST" fromDate="2007-12-14 16:45:21.831"/> + <WorkEffort workEffortId="9101" workEffortTypeId="PHASE" currentStatusId="_NA_" lastStatusUpdate="2007-12-14 16:45:14.226" workEffortParentId="9100" workEffortName="phase1" revisionNumber="1" /> + <WorkEffort workEffortId="9102" workEffortTypeId="TASK" currentStatusId="PTS_CREATED" lastStatusUpdate="2007-12-14 16:45:21.831" workEffortParentId="9101" scopeEnumId="WES_PUBLIC" workEffortName="task1" estimatedStartDate="2007-12-03 00:00:00.0" estimatedCompletionDate="2007-12-05 00:00:00.0" revisionNumber="1" /> + <WorkEffortSkillStandard workEffortId="9102" skillTypeId="9000" estimatedDuration="16.0"/> + <WorkEffort workEffortId="9103" workEffortTypeId="TASK" currentStatusId="PTS_CREATED" lastStatusUpdate="2007-12-14 16:45:29.453" workEffortParentId="9101" scopeEnumId="WES_PUBLIC" workEffortName="task2" estimatedStartDate="2007-12-05 00:00:00.0" estimatedCompletionDate="2007-12-16 00:00:00.0" revisionNumber="1" /> + <WorkEffortSkillStandard workEffortId="9103" skillTypeId="9000" estimatedDuration="24.0"/> + <WorkEffort workEffortId="9104" workEffortTypeId="PHASE" currentStatusId="_NA_" lastStatusUpdate="2007-12-14 16:45:35.939" workEffortParentId="9100" workEffortName="phase2" revisionNumber="1"/> + <WorkEffort workEffortId="9105" workEffortTypeId="TASK" currentStatusId="PTS_CREATED" lastStatusUpdate="2007-12-14 16:45:50.84" workEffortParentId="9104" scopeEnumId="WES_PUBLIC" workEffortName="task3" estimatedStartDate="2007-12-16 00:00:00.0" estimatedCompletionDate="2007-12-17 00:00:00.0" revisionNumber="1"/> + <WorkEffortSkillStandard workEffortId="9105" skillTypeId="9000" estimatedDuration="32.0"/> + <WorkEffort workEffortId="9106" workEffortTypeId="TASK" currentStatusId="PTS_CREATED" lastStatusUpdate="2007-12-14 16:45:58.857" workEffortParentId="9104" scopeEnumId="WES_PUBLIC" workEffortName="task4" estimatedStartDate="2007-12-18 00:00:00.0" estimatedCompletionDate="2007-12-20 00:00:00.0" revisionNumber="1"/> + <WorkEffortSkillStandard workEffortId="9106" skillTypeId="9000" estimatedDuration="40.0"/> + + <!-- task dependencies --> + <WorkEffortAssoc workEffortIdFrom="9102" workEffortIdTo="9103" workEffortAssocTypeId="WORK_EFF_DEPENDENCY" sequenceNum="0" fromDate="2000-01-01 00:00:00.0"/> + <WorkEffortAssoc workEffortIdFrom="9103" workEffortIdTo="9105" workEffortAssocTypeId="WORK_EFF_DEPENDENCY" sequenceNum="0" fromDate="2000-01-01 00:00:00.0"/> + <WorkEffortAssoc workEffortIdFrom="9105" workEffortIdTo="9106" workEffortAssocTypeId="WORK_EFF_DEPENDENCY" sequenceNum="0" fromDate="2000-01-01 00:00:00.0"/> + </entity-engine-xml> Modified: ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrSecurityData.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrSecurityData.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrSecurityData.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/data/ProjectMgrSecurityData.xml Mon Dec 31 18:45:50 2007 @@ -20,11 +20,17 @@ <entity-engine-xml> <!-- Project Manager security --> - <SecurityPermission description="View operations in the Project Manager." permissionId="PROJECT_VIEW"/> + <SecurityPermission description="ALL operations in the Project Manager." permissionId="PROJECTMGR_ADMIN"/> + <SecurityPermission description="ALL operations in the project the user is member of" permissionId="PROJECTMGR_USER"/> + <SecurityPermission description="View operations in the Project Manager." permissionId="PROJECTMGR_VIEW"/> - <SecurityGroupPermission groupId="FLEXADMIN" permissionId="PROJECT_VIEW"/> - <SecurityGroupPermission groupId="FULLADMIN" permissionId="PROJECT_VIEW"/> - <SecurityGroupPermission groupId="VIEWADMIN" permissionId="PROJECT_VIEW"/> - <SecurityGroupPermission groupId="BIZADMIN" permissionId="PROJECT_VIEW"/> + <!-- the system makes heavily use of the workeffort component, but NOT its security, in the workeffort component + work is going on to move the security from the service program to the service definition level --> + <SecurityGroup description="Project User group, has only access to own projects." groupId="PROJECTUSER"/> + <SecurityGroupPermission groupId="PROJECTUSER" permissionId="PROJECTMGR_USER"/> + <SecurityGroupPermission groupId="PROJECTUSER" permissionId="PROJECTMGR_VIEW"/> + + <!-- allow the userlogin 'admin' full access --> + <SecurityGroupPermission groupId="FULLADMIN" permissionId="PROJECTMGR_ADMIN"/> </entity-engine-xml> Modified: ofbiz/trunk/specialpurpose/projectmgr/ofbiz-component.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/ofbiz-component.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/ofbiz-component.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/ofbiz-component.xml Mon Dec 31 18:45:50 2007 @@ -39,7 +39,7 @@ title="Project" server="default-server" location="webapp/projectmgr" - base-permission="OFBTOOLS,PROJECT" + base-permission="PROJECTMGR" mount-point="/projectmgr" app-bar-display="true"/> </ofbiz-component> Added: 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=607794&view=auto ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml (added) +++ ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectPermissionServices.xml Mon Dec 31 18:45:50 2007 @@ -0,0 +1,79 @@ +<?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. +--> + +<simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/simple-methods.xsd"> + + <simple-method method-name="projectMgrPermission" short-description="general service to check access to the project component"> + <set field="primaryPermission" value="PROJECTMGR"/> + <set field="hasPermission" value="true" type="Boolean"/> + <if-has-permission permission="PROJECTMGR" action="_ADMIN"> + <field-to-result field-name="hasPermission"/> + <return/> + <else> + <if-has-permission permission="PROJECTMGR" action="_VIEW"> + <if-has-permission permission="PROJECTMGR" action="_USER"> + <!-- object dependent checks here --> + <if-compare field-name="sec_object" value="PROJECT" operator="not-equals"> + <!-- if not project check if member of task, when not get the projectId --> + <if-compare field-name="sec_object" value="TASK" operator="equals"> + <!-- check if login party member of the task --> + <set field="findRel.workEffortId" from-field="sec_id"/> + <set field="findRel.partyId" from-field="userLogin.partyId"/> + <find-by-and entity-name="WorkEffortPartyAssignment" map-name="findRel" list-name="assigns"/> + <filter-list-by-date list-name="assigns" to-list-name="assignsFilt"/> + <if-not-empty field-name="assignsFilt"> + <field-to-result field-name="hasPermission"/> + <return/> + </if-not-empty> + <set field="getProj.workEffortId" from-field="sec_id"/> + <else> + <set field="getProj.phaseId" from-field="sec_id"/> + </else> + </if-compare> + <call-service service-name="getProjectIdAndName" in-map-name="getProj"> + <result-to-field result-name="projectId"/> + </call-service> + </if-compare> + <!-- see if login party member of the project --> + <set field="findRel.workEffortId" from-field="sec_id"/> + <set field="findRel.partyId" from-field="userLogin.partyId"/> + <find-by-and entity-name="WorkEffortPartyAssignment" map-name="findRel" list-name="assigns"/> + <filter-list-by-date list-name="assigns" to-list-name="assignsFilt"/> + <if-not-empty field-name="assignsFilt"> + <field-to-result field-name="hasPermission"/> + <return/> + </if-not-empty> + <else> + <if-compare field-name="sec_action" value="WRITE" operator="equals"> + <add-error> + <fail-property resource="ProjectMgrUiLabels" property="noAccess:NeedWriteOrUserAccess"/> + </add-error> + </if-compare> + </else> + </if-has-permission> + </if-has-permission> + </else> + </if-has-permission> + <check-errors/> + <field-to-result field-name="hasPermission"/> + </simple-method> + +</simple-methods> Modified: ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml Mon Dec 31 18:45:50 2007 @@ -21,61 +21,59 @@ <simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/simple-methods.xsd"> - <simple-method method-name="updateMyTaskAssigment" - short-description="Update my workEffortPartyAssigment, if required create a new one by re-assigment"> - <if-compare-field field-name="parameters.partyId" to-field-name="userLogin.partyId" operator="equals"> - <!-- check if roleType changed if yes delete old and create new assign--> - <if-compare-field field-name="parameters.roleTypeId" operator="not-equals" to-field-name="parameters.oldRoleTypeId"> - <set-service-fields service-name="deletePartyToWorkEffortAssignment" map-name="parameters" to-map-name="upd"/> - <set field="upd.roleTypeId" from-field="parameters.oldRoleTypeId"/> - <call-service service-name="deletePartyToWorkEffortAssignment" in-map-name="upd"/> - <set-service-fields service-name="assignPartyToWorkEffort" map-name="parameters" to-map-name="upd"/> - <clear-field field-name="upd.fromDate"/> - <call-service service-name="assignPartyToWorkEffort" in-map-name="upd"/> - <else> - <!-- simply update status --> - <set-service-fields service-name="updatePartyToWorkEffortAssignment" map-name="parameters" to-map-name="upd"/> - <call-service service-name="updatePartyToWorkEffortAssignment" in-map-name="upd"/> - </else> - </if-compare-field> + <simple-method method-name="updateTaskAssigment" + short-description="Update task to resource assignment, if required create a new one by re-assigment"> + <field-to-result map-name="parameters" field-name="workEffortId"/> + <if> + <condition> + <or> + <and> + <not> + <if-empty field-name="parameters.newPartyId"/> + </not> + <if-compare-field field-name="parameters.partyId" to-field-name="parameters.newPartyId" operator="not-equals"/> + </and> + <and> + <not> + <if-empty field-name="parameters.newRoleTypeId"/> + </not> + <if-compare-field field-name="parameters.roleTypeId" to-field-name="parameters.newRoleTypeId" operator="not-equals"/> + </and> + </or> + </condition> + <then> + <!-- roleType and/or partyId changed: end old and create new assign--> + <set-service-fields service-name="deletePartyToWorkEffortAssignment" map-name="parameters" to-map-name="del"/> + <call-service service-name="deletePartyToWorkEffortAssignment" in-map-name="del"/> + <set field="newAssign.workEffortId" from-field="parameters.workEffortId"/> + <set field="newAssign.partyId" from-field="parameters.newPartyId"/> + <set field="newAssign.roleTypeId" from-field="parameters.newRoleTypeId"/> + <set field="newAssign.statusId" value="PAS_ASSIGNED"/> + <call-service service-name="assignPartyToWorkEffort" in-map-name="newAssign"/> + </then> <else> - <!-- reassignment to other person --> - <!-- check if new person is part of the project --> - <set field="getProjectId.taskId" from-field="parameters.workEffortId"/> - <call-service service-name="getProjectIdAndName" in-map-name="getProjectId"> - <result-to-field result-name="projectId" field-name="findAssign.workEffortId"/> - </call-service> - <set field="findAssign.partyId" from-field="parameters.partyId"/> - <find-by-and entity-name="WorkEffortPartyAssignment" map-name="findAssign" list-name="assignments"/> - <filter-list-by-date list-name="assignments" to-list-name="validAssignments"/> - <set field="findValidAssign.partyId" from-field="parameters.partyId"/> - <filter-list-by-and list-name="validAssignments" map-name="findValidAssign" to-list-name="isValid"/> - <if-not-empty field-name="isValid"> - <!-- person is valid. - so end old entry and .....--> - <set-service-fields service-name="updatePartyToWorkEffortAssignment" map-name="parameters" to-map-name="endAssign"/> - <set field="endAssign.partyId" from-field="userLogin.partyId"/> - <now-timestamp-to-env env-name="endAssign.thruDate"/> - <call-service service-name="updatePartyToWorkEffortAssignment" in-map-name="endAssign"/> - <!-- ...create new one --> - <set-service-fields service-name="assignPartyToWorkEffort" map-name="parameters" to-map-name="createAssign"/> - <now-timestamp-to-env env-name="createAssign.fromDate"/> - <set field="createAssign.roleTypeId" from-field="parameters.newRoleTypeId"/> - <set field="statusId" value="PRTYASGN_ASSIGNED"/> - <call-service service-name="assignPartyToWorkEffort" in-map-name="createAssign"/> - <else> - <!-- person Id not valid, issue error and exit --> - <add-error><fail-message message="New party not member of this project"/></add-error> - <return response-code="error"/> - </else> - </if-not-empty> - + <!-- status changed or assignment ended --> + <entity-one entity-name="WorkEffortPartyAssignment" value-name="assignment"/> + <if-compare field-name="parameters.statusId" value="PAS_ENDED" operator="equals"> + <!-- special case to indicate end of assignment --> + <now-date-to-env env-name="assignment.thruDate"/> + <clear-field field-name="parameters.statusId"/> + </if-compare> + <set-nonpk-fields value-name="assignment" map-name="parameters"/> + <store-value value-name="assignment"/> + <call-simple-method method-name="updateTaskStatus"/> </else> - </if-compare-field> + </if> </simple-method> - + + <simple-method method-name="addTaskAssigment" short-description="assign a party to a task"> + <set-service-fields service-name="assignPartyToWorkEffort" map-name="parameters" to-map-name="add"/> + <set field="add.statusId" value="PAS_ASSIGNED"/> + <call-service service-name="assignPartyToWorkEffort" in-map-name="add"/> + </simple-method> + <simple-method method-name="updateTaskStatus" - short-description="Check partyassignements on a task, if all completes set task status to completed and set actual completiondate to now"> + short-description="Check partyassignments on a task, if all completes set task status to completed and set actual completiondate to now"> <entity-and entity-name="WorkEffortPartyAssignment" list-name="assignments" filter-by-date="true"> <field-map field-name="workEffortId" env-name="parameters.workEffortId"/> </entity-and> @@ -894,5 +892,4 @@ </else> </if-not-empty> </simple-method> - </simple-methods> Modified: ofbiz/trunk/specialpurpose/projectmgr/servicedef/secas.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/servicedef/secas.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/servicedef/secas.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/servicedef/secas.xml Mon Dec 31 18:45:50 2007 @@ -22,9 +22,9 @@ xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/service-eca.xsd"> <!-- update task status, actual completion date when all assignments complete --> - <eca service="updatePartyToWorkEffortAssignment" event="commit"> + <!--eca service="updateTaskAssigment" event="commit"> <condition field-name="statusId" operator="equals" value="PAS_COMPLETED"/> <action service="updateTaskStatus" mode="sync"/> - </eca> + </eca--> </service-eca> Modified: ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml Mon Dec 31 18:45:50 2007 @@ -19,15 +19,24 @@ --> <services xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/services.xsd"> + xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/services.xsd"> <description>Project Manager service definitions.</description> + <service name="projectMgrPermission" engine="simple" + location="org/ofbiz/project/ProjectPermissionServices.xml" invoke="projectMgrPermission"> + <implements service="permissionInterface"/> + <attribute name="projectId" type="String" mode="IN" optional="true"/> + <attribute name="phaseId" type="String" mode="IN" optional="true"/> + <attribute name="workEffortId" type="String" mode="IN" optional="true"/> + </service> + <service name="updateTaskStatus" engine="simple" location="org/ofbiz/project/ProjectServices.xml" invoke="updateTaskStatus"> <description>Update task status if required</description> + <permission-service service-name="projectMgrPermission" main-action="UPDATE"/> <attribute name="workEffortId" type="String" mode="IN"/> </service> - + <service name="updateTimeEntryByWorkeffort" engine="simple" location="org/ofbiz/project/ProjectServices.xml" invoke="updateTimeEntryByWorkeffort"> <description>Update workeffort by workeffort and timesheetId </description> @@ -52,7 +61,7 @@ <service name="createProject" engine="simple" default-entity-name="WorkEffort" location="org/ofbiz/project/ProjectServices.xml" invoke="createProject"> <description>Copy a project planning from a template.</description> - <permission-service service-name="workEffortGenericPermission" main-action="CREATE"/> + <permission-service service-name="projectPermission" main-action="CREATE"/> <implements service="interfaceWorkEffort"/> <auto-attributes mode="INOUT" include="pk" optional="true"/> <attribute name="projectId" type="String" mode="INOUT" optional="true"/> @@ -66,6 +75,23 @@ <override name="currentStatusId" optional="false"/> </service> + <service name="createProjectTask" engine="simple" default-entity-name="WorkEffort" + location="org/ofbiz/workeffort/workeffort/WorkEffortSimpleServices.xml" invoke="createWorkEffortAndPartyAssign"> + <description>Create a new task and optionally assign to a resource.</description> + <permission-service service-name="projectMgrPermission" main-action="CREATE"/> + <implements service="interfaceWorkEffort"/> + <auto-attributes mode="INOUT" include="pk" optional="true"/> + <attribute name="partyId" type="String" mode="IN" optional="false"/> + <attribute name="roleTypeId" type="String" mode="IN" optional="false"/> + <attribute name="statusId" type="String" mode="IN" optional="false"/> + <attribute name="quickAssignPartyId" type="String" mode="IN" optional="true"/> + <attribute name="requirementId" type="String" mode="IN" optional="true"/> + <attribute name="communicationEventId" type="String" mode="IN" optional="true"/> + <override name="workEffortTypeId" optional="false"/> + <override name="workEffortName" optional="false"/> + <override name="currentStatusId" optional="false"/> + </service> + <service name="copyProject" engine="simple" location="org/ofbiz/project/ProjectServices.xml" invoke="copyProject"> <description>Copy a project planning data but ignore the actual data.</description> @@ -135,15 +161,26 @@ <attribute name="taskParties" type="List" mode="OUT" optional="true"/> </service> - <service name="updateMyTaskAssigment" default-entity-name="WorkEffortPartyAssignment" engine="simple" - location="org/ofbiz/project/ProjectServices.xml" invoke="updateMyTaskAssigment"> - <description>Update a WorkEffortPartyAssignment Entity</description> - <permission-service service-name="workEffortGenericPermission" main-action="UPDATE"/> - <auto-attributes mode="IN" include="pk" optional="false"/> - <auto-attributes mode="IN" include="nonpk" optional="true"> - <exclude field-name="statusDateTime"/> - </auto-attributes> - <attribute name="oldRoleTypeId" type="String" mode="IN"/> + <service name="updateTaskAssigment" default-entity-name="WorkEffortPartyAssignment" engine="simple" + location="org/ofbiz/project/ProjectServices.xml" invoke="updateTaskAssigment"> + <description>Update a WorkEffortPartyAssignment Entity, including set enddate and create new</description> + <permission-service service-name="projectMgrPermission" main-action="UPDATE" /> + <attribute name="workEffortId" type="String" mode="INOUT"/> + <attribute name="newPartyId" type="String" mode="IN" optional="true"/> + <attribute name="partyId" type="String" mode="IN"/> + <attribute name="newRoleTypeId" type="String" mode="IN" optional="true"/> + <attribute name="roleTypeId" type="String" mode="IN"/> + <attribute name="statusId" type="String" mode="IN" optional="true"/> + <attribute name="fromDate" type="Timestamp" mode="IN" optional="true"/> + </service> + + <service name="addTaskAssigment" default-entity-name="WorkEffortPartyAssignment" engine="simple" + location="org/ofbiz/project/ProjectServices.xml" invoke="addTaskAssigment"> + <description>Add a WorkEffortPartyAssignment</description> + <permission-service service-name="projectMgrPermission" main-action="UPDATE" /> + <attribute name="workEffortId" type="String" mode="IN"/> + <attribute name="partyId" type="String" mode="IN"/> + <attribute name="roleTypeId" type="String" mode="IN"/> </service> </services> Modified: ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/actions/EditWeekTimesheet.bsh URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/actions/EditWeekTimesheet.bsh?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/actions/EditWeekTimesheet.bsh (original) +++ ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/actions/EditWeekTimesheet.bsh Mon Dec 31 18:45:50 2007 @@ -53,15 +53,19 @@ if (!UtilValidate.isEmpty(timesheets)) { timesheet = timesheets.get(0); } else { - if (security.hasPermission("WORKEFFORTMGR_CREATE", session)) { + if (security.hasPermission("WORKEFFORTMGR_CREATE", session) || security.hasPermission("WORKEFFORTMGR_ADMIN", session)) { result = dispatcher.runSync("createTimesheetForThisWeek", UtilMisc.toMap("userLogin", userLogin, "partyId", partyId)); + } else { + request.setAttribute("errorMessageList", UtilMisc.toList("Unable to create timesheet, permission error")); } if (result != void && result.get("timesheetId") != null) { timesheet = delegator.findByPrimaryKey("Timesheet", UtilMisc.toMap("timesheetId", result.get("timesheetId"))); } } } +// get the user names +context.put("partyNameView", delegator.findByPrimaryKey("PartyNameView", UtilMisc.toMap("partyId", partyId))); if (timesheet == null) return; @@ -189,8 +193,6 @@ } context.put("timesheets", timesheets); -// get the user names -context.put("partyNameView", delegator.findByPrimaryKey("PartyNameView", UtilMisc.toMap("partyId", partyId))); Modified: ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/controller.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/controller.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/controller.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/controller.xml Mon Dec 31 18:45:50 2007 @@ -158,27 +158,21 @@ <response name="success" type="view" value="MyTasks"/> <response name="error" type="view" value="MyTasks"/> </request-map> - <request-map uri="addMyTask"> - <security https="true" auth="true"/> - <event type="service" invoke="assignPartyToWorkEffort"/> - <response name="success" type="view" value="MyTasks"/> - <response name="error" type="view" value="MyTasks"/> - </request-map> + <request-map uri="updateTaskAssigment"> + <security https="true" auth="true"/> + <event type="service" invoke="updateTaskAssigment"/> + <response name="success" type="view" value="MyTasks"/> + <response name="error" type="view" value="MyTasks"/> + </request-map> + <request-map uri="addTaskAssigment"> + <security https="true" auth="true"/> + <event type="service" invoke="addTaskAssigment"/> + <response name="success" type="view" value="MyTasks"/> + <response name="error" type="view" value="MyTasks"/> + </request-map> <request-map uri="updateTaskPartyAssign"> <security https="true" auth="true"/> - <event type="service" invoke="updatePartyToWorkEffortAssignment"/> - <response name="success" type="view" value="EditTaskPartyAssigns"/> - <response name="error" type="view" value="EditTaskPartyAssigns"/> - </request-map> - <request-map uri="updateMyTasks"> - <security https="true" auth="true"/> - <event type="service" invoke="updateMyTaskAssigment"/> - <response name="success" type="view" value="MyTasks"/> - <response name="error" type="view" value="MyTasks"/> - </request-map> - <request-map uri="deleteTaskPartyAssign"> - <security https="true" auth="true"/> - <event type="service" invoke="deletePartyToWorkEffortAssignment"/> + <event type="service" invoke="updateTaskAssigment"/> <response name="success" type="view" value="EditTaskPartyAssigns"/> <response name="error" type="view" value="EditTaskPartyAssigns"/> </request-map> @@ -190,7 +184,7 @@ </request-map> <request-map uri="createMyTask"> <security https="true" auth="true"/> - <event type="service" invoke="createWorkEffortAndPartyAssign"/> + <event type="service" invoke="createProjectTask"/> <response name="success" type="view" value="MyTasks"/> <response name="error" type="view" value="MyTasks"/> </request-map> Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml Mon Dec 31 18:45:50 2007 @@ -139,7 +139,7 @@ <container style="screenlet"> <container style="screenlet-title-bar"><label style="boxhead">${uiLabelMap.ProjectMgrAssignATaskToMe}</label></container> <container style="screenlet-body"> - <include-form name="AddMyTask" location="component://projectmgr/widget/forms/TaskForms.xml"/> + <include-form name="assignTaskToMe" location="component://projectmgr/widget/forms/TaskForms.xml"/> </container> </container> </container> Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml?rev=607794&r1=607793&r2=607794&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml Mon Dec 31 18:45:50 2007 @@ -18,8 +18,8 @@ under the License. --> -<forms xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - > +<forms xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-form.xsd"> <form name="EditTask" type="single" target="updateTask" default-map-name="task"> <actions> @@ -29,10 +29,10 @@ <set field="statusId" from-field="result.taskInfo.currentStatusId"/> </actions> <alt-target use-when="myTask!=null" target="createMyTask"/> - <alt-target use-when="task==null" target="createTask"/> + <alt-target use-when="task==null" target="createTask"/> + <field name="statusId"><hidden value="PAS_ASSIGNED"/></field> <field use-when="myTask!=null" name="partyId"><hidden value="${userLogin.partyId}"/></field> <field name="projectId"><hidden value="${parameters.projectId}"/></field> - <field name="DONE_PAGE"><hidden value="${donePage}"/></field> <field name="workEffortTypeId"><hidden value="TASK"/></field> <field use-when="task!=null" name="workEffortId" title="${uiLabelMap.ProjectMgrWorkEffortId}" tooltip="${uiLabelMap.CommonNotModifRecreat}"><display/></field> <field use-when="task==null" entry-name="dummy" name="workEffortName" title="${uiLabelMap.ProjectMgrTaskName}*" tooltip="${uiLabelMap.CommonRequired}"><text/></field> @@ -99,7 +99,7 @@ <form name="AddProjectTask" type="single" target="createProjectTaskOrPhase"> <field name="projectId"><hidden value="${parameters.projectId}"/></field> <field name="workEffortTypeId"><hidden value="TASK"/></field> - <field name="currentStatusId"><hidden value="PTS_CREATED"/></field> + <field name="currentStatusId"><hidden value="PTS_CREATED"/></field> <field name="taskName" parameter-name="workEffortName" title="${uiLabelMap.ProjectMgrTaskName}*" tooltip="${uiLabelMap.CommonRequired}"><text/></field> <field name="taskDescription" parameter-name="description" title="${uiLabelMap.CommonDescription}"><text/></field> <field name="phaseName" parameter-name="workEffortParentId" title="${uiLabelMap.ProjectMgrTaskPhase}"> @@ -203,7 +203,7 @@ <field name="projectName" title="${uiLabelMap.ProjectMgrProjectName}" widget-style="buttontext"> <hyperlink also-hidden="false" description="${projectName}" target="projectView?projectId=${projectId}"/> </field> - <field name="currentStatusId"><display-entity entity-name="StatusItem" key-field-name="statusId"></display-entity>/></field> + <field name="currentStatusId"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field> <field name="priority"><display/></field> <field name="estimatedStartDate" title="${uiLabelMap.WorkEffortEstimatedStartDate}"><display type="date"/></field> <field name="estimatedCompletionDate" title="${uiLabelMap.WorkEffortEstimatedCompletionDate}" red-when="before-now"><display type="date"/></field> @@ -212,8 +212,8 @@ <field name="plannedHours" title="${uiLabelMap.ProjectMgrPlannedHours}"><display/></field> <field name="actualHours" title="${uiLabelMap.ProjectMgrActualHours}"><display/></field> </form> - <form name="MyTasks" type="list" list-name="tasks" paginate-target="MyTasks" target="updateMyTasks"> - <row-actions> + <form name="MyTasks" type="list" list-name="tasks" paginate-target="MyTasks" target="updateTaskAssigment"> + <row-actions> <service service-name="getProjectTask" result-map-name="result"> <field-map field-name="taskId" env-name="workEffortId"/> <field-map field-name="hoursPartyId" env-name="userLogin.partyId"/> @@ -224,21 +224,32 @@ <set field="projectId" from-field="result.projectId"/> <set field="projectName" from-field="result.projectName"/> <set field="currentStatusId" from-field="task.currentStatusId"/> + <service service-name="getProjectIdAndName" result-map-name="resultProject"> + <field-map field-name="taskId" env-name="workEffortId"/> + </service> + <set field="projectId" from-field="resultProject.projectId"/> + <set field="projectName" from-field="resultProject.projectName"/> + <set field="phaseId" from-field="resultProject.phaseId"/> + <set field="phaseName" from-field="resultProject.phaseName"/> </row-actions> + <field name="fromDate"><hidden/></field> + <field name="oldRoleTypeId" parameter-name="roleTypeId"><hidden value="${roleTypeId}"/></field> + <field name="oldPartyId" parameter-name="partyId"><hidden value="${partyId}"/></field> <field name="workEffortId" title="${uiLabelMap.ProjectMgrTaskName}" widget-style="buttontext"> - <hyperlink also-hidden="false" description="${workEffortName} [${workEffortId}]" target="taskView?workEffortId=${workEffortId}"/> + <hyperlink also-hidden="false" description="${workEffortName}" target="taskView?workEffortId=${workEffortId}"/> </field> - <field name="projectName" title="${uiLabelMap.CommonStatus}"><display/></field> + <field name="phaseName" title="${uiLabelMap.ProjectMgrPhaseName}"><hyperlink target="FindPhase?projectId=${projectId}" description="${phaseName}"/></field> + <field name="projectName" title="${uiLabelMap.ProjectMgrProjectName}"><hyperlink target="projectView?projectId=${projectId}" description="${projectName}"/></field> <field name="currentStatusId" ><display-entity entity-name="StatusItem" key-field-name="statusId"/></field> <field name="priority"><display/></field> <field name="estimatedStartDate" title="${uiLabelMap.WorkEffortEstimatedStartDate}"><display type="date"/></field> <field name="estimatedCompletionDate" title="${uiLabelMap.WorkEffortEstimatedCompletionDate}" red-when="before-now"><display type="date"/></field> <field name="actualStartDate" title="${uiLabelMap.WorkEffortActualStartDate}"><display type="date"/></field> <field name="actualCompletionDate" title="${uiLabelMap.WorkEffortActualCompletionDate}" red-when="before-now"><display type="date"/></field> - <field name="plannedHours"><display/></field> - <field name="actualHours"><display/></field> - <field name="oldRoleTypeId"><hidden value="${roleTypeId}"/></field> - <field name="roleTypeId" title="${uiLabelMap.PartyRole}"> + <field name="plannedHours" title="${uiLabelMap.ProjectMgrPlannedHours}"><display/></field> + <field name="actualHours" title="${uiLabelMap.ProjectMgrActualHours}"><display/></field> + <field name="statusId" title="${uiLabelMap.CommonStatus}"><display-entity entity-name="StatusItem"/></field> + <field name="roleTypeId" parameter-name="newRoleTypeId" title="${uiLabelMap.PartyRole}"> <drop-down> <entity-options entity-name="RoleType" description="${description}"> <entity-constraint name="parentTypeId" value="PROJECT_TEAM"/> @@ -246,28 +257,20 @@ </entity-options> </drop-down> </field> - <field name="dummy" parameter-name="workEffortId"><hidden value="${workEffortId}"/></field> - <field name="fromDate"><hidden/></field> - <field name="statusId" title="${uiLabelMap.CommonStatus}"> - <drop-down> - <entity-options entity-name="StatusItem" description="${description}"> - <entity-constraint name="statusTypeId" value="PROJECT_ASSGN_STATUS"/> - </entity-options> - </drop-down> - </field> - <field name="partyId"> + <field name="partyId" parameter-name="newPartyId"> <drop-down> <entity-options entity-name="PartyDetailAndWorkEffortAssign" description="${firstName} ${middleName} ${lastName}"> <entity-constraint name="workEffortId" env-name="projectId"/> - <entity-constraint name="workEffortTypeId" value="PROJECT"/> + <entity-constraint name="workEffortTypeId" value="PROJECT"/> </entity-options> </drop-down> </field> - <field name="updateButton"><submit/></field> + <field name="updateButton"><submit/></field> + <field name="remove" title="${uiLabelMap.CommonRemove}"><hyperlink target="updateTaskAssigment?workEffortId=${workEffortId}&partyId=${partyId}&roleTypeId=${roleTypeId}&fromDate=${fromDate}&statusId=PAS_ENDED" description="${uiLabelMap.CommonRemove}"/></field> + <field name="toComplete" title="${uiLabelMap.CommonStatustoComplete}"><hyperlink target="updateTaskAssigment?workEffortId=${workEffortId}&partyId=${partyId}&roleTypeId=${roleTypeId}&fromDate=${fromDate}&statusId=PAS_COMPLETED" description="${uiLabelMap.CommonStatustoComplete}"/></field> </form> - <form name="AddMyTask" type="single" target="addMyTask"> + <form name="assignTaskToMe" type="single" target="addTaskAssigment"> <field name="partyId"><hidden value="${userLogin.partyId}"/></field> - <field name="statusId"><hidden value="PAS_ASSIGNED"/></field> <field name="workEffortId" title="${uiLabelMap.ProjectMgrTaskName}"> <drop-down> <entity-options entity-name="ProjectPartyAndPhaseAndTask" description="${workEffortName} (${phaseName}-${projectName})"> |
Free forum by Nabble | Edit this page |