Authored by mlge

请求方式修改

@@ -9,6 +9,7 @@ import org.slf4j.Logger; @@ -9,6 +9,7 @@ import org.slf4j.Logger;
9 import org.slf4j.LoggerFactory; 9 import org.slf4j.LoggerFactory;
10 import org.springframework.beans.factory.annotation.Autowired; 10 import org.springframework.beans.factory.annotation.Autowired;
11 import org.springframework.stereotype.Controller; 11 import org.springframework.stereotype.Controller;
  12 +import org.springframework.web.bind.annotation.RequestBody;
12 import org.springframework.web.bind.annotation.RequestMapping; 13 import org.springframework.web.bind.annotation.RequestMapping;
13 import org.springframework.web.bind.annotation.ResponseBody; 14 import org.springframework.web.bind.annotation.ResponseBody;
14 15
@@ -28,14 +29,14 @@ public class GrassLabelController { @@ -28,14 +29,14 @@ public class GrassLabelController {
28 29
29 @RequestMapping("/getGrassLabelList") 30 @RequestMapping("/getGrassLabelList")
30 @ResponseBody 31 @ResponseBody
31 - public ApiResponse getGrassLabelList(GrassLabelReq req){ 32 + public ApiResponse getGrassLabelList(@RequestBody GrassLabelReq req){
32 PageResponseVO<GrassLabelBo> result = ilabelService.getGrassLabelList(req); 33 PageResponseVO<GrassLabelBo> result = ilabelService.getGrassLabelList(req);
33 return new ApiResponse.ApiResponseBuilder().data(result).build(); 34 return new ApiResponse.ApiResponseBuilder().data(result).build();
34 } 35 }
35 36
36 @RequestMapping("/addUpGrassLabel") 37 @RequestMapping("/addUpGrassLabel")
37 @ResponseBody 38 @ResponseBody
38 - public ApiResponse addUpGrassLabel(GrassLabelReq req){ 39 + public ApiResponse addUpGrassLabel(@RequestBody GrassLabelReq req){
39 logger.info("enter getRedpacketList,req={}",req); 40 logger.info("enter getRedpacketList,req={}",req);
40 ilabelService.addUpLabel(req); 41 ilabelService.addUpLabel(req);
41 return new ApiResponse.ApiResponseBuilder().build(); 42 return new ApiResponse.ApiResponseBuilder().build();
@@ -43,7 +44,7 @@ public class GrassLabelController { @@ -43,7 +44,7 @@ public class GrassLabelController {
43 44
44 @RequestMapping("/deleteGrassLabel") 45 @RequestMapping("/deleteGrassLabel")
45 @ResponseBody 46 @ResponseBody
46 - public ApiResponse deleteGrassLabel(GrassLabelReq req){ 47 + public ApiResponse deleteGrassLabel(@RequestBody GrassLabelReq req){
47 logger.info("enter updatePacketStatus,req = {}", req); 48 logger.info("enter updatePacketStatus,req = {}", req);
48 ilabelService.deleteLabel(req); 49 ilabelService.deleteLabel(req);
49 return new ApiResponse.ApiResponseBuilder().build(); 50 return new ApiResponse.ApiResponseBuilder().build();
@@ -10,6 +10,7 @@ import org.slf4j.Logger; @@ -10,6 +10,7 @@ import org.slf4j.Logger;
10 import org.slf4j.LoggerFactory; 10 import org.slf4j.LoggerFactory;
11 import org.springframework.beans.factory.annotation.Autowired; 11 import org.springframework.beans.factory.annotation.Autowired;
12 import org.springframework.stereotype.Controller; 12 import org.springframework.stereotype.Controller;
  13 +import org.springframework.web.bind.annotation.RequestBody;
13 import org.springframework.web.bind.annotation.RequestMapping; 14 import org.springframework.web.bind.annotation.RequestMapping;
14 import org.springframework.web.bind.annotation.ResponseBody; 15 import org.springframework.web.bind.annotation.ResponseBody;
15 16
@@ -26,14 +27,14 @@ public class GrassTopicController { @@ -26,14 +27,14 @@ public class GrassTopicController {
26 27
27 @RequestMapping("/getGrassTopicList") 28 @RequestMapping("/getGrassTopicList")
28 @ResponseBody 29 @ResponseBody
29 - public ApiResponse getGrassTopicList(GrassTopicReq req){ 30 + public ApiResponse getGrassTopicList(@RequestBody GrassTopicReq req){
30 PageResponseVO<TopicRespBo> result = topicService.getGrassTopicList(req); 31 PageResponseVO<TopicRespBo> result = topicService.getGrassTopicList(req);
31 return new ApiResponse.ApiResponseBuilder().data(result).build(); 32 return new ApiResponse.ApiResponseBuilder().data(result).build();
32 } 33 }
33 34
34 @RequestMapping("/addUpGrassTopic") 35 @RequestMapping("/addUpGrassTopic")
35 @ResponseBody 36 @ResponseBody
36 - public ApiResponse addUpGrassTopic(GrassTopicReq req){ 37 + public ApiResponse addUpGrassTopic(@RequestBody GrassTopicReq req){
37 topicService.addUpGrassTopic(req); 38 topicService.addUpGrassTopic(req);
38 return new ApiResponse.ApiResponseBuilder().build(); 39 return new ApiResponse.ApiResponseBuilder().build();
39 } 40 }
@@ -29,7 +29,7 @@ public class LabelGroupController { @@ -29,7 +29,7 @@ public class LabelGroupController {
29 29
30 @RequestMapping("/getLabelGroupList") 30 @RequestMapping("/getLabelGroupList")
31 @ResponseBody 31 @ResponseBody
32 - public ApiResponse getLabelGroupList(LabelGroupReq req){ 32 + public ApiResponse getLabelGroupList(@RequestBody LabelGroupReq req){
33 logger.info("enter getRedpacketList,req={}",req); 33 logger.info("enter getRedpacketList,req={}",req);
34 PageResponseVO<LabelGroupBo> result = labelGroupService.getLabelGroupList(req); 34 PageResponseVO<LabelGroupBo> result = labelGroupService.getLabelGroupList(req);
35 return new ApiResponse.ApiResponseBuilder().data(result).build(); 35 return new ApiResponse.ApiResponseBuilder().data(result).build();
@@ -37,7 +37,7 @@ public class LabelGroupController { @@ -37,7 +37,7 @@ public class LabelGroupController {
37 37
38 @RequestMapping("/addUpLabelGroup") 38 @RequestMapping("/addUpLabelGroup")
39 @ResponseBody 39 @ResponseBody
40 - public ApiResponse addUpLabelGroup(LabelGroupReq req){ 40 + public ApiResponse addUpLabelGroup(@RequestBody LabelGroupReq req){
41 logger.info("enter getRedpacketList,req={}",req); 41 logger.info("enter getRedpacketList,req={}",req);
42 labelGroupService.addUpLabelGroup(req); 42 labelGroupService.addUpLabelGroup(req);
43 return new ApiResponse.ApiResponseBuilder().build(); 43 return new ApiResponse.ApiResponseBuilder().build();
@@ -45,7 +45,7 @@ public class LabelGroupController { @@ -45,7 +45,7 @@ public class LabelGroupController {
45 45
46 @RequestMapping("/deleteLabelGroup") 46 @RequestMapping("/deleteLabelGroup")
47 @ResponseBody 47 @ResponseBody
48 - public ApiResponse deleteLabelGroup(LabelGroupReq req){ 48 + public ApiResponse deleteLabelGroup(@RequestBody LabelGroupReq req){
49 logger.info("enter updatePacketStatus,req = {}", req); 49 logger.info("enter updatePacketStatus,req = {}", req);
50 int flag = labelGroupService.deleteLabelGroup(req); 50 int flag = labelGroupService.deleteLabelGroup(req);
51 if(flag == 2){ 51 if(flag == 2){