EntityList theList;
int offset = 0;
- theList = mainModule.getByWhereClause("to_parent_id=NULL", offset);
+ theList = mainModule.getByWhereClause("to_parent_id=NULL", "title", offset);
modelRoot.put("new", "1");
modelRoot.put("imcsparentlist",HTMLTemplateProcessor.makeSimpleList(theList));
if (theList == null || theList.getCount() == 0 || theList.getCount()>1){
HTMLTemplateProcessor.process(res,getLanguage(req)+"/"+templateObjektString, modelRoot, res.getWriter());
-
} else {
deliver(req, res, modelRoot, templateObjektString);
}
throws ServletModuleException {
try {
- theLog.printDebugInfo("-- links_imcs_list: list");
+ SimpleHash modelRoot = new SimpleHash();
EntityList theParentList;
EntityList theImcsList;
- SimpleHash modelRoot = new SimpleHash();
String offsetParam = req.getParameter("offset");
- String where ="";
+ String where = "";
int offset=0;
- PrintWriter out = res.getWriter();
+ PrintWriter out = res.getWriter();
// hier offsetcode bearbeiten
if (offsetParam != null && !offsetParam.equals("")){
offset = Integer.parseInt(req.getParameter("prevoffset"));
}
}
+
theParentList = mainModule.getByWhereClause("to_parent_id=NULL", offset);
- theImcsList = mainModule.getByWhereClause(null, offset);
+ theImcsList = mainModule.getByWhereClause(null, "title", offset);
modelRoot.put("parentlist",HTMLTemplateProcessor.makeSimpleList(theParentList));
modelRoot.put("imcslist",HTMLTemplateProcessor.makeSimpleList(theImcsList));
String idParam = req.getParameter("id");
String where = "";
- parentList = mainModule.getByWhereClause("to_parent_id=NULL", offset);
+ parentList = mainModule.getByWhereClause("to_parent_id=NULL", "title", offset);
modelRoot.put("imcsparentlist",HTMLTemplateProcessor.makeSimpleList(parentList));
modelRoot.put("entity", HTMLTemplateProcessor.makeSimpleHash(mainModule.getById(idParam)));
-
-
deliver(req, res, modelRoot, templateObjektString);
} catch(ModuleException e) {
}
}
- public void update(HttpServletRequest req, HttpServletResponse res)
- throws ServletModuleException {
- try {
- String idParam = req.getParameter("id");
- HashMap withValues = getIntersectingValues(req, mainModule.getStorageObject());
- String id = mainModule.set(withValues);
- //theLog.printInfo("Showing Entity with id: " + id);
- //edit(req,res);
- String whereParam = req.getParameter("where");
- String orderParam = req.getParameter("order");
- if ((whereParam!=null && !whereParam.equals("")) || (orderParam!=null && !orderParam.equals(""))){
- //theLog.printDebugInfo("update to list");
- list(req,res);
- } else {
- edit(req, res);
- }
- //list(req,res);
- } catch (Exception e) {
- throw new ServletModuleException(e.toString());
- }
- }
-
}