You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by mb...@apache.org on 2020/02/18 20:31:32 UTC
[ofbiz-framework] branch release17.12 updated: Fixed: CMS add
content not working. (OFBIZ-10833)
This is an automated email from the ASF dual-hosted git repository.
mbrohl pushed a commit to branch release17.12
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git
The following commit(s) were added to refs/heads/release17.12 by this push:
new b318f00 Fixed: CMS add content not working. (OFBIZ-10833)
b318f00 is described below
commit b318f00d057d5f0a388236c47d2418f9113054ab
Author: Michael Brohl <mb...@apache.org>
AuthorDate: Tue Feb 18 21:29:26 2020 +0100
Fixed: CMS add content not working.
(OFBIZ-10833)
This fixes the mission content association and wrong update of the
parent content reported by Ingo Wolfmayr. Thanks Sebastian Berg for
providing the patch.
---
applications/content/servicedef/services_content.xml | 3 +++
applications/content/template/website/WebSiteCMSContent.ftl | 9 +++------
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/applications/content/servicedef/services_content.xml b/applications/content/servicedef/services_content.xml
index 528c585..5b35948 100644
--- a/applications/content/servicedef/services_content.xml
+++ b/applications/content/servicedef/services_content.xml
@@ -28,6 +28,9 @@
<description>Create a Content</description>
<permission-service service-name="genericContentPermission" main-action="CREATE"/>
<auto-attributes entity-name="Content" include="nonpk" mode="IN" optional="true"/>
+ <attribute name="contentAssocTypeId" type="String" mode="INOUT" optional="true"/>
+ <attribute name="contentIdFrom" type="String" mode="INOUT" optional="true"/>
+ <attribute name="contentIdTo" type="String" mode="INOUT" optional="true"/>
<!-- TODO: the following fields are deprecated; but will not be removed until all services and callers are updated -->
<attribute mode="IN" name="targetOperationList" optional="true" type="List"/>
<attribute mode="IN" name="targetOperationString" optional="true" type="String"/>
diff --git a/applications/content/template/website/WebSiteCMSContent.ftl b/applications/content/template/website/WebSiteCMSContent.ftl
index 622413a..d2e1373 100644
--- a/applications/content/template/website/WebSiteCMSContent.ftl
+++ b/applications/content/template/website/WebSiteCMSContent.ftl
@@ -154,14 +154,11 @@
<form name="cmsform" enctype="multipart/form-data" method="post" action="<@o...@ofbizUrl>" style="margin: 0;">
<#if (content?has_content)>
<input type="hidden" name="dataResourceId" value="${(dataResource.dataResourceId)!}"/>
- <input type="hidden" name="contentIdTo" value="${content.contentId}"/>
+ <input type="hidden" name="contentId" value="${content.contentId}"/>
<#list requestParameters.keySet() as paramName>
- <#if paramName == 'contentIdFrom'>
- <input type="hidden" name="contentId" value="${requestParameters.get(paramName)}"/>
- </#if>
- <#if (paramName == 'contentAssocTypeId' || paramName == 'fromDate')>
- <input type="hidden" name="${paramName}" value="${requestParameters.get(paramName)}"/>
+ <#if (paramName == 'contentIdFrom' || paramName == 'contentAssocTypeId' || paramName == 'fromDate')>
+ <input type="hidden" name="${paramName}" value="${requestParameters.get(paramName)}"/>
</#if>
</#list>
<#else>