提交 | 用户 | 时间
|
71e81e
|
1 |
package cn.stylefeng.guns.modular.kb.badBoard; |
懒 |
2 |
|
|
3 |
import cn.stylefeng.guns.base.pojo.page.LayuiPageInfo; |
|
4 |
import cn.stylefeng.guns.modular.kb.utils.IPUtil; |
|
5 |
import cn.stylefeng.guns.modular.sc.kanbanConf.model.params.KanbanConfParam; |
|
6 |
import cn.stylefeng.guns.modular.sc.kanbanConf.service.KanbanConfService; |
|
7 |
import cn.stylefeng.roses.kernel.model.response.ResponseData; |
|
8 |
import org.springframework.beans.factory.annotation.Autowired; |
|
9 |
import org.springframework.stereotype.Controller; |
|
10 |
import org.springframework.web.bind.annotation.RequestMapping; |
|
11 |
import org.springframework.web.bind.annotation.ResponseBody; |
|
12 |
|
|
13 |
import javax.servlet.http.HttpServletRequest; |
|
14 |
|
|
15 |
@Controller |
|
16 |
@RequestMapping("/badBoard") |
|
17 |
public class badBoardController { |
|
18 |
private String PREFIX = "modular/kb/badBoard"; |
|
19 |
@Autowired |
|
20 |
private KanbanConfService kanbanConfService; |
|
21 |
/** |
|
22 |
* 跳转到主页面 |
|
23 |
* |
|
24 |
* @author cl |
|
25 |
* @Date 2022-10-27 |
|
26 |
*/ |
|
27 |
@RequestMapping("") |
|
28 |
public String index() { |
|
29 |
return PREFIX + "/badBoard.html"; |
|
30 |
} |
|
31 |
|
|
32 |
@RequestMapping("/boardHome") |
|
33 |
public String boardHome() { |
|
34 |
return PREFIX + "/boardHome.html"; |
|
35 |
} |
|
36 |
|
|
37 |
@RequestMapping("/reportRecord") |
|
38 |
public String reportRecord() { |
|
39 |
return PREFIX + "/reportRecord.html"; |
|
40 |
} |
|
41 |
|
|
42 |
/** |
|
43 |
* 新增看板配置页面 |
|
44 |
* |
|
45 |
* @author cl |
|
46 |
* @Date 2022-10-31 |
|
47 |
*/ |
|
48 |
@RequestMapping("/add") |
|
49 |
public String add() { |
|
50 |
return PREFIX + "/kanbanConf_add.html"; |
|
51 |
} |
|
52 |
|
|
53 |
/** |
|
54 |
* 编辑页面 |
|
55 |
* |
|
56 |
* @author cl |
|
57 |
* @Date 2022-10-31 |
|
58 |
*/ |
|
59 |
@RequestMapping("/edit") |
|
60 |
public String edit() { |
|
61 |
return PREFIX + "/kanbanConf_edit.html"; |
|
62 |
} |
|
63 |
|
|
64 |
@RequestMapping("/orderEdit") |
|
65 |
public String orderEdit() { |
|
66 |
return PREFIX + "/kanbanConf_orderEdit.html"; |
|
67 |
} |
|
68 |
|
|
69 |
/** |
|
70 |
* 新增接口 |
|
71 |
* |
|
72 |
* @author cl |
|
73 |
* @Date 2022-10-31 |
|
74 |
*/ |
|
75 |
@RequestMapping("/addKanBanConfItem") |
|
76 |
@ResponseBody |
|
77 |
public ResponseData addItem(KanbanConfParam kanbanConfParam, HttpServletRequest request) { |
|
78 |
String realIp = IPUtil.getRealIp(request); |
|
79 |
kanbanConfParam.setIpAddress(realIp); |
|
80 |
|
|
81 |
this.kanbanConfService.add(kanbanConfParam); |
|
82 |
return ResponseData.success(); |
|
83 |
} |
|
84 |
|
|
85 |
/** |
|
86 |
* 编辑接口 |
|
87 |
* |
|
88 |
* @author cl |
|
89 |
* @Date 2022-10-31 |
|
90 |
*/ |
|
91 |
@RequestMapping("/editKanBanConfItem") |
|
92 |
@ResponseBody |
|
93 |
public ResponseData editItem(KanbanConfParam kanbanConfParam) { |
|
94 |
this.kanbanConfService.update(kanbanConfParam); |
|
95 |
return ResponseData.success(); |
|
96 |
} |
|
97 |
|
|
98 |
/** |
|
99 |
* 查询列表 |
|
100 |
* |
|
101 |
* @author cl |
|
102 |
* @Date 2022-10-31 |
|
103 |
*/ |
|
104 |
@ResponseBody |
|
105 |
@RequestMapping("/qryKBConflist") |
|
106 |
public LayuiPageInfo list(KanbanConfParam kanbanConfParam, HttpServletRequest request) { |
|
107 |
String realIp = IPUtil.getRealIp(request); |
|
108 |
kanbanConfParam.setIpAddress(realIp); |
|
109 |
|
|
110 |
return this.kanbanConfService.findPageBySpec(kanbanConfParam); |
|
111 |
} |
|
112 |
} |