IndexAction.java~555~
资源名称:shihua.rar [点击查看]
上传用户:zghglow
上传日期:2022-08-09
资源大小:27227k
文件大小:31k
源码类别:
WEB源码(ASP,PHP,...)
开发平台:
JavaScript
- package com.chinacannel.xlchemical.struts.Action;
- import org.apache.struts.actions.DispatchAction;
- import org.apache.struts.action.ActionForward;
- import javax.servlet.http.HttpServletRequest;
- import org.apache.struts.action.ActionMapping;
- import javax.servlet.http.HttpServletResponse;
- import org.apache.struts.action.ActionForm;
- import java.util.List;
- import java.util.ArrayList;
- import com.chinacannel.entity.*;
- import com.chinacannel.xlchemical.struts.Vo.ModelVo;
- import com.chinacannel.common.PageInfo;
- import com.chinacannel.xlchemical.service.*;
- import com.chinacannel.xlchemical.struts.ActionForm.AdminActionForm;
- import java.io.IOException;
- public class IndexAction extends DispatchAction {
- IndexService is = new IndexService();
- MenuService ms = new MenuService();
- CategoryService cs = new CategoryService();
- InformationService infs = new InformationService();
- DownLoadService ds = new DownLoadService();
- LeaveWordService ls = new LeaveWordService();
- ProductService ps = new ProductService();
- JobsService js = new JobsService();
- LinkService links = new LinkService();
- public ActionForward OpenIndex(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- List list = null;
- String Language = "CN";
- List LinkList1 = null;
- List LinkList2 = null;
- try {
- if (servletRequest.getParameter("Language") != null) {
- Language = servletRequest.getParameter("Language");
- servletRequest.getSession().setAttribute("Language", Language);
- servletRequest.getSession().setMaxInactiveInterval(60 * 60 * 24);
- } else {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute(
- "Language").toString();
- } else {
- servletRequest.getSession().setAttribute("Language",
- Language);
- }
- }
- is.beginTran();
- list = is.GetIndexMenu(Language);
- LinkList1 = links.GetLinkByType(new Long(1));
- LinkList2 = links.GetLinkByType(new Long(2));
- servletRequest.setAttribute("LinkList1", LinkList1);
- servletRequest.setAttribute("LinkList2", LinkList2);
- is.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- is.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- if (list.size() > 0) {
- servletRequest.setAttribute("menu1", (Menu) list.get(0));
- }
- if (list.size() > 1) {
- servletRequest.setAttribute("menu2", (Menu) list.get(1));
- }
- if (list.size() > 2) {
- servletRequest.setAttribute("menu3", (Menu) list.get(2));
- }
- if (list.size() > 3) {
- servletRequest.setAttribute("menu4", (Menu) list.get(3));
- }
- return actionMapping.findForward("OpenIndex");
- }
- private void LeftMenu(String Language, HttpServletRequest servletRequest) {
- List menuList = null;
- Menu fMenu = null;
- Long fMenuID = new Long(0);
- if (servletRequest.getParameter("fMenuID") != null) {
- fMenuID = new Long(servletRequest.getParameter("fMenuID"));
- }
- fMenu = ms.GetMenuById(fMenuID);
- menuList = ms.GetMenuBySuperior(fMenuID, Language);
- servletRequest.setAttribute("menu", fMenu);
- servletRequest.setAttribute("menuList", menuList);
- }
- public ActionForward ShowMenu(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) throws
- IOException {
- String Language = "CN";
- String key = "";
- String s = "";
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- if (servletRequest.getParameter("key") != null) {
- key = servletRequest.getParameter("key");
- }
- ms.beginTran();
- Menu menu1 = ms.GetMenuByKey(key + Language);
- List menuList = ms.GetMenuBySuperior(menu1.getMen_ID(), Language);
- ms.commit();
- for (int i = 0; i < menuList.size(); i++) {
- Menu menu = (Menu) menuList.get(i);
- if (s == "") {
- s = "{"name":"" + menu.getMen_DefaultName() +
- "","fId":"" + menu.getMen_Superior() +
- "","cId":"" + menu.getMen_ID() + ""}";
- } else {
- s += "," + "{"name":"" + menu.getMen_DefaultName() +
- "","fId":"" + menu.getMen_Superior() +
- "","cId":"" + menu.getMen_ID() + ""}";
- }
- }
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- is.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletResponse.setCharacterEncoding("GBK");
- servletResponse.getWriter().write("[" + s + "]");
- return actionMapping.findForward("ShowMenu");
- }
- public ActionForward OpenIndexMenu(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- String key = "";
- Long cMenuID = new Long(0);
- List menuList = null;
- Menu menu = null;
- Menu fMenu = null;
- String title = "";
- String Language = "CN";
- Long fMenuID = new Long(0);
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- if (servletRequest.getParameter("key") != null) {
- key = servletRequest.getParameter("key");
- }
- if (servletRequest.getParameter("fMenuID") != null) {
- fMenuID = new Long(servletRequest.getParameter("fMenuID"));
- }
- if (servletRequest.getParameter("cMenuID") != null) {
- cMenuID = new Long(servletRequest.getParameter("cMenuID"));
- }
- ms.beginTran();
- if (!key.equals("")) {
- fMenu = ms.GetMenuByKey(key);
- } else {
- fMenu = ms.GetMenuById(fMenuID);
- }
- menuList = ms.GetMenuBySuperior(fMenu.getMen_ID(), Language);
- if (!cMenuID.equals(new Long(0))) {
- menu = ms.GetMenuById(cMenuID);
- } else {
- menu = (Menu) menuList.get(0);
- }
- if (menu != null) {
- if (!menu.getMen_Default().equals(new Long(1))) {
- if (menu.getMen_Type().equals(new Long(0))) {
- Information inf = infs.GetFirstInformationByMenuID(menu.
- getMen_ID());
- if (inf != null) {
- title = inf.getInf_Title();
- servletRequest.setAttribute("inf", inf);
- }
- } else {
- PageInfo pageInfo = infs.getPageInfo("", null, menu,
- menu.getMen_Language(), 0);
- title = menu.getMen_Name();
- servletRequest.setAttribute("type", menu.getMen_Type());
- servletRequest.setAttribute("pageInfo", pageInfo);
- }
- } else {
- String url = menu.getMen_Url() + "&fMenuID=" + fMenu.getMen_ID();
- servletRequest.setAttribute("url", url);
- return actionMapping.findForward("Jumping");
- }
- }
- ms.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- is.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("title", title);
- servletRequest.setAttribute("menu", fMenu);
- servletRequest.setAttribute("menuList", menuList);
- if (menu.getMen_Type().equals(new Long(0))) {
- return actionMapping.findForward("OpenInfo");
- } else if (menu.getMen_Type().equals(new Long(1))) {
- return actionMapping.findForward("OpenList1");
- } else if (menu.getMen_Type().equals(new Long(2))) {
- return actionMapping.findForward("OpenList2");
- } else if (menu.getMen_Type().equals(new Long(3))) {
- return actionMapping.findForward("OpenList3");
- } else {
- return actionMapping.findForward("OpenList4");
- }
- }
- public ActionForward OpenInfo(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- Long type = new Long(0);
- Information inf = null;
- Long fMenuID = new Long(0);
- Menu fMenu = null;
- List menuList = null;
- String Language = "CN";
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- if (servletRequest.getParameter("type") != null) {
- type = new Long(servletRequest.getParameter("type"));
- }
- if (servletRequest.getParameter("fMenuID") != null) {
- fMenuID = new Long(servletRequest.getParameter("fMenuID"));
- }
- infs.beginTran();
- fMenu = ms.GetMenuById(fMenuID);
- menuList = ms.GetMenuBySuperior(fMenuID, Language);
- inf = infs.GetInformationById(new Long(servletRequest.
- getParameter("infID")));
- if (inf.getInf_Click() == null) {
- inf.setInf_Click(new Long(1));
- } else {
- inf.setInf_Click(inf.getInf_Click() + new Long(1));
- }
- infs.UpdateInformation(inf);
- infs.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- is.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("inf", inf);
- servletRequest.setAttribute("menu", fMenu);
- servletRequest.setAttribute("menuList", menuList);
- if (!type.equals(new Long(4))) {
- return actionMapping.findForward("OpenInfo1");
- } else {
- return actionMapping.findForward("OpenInfo2");
- }
- }
- public ActionForward OpenMenu(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- Admin adm = null;
- List fModelList = new ArrayList();
- List cModelList = new ArrayList();
- Role role = null;
- RoleService rs = new RoleService();
- ModelService ms = new ModelService();
- try {
- rs.beginTran();
- adm = (Admin) servletRequest.getSession().getAttribute("admin");
- role = rs.GetRoleById(adm.getRole().getRol_ID());
- String[] fmodels = role.getRol_FModel().split(",");
- String[] cmodels = role.getRol_CModel().split(",");
- for (int i = 0; i < cmodels.length; i++) {
- cModelList.add(cmodels[i]);
- }
- for (int i = 0; i < fmodels.length; i++) {
- ModelVo mv = new ModelVo();
- Model model = ms.GetModelByKey(fmodels[i]);
- mv.setMod_CnName(model.getMod_CnName());
- mv.setMod_EnName(model.getMod_EnName());
- mv.setMod_ID(model.getMod_ID());
- mv.setMod_Key(model.getMod_Key());
- mv.setMod_Order(model.getMod_Order());
- mv.setMod_Superior(model.getMod_Superior());
- mv.setMod_Url(model.getMod_Url());
- mv.setMod_EnUrl(model.getMod_EnUrl());
- List childList = ms.GetChildModel(model.getMod_ID());
- List cList = new ArrayList();
- for (int j = 0; j < childList.size(); j++) {
- Model cmod = (Model) childList.get(j);
- if (cModelList.contains(cmod.getMod_Key())) {
- cList.add(cmod);
- }
- }
- mv.setChildModel(cList);
- fModelList.add(mv);
- }
- rs.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- is.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("modelLength", fModelList.size());
- servletRequest.setAttribute("modelList", fModelList);
- return actionMapping.findForward("OpenMenu");
- }
- //打开后台首页
- public ActionForward OpenBackIndex(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- String language = "CN";
- try {
- if (servletRequest.getParameter("Language") != null) {
- language = servletRequest.getParameter("Language");
- }
- servletRequest.getSession().setAttribute("Language", language);
- servletRequest.getSession().setMaxInactiveInterval(60 * 60 * 24);
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- is.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- return actionMapping.findForward("OpenBackIndex");
- }
- public ActionForward ShowHonnors(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- String Language = "CN";
- List list = null;
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- cs.beginTran();
- LeftMenu(Language, servletRequest);
- list = cs.getCategoryListByKey("QYRY", Language);
- cs.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- cs.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("categoryList", list);
- return actionMapping.findForward("ShowHonnors");
- }
- public ActionForward ShowDownLoad(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- int pageNo = 0;
- PageInfo pageInfo = null;
- String Language = "CN";
- Long type = new Long(0);
- String title = "";
- try {
- pageNo = Integer.parseInt(servletRequest.getParameter("pageNo"));
- } catch (Exception ex1) {}
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- if (servletRequest.getParameter("Type") != null) {
- type = new Long(servletRequest.getParameter("Type"));
- }
- ds.beginTran();
- LeftMenu(Language, servletRequest);
- pageInfo = ds.getPageInfo(type, Language, pageNo);
- if (type.equals(new Long(1))) {
- if (Language.equals("CN")) {
- title = "公司报告";
- } else {
- title = "Company Reports";
- }
- } else if (type.equals(new Long(0))) {
- if (Language.equals("CN")) {
- title = "运营数据";
- } else {
- title = "Operators Data";
- }
- }
- ds.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- cs.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("title", title);
- servletRequest.setAttribute("pageInfo", pageInfo);
- return actionMapping.findForward("ShowDownLoad");
- }
- public ActionForward ShowLeaveWord(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- String Language = "CN";
- int pageNo = 0;
- PageInfo pageInfo = null;
- try {
- pageNo = Integer.parseInt(servletRequest.getParameter("pageNo"));
- } catch (Exception ex1) {}
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- ls.beginTran();
- LeftMenu(Language, servletRequest);
- pageInfo = ls.getPageInfo(Language, "1", pageNo);
- ls.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- ls.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("pageInfo", pageInfo);
- return actionMapping.findForward("ShowLeaveWord");
- }
- public ActionForward ShowContact(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- String Language = "CN";
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- LeftMenu(Language, servletRequest);
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- ls.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- return actionMapping.findForward("ShowContact");
- }
- public ActionForward OpenProduct(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- int pageNo = 0;
- String Language = "CN";
- PageInfo pageInfo = null;
- try {
- pageNo = Integer.parseInt(servletRequest.getParameter("pageNo"));
- } catch (Exception ex1) {}
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- ps.beginTran();
- LeftMenu(Language, servletRequest);
- pageInfo = ps.getPageInfo(Language, pageNo);
- ps.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- ps.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("pageInfo", pageInfo);
- return actionMapping.findForward("OpenProduct");
- }
- public ActionForward OpenJobs(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- int pageNo = 0;
- String Language = "CN";
- PageInfo pageInfo = null;
- try {
- pageNo = Integer.parseInt(servletRequest.getParameter("pageNo"));
- } catch (Exception ex1) {}
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- js.beginTran();
- LeftMenu(Language, servletRequest);
- pageInfo = js.getPageInfo(Language, pageNo);
- js.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- js.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("pageInfo", pageInfo);
- return actionMapping.findForward("OpenJobs");
- }
- public ActionForward ShowInvitesInfo(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- Jobs jobs = null;
- boolean b = false;
- String Language = "CN";
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- js.beginTran();
- LeftMenu(Language, servletRequest);
- jobs = js.GetJobsById(new Long(servletRequest.getParameter("jobID")));
- jobs.setJob_Click(jobs.getJob_Click() + new Long(1));
- b = js.UpdateJobs(jobs);
- js.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- js.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- if (b == false) {
- }
- servletRequest.setAttribute("jobs", jobs);
- return actionMapping.findForward("ShowInvitesInfo");
- }
- public ActionForward ShowLink(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- int pageNo = 0;
- PageInfo pageInfo = null;
- String Language = "CN";
- try {
- pageNo = Integer.parseInt(servletRequest.getParameter("pageNo"));
- } catch (Exception ex1) {}
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- ls.beginTran();
- LeftMenu(Language, servletRequest);
- pageInfo = links.getPageInfo(new Long(1), pageNo);
- ls.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- ls.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("pageInfo", pageInfo);
- return actionMapping.findForward("ShowLink");
- }
- public ActionForward ShowMap(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- String Language = "CN";
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- ms.beginTran();
- LeftMenu(Language, servletRequest);
- MapSubmit("QYXX", servletRequest);
- MapSubmit("QYWH", servletRequest);
- MapSubmit("XWGG", servletRequest);
- MapSubmit("GDTD", servletRequest);
- MapSubmit("SCJY", servletRequest);
- MapSubmit("LLZY", servletRequest);
- ms.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- ls.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- return actionMapping.findForward("ShowMap");
- }
- private void MapSubmit(String ColumnName, HttpServletRequest servletRequest) {
- Menu menu = null;
- List list = null;
- String Language = "CN";
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- menu = ms.GetMenuByKey(ColumnName + Language);
- list = ms.GetMenuBySuperior(menu.getMen_ID(), Language);
- servletRequest.setAttribute(ColumnName + "List", list);
- }
- public ActionForward SearchIndex(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- AdminActionForm aaf = (AdminActionForm) actionForm;
- int pageNo = 0;
- PageInfo pageInfo = null;
- String Language = "CN";
- try {
- pageNo = Integer.parseInt(servletRequest.getParameter("pageNo"));
- } catch (Exception ex1) {}
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- is.beginTran();
- pageInfo = is.getPageInfo(aaf.getCondition(),null, Language, pageNo);
- is.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- ls.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("pageInfo", pageInfo);
- return actionMapping.findForward("SearchIndex");
- }
- public ActionForward SearchInformation(ActionMapping actionMapping,
- ActionForm actionForm,
- HttpServletRequest servletRequest,
- HttpServletResponse servletResponse) {
- AdminActionForm aaf = (AdminActionForm) actionForm;
- int pageNo = 0;
- PageInfo pageInfo = null;
- String Language = "CN";
- Menu cmenu = null;
- Long menuID = new Long(0);
- String key = "";
- Menu fMenu = null;
- List menuList = null;
- Long cMenuID = new Long(0);
- try {
- pageNo = Integer.parseInt(servletRequest.getParameter("pageNo"));
- } catch (Exception ex1) {}
- try {
- if (servletRequest.getSession().getAttribute("Language") != null) {
- Language = servletRequest.getSession().getAttribute("Language").
- toString();
- }
- if (servletRequest.getParameter("menuID") != null) {
- menuID = new Long(servletRequest.getParameter("menuID"));
- }
- if (servletRequest.getParameter("cMenuID") != null) {
- cMenuID = new Long(servletRequest.getParameter("cMenuID"));
- }
- if (servletRequest.getParameter("key") != null) {
- key = servletRequest.getParameter("key");
- }
- is.beginTran();
- if (key.equals("")) {
- fMenu = ms.GetMenuById(menuID);
- } else {
- fMenu = ms.GetMenuByKey(key);
- }
- menuList = ms.GetMenuBySuperior(fMenu.getMen_ID(), Language);
- if (!cMenuID.equals(new Long(0))) {
- cmenu = ms.GetMenuById(cMenuID);
- } else {
- cmenu = (Menu) menuList.get(0);
- }
- pageInfo = is.getPageInfo(aaf.getCondition1(), cmenu, Language,
- pageNo);
- is.commit();
- } catch (Exception ex) {
- log.error(ex.getMessage(), ex);
- try {
- is.rollback();
- } catch (Exception ex2) {
- log.error(ex2.getMessage(), ex2);
- }
- }
- servletRequest.setAttribute("menu", fMenu);
- servletRequest.setAttribute("menuList", menuList);
- servletRequest.setAttribute("pageInfo", pageInfo);
- return actionMapping.findForward("SearchIndex");
- }
- }