Author: hansbak
Date: Mon Oct 27 00:54:48 2008 New Revision: 708103 URL: http://svn.apache.org/viewvc?rev=708103&view=rev Log: enable the attachements of files to projects and tasks Modified: ofbiz/trunk/specialpurpose/projectmgr/config/ProjectMgrUiLabels.xml ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectSimpleEvents.xml ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/controller.xml ofbiz/trunk/specialpurpose/projectmgr/widget/Menus.xml ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml Modified: ofbiz/trunk/specialpurpose/projectmgr/config/ProjectMgrUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/config/ProjectMgrUiLabels.xml?rev=708103&r1=708102&r2=708103&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/config/ProjectMgrUiLabels.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/config/ProjectMgrUiLabels.xml Mon Oct 27 00:54:48 2008 @@ -1311,4 +1311,18 @@ <value xml:lang="en">Can not cancel request, the request is already being implemented.</value> <value xml:lang="fr">Impossible d'annuler cette demande, elle est déjà implémentée</value> </property> + <property key="ProjectMgrContentList"> + <value xml:lang="en">Project Content List</value> + </property> + <property key="TaskContentList"> + <value xml:lang="en">Task Content List</value> + </property> + <property key="PageTitleAddProjectContent"> + <value xml:lang="en">Add Project Content</value> + <value xml:lang="th">à¹à¸à¸´à¹à¸¡à¸«à¸±à¸§à¸à¹à¸à¹à¸à¸£à¹à¸à¹à¸</value> + </property> + <property key="PageTitleAddTaskContent"> + <value xml:lang="en">Add Task Content</value> + <value xml:lang="th">à¹à¸à¸´à¹à¸¡à¸«à¸±à¸§à¸à¹à¸à¸à¸²à¸ </value> + </property> </resource> 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=708103&r1=708102&r2=708103&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectSimpleEvents.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/script/org/ofbiz/project/ProjectSimpleEvents.xml Mon Oct 27 00:54:48 2008 @@ -100,4 +100,84 @@ <set field="roleData.roleTypeId" value="PROJECT_TEAM"/> <call-service service-name="createPartyRole" in-map-name="roleData"/> </simple-method> + <!-- create workEffort content --> + <simple-method method-name="createWorkEffortContent" short-description="Creates Party Associated Content" login-required="false"> + <call-class-method class-name="org.ofbiz.content.layout.LayoutWorker" + method-name="uploadImageAndParameters" + ret-field-name="formInput"> + <field field-name="request" type="javax.servlet.http.HttpServletRequest"/> + <string value="dataResourceName"/> + </call-class-method> + + <set-service-fields service-name="createContentFromUploadedFile" map-name="formInput.formInput" to-map-name="inMap"/> + <set field="inMap._uploadedFile_fileName" from-field="formInput.imageFileName"/> + <set field="inMap.uploadedFile" from-field="formInput.imageData"/> + <set field="inMap._uploadedFile_contentType" from-field="formInput.formInput.mimeTypeId"/> + + <call-service service-name="createContentFromUploadedFile" in-map-name="inMap"> + <result-to-field result-name="contentId" field-name="context.contentId"/> + </call-service> + + <if-empty field="formInput.formInput.workEffortId"> + <if-not-empty field="formInput.formInput.projectId"> + <set field="context.workEffortId" from-field="formInput.formInput.projectId"/> + </if-not-empty> + <else> + <set field="context.workEffortId" from-field="formInput.formInput.workEffortId"/> + </else> + </if-empty> + <set field="context.workEffortContentTypeId" from-field="formInput.formInput.workEffortContentTypeId"/> + <now-timestamp-to-env env-name="context.fromDate"/> + <call-map-processor in-map-name="context" out-map-name="workEffortContext"> + <simple-map-processor name="newWorkEffortContent"> + <process field="workEffortContentTypeId"><copy to-field="workEffortContentTypeId"/></process> + <process field="contentId"><copy to-field="contentId"/></process> + <process field="workEffortId"><copy to-field="workEffortId"/></process> + <process field="fromDate"><copy to-field="fromDate"/></process> + </simple-map-processor> + </call-map-processor> + + <call-service service-name="createWorkEffortContent" in-map-name="workEffortContext"> + <result-to-field result-name="contentId" field-name="contentId"/> + </call-service> + <!-- set the partyId in the request --> + <field-to-request field-name="workEffortId" map-name="context" request-name="workEffortId"/> + <field-to-request field-name="projectId" map-name="context" request-name="projectId"/> + <field-to-request field-name="contentId" request-name="contentId"/> + </simple-method> + + <!-- Update workEffort content --> + <simple-method method-name="updateWorkEffortContent" short-description="Update Party Associated Content" login-required="false"> + <call-class-method class-name="org.ofbiz.content.layout.LayoutWorker" + method-name="uploadImageAndParameters" + ret-field-name="formInput"> + <field field-name="request" type="javax.servlet.http.HttpServletRequest"/> + <string value="dataResourceName"/> + </call-class-method> + <entity-one entity-name="Content" value-name="content"> + <field-map field-name="contentId" env-name="formInput.formInput.contentId"/> + </entity-one> + <set-service-fields service-name="updateContentAndUploadedFile" map-name="formInput.formInput" to-map-name="inMap"/> + <set field="inMap._uploadedFile_fileName" from-field="formInput.imageFileName"/> + <set field="inMap.uploadedFile" from-field="formInput.imageData"/> + <set field="inMap._uploadedFile_contentType" from-field="formInput.formInput.mimeTypeId"/> + <set field="inMap.contentId" from-field="formInput.formInput.contentId"/> + <set field="inMap.dataResourceId" from-field="content.dataResourceId"/> + <call-service service-name="updateContentAndUploadedFile" in-map-name="inMap"> + <result-to-field result-name="contentId" field-name="context.contentId"/> + </call-service> + <if-empty field="formInput.formInput.workEffortId"> + <if-not-empty field="formInput.formInput.projectId"> + <set field="workEffortId" from-field="formInput.formInput.projectId"/> + </if-not-empty> + <else> + <set field="workEffortId" from-field="formInput.formInput.workEffortId"/> + </else> + </if-empty> + + <!-- set the partyId in the request --> + <field-to-request field-name="workEffortId" request-name="workEffortId"/> + <field-to-request field-name="projectId" request-name="projectId"/> + <field-to-request field-name="contentId" map-name="context"/> + </simple-method> </simple-methods> 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=708103&r1=708102&r2=708103&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/controller.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/webapp/projectmgr/WEB-INF/controller.xml Mon Oct 27 00:54:48 2008 @@ -799,7 +799,46 @@ <response name="success" type="view" value="EditPartyRates"/> <response name="error" type="view" value="EditPartyRates"/> </request-map> - + <!-- Upload Project Content --> + <request-map uri="EditProjectContents"> + <security auth="true" https="true"/> + <response name="success" type="view" value="EditProjectContents"/> + </request-map> + <request-map uri="createProjectContent"> + <security auth="true" https="true"/> + <event type="simple" path="org/ofbiz/project/ProjectSimpleEvents.xml" invoke="createWorkEffortContent"/> + <response name="success" type="request-redirect" value="EditProjectContents"/> + </request-map> + <request-map uri="updateProjectContent"> + <security auth="true" https="true"/> + <event type="simple" path="org/ofbiz/project/ProjectSimpleEvents.xml" invoke="updateWorkEffortContent"/> + <response name="success" type="view" value="EditProjectContents"/> + </request-map> + <request-map uri="deleteProjectContent"> + <security auth="true" https="true"/> + <event type="service" invoke="deleteWorkEffortContent"/> + <response name="success" type="view" value="EditProjectContents"/> + </request-map> + <!-- Upload Task Content --> + <request-map uri="EditTaskContents"> + <security auth="true" https="true"/> + <response name="success" type="view" value="EditTaskContents"/> + </request-map> + <request-map uri="createTaskContent"> + <security auth="true" https="true"/> + <event type="simple" path="org/ofbiz/project/ProjectSimpleEvents.xml" invoke="createWorkEffortContent"/> + <response name="success" type="request-redirect" value="EditTaskContents"/> + </request-map> + <request-map uri="updateTaskContent"> + <security auth="true" https="true"/> + <event type="simple" path="org/ofbiz/project/ProjectSimpleEvents.xml" invoke="updateWorkEffortContent"/> + <response name="success" type="view" value="EditTaskContents"/> + </request-map> + <request-map uri="deleteTaskContent"> + <security auth="true" https="true"/> + <event type="service" invoke="deleteWorkEffortContent"/> + <response name="success" type="view" value="EditTaskContents"/> + </request-map> <!-- end of request mappings --> <!-- View Mappings --> @@ -873,5 +912,7 @@ <view-map name="RequestList" type="screen" page="component://projectmgr/widget/RequestScreens.xml#RequestList"/> <view-map name="EditRequest" type="screen" page="component://projectmgr/widget/RequestScreens.xml#EditRequest"/> <view-map name="ViewRequest" type="screen" page="component://projectmgr/widget/RequestScreens.xml#ViewRequest"/> - <!-- end of view mappings --> + <view-map name="EditProjectContents" type="screen" page="component://projectmgr/widget/ProjectScreens.xml#EditProjectContents"/> + <view-map name="EditTaskContents" type="screen" page="component://projectmgr/widget/TaskScreens.xml#EditTaskContents"/> + <!-- end of view mappings --> </site-conf> Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/Menus.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/Menus.xml?rev=708103&r1=708102&r2=708103&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/widget/Menus.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/widget/Menus.xml Mon Oct 27 00:54:48 2008 @@ -130,6 +130,17 @@ </condition> <link target="ListWorkEffortPartyAssigns?projectId=${projectId}"/> </menu-item> + <menu-item name="projectContent" title="${uiLabelMap.CommonContent}"> + <condition> + <and> + <if-compare field-name="hasUpdatePermission" operator="equals" value="true"/> + <if-compare field-name="project.currentStatusId" operator="not-equals" value="PTS_COMPLETED"/> + <if-compare field-name="project.currentStatusId" operator="not-equals" value="PTS_ON_HOLD"/> + <if-compare field-name="project.currentStatusId" operator="not-equals" value="PTS_CANCELED"/> + </and> + </condition> + <link target="EditProjectContents?projectId=${projectId}"/> + </menu-item> <menu-item name="notes" title="${uiLabelMap.CommonNotes}"> <condition> <and> @@ -279,6 +290,17 @@ </condition> <link target="EditTimeEntries?workEffortId=${workEffortId}"/> </menu-item> + <menu-item name="taskContent" title="${uiLabelMap.CommonContent}"> + <condition> + <and> + <not><if-empty field-name="workEffort"/></not> + <if-compare field-name="workEffort.currentStatusId" operator="not-equals" value="PTS_COMPLETED"/> + <if-compare field-name="workEffort.currentStatusId" operator="not-equals" value="PTS_ON_HOLD"/> + <if-compare field-name="workEffort.currentStatusId" operator="not-equals" value="PTS_CANCELED"/> + </and> + </condition> + <link target="EditTaskContents?workEffortId=${workEffortId}"/> + </menu-item> <menu-item name="notes" title="${uiLabelMap.CommonNotes}"> <condition> <not><if-empty field-name="workEffort"/></not> Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml?rev=708103&r1=708102&r2=708103&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/widget/ProjectScreens.xml Mon Oct 27 00:54:48 2008 @@ -490,6 +490,7 @@ <include-screen name="SubProjectsInfo"/> <include-screen name="PartiesInfo"/> <include-screen name="NoteInfo"/> + <include-screen name="ListProjectContent"/> </container> </decorator-section> </decorator-screen> @@ -997,4 +998,60 @@ </widgets> </section> </screen> + <screen name="EditProjectContents"> + <section> + <actions> + <property-map resource="ContentUiLabels" map-name="uiLabelMap" global="true"/> + <set field="titleProperty" value="PageTitleListContent"/> + <set field="tabButtonItem" value="projectContent"/> + <set field="headerItem" value="EditProjectContents"/> + <set field="contentId" from-field="parameters.contentId"/> + <entity-one entity-name="Content" value-name="content"/> + <set field="projectId" from-field="parameters.projectId" default-value="${parameters.workEffortId}"/> + <set field="workEffortId" from-field="parameters.projectId" default-value="${parameters.workEffortId}"/> + <entity-and entity-name="WorkEffortAndContentDataResource" list-name="workEffortAndContentDataResources"> + <field-map field-name="workEffortId" env-name="projectId"/> + </entity-and> + </actions> + <widgets> + <decorator-screen name="CommonProjectDecorator" location="${parameters.mainDecoratorLocation}"> + <decorator-section name="body"> + <section> + <condition> + <or> + <if-has-permission permission="PROJECTMGR_ROLE_ADMIN"/> + <if-has-permission permission="PROJECTMGR_ROLE_TASK_CREATE"/> + <if-has-permission permission="PROJECTMGR_ROLE_UPDATE"/> + </or> + </condition> + <widgets> + <screenlet title="${uiLabelMap.ProjectMgrContentList}"> + <container><link target="EditProjectContents?projectId=${projectId}" text="${uiLabelMap.CommonCreateNew}" style="smallSubmit"/></container> + <include-form name="ListContents" location="component://projectmgr/widget/forms/ProjectForms.xml"/> + </screenlet> + <screenlet title="${uiLabelMap.PageTitleAddProjectContent}"> + <include-form name="UploadWorkEffortContent" location="component://projectmgr/widget/forms/ProjectForms.xml"/> + </screenlet> + </widgets> + <fail-widgets> + <include-screen name="ListProjectContent"/> + </fail-widgets> + </section> + </decorator-section> + </decorator-screen> + </widgets> + </section> + </screen> + <screen name="ListProjectContent"> + <section> + <actions> + <set field="parameters.workEffortId" from-field="parameters.projectId"/> + </actions> + <widgets> + <screenlet title="${uiLabelMap.ProjectMgrContentList}"> + <include-form name="ListTaskContent" location="component://projectmgr/widget/forms/TaskForms.xml"/> + </screenlet> + </widgets> + </section> + </screen> </screens> \ No newline at end of file Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml?rev=708103&r1=708102&r2=708103&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/widget/TaskScreens.xml Mon Oct 27 00:54:48 2008 @@ -601,5 +601,48 @@ </decorator-screen> </widgets> </section> - </screen> + </screen> + <screen name="EditTaskContents"> + <section> + <actions> + <property-map resource="ContentUiLabels" map-name="uiLabelMap" global="true"/> + <set field="titleProperty" value="PageTitleListContent"/> + <set field="tabButtonItem" value="taskContent"/> + <set field="headerItem" value="EditTaskContents"/> + <set field="contentId" from-field="parameters.contentId"/> + <entity-one entity-name="Content" value-name="content"/> + <set field="workEffortId" from-field="parameters.workEffortId" default-value="${parameters.workEffortId}"/> + <entity-and entity-name="WorkEffortAndContentDataResource" list-name="workEffortAndContentDataResources"> + <field-map field-name="workEffortId" env-name="workEffortId"/> + </entity-and> + </actions> + <widgets> + <decorator-screen name="CommonTaskDecorator" location="${parameters.mainDecoratorLocation}"> + <decorator-section name="body"> + <section> + <condition> + <or> + <if-has-permission permission="PROJECTMGR_ROLE_ADMIN"/> + <if-has-permission permission="PROJECTMGR_ROLE_TASK_CREATE"/> + <if-has-permission permission="PROJECTMGR_ROLE_UPDATE"/> + </or> + </condition> + <widgets> + <screenlet title="${uiLabelMap.TaskContentList}"> + <container><link target="EditTaskContents?workEffortId=${workEffortId}" text="${uiLabelMap.CommonCreateNew}" style="smallSubmit"/></container> + <include-form name="ListContents" location="component://projectmgr/widget/forms/ProjectForms.xml"/> + </screenlet> + <screenlet title="${uiLabelMap.PageTitleAddTaskContent}"> + <include-form name="UploadWorkEffortContent" location="component://projectmgr/widget/forms/ProjectForms.xml"/> + </screenlet> + </widgets> + <fail-widgets> + <include-screen name="ListTaskContent"/> + </fail-widgets> + </section> + </decorator-section> + </decorator-screen> + </widgets> + </section> + </screen> </screens> \ No newline at end of file Modified: ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml?rev=708103&r1=708102&r2=708103&view=diff ============================================================================== --- ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml (original) +++ ofbiz/trunk/specialpurpose/projectmgr/widget/forms/ProjectForms.xml Mon Oct 27 00:54:48 2008 @@ -562,4 +562,97 @@ </field> <field name="submitButton" title="${uiLabelMap.PageTitleAddProjectTimeToNewInvoice}" widget-style="smallSubmit"><submit button-type="button"/></field> </form> + <form name="ListContents" extends="ListWorkEffortContents" extends-resource="component://workeffort/widget/WorkEffortForms.xml"> + <field name="contentId" use-when="headerItem.equals("EditProjectContents")"> + <display-entity entity-name="Content" key-field-name="contentId" description="${contentName}" also-hidden="true"> + <sub-hyperlink target="EditProjectContents?contentId=${contentId}&projectId=${projectId}&workEffortContentTypeId=${workEffortContentTypeId}" description="${contentId}" link-style="buttontext" target-type="inter-app"/> + </display-entity> + </field> + <field name="contentId" use-when="headerItem.equals("EditTaskContents")"> + <display-entity entity-name="Content" key-field-name="contentId" description="${contentName}" also-hidden="true"> + <sub-hyperlink target="EditTaskContents?contentId=${contentId}&workEffortId=${workEffortId}&workEffortContentTypeId=${workEffortContentTypeId}" description="${contentId}" link-style="buttontext" target-type="inter-app"/> + </display-entity> + </field> + <field name="thruDate"><ignored/></field> + <field name="submitButton"><ignored/></field> + <field name="deleteLink" title="${uiLabelMap.CommonEmptyHeader}" widget-style="buttontext" use-when="headerItem.equals("EditProjectContents")"> + <hyperlink also-hidden="false" description="${uiLabelMap.CommonDelete}" target="deleteProjectContent?contentId=${contentId}&workEffortId=${workEffortId}&workEffortContentTypeId=${workEffortContentTypeId}&fromDate=${fromDate}"/> + </field> + <field name="deleteLink" title="${uiLabelMap.CommonEmptyHeader}" widget-style="buttontext" use-when="headerItem.equals("EditTaskContents")"> + <hyperlink also-hidden="false" description="${uiLabelMap.CommonDelete}" target="deleteTaskContent?contentId=${contentId}&workEffortId=${workEffortId}&workEffortContentTypeId=${workEffortContentTypeId}&fromDate=${fromDate}"/> + </field> + </form> + <form name="UploadWorkEffortContent" type="upload" default-map-name="content" + focus-field-name="contentTypeId" header-row-style="header-row" default-table-style="basic-table" target="updateProjectContent"> + <actions> + <set field="projectId" from-field="parameters.projectId" default-value="${parameters.workEffortId}"/> + <set field="workEffortId" from-field="parameters.workEffortId"/> + <entity-one entity-name="StatusItem" value-name="currentStatus" auto-field-map="false"> + <field-map field-name="statusId" env-name="content.statusId"/> + </entity-one> + <entity-one entity-name="DataResource" value-name="dataResource" auto-field-map="false"> + <field-map field-name="dataResourceId" env-name="content.dataResourceId"/> + </entity-one> + </actions> + + <alt-target use-when="content!=null&&headerItem.equals("EditTaskContents")" target="updateTaskContent"/> + <alt-target use-when="content==null&&headerItem.equals("EditProjectContents")" target="createProjectContent"/> + <alt-target use-when="content==null&&headerItem.equals("EditTaskContents")" target="createTaskContent"/> + + <field name="workEffortId" map-name="parameters"><hidden/></field> + <field name="projectId" map-name="parameters"><hidden/></field> + <field use-when="content!=null" name="contentId" tooltip="${uiLabelMap.CommonNotModifRecreat}"><display/></field> + <field name="workEffortContentTypeId"> + <drop-down allow-empty="false"> + <entity-options description="${description}" entity-name="WorkEffortContentType" key-field-name="workEffortContentTypeId"/> + </drop-down> + </field> + <!-- note sure if these two are necessray, but they are kind of confusing in this context: + <field name="ownerContentId"><lookup target-form-name="LookupContent"/></field> + <field name="dataResourceId"><lookup target-form-name="LookupDataResource"/></field> + --> + <field name="contentTypeId"> + <drop-down allow-empty="false" no-current-selected-key="DOCUMENT"> + <entity-options description="${description}" entity-name="ContentType"/> + </drop-down> + </field> + <field name="statusId" use-when="content==null"> + <drop-down allow-empty="false" no-current-selected-key="CTNT_AVAILABLE"> + <entity-options description="${description}" entity-name="StatusItem" key-field-name="statusId"> + <entity-constraint name="statusTypeId" value="CONTENT_STATUS"/> + <entity-order-by field-name="sequenceId"/> + </entity-options> + </drop-down> + </field> + <field name="statusId" use-when="content!=null"> + <drop-down allow-empty="false" current-description="${currentStatus.description}" no-current-selected-key="CTNT_AVAILABLE"> + <entity-options entity-name="StatusValidChangeToDetail" key-field-name="statusIdTo" description="${transitionName} (${description})"> + <entity-constraint name="statusId" value="${content.statusId}"/> + <entity-order-by field-name="sequenceId"/> + </entity-options> + </drop-down> + </field> + <field name="mimeTypeId" > + <drop-down allow-empty="false"> + <entity-options description="${description}" entity-name="MimeType" key-field-name="mimeTypeId"/> + </drop-down> + </field> + <field name="dataResourceName" title="${uiLabelMap.CommonUpload}"><file/></field> + <field name="dataCategoryId" use-when="dataResource==null"> + <drop-down allow-empty="false"> + <entity-options description="${categoryName}" entity-name="DataCategory" key-field-name="dataCategoryId"/> + </drop-down> + </field> + <field name="dataCategoryId" use-when="dataResource!=null"> + <drop-down allow-empty="false"> + <entity-options description="${categoryName}" entity-name="DataCategory"> + <entity-constraint name="dataCategoryId" value="${dataResource.dataCategoryId}"/> + <entity-order-by field-name="categoryName"/> + </entity-options> + <entity-options description="${categoryName}" entity-name="DataCategory" key-field-name="dataCategoryId"/> + </drop-down> + </field> + <field name="createButton" use-when="content==null"><submit button-type="button"/></field> + <field name="updateButton" use-when="content!=null"><submit button-type="button"/></field> + </form> </forms> \ No newline at end of file |
Free forum by Nabble | Edit this page |