You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by le...@apache.org on 2008/05/17 23:58:38 UTC

svn commit: r657468 - in /ofbiz/trunk/applications/content: webapp/content/website/WebSiteCMSNav.ftl widget/WebSiteScreens.xml

Author: lektran
Date: Sat May 17 14:58:38 2008
New Revision: 657468

URL: http://svn.apache.org/viewvc?rev=657468&view=rev
Log:
Fix for OFBIZ-1652 reported by Jacques Le Roux, Websites -> CMS wasn't working properly.  There were two problems:
There was no uiLabelMap defined in the context for WebSiteCMSContent.ftl
There was no div tag with id="cmscontent" which is where dojo tries to load the content after clicking on an item in the tree

Modified:
    ofbiz/trunk/applications/content/webapp/content/website/WebSiteCMSNav.ftl
    ofbiz/trunk/applications/content/widget/WebSiteScreens.xml

Modified: ofbiz/trunk/applications/content/webapp/content/website/WebSiteCMSNav.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/content/webapp/content/website/WebSiteCMSNav.ftl?rev=657468&r1=657467&r2=657468&view=diff
==============================================================================
--- ofbiz/trunk/applications/content/webapp/content/website/WebSiteCMSNav.ftl (original)
+++ ofbiz/trunk/applications/content/webapp/content/website/WebSiteCMSNav.ftl Sat May 17 14:58:38 2008
@@ -232,7 +232,7 @@
             mimetype: 'text/html',
             content: ctx,
             error: function(type, data, evt) {
-                alert("An error occured loading editor! : " + data);
+                alert("An error occured loading editor! : " + data.message);
             },
             load: function(type, data, evt) {
                 var editPage = dojo.byId('cmscontent');

Modified: ofbiz/trunk/applications/content/widget/WebSiteScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/content/widget/WebSiteScreens.xml?rev=657468&r1=657467&r2=657468&view=diff
==============================================================================
--- ofbiz/trunk/applications/content/widget/WebSiteScreens.xml (original)
+++ ofbiz/trunk/applications/content/widget/WebSiteScreens.xml Sat May 17 14:58:38 2008
@@ -324,6 +324,10 @@
     <screen name="WebSiteCMSContent">
         <section>
             <actions>
+                <property-map resource="ContentUiLabels" map-name="uiLabelMap" global="true"/>
+                <property-map resource="CommonUiLabels" map-name="uiLabelMap" global="true"/>
+                <property-map resource="WorkEffortUiLabels" map-name="uiLabelMap" global="true"/>
+
                 <set field="contentAssocTypeId" from-field="parameters.contentAssocTypeId"/>
                 <set field="dataResourceTypeId" from-field="parameters.dataResourceTypeId"/> 
                 <set field="contentIdFrom" from-field="parameters.contentIdFrom"/>
@@ -364,24 +368,26 @@
                 </entity-and>
             </actions>
             <widgets>
-                <container style="screenlet">
-                    <container style="screenlet-title-bar">
-                        <container style="h3">
-                            <label text="${uiLabelMap.PageTitleWebSiteCMSContent}"/>
+                <container id="cmscontent">
+                    <container style="screenlet">
+                        <container style="screenlet-title-bar">
+                            <container style="h3">
+                                <label text="${uiLabelMap.PageTitleWebSiteCMSContent}"/>
+                            </container>
+                        </container>
+                        <container style="screenlet-body">
+                            <section>
+                                <widgets>    
+                                    <platform-specific>
+                                        <html>
+                                            <html-template location="component://content/webapp/content/website/WebSiteCMSContent.ftl"/>
+                                       </html>
+                                    </platform-specific>
+                                </widgets>
+                            </section>
                         </container>
-                    </container>
-                    <container style="screenlet-body">
-                        <section>
-                            <widgets>    
-                                <platform-specific>
-                                    <html>
-                                        <html-template location="component://content/webapp/content/website/WebSiteCMSContent.ftl"/>
-                                    </html>
-                                </platform-specific>
-                            </widgets>
-                        </section>
-                    </container>
-                </container>
+                   </container>
+               </container>
             </widgets>
         </section>
     </screen>