svn commit: r1750097 - in /ofbiz/trunk/specialpurpose/projectmgr: template/project/summary/NoteInfo.ftl widget/ProjectScreens.xml widget/TaskScreens.xml

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

svn commit: r1750097 - in /ofbiz/trunk/specialpurpose/projectmgr: template/project/summary/NoteInfo.ftl widget/ProjectScreens.xml widget/TaskScreens.xml

ashish-18
Author: ashish
Date: Fri Jun 24 13:47:36 2016
New Revision: 1750097

URL: http://svn.apache.org/viewvc?rev=1750097&view=rev
Log:
Applied patch from jira issue - OFBIZ-7556 - Error occurred when making notes private/public from project screen.
Thanks Deepak Baghel for the contribution.

Modified:
    ofbiz/trunk/specialpurpose/projectmgr/template/project/summary/NoteInfo.ftl
    ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml
    ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml

Modified: ofbiz/trunk/specialpurpose/projectmgr/template/project/summary/NoteInfo.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/template/project/summary/NoteInfo.ftl?rev=1750097&r1=1750096&r2=1750097&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/template/project/summary/NoteInfo.ftl (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/template/project/summary/NoteInfo.ftl Fri Jun 24 13:47:36 2016
@@ -49,17 +49,37 @@ under the License.
                     <#if note.internalNote! == "N">
                         <div>${uiLabelMap.ProjectMgrPrintableNote}</div>
                           <#if project?has_content>
-                            <a href="<@ofbizUrl>updateProjectNote?workEffortId=${project.workEffortId!}&amp;noteId=${note.noteId}&amp;internalNote=Y</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderNotesPrivate}</a>
+                            <form name="updateProjectNoteForPublicNote" method="post" action="<@ofbizUrl>updateProjectNote</@ofbizUrl>">
+                              <input type="hidden" name="workEffortId" value="${project.workEffortId!}" />
+                              <input type="hidden" name="noteId" value="${note.noteId}" />
+                              <input type="hidden" name="internalNote" value="Y" />
+                              <input type="submit" value="${uiLabelMap.OrderNotesPrivate}"/>
+                            </form>
                           <#else>
-                            <a href="<@ofbizUrl>updateTaskNoteSummary?workEffortId=${task.workEffortId!}&amp;noteId=${note.noteId}&amp;internalNote=Y</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderNotesPrivate}</a>
+                            <form name="updateTaskNoteSummaryPublicNote" method="post" action="<@ofbizUrl>updateTaskNoteSummary</@ofbizUrl>">
+                              <input type="hidden" name="workEffortId" value="${task.workEffortId!}" />
+                              <input type="hidden" name="noteId" value="${note.noteId}" />
+                              <input type="hidden" name="internalNote" value="Y" />
+                              <input type="submit" value="${uiLabelMap.OrderNotesPrivate}"/>
+                            </form>
                           </#if>
                     </#if>
                     <#if note.internalNote! == "Y">
                         <div>${uiLabelMap.OrderNotPrintableNote}</div>
                            <#if project?has_content>
-                             <a href="<@ofbizUrl>updateProjectNote?workEffortId=${project.workEffortId!}&amp;noteId=${note.noteId}&amp;internalNote=N</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderNotesPublic}</a>
+                             <form name="updateProjectNoteForPrivateNote" method="post" action="<@ofbizUrl>updateProjectNote</@ofbizUrl>">
+                               <input type="hidden" name="workEffortId" value="${project.workEffortId!}" />
+                               <input type="hidden" name="noteId" value="${note.noteId}" />
+                               <input type="hidden" name="internalNote" value="N" />
+                               <input type="submit" value="${uiLabelMap.OrderNotesPublic}"/>
+                             </form>
                           <#else>
-                            <a href="<@ofbizUrl>updateTaskNoteSummary?workEffortId=${task.workEffortId!}&amp;noteId=${note.noteId}&amp;internalNote=N</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderNotesPublic}</a>
+                            <form name="updateTaskNoteSummaryPrivateNote" method="post" action="<@ofbizUrl>updateTaskNoteSummary</@ofbizUrl>">
+                              <input type="hidden" name="workEffortId" value="${task.workEffortId!}" />
+                              <input type="hidden" name="noteId" value="${note.noteId}" />
+                              <input type="hidden" name="internalNote" value="N" />
+                              <input type="submit" value="${uiLabelMap.OrderNotesPublic}"/>
+                            </form>
                           </#if>
                     </#if>
                   </td>

Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml?rev=1750097&r1=1750096&r2=1750097&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml Fri Jun 24 13:47:36 2016
@@ -562,6 +562,9 @@ under the License.
         <section>
             <actions>
                 <set field="workEffortId" from-field="projectId"/>
+                <entity-one entity-name="WorkEffort" value-field="project">
+                    <field-map field-name="workEffortId" from-field="workEffortId"/>
+                </entity-one>
                 <entity-and entity-name="WorkEffortNoteAndData" list="workEffortNoteandDetails">
                     <field-map field-name="workEffortId" from-field="workEffortId"/>
                     <order-by field-name="-noteDateTime"/>

Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml?rev=1750097&r1=1750096&r2=1750097&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml (original)
+++ ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml Fri Jun 24 13:47:36 2016
@@ -396,6 +396,9 @@ under the License.
     <screen name="NoteInfo">
         <section>
             <actions>
+                <entity-one entity-name="WorkEffort" value-field="task">
+                    <field-map field-name="workEffortId" from-field="workEffortId"/>
+                </entity-one>
                 <entity-and entity-name="WorkEffortNoteAndData" list="workEffortNoteandDetails">
                     <field-map field-name="workEffortId" from-field="workEffortId"/>
                     <order-by field-name="-noteDateTime"/>