| | |
| | |
|
| | | import javax.annotation.Resource;
|
| | |
|
| | | import com.yeshi.fanli.entity.accept.AdminAcceptData;
|
| | | import org.springframework.stereotype.Controller;
|
| | | import org.springframework.web.bind.annotation.RequestMapping;
|
| | | import org.springframework.web.bind.annotation.RequestMethod;
|
| | |
| | | private MsgConfigService msgConfigService;
|
| | |
|
| | | @RequestMapping(value = "getZhuShou")
|
| | | public void getZhuShou(String callback, PrintWriter out) {
|
| | | public void getZhuShou(AdminAcceptData acceptData, String callback, PrintWriter out) {
|
| | | // 板栗快省小助手
|
| | | MsgCommonDTO zhuShouMsg = msgConfigService.getZhuShouMsg();
|
| | | MsgCommonDTO zhuShouMsg = msgConfigService.getZhuShouMsg(acceptData.getSystem());
|
| | | JsonUtil.printMode(out, callback, JsonUtil.loadTrueResult(new Gson().toJson(zhuShouMsg)));
|
| | | }
|
| | |
|
| | | @RequestMapping(value = "saveZhuShou", method = RequestMethod.POST)
|
| | | public void saveZhouShou(String callback, MsgCommonDTO dto, PrintWriter out) {
|
| | | public void saveZhouShou(AdminAcceptData acceptData,String callback, MsgCommonDTO dto, PrintWriter out) {
|
| | | if (dto.getJumpDetail() == null) {
|
| | | JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult("请指定跳转方式"));
|
| | | return;
|
| | | }
|
| | | try {
|
| | | msgConfigService.addZhuShouMsg(dto);
|
| | | msgConfigService.addZhuShouMsg(dto,acceptData.getSystem());
|
| | | } catch (ConfigException e) {
|
| | | JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult(e.getMsg()));
|
| | | return;
|
| | |
| | | }
|
| | |
|
| | | @RequestMapping(value = "getGuanXuan", method = RequestMethod.POST)
|
| | | public void getGuanXuan(String callback, PrintWriter out) {
|
| | | MsgCommonDTO guanXuan = msgConfigService.getGuanXuanMsg();
|
| | | public void getGuanXuan(AdminAcceptData acceptData,String callback, PrintWriter out) {
|
| | | MsgCommonDTO guanXuan = msgConfigService.getGuanXuanMsg(acceptData.getSystem());
|
| | | JsonUtil.printMode(out, callback, JsonUtil.loadTrueResult(new Gson().toJson(guanXuan)));
|
| | | }
|
| | |
|
| | | @RequestMapping(value = "saveGuanXuan", method = RequestMethod.POST)
|
| | | public void saveGuanXuan(String callback, MsgCommonDTO dto, PrintWriter out) {
|
| | | public void saveGuanXuan(AdminAcceptData acceptData,String callback, MsgCommonDTO dto, PrintWriter out) {
|
| | | if (dto.getJumpDetail() == null) {
|
| | | JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult("请指定跳转方式"));
|
| | | return;
|
| | | }
|
| | | try {
|
| | | msgConfigService.addGuanXuanMsg(dto);
|
| | | msgConfigService.addGuanXuanMsg(dto,acceptData.getSystem());
|
| | | } catch (ConfigException e) {
|
| | | JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult(e.getMsg()));
|
| | | return;
|