Authored by csgyoho

种草-完善

... ... @@ -29,48 +29,48 @@ public class GrassGoodsController {
@RequestMapping("/queryGoods")
@ResponseBody
public ApiResponse queryGoods(GoodsQueryReq req){
logger.info("enter queryGoods.param is {}",req);
public ApiResponse queryGrassGoods(GoodsQueryReq req){
logger.info("enter queryGrassGoods.param is {}",req);
PageResponseVO<GoodsQueryRsp> result = grassGoodsService.queryGoods(req);
return new ApiResponse.ApiResponseBuilder().data(result).build();
}
@RequestMapping("/searchProducts")
@ResponseBody
public ApiResponse searchProducts(ProductSearchReq req){
logger.info("enter searchProducts.param is {}",req);
public ApiResponse searchGrassProducts(ProductSearchReq req){
logger.info("enter searchGrassProducts.param is {}",req);
PageResponseVO<JSONObject> result = grassGoodsService.searchProducts(req);
return new ApiResponse.ApiResponseBuilder().data(result).build();
}
@RequestMapping("/batchAddGoods")
@ResponseBody
public ApiResponse batchAddGoods(@RequestBody List<BatchAddGoodsReq> reqList){
logger.info("enter batchAddGoods.param is {}",reqList);
public ApiResponse batchAddGrassGoods(@RequestBody List<BatchAddGoodsReq> reqList){
logger.info("enter batchAddGrassGoods.param is {}",reqList);
grassGoodsService.batchAddGoods(reqList);
return new ApiResponse.ApiResponseBuilder().message("批量新增成功").build();
}
@RequestMapping("/getGoods")
@ResponseBody
public ApiResponse getGoods(@RequestParam("id") Integer id){
logger.info("enter getGoods.id is {}",id);
public ApiResponse getGrassGoods(@RequestParam("id") Integer id){
logger.info("enter getGrassGoods.id is {}",id);
GrassGoods result = grassGoodsService.getGoods(id);
return new ApiResponse.ApiResponseBuilder().data(result).build();
}
@RequestMapping("/modifyGoodsStatus")
@ResponseBody
public ApiResponse modifyGoodsStatus(@RequestParam("status") Integer status,@RequestParam("id") Integer id){
logger.info("enter modifyGoodsStatus.status is {}",status);
public ApiResponse modifyGrassGoodsStatus(@RequestParam("status") Integer status,@RequestParam("id") Integer id){
logger.info("enter modifyGrassGoodsStatus.status is {}",status);
grassGoodsService.modifyGoodsStatus(status,id);
return new ApiResponse.ApiResponseBuilder().message("修改成功").build();
}
@RequestMapping("/modifyGoods")
@ResponseBody
public ApiResponse modifyGoods(GoodsModifyReq req){
logger.info("enter modifyGoods.param is {}",req);
public ApiResponse modifyGrassGoods(GoodsModifyReq req){
logger.info("enter modifyGrassGoods.param is {}",req);
grassGoodsService.modifyGoods(req);
return new ApiResponse.ApiResponseBuilder().message("修改成功").build();
}
... ...