svn commit: r577115 - in /ofbiz/trunk/applications/workeffort: config/ entitydef/ script/org/ofbiz/workeffort/workeffort/ servicedef/ webapp/workeffort/WEB-INF/ widget/

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

svn commit: r577115 - in /ofbiz/trunk/applications/workeffort: config/ entitydef/ script/org/ofbiz/workeffort/workeffort/ servicedef/ webapp/workeffort/WEB-INF/ widget/

apatel-2
Author: apatel
Date: Tue Sep 18 16:57:21 2007
New Revision: 577115

URL: http://svn.apache.org/viewvc?rev=577115&view=rev
Log:
added field to workeffortnote,similar to ordernote, so user can make a note Public or Private.

Modified:
    ofbiz/trunk/applications/workeffort/config/WorkEffortUiLabels.properties
    ofbiz/trunk/applications/workeffort/entitydef/entitymodel.xml
    ofbiz/trunk/applications/workeffort/entitydef/entitymodel_view.xml
    ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/workeffort/WorkEffortSimpleServices.xml
    ofbiz/trunk/applications/workeffort/servicedef/services.xml
    ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/controller.xml
    ofbiz/trunk/applications/workeffort/widget/WorkEffortForms.xml

Modified: ofbiz/trunk/applications/workeffort/config/WorkEffortUiLabels.properties
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/config/WorkEffortUiLabels.properties?rev=577115&r1=577114&r2=577115&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/config/WorkEffortUiLabels.properties (original)
+++ ofbiz/trunk/applications/workeffort/config/WorkEffortUiLabels.properties Tue Sep 18 16:57:21 2007
@@ -146,7 +146,7 @@
 TimesheetTimeEntries=Time Entries
 TimesheetTimeEntry=Time Entry
 TimesheetQuickTimeEntry=Quick Time Entry
-
+TimesheetTimsheetEdit=Edit Timesheet
 WorkEffortAcceptAssignment=Accept Assignment
 WorkEffortActivityDetail=Activity Detail
 WorkEffortActivityName=Activity Name
@@ -222,6 +222,7 @@
 WorkEffortGeneral=General
 WorkEffortIncludeAllSubWorkEfforts=Include all Sub-WorkEfforts
 WorkEffortInformation=Information
+WorKEffortInternalNote=Internal Note
 WorkEffortItem=Item
 WorkEffortJobList=Submitted Jobs
 WorkEffortKeyword=Keyword
@@ -353,7 +354,7 @@
 WorkEffortWorkflowActivitiesUserGroup=Workflow activities assigned to User Group
 WorkEffortWorkflowActivitiesUserRole=Workflow activities assigned to User Role
 
-WorkEffortNotes = Notes
+
 
 WorkEffortCreatePermissionError=Security Error: to run this operation you must have the WORKEFFORTMGR_CREATE or WORKEFFORTMGR_ADMIN permission
 WorkEffortUpdatePermissionError=Security Error: to run this operation you must have the WORKEFFORTMGR_UPDATE or WORKEFFORTMGR_ADMIN permission
@@ -448,4 +449,5 @@
 FormFieldTitle_finishDateTime=Finish Date Time
 FormFieldTitle_cancelDateTime=Cancel Date Time
 PriorityFormatNotCorrect=Priority format is incorrect
+
 

Modified: ofbiz/trunk/applications/workeffort/entitydef/entitymodel.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/entitydef/entitymodel.xml?rev=577115&r1=577114&r2=577115&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/entitydef/entitymodel.xml (original)
+++ ofbiz/trunk/applications/workeffort/entitydef/entitymodel.xml Tue Sep 18 16:57:21 2007
@@ -644,6 +644,7 @@
             title="Work Effort Note Entity">
       <field name="workEffortId" type="id-ne"></field>
       <field name="noteId" type="id-ne"></field>
+      <field name="internalNote" type="indicator"></field>
       <prim-key field="workEffortId"/>
       <prim-key field="noteId"/>
       <relation type="one" fk-name="WKEFF_NTE_WEFF" rel-entity-name="WorkEffort">

Modified: ofbiz/trunk/applications/workeffort/entitydef/entitymodel_view.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/entitydef/entitymodel_view.xml?rev=577115&r1=577114&r2=577115&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/entitydef/entitymodel_view.xml (original)
+++ ofbiz/trunk/applications/workeffort/entitydef/entitymodel_view.xml Tue Sep 18 16:57:21 2007
@@ -231,6 +231,7 @@
       <member-entity entity-alias="WEN" entity-name="WorkEffortNote"/>
       <member-entity entity-alias="ND" entity-name="NoteData"/>
       <alias entity-alias="WEN" name="workEffortId"/>
+      <alias entity-alias="WEN" name="internalNote"/>
       <alias entity-alias="WEN" name="noteId"/>
       <alias entity-alias="ND" name="noteName"/>
       <alias entity-alias="ND" name="noteInfo"/>

Modified: ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/workeffort/WorkEffortSimpleServices.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/workeffort/WorkEffortSimpleServices.xml?rev=577115&r1=577114&r2=577115&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/workeffort/WorkEffortSimpleServices.xml (original)
+++ ofbiz/trunk/applications/workeffort/script/org/ofbiz/workeffort/workeffort/WorkEffortSimpleServices.xml Tue Sep 18 16:57:21 2007
@@ -529,9 +529,14 @@
         <make-value value-name="newWorkEffortNote" entity-name="WorkEffortNote"/>
         <set from-field="newEntity.noteId" field="newWorkEffortNote.noteId"/>
         <set from-field="parameters.workEffortId" field="newWorkEffortNote.workEffortId"/>
+        <set from-field="parameters.internalNote" field="newWorkEffortNote.internalNote"/>
         <create-value value-name="newWorkEffortNote"/>
     </simple-method>
-    
+    <simple-method method-name="updateWorkEffortNote" short-description="Update Work Effort Note">
+        <entity-one entity-name="WorkEffortNote" value-name="lookedUpValue"/>
+        <set-nonpk-fields value-name="lookedUpValue" map-name="parameters"/>
+        <store-value value-name="lookedUpValue"/>  
+    </simple-method>    
     <simple-method method-name="createWorkEffortAndAssoc" short-description="Create a WorkEffort and association">
         <if-empty field-name="parameters.fromDate">
             <now-timestamp-to-env env-name="parameters.fromDate"/>

Modified: ofbiz/trunk/applications/workeffort/servicedef/services.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/servicedef/services.xml?rev=577115&r1=577114&r2=577115&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/servicedef/services.xml (original)
+++ ofbiz/trunk/applications/workeffort/servicedef/services.xml Tue Sep 18 16:57:21 2007
@@ -130,9 +130,16 @@
         <attribute name="noteInfo" type="String" mode="IN" optional="false"/>
         <attribute name="noteParty" type="String" mode="IN" optional="true"/>
         <attribute name="noteName" type="String" mode="IN" optional="true"/>
+        <attribute name="internalNote" type="String" mode="IN" optional="true"/>
         <attribute name="noteId" type="String" mode="OUT" optional="false"/>
     </service>
-    
+    <service name="updateWorkEffortNote" engine="simple"
+            location="org/ofbiz/workeffort/workeffort/WorkEffortSimpleServices.xml" invoke="updateWorkEffortNote" auth="true">
+        <description>Update a WorkEffort Note</description>
+        <attribute name="workEffortId" type="String" mode="IN" optional="false"/>
+        <attribute name="noteId" type="String" mode="IN" optional="false"/>
+        <attribute name="internalNote" type="String" mode="IN" optional="false"/>
+    </service>    
     <!-- Services for finding Assigned WorkEfforts -->
     <service name="getWorkEffortAssignedEventsForRole" engine="java"
             location="org.ofbiz.workeffort.workeffort.WorkEffortServices" invoke="getWorkEffortAssignedEventsForRole">

Modified: ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/controller.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/controller.xml?rev=577115&r1=577114&r2=577115&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/controller.xml (original)
+++ ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/controller.xml Tue Sep 18 16:57:21 2007
@@ -463,7 +463,13 @@
         <response name="success" type="view" value="EditWorkEffortNotes"/>
         <response name="error" type="view" value="EditWorkEffortNotes"/>
     </request-map>
-
+    <request-map uri="updateWorkEffortNote">
+        <security https="true" auth="true"/>
+        <event type="service" invoke="updateWorkEffortNote"/>
+        <response name="success" type="view" value="EditWorkEffortNotes"/>
+        <response name="error" type="view" value="EditWorkEffortNotes"/>
+    </request-map>
+
     <!-- WorkEffort Content Requests -->
     <request-map uri="EditWorkEffortContents">
         <security https="true" auth="true"/>

Modified: ofbiz/trunk/applications/workeffort/widget/WorkEffortForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/widget/WorkEffortForms.xml?rev=577115&r1=577114&r2=577115&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/widget/WorkEffortForms.xml (original)
+++ ofbiz/trunk/applications/workeffort/widget/WorkEffortForms.xml Tue Sep 18 16:57:21 2007
@@ -778,13 +778,31 @@
         </field>
         <field name="noteInfo" title="${uiLabelMap.CommonNote}" widget-style="tabletext"><display/></field>
         <field name="noteParty" title="${uiLabelMap.CommonBy}" widget-style="tabletext"><display description="${bsh:org.ofbiz.party.party.PartyHelper.getPartyName(delegator, noteParty, true)} at ${noteDateTime}"/></field>
+
+        <field name="deleteLink" title="${uiLabelMap.CommonEmptyHeader}" widget-style="buttontext">
+            <hyperlink target="deleteWorkEffortTimeEntry?workEffortId=${workEffortId}&amp;timeEntryId=${timeEntryId}" description="${uiLabelMap.CommonDelete}" also-hidden="false"/>
+        </field>
+        <field name="isPritable" use-when="internalNote.equals(&quot;N&quot;)"><display description="${uiLabelMap.OrderPrintableNote}"/></field>
+        <field name="isPritable" use-when="internalNote.equals(&quot;Y&quot;)"><display description="${uiLabelMap.OrderNotPrintableNote}"/></field>
+        <field name="Private/Public"  widget-style="buttontext" use-when="internalNote.equals(&quot;N&quot;)">
+            <hyperlink target="updateWorkEffortNote?workEffortId=${workEffortId}&amp;noteId=${noteId}&amp;internalNote=Y" description="${uiLabelMap.OrderNotesPrivate}" />
+        </field>
+        <field name="Private/Public"  widget-style="buttontext" use-when="internalNote.equals(&quot;Y&quot;)">
+            <hyperlink target="updateWorkEffortNote?workEffortId=${workEffortId}&amp;noteId=${noteId}&amp;internalNote=N" description="${uiLabelMap.OrderNotesPublic}"/>
+        </field>
     </form>
     
     <form name="AddWorkEffortNote" type="single" target="createWorkEffortNote" title="">
         <auto-fields-service service-name="createWorkEffortNote"/>
         <field name="noteId"><ignored/><!-- don't pass, will be sequenced --></field>
         <field name="workEffortId"><hidden/></field>
-        <field name="noteInfo" title="${uiLabelMap.OrderNote}"><textarea cols="70" rows="5" /></field>
+        <field name="noteInfo" title="${uiLabelMap.CommonNote}"><textarea cols="70" rows="5" /></field>
+        <field name="internalNote" title="${uiLabelMap.WorKEffortInternalNote}">
+            <drop-down no-current-selected-key="">
+                <option key="Y" description="${uiLabelMap.CommonYes}"/>
+                <option key="N" description="${uiLabelMap.CommonNo}"/>                
+            </drop-down>
+        </field>
         <field name="noteParty"><hidden/></field>
         <field name="noteName"><hidden/></field>
         <field name="submitButton" title="${uiLabelMap.CommonAdd}" widget-style="smallSubmit"><submit button-type="button"/></field>