You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by ha...@apache.org on 2008/10/25 09:17:34 UTC
svn commit: r707821 - in /ofbiz/trunk/specialpurpose/projectmgr: entitydef/
script/org/ofbiz/project/ servicedef/ webapp/projectmgr/WEB-INF/actions/
widget/ widget/forms/
Author: hansbak
Date: Sat Oct 25 00:17:34 2008
New Revision: 707821
URL: http://svn.apache.org/viewvc?rev=707821&view=rev
Log:
better implementation of rev: 707540, and made the menus under task more consistant
Removed:
ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/actions/getPartyRoles.groovy
Modified:
ofbiz/trunk/specialpurpose/projectmgr/entitydef/entitymodel.xml
ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml
ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectSimpleEvents.xml
ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml
ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml
ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml
ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml
Modified: ofbiz/trunk/specialpurpose/projectmgr/entitydef/entitymodel.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/entitydef/entitymodel.xml?rev=707821&r1=707820&r2=707821&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/entitydef/entitymodel.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/entitydef/entitymodel.xml Sat Oct 25 00:17:34 2008
@@ -88,6 +88,30 @@
</relation>
</view-entity>
+ <view-entity entity-name="ProjectIdPartyRoleAndTask"
+ package-name="org.ofbiz.specialpurpose.project"
+ title="WorkEffort for use in party -> project -> phase -> task">
+ <member-entity entity-alias="WEPA" entity-name="WorkEffortPartyAssignment"/>
+ <member-entity entity-alias="RT" entity-name="RoleType"/>
+ <member-entity entity-alias="WEPH" entity-name="WorkEffort"/>
+ <member-entity entity-alias="WET" entity-name="WorkEffort"/>
+ <alias entity-alias="WEPH" field="workEffortParentId" name="projectId"/>
+ <alias entity-alias="WEPH" field="workEffortId" name="phaseId"/>
+ <alias entity-alias="WET" field="workEffortId" name="taskId"/>
+ <alias entity-alias="WEPA" name="partyId"/>
+ <alias entity-alias="WEPA" name="roleTypeId"/>
+ <alias entity-alias="RT" name="description"/>
+ <view-link entity-alias="WEPH" rel-entity-alias="WET">
+ <key-map field-name="workEffortId" rel-field-name="workEffortParentId"/>
+ </view-link>
+ <view-link entity-alias="WEPH" rel-entity-alias="WEPA">
+ <key-map field-name="workEffortParentId" rel-field-name="workEffortId"/>
+ </view-link>
+ <view-link entity-alias="WEPA" rel-entity-alias="RT">
+ <key-map field-name="roleTypeId"/>
+ </view-link>
+ </view-entity>
+
<view-entity entity-name="ProjectAndPhaseAndTaskParty"
package-name="org.ofbiz.specialpurpose.project"
title="WorkEffort for use in party -> project -> phase -> task">
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=707821&r1=707820&r2=707821&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml Sat Oct 25 00:17:34 2008
@@ -55,9 +55,6 @@
<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-compare field="parameters.checkPartyRole" value="Y" operator="equals">
- <return/>
- </if-compare>
<if>
<!-- check if a change in partyId Or roletypeId: need to delete and create new -->
<condition>
Modified: ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectSimpleEvents.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectSimpleEvents.xml?rev=707821&r1=707820&r2=707821&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectSimpleEvents.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectSimpleEvents.xml Sat Oct 25 00:17:34 2008
@@ -94,7 +94,7 @@
</else>
</if-not-empty>
</simple-method>
- <simple-method method-name="addProjectMgrResource" short-description="Set the task status to complete, if resources assigned that status will also be set to complete">
+ <simple-method method-name="addProjectMgrResource" short-description="make parties available in the project manager.">
<set-service-fields service-name="createPartyRole" map-name="parameters" to-map-name="roleData"/>
<call-service service-name="createPartyRole" in-map-name="roleData"/>
<set field="roleData.roleTypeId" value="PROJECT_TEAM"/>
Modified: ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml?rev=707821&r1=707820&r2=707821&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/servicedef/services.xml Sat Oct 25 00:17:34 2008
@@ -229,9 +229,8 @@
<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="checkPartyRole" type="String" mode="IN"/>
<attribute name="newRoleTypeId" type="String" mode="IN" optional="true"/>
- <attribute name="roleTypeId" type="String" mode="IN" optional="true"/>
+ <attribute name="roleTypeId" type="String" mode="IN" optional="false"/>
<attribute name="statusId" type="String" mode="IN"/>
<attribute name="fromDate" type="Timestamp" mode="INOUT" optional="true"/>
<attribute name="delegateReasonEnumId" type="String" mode="IN" optional="true"/>
Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml?rev=707821&r1=707820&r2=707821&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml Sat Oct 25 00:17:34 2008
@@ -44,10 +44,10 @@
</actions>
<widgets>
<container style="lefthalf">
+ <include-form name="DependenciesBefore" location="component://projectmgr/widget/forms/TaskForms.xml"/>
<screenlet id="AddDependenciesBeforePanel" title="${uiLabelMap.PageTitleAddDependencyBefore}" collapsible="true">
<include-form name="AddDependencyBefore" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</screenlet>
- <include-form name="DependenciesBefore" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</container>
</widgets>
</section>
@@ -60,10 +60,10 @@
</actions>
<widgets>
<container style="righthalf">
+ <include-form name="DependenciesAfter" location="component://projectmgr/widget/forms/TaskForms.xml"/>
<screenlet id="AddDependenciesAfterPanel" title="${uiLabelMap.PageTitleAddDependencyAfter}" collapsible="true">
<include-form name="AddDependencyAfter" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</screenlet>
- <include-form name="DependenciesAfter" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</container>
</widgets>
</section>
@@ -274,9 +274,7 @@
<widgets>
<decorator-screen name="CommonTaskDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
- <screenlet title="${uiLabelMap.${titleProperty}}">
- <include-form name="ListTaskSkills" location="component://projectmgr/widget/forms/TaskForms.xml"/>
- </screenlet>
+ <include-form name="ListTaskSkills" location="component://projectmgr/widget/forms/TaskForms.xml"/>
<screenlet title="${uiLabelMap.${titleProperty}}">
<include-form name="AddTaskSkill" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</screenlet>
@@ -296,9 +294,7 @@
<widgets>
<decorator-screen name="CommonTaskDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
- <screenlet title="${uiLabelMap.${titleProperty}} ${workEffortId}">
- <include-form name="ListTimeEntries" location="component://projectmgr/widget/forms/TaskForms.xml"/>
- </screenlet>
+ <include-form name="ListTimeEntries" location="component://projectmgr/widget/forms/TaskForms.xml"/>
<screenlet title="${uiLabelMap.ProjectMgrAddTimeEntry}">
<include-form name="createTimeEntry" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</screenlet>
@@ -370,10 +366,10 @@
<widgets>
<decorator-screen name="CommonTaskDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
+ <include-form name="EditWorkEffortPartyAssigns" location="component://projectmgr/widget/forms/TaskForms.xml"/>
<screenlet id="AddTaskPartyAssignsPanel" title="${uiLabelMap.PageTitleAddPartyAssign}" collapsible="true">
<include-form name="AddWorkEffortPartyAssign" location="component://projectmgr/widget/forms/ProjectForms.xml"/>
</screenlet>
- <include-form name="EditWorkEffortPartyAssigns" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -392,10 +388,10 @@
<widgets>
<decorator-screen name="CommonTaskDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
+ <include-form name="ListTaskNotes" location="component://projectmgr/widget/forms/TaskForms.xml"/>
<screenlet id="AddTaskNotesPanel" title="${uiLabelMap.PageTitleAddTaskNotes}" collapsible="true">
<include-form name="AddTaskNote" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</screenlet>
- <include-form name="ListTaskNotes" location="component://projectmgr/widget/forms/TaskForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml?rev=707821&r1=707820&r2=707821&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml Sat Oct 25 00:17:34 2008
@@ -367,12 +367,13 @@
</form>
<form name="AddWorkEffortPartyAssign" target="createWorkEffortPartyAssign" title="" type="single"
header-row-style="header-row" default-table-style="basic-table">
- <alt-target use-when="workEffortId!=projectId" target="createTaskPartyAssign"/><!-- this used for tasks else for project -->
+ <alt-target use-when="workEffortId!=projectId && parameters.get("partyId")==null" target="EditTaskPartyAssigns"/>
+ <alt-target use-when="workEffortId!=projectId && parameters.get("partyId")!=null" target="createTaskPartyAssign"/><!-- this used for tasks else for project -->
<field name="projectId"><hidden/></field>
<field name="statusId"><hidden value="PRTYASGN_ASSIGNED"/></field>
<field name="workEffortId"><hidden value="${workEffortId}"/></field>
- <field use-when="workEffortId==projectId" entry-name="xx" name="partyId"><!-- project level -->
- <drop-down>
+ <field use-when="workEffortId==projectId" entry-name="xx" name="partyId" event="onChange" action="javascript:document.AddWorkEffortPartyAssign.submit();"><!-- project level -->
+ <drop-down allow-empty="true" current="selected">
<entity-options entity-name="PartyRoleAndPartyDetail" description="${firstName} ${middleName} ${lastName} ${groupName}">
<entity-constraint name="roleTypeId" value="PROJECT_TEAM"/>
<entity-order-by field-name="lastName"/>
@@ -381,8 +382,12 @@
</entity-options>
</drop-down>
</field>
- <field name="checkPartyRole"><hidden value="N"/></field>
- <field use-when="workEffortId!=projectId" name="partyId" event="onChange" action="javascript:document.AddWorkEffortPartyAssign.checkPartyRole.value='Y';document.AddWorkEffortPartyAssign.submit();"><!-- task level -->
+ <field use-when="workEffortId!=projectId && parameters.get("partyId")!=null" name="partyId">
+ <display-entity entity-name="PartyNameView" description="${firstName} ${middleName} ${lastName} ${groupName}[${partyId}]">
+ <sub-hyperlink target="EditTaskPartyAssigns?workEffortId=${workEffortId}" description="${uiLabelMap.CommonChange}"/>
+ </display-entity>
+ </field>
+ <field use-when="workEffortId!=projectId && parameters.get("partyId")==null" name="partyId" event="onChange" action="javascript:document.AddWorkEffortPartyAssign.submit();"><!-- task level -->
<drop-down allow-empty="true" current="selected">
<entity-options entity-name="WorkEffortPartyAssignView" filter-by-date="true" description="${firstName} ${middleName} ${lastName} ${groupName}">
<entity-constraint name="workEffortId" env-name="projectId"/>
@@ -400,7 +405,7 @@
</entity-options>
</drop-down>
</field>
- <field entry-name="xx" name="roleTypeId" title="${uiLabelMap.PartyRoleType}">
+ <field use-when="workEffortId!=projectId" entry-name="xx" name="roleTypeId" title="${uiLabelMap.PartyRoleType}">
<drop-down>
<entity-options entity-name="PartyRoleDetailAndPartyDetail" description="${description}">
<entity-constraint name="parentTypeId" value="PROJECT_TEAM"/>
Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml?rev=707821&r1=707820&r2=707821&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml Sat Oct 25 00:17:34 2008
@@ -284,12 +284,14 @@
</form>
<form name="assignTaskToMe" type="single" target="addTaskAssignment"
header-row-style="header-row" default-table-style="basic-table">
- <actions>
- <script location="component://projectmgr/webapp/projectmgr/WEB-INF/actions/getPartyRoles.groovy"/>
- </actions>
+ <alt-target use-when="parameters.get("workEffortId")==null" target="MyTasks"/>
<field name="partyId"><hidden value="${userLogin.partyId}"/></field>
<field name="statusId"><hidden value="PAS_ASSIGNED"/></field>
- <field name="workEffortId" title="${uiLabelMap.ProjectMgrTaskName}" event="onChange" action="javascript:document.assignTaskToMe.checkPartyRole.value='Y';document.assignTaskToMe.submit();">
+ <field name="workEffortId" title="${uiLabelMap.ProjectMgrTaskName}" use-when="parameters.get("workEffortId")!=null">
+ <display-entity entity-name="WorkEffort" description="${workEffortName}[${workEffortId}]">
+ <sub-hyperlink target="MyTasks" description="[${uiLabelMap.CommonChange}]" />
+ </display-entity></field>
+ <field name="workEffortId" title="${uiLabelMap.ProjectMgrTaskName}" event="onChange" action="javascript:document.assignTaskToMe.submit();" use-when="parameters.get("workEffortId")==null">
<drop-down allow-empty="true">
<entity-options entity-name="ProjectPartyAndPhaseAndTask" description="${projectName} -- ${phaseName} -- ${workEffortName}" key-field-name="workEffortId" filter-by-date="true">
<entity-constraint name="partyId" operator="equals" value="${parameters.userLogin.partyId}"/>
@@ -300,10 +302,13 @@
</entity-options>
</drop-down>
</field>
- <field name="checkPartyRole"><hidden value="N"/></field>
<field name="roleTypeId">
<drop-down current="selected" allow-empty="false">
- <list-options list-name="roleList" key-name="KEY" description="${VALUE}"/>
+ <entity-options entity-name="ProjectIdPartyRoleAndTask" description="${description}">
+ <entity-constraint name="partyId" operator="equals" env-name="userLogin.partyId"/>
+ <entity-constraint name="taskId" operator="equals" env-name="parameters.workEffortId"/>
+ <entity-order-by field-name="description"/>
+ </entity-options>
</drop-down>
</field>
<field name="addButton"><submit/></field>
@@ -383,7 +388,7 @@
<field name="addButton"><submit/></field>
</form>
<form name="ListTaskSkills" type="list" target="updateTaskSkillStandard" list-name="workEffortSkillStandards" paginate-target="EditTaskSkills" separate-columns="true"
- odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
+ odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<field name="workEffortId" title="${uiLabelMap.ProjectMgrWorkEffortId}">
<display-entity entity-name="WorkEffort" description="${workEffortName}">
<sub-hyperlink target="EditTask?workEffortId=${workEffortId}" description="${workEffortId}" link-style="buttontext"/>
@@ -408,7 +413,7 @@
<field name="add" title="${uiLabelMap.CommonAdd}"><submit/></field>
</form>
<form name="ListTimeEntries" type="list" list-name="timesheetEntries" target="updateTimeEntry" paginate-target="EditTimeEntries"
- odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
+ odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<entity-condition entity-name="TimeEntry">
<condition-expr field-name="workEffortId" env-name="workEffortId"/>