Page Renderer prototype - various enhancements and refactoring to support modified avm structure, webscript request attributes concept.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6854 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2007-09-21 13:48:56 +00:00
parent ef2c905758
commit 3df0a89e60
6 changed files with 232 additions and 76 deletions

View File

@@ -104,6 +104,13 @@ public class DeclarativeWebScript extends AbstractWebScript
model.put("status", status);
model.put("cache", cache);
// extract any request attributes and add them to the model - this is useful for requests
// that wish to pass further arbituary data into a webscript model
for (String name : req.getAttributeNames())
{
model.put(name, req.getAttribute(name));
}
// execute script if it exists
if (executeScript != null)
{
@@ -119,7 +126,7 @@ public class DeclarativeWebScript extends AbstractWebScript
}
// create model for template rendering
Map<String, Object> templateModel = createTemplateModel(req, res, model);
Map<String, Object> templateModel = createTemplateModel(req, res, model);
// is a redirect to a status specific template required?
if (status.getRedirect())