Andrew, Tim, Joe, others involved in the new CMS stuff, After playing with the cmssite stuff I noticed that for decorated content all of the thisContent stuff was broken because it was finally rendered as a DataResource instead of a Content (to avoid the infinite recursion problems). To fix this I changed the content map facade and content worker objects to work together to track a content with a decoratorContentId has already been decorated, this rendering the content and skipping the decorator content, using the isDecorated field. This is in place now and is working. The main change in the decorator template is: > -${decoratedContent.data.render} > +${decoratedContent} Note that this also doesn't have the ".render" because the toString() method now does a render by default. -David Begin forwarded message: > From: [hidden email] > Date: March 10, 2007 2:38:05 AM MST > To: [hidden email] > Subject: svn commit: r516669 - in /ofbiz/trunk: applications/ > content/src/org/ofbiz/content/cms/ applications/content/src/org/ > ofbiz/content/content/ applications/content/src/org/ofbiz/content/ > webapp/ftl/ specialpurpose/cmssite/data/ specialpurpose/cmssite/ > templa... > Reply-To: [hidden email] > > Author: jonesde > Date: Sat Mar 10 01:38:03 2007 > New Revision: 516669 > > URL: http://svn.apache.org/viewvc?view=rev&rev=516669 > Log: > Various cleanups in the cmsssite templates and data; implemented a > change to support rendering the Content instead of the DataResource > when it is decorated, which is necessary in order for the > thisContent object to exist and function, which is necessary for > including sub-content and such; also implemented the content map > facade link element to get a link out of the context that the cms > event puts in it > > Modified: > ofbiz/trunk/applications/content/src/org/ofbiz/content/cms/ > CmsEvents.java > ofbiz/trunk/applications/content/src/org/ofbiz/content/content/ > ContentMapFacade.java > ofbiz/trunk/applications/content/src/org/ofbiz/content/content/ > ContentWorker.java > ofbiz/trunk/applications/content/src/org/ofbiz/content/webapp/ > ftl/TraverseSubContentTransform.java > ofbiz/trunk/specialpurpose/cmssite/data/CmsSiteDemoData.xml > ofbiz/trunk/specialpurpose/cmssite/template/cms/MainDecorator.ftl > ofbiz/trunk/specialpurpose/cmssite/webapp/cmssite/DemoFooter.ftl > ofbiz/trunk/specialpurpose/cmssite/webapp/cmssite/DemoHeader.ftl > ofbiz/trunk/specialpurpose/cmssite/webapp/cmssite/DemoHome.ftl > smime.p7s (3K) Download Attachment |
David, that makes really good sense - thanks for following up on that so quickly! I'm going to download this and check it out first thing in the morning.
Cheers, Tim -- Tim Ruppert HotWax Media o:801.649.6594 f:801.649.6595 On Mar 10, 2007, at 2:45 AM, David E. Jones wrote:
smime.p7s (3K) Download Attachment |
Free forum by Nabble | Edit this page |