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 2007/12/28 01:41:53 UTC

svn commit: r607148 - in /ofbiz/trunk/specialpurpose/projectmgr: script/org/ofbiz/project/ProjectServices.xml webapp/projectmgr/WEB-INF/actions/EditWeekTimesheet.bsh widget/forms/TaskForms.xml

Author: hansbak
Date: Thu Dec 27 16:41:51 2007
New Revision: 607148

URL: http://svn.apache.org/viewvc?rev=607148&view=rev
Log:
corrected error in planned hours timesheet, added total planned hours in task info service, improved task skill standard form

Modified:
    ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml
    ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/actions/EditWeekTimesheet.bsh
    ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml

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=607148&r1=607147&r2=607148&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectServices.xml Thu Dec 27 16:41:51 2007
@@ -819,6 +819,16 @@
                         </if-not-empty>
                     </then>
                 </if>
+                <!-- keep also a general total for the actual hours of all participants -->
+                <if-not-empty field-name="highInfo.actualTotalHours">
+                    <calculate field-name="highInfo.actualTotalHours">
+                        <calcop operator="get" field-name="highInfo.actualTotalHours"/>
+                        <calcop operator="add" field-name="actual.hours"></calcop>
+                    </calculate>
+                    <else>
+                        <set field="highInfo.actualTotalHours" from-field="actual.hours"/>
+                    </else>                            
+                </if-not-empty>
             </if-not-empty>
         </iterate>
     </simple-method>

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=607148&r1=607147&r2=607148&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 Thu Dec 27 16:41:51 2007
@@ -66,13 +66,17 @@
 day0Total = 0.00; day1Total=0.00;day2Total=0.00; day3Total=0.00;day4Total=0.00;day5Total=0.00;day6Total=0.00;
 pHours = 0.00;
 timeEntry = null;
+lastTimeEntry = null;
 while(te.hasNext()) {
+	if (timeEntry!=void) {
+		lastTimeEntry = timeEntry;
+	} 
     timeEntry = te.next();
     
     if (lastWorkEffortId != null && !lastWorkEffortId.equals(timeEntry.getString("workEffortId"))) {
         entry.put("total", taskTotal);
         // get the planned number of hours
-        entryWorkEffort = timeEntry.getRelatedOne("WorkEffort");
+        entryWorkEffort = lastTimeEntry.getRelatedOne("WorkEffort");
         if (entryWorkEffort != null) {
         	plannedHours = entryWorkEffort.getRelated("WorkEffortSkillStandard");
 	        ph = plannedHours.iterator();

Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml?rev=607148&r1=607147&r2=607148&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/widget/forms/TaskForms.xml Thu Dec 27 16:41:51 2007
@@ -357,9 +357,9 @@
         </field>
         <field name="add"><submit/></field>
     </form>
-    <form name="ListTaskSkills" type="list" target="updateTaskSkillStandard" list-name="workEffortSkillStandards" paginate-target="EditTaskSkills">
+    <form name="ListTaskSkills" type="list" target="updateTaskSkillStandard" list-name="workEffortSkillStandards" paginate-target="EditTaskSkills" separate-columns="true">
         <field name="workEffortId" title="${uiLabelMap.ProjectMgrWorkEffortId}">
-            <display-entity entity-name="WorkEffort" description="${workEffortName} ${workEffortId}">
+            <display-entity entity-name="WorkEffort" description="${workEffortName}">
                 <sub-hyperlink target="EditTask?workEffortId=${workEffortId}" description="${workEffortId}" link-style="buttontext"/>
             </display-entity>
         </field>