| | |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpSession; |
| | | |
| | | import com.yeshi.buwan.util.SystemUtil; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestMethod; |
| | |
| | | * @return |
| | | */ |
| | | @RequestMapping(value = "/specialList", method = RequestMethod.POST) |
| | | public void specialList(int pageIndex,String key,int detailsystem,PrintWriter out) { |
| | | public void specialList(int pageIndex, String key, int detailsystem, HttpSession session, PrintWriter out) { |
| | | |
| | | if (pageIndex == 0) |
| | | pageIndex = 1; |
| | | |
| | | List<SpecialAdmin> list = specialService.getSpecialAdmin(key, detailsystem, pageIndex); |
| | | long count = specialService.getSpecialAdminCount(key, detailsystem); |
| | | List<SpecialAdmin> list = specialService.getSpecialAdmin(key, SystemUtil.getAdminSelectedSystemId(session), detailsystem, pageIndex); |
| | | long count = specialService.getSpecialAdminCount(key, SystemUtil.getAdminSelectedSystemId(session), detailsystem); |
| | | PageEntity pe = new PageEntity(); |
| | | pe.setPageIndex(pageIndex); |
| | | pe.setPageSize(Constant.pageCount); |
| | |
| | | out.print(json); |
| | | return ; |
| | | } |
| | | |
| | | @RequestMapping(value = "/updateSpecial", method = RequestMethod.POST) |
| | | public void updateSpecial(String id,String introduction,String name,int orderby,String picture,String show,String showonmain,PrintWriter out) { |
| | | |
| | |
| | | out.print("yes"); |
| | | return ; |
| | | } |
| | | |
| | | @RequestMapping(value = "/addSpecial", method = RequestMethod.POST) |
| | | public void addSpecial(String detailSystems,String introduction,String name,int orderby,String picture,String show,String showonmain,PrintWriter out) { |
| | | public void addSpecial(String detailSystems, String introduction, String name, int orderby, String picture, String show, String showonmain, HttpSession session, PrintWriter out) { |
| | | |
| | | System.out.println("name:"+name); |
| | | System.out.println("detailSystems:"+detailSystems); |
| | |
| | | else |
| | | special.setShowonmain(false); |
| | | |
| | | |
| | | special.setSystem(SystemUtil.getAdminSelectedSystem(session)); |
| | | |
| | | specialService.addSpecial(special); |
| | | |
| | | for (String ds : sysList) { |