|
@@ -39,80 +39,80 @@ public class TaMiniappQrcodeController extends BaseController {
|
39
|
39
|
@Autowired
|
40
|
40
|
public ITaMiniappQrcodeService iTaMiniappQrcodeService;
|
41
|
41
|
|
42
|
|
-
|
43
|
|
- /**
|
44
|
|
- * 分页查询列表
|
45
|
|
- * @param pageNum
|
46
|
|
- * @param pageSize
|
47
|
|
- * @return
|
48
|
|
- */
|
49
|
|
- @RequestMapping(value="/taMiniappQrcode",method= RequestMethod.GET)
|
50
|
|
- @ApiOperation(value="列表", notes = "列表", httpMethod = "GET", response = ResponseBean.class)
|
51
|
|
- public ResponseBean taMiniappQrcodeList(@ApiParam("页码") @RequestParam(value ="pageNum",defaultValue = "1") Integer pageNum,
|
52
|
|
- @ApiParam("单页数据量") @RequestParam(value ="pageSize",defaultValue = "10") Integer pageSize) throws Exception{
|
53
|
|
-
|
54
|
|
- IPage<TaMiniappQrcode> pg = new Page<>(pageNum, pageSize);
|
55
|
|
- QueryWrapper<TaMiniappQrcode> queryWrapper = new QueryWrapper<>();
|
56
|
|
- queryWrapper.orderByDesc("create_date");
|
57
|
|
-
|
58
|
|
- IPage<TaMiniappQrcode> result = iTaMiniappQrcodeService.page(pg, queryWrapper);
|
59
|
|
- return ResponseBean.success(result);
|
60
|
|
- }
|
61
|
|
-
|
62
|
|
- /**
|
63
|
|
- * 保存对象
|
64
|
|
- * @param taMiniappQrcode 实体对象
|
65
|
|
- * @return
|
66
|
|
- */
|
67
|
|
- @RequestMapping(value="/taMiniappQrcode",method= RequestMethod.POST)
|
68
|
|
- @ApiOperation(value="保存", notes = "保存", httpMethod = "POST", response = ResponseBean.class)
|
69
|
|
- public ResponseBean taMiniappQrcodeAdd(@ApiParam("保存内容") @RequestBody TaMiniappQrcode taMiniappQrcode) throws Exception{
|
70
|
|
-
|
71
|
|
- if (iTaMiniappQrcodeService.save(taMiniappQrcode)){
|
72
|
|
- return ResponseBean.success(taMiniappQrcode);
|
73
|
|
- }else {
|
74
|
|
- return ResponseBean.error("保存失败, 请重试", ResponseBean.ERROR_UNAVAILABLE);
|
75
|
|
- }
|
76
|
|
- }
|
77
|
|
-
|
78
|
|
- /**
|
79
|
|
- * 根据id删除对象
|
80
|
|
- * @param id 实体ID
|
81
|
|
- */
|
82
|
|
- @RequestMapping(value="/taMiniappQrcode/{id}", method= RequestMethod.DELETE)
|
83
|
|
- @ApiOperation(value="删除", notes = "删除", httpMethod = "DELETE", response = ResponseBean.class)
|
84
|
|
- public ResponseBean taMiniappQrcodeDelete(@ApiParam("对象ID") @PathVariable Integer id) throws Exception{
|
85
|
|
- if(iTaMiniappQrcodeService.removeById(id)){
|
86
|
|
- return ResponseBean.success("success");
|
87
|
|
- }else {
|
88
|
|
- return ResponseBean.error("删除失败, 请重试", ResponseBean.ERROR_UNAVAILABLE);
|
89
|
|
- }
|
90
|
|
- }
|
91
|
|
-
|
92
|
|
- /**
|
93
|
|
- * 修改对象
|
94
|
|
- * @param id 实体ID
|
95
|
|
- * @param taMiniappQrcode 实体对象
|
96
|
|
- * @return
|
97
|
|
- */
|
98
|
|
- @RequestMapping(value="/taMiniappQrcode/{id}",method= RequestMethod.PUT)
|
99
|
|
- @ApiOperation(value="更新", notes = "更新", httpMethod = "PUT", response = ResponseBean.class)
|
100
|
|
- public ResponseBean taMiniappQrcodeUpdate(@ApiParam("对象ID") @PathVariable Integer id,
|
101
|
|
- @ApiParam("更新内容") @RequestBody TaMiniappQrcode taMiniappQrcode) throws Exception{
|
102
|
|
-
|
103
|
|
- if (iTaMiniappQrcodeService.updateById(taMiniappQrcode)){
|
104
|
|
- return ResponseBean.success(iTaMiniappQrcodeService.getById(id));
|
105
|
|
- }else {
|
106
|
|
- return ResponseBean.error("修改失败, 请重试", ResponseBean.ERROR_UNAVAILABLE);
|
107
|
|
- }
|
108
|
|
- }
|
|
42
|
+//
|
|
43
|
+// /**
|
|
44
|
+// * 分页查询列表
|
|
45
|
+// * @param pageNum
|
|
46
|
+// * @param pageSize
|
|
47
|
+// * @return
|
|
48
|
+// */
|
|
49
|
+// @RequestMapping(value="/taMiniappQrcode",method= RequestMethod.GET)
|
|
50
|
+// @ApiOperation(value="列表", notes = "列表", httpMethod = "GET", response = ResponseBean.class)
|
|
51
|
+// public ResponseBean taMiniappQrcodeList(@ApiParam("页码") @RequestParam(value ="pageNum",defaultValue = "1") Integer pageNum,
|
|
52
|
+// @ApiParam("单页数据量") @RequestParam(value ="pageSize",defaultValue = "10") Integer pageSize) throws Exception{
|
|
53
|
+//
|
|
54
|
+// IPage<TaMiniappQrcode> pg = new Page<>(pageNum, pageSize);
|
|
55
|
+// QueryWrapper<TaMiniappQrcode> queryWrapper = new QueryWrapper<>();
|
|
56
|
+// queryWrapper.orderByDesc("create_date");
|
|
57
|
+//
|
|
58
|
+// IPage<TaMiniappQrcode> result = iTaMiniappQrcodeService.page(pg, queryWrapper);
|
|
59
|
+// return ResponseBean.success(result);
|
|
60
|
+// }
|
|
61
|
+//
|
|
62
|
+// /**
|
|
63
|
+// * 保存对象
|
|
64
|
+// * @param taMiniappQrcode 实体对象
|
|
65
|
+// * @return
|
|
66
|
+// */
|
|
67
|
+// @RequestMapping(value="/taMiniappQrcode",method= RequestMethod.POST)
|
|
68
|
+// @ApiOperation(value="保存", notes = "保存", httpMethod = "POST", response = ResponseBean.class)
|
|
69
|
+// public ResponseBean taMiniappQrcodeAdd(@ApiParam("保存内容") @RequestBody TaMiniappQrcode taMiniappQrcode) throws Exception{
|
|
70
|
+//
|
|
71
|
+// if (iTaMiniappQrcodeService.save(taMiniappQrcode)){
|
|
72
|
+// return ResponseBean.success(taMiniappQrcode);
|
|
73
|
+// }else {
|
|
74
|
+// return ResponseBean.error("保存失败, 请重试", ResponseBean.ERROR_UNAVAILABLE);
|
|
75
|
+// }
|
|
76
|
+// }
|
|
77
|
+//
|
|
78
|
+// /**
|
|
79
|
+// * 根据id删除对象
|
|
80
|
+// * @param id 实体ID
|
|
81
|
+// */
|
|
82
|
+// @RequestMapping(value="/taMiniappQrcode/{id}", method= RequestMethod.DELETE)
|
|
83
|
+// @ApiOperation(value="删除", notes = "删除", httpMethod = "DELETE", response = ResponseBean.class)
|
|
84
|
+// public ResponseBean taMiniappQrcodeDelete(@ApiParam("对象ID") @PathVariable Integer id) throws Exception{
|
|
85
|
+// if(iTaMiniappQrcodeService.removeById(id)){
|
|
86
|
+// return ResponseBean.success("success");
|
|
87
|
+// }else {
|
|
88
|
+// return ResponseBean.error("删除失败, 请重试", ResponseBean.ERROR_UNAVAILABLE);
|
|
89
|
+// }
|
|
90
|
+// }
|
|
91
|
+//
|
|
92
|
+// /**
|
|
93
|
+// * 修改对象
|
|
94
|
+// * @param id 实体ID
|
|
95
|
+// * @param taMiniappQrcode 实体对象
|
|
96
|
+// * @return
|
|
97
|
+// */
|
|
98
|
+// @RequestMapping(value="/taMiniappQrcode/{id}",method= RequestMethod.PUT)
|
|
99
|
+// @ApiOperation(value="更新", notes = "更新", httpMethod = "PUT", response = ResponseBean.class)
|
|
100
|
+// public ResponseBean taMiniappQrcodeUpdate(@ApiParam("对象ID") @PathVariable Integer id,
|
|
101
|
+// @ApiParam("更新内容") @RequestBody TaMiniappQrcode taMiniappQrcode) throws Exception{
|
|
102
|
+//
|
|
103
|
+// if (iTaMiniappQrcodeService.updateById(taMiniappQrcode)){
|
|
104
|
+// return ResponseBean.success(iTaMiniappQrcodeService.getById(id));
|
|
105
|
+// }else {
|
|
106
|
+// return ResponseBean.error("修改失败, 请重试", ResponseBean.ERROR_UNAVAILABLE);
|
|
107
|
+// }
|
|
108
|
+// }
|
109
|
109
|
|
110
|
110
|
/**
|
111
|
111
|
* 根据id查询对象
|
112
|
112
|
* @param id 实体ID
|
113
|
113
|
*/
|
114
|
|
- @RequestMapping(value="/taMiniappQrcode/{id}",method= RequestMethod.GET)
|
115
|
|
- @ApiOperation(value="详情", notes = "详情", httpMethod = "GET", response = ResponseBean.class)
|
|
114
|
+ @RequestMapping(value="/wx/{clientId}/qrcode/{id}",method= RequestMethod.GET)
|
|
115
|
+ @ApiOperation(value="查询二维码详情", notes = "查询二维码详情", httpMethod = "GET", response = ResponseBean.class)
|
116
|
116
|
public ResponseBean taMiniappQrcodeGet(@ApiParam("对象ID") @PathVariable Integer id) throws Exception{
|
117
|
117
|
return ResponseBean.success(iTaMiniappQrcodeService.getById(id));
|
118
|
118
|
}
|