public void add(HttpServletRequest req, HttpServletResponse res)
throws ServletModuleException {
try {
- SimpleHash mergeData = new SimpleHash();
+ SimpleHash modelRoot = new SimpleHash();
EntityList theList;
int offset = 0;
+
theList = mainModule.getByWhereClause("", offset);
- mergeData.put("contentlist",HTMLTemplateProcessor.makeSimpleHash(theList));
- mergeData.put("new", "1");
+ modelRoot.put("new", "1");
+ modelRoot.put("contentlist",HTMLTemplateProcessor.makeSimpleHash(theList));
+ //modelRoot.put("contentlist", DatabaseLinksImcs.getInstance().getHashData());
PrintWriter out = res.getWriter();
if (theList == null || theList.getCount() == 0 || theList.getCount()>1){
//HTMLTemplateProcessor.process(getLanguage(req)+"/"+templateObjektString, theList, out);
- HTMLTemplateProcessor.process(getLanguage(req)+"/"+templateObjektString, mergeData, out);
+ HTMLTemplateProcessor.process(getLanguage(req)+"/"+templateObjektString, modelRoot, out);
} else {
//deliver(req, res, theList.elementAt(0), templateObjektString);
- deliver(req, res, mergeData, templateObjektString);
+ deliver(req, res, modelRoot, templateObjektString);
}
} catch(ModuleException e) {