Przeglądaj źródła

反馈中心开发

liude 1 rok temu
rodzic
commit
c68c2e97cf

+ 1 - 2
src/main/java/com/chelvc/cloud/maintain/controller/AssessController.java

@@ -32,7 +32,6 @@ import java.util.Map;
 @Validated
 @Validated
 @RestController
 @RestController
 @ResponseWrapping
 @ResponseWrapping
-@PreAuthorize("isScope('EMPLOYEE')")
 public class AssessController {
 public class AssessController {
 
 
     private static final String DEFAULT_MSG= "亲爱的顾客,感谢您认可我们的服务,我们会努力做的更好,祝您生活愉快!";
     private static final String DEFAULT_MSG= "亲爱的顾客,感谢您认可我们的服务,我们会努力做的更好,祝您生活愉快!";
@@ -70,7 +69,7 @@ public class AssessController {
     /**
     /**
      * 评价查询
      * 评价查询
      */
      */
-    @GetMapping("/assess/query")
+    @PostMapping("/assess/query")
     public List<GoodsAssessDto> addAssess(@RequestBody AssessQueryParam param){
     public List<GoodsAssessDto> addAssess(@RequestBody AssessQueryParam param){
         return assessService.query(param);
         return assessService.query(param);
     }
     }

+ 1 - 1
src/main/java/com/chelvc/cloud/maintain/controller/CartItemController.java

@@ -69,7 +69,7 @@ public class CartItemController {
      *
      *
      * @return 购物车主键
      * @return 购物车主键
      */
      */
-    @PutMapping("/cartItem/deleteCartItem/{ids}")
+    @PostMapping("/cartItem/deleteCartItem/{ids}")
     public void deleteCartItem( @PathVariable("ids") @NotEmpty(message = "购物车ID不能为空") List<Long> ids) {
     public void deleteCartItem( @PathVariable("ids") @NotEmpty(message = "购物车ID不能为空") List<Long> ids) {
          this.cartItemService.delete(ids);
          this.cartItemService.delete(ids);
     }
     }

+ 6 - 3
src/main/java/com/chelvc/cloud/maintain/controller/FeedbackController.java

@@ -5,6 +5,7 @@ import com.chelvc.cloud.vehicle.api.service.FeedbackService;
 import com.chelvc.framework.base.annotation.ResponseWrapping;
 import com.chelvc.framework.base.annotation.ResponseWrapping;
 import org.apache.dubbo.config.annotation.DubboReference;
 import org.apache.dubbo.config.annotation.DubboReference;
 import org.springframework.validation.annotation.Validated;
 import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.PutMapping;
 import org.springframework.web.bind.annotation.PutMapping;
@@ -13,6 +14,8 @@ import org.springframework.web.bind.annotation.RestController;
 
 
 import javax.validation.Valid;
 import javax.validation.Valid;
 import javax.validation.constraints.Min;
 import javax.validation.constraints.Min;
+import javax.validation.constraints.NotEmpty;
+import java.util.List;
 
 
 /**
 /**
  * 意见反馈接口
  * 意见反馈接口
@@ -53,9 +56,9 @@ public class FeedbackController {
     /**
     /**
      * 查询意见反馈
      * 查询意见反馈
      */
      */
-    @PostMapping("/feedback/queryById")
-    public FeedBackDTO queryById() {
-        return this.feedbackService.getFeedback();
+    @GetMapping("/feedback/query")
+    public List<FeedBackDTO> queryById(@Valid @NotEmpty String channel) {
+        return this.feedbackService.getFeedback(channel);
     }
     }
 
 
 
 

+ 53 - 0
src/main/java/com/chelvc/cloud/maintain/controller/FeedbackReplyController.java

@@ -0,0 +1,53 @@
+package com.chelvc.cloud.maintain.controller;
+import com.chelvc.cloud.vehicle.api.param.FeedBackReplyModifyParam;
+import com.chelvc.cloud.vehicle.api.service.FeedbackReplyService;
+import com.chelvc.framework.base.annotation.ResponseWrapping;
+import org.apache.dubbo.config.annotation.DubboReference;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RestController;
+import javax.validation.Valid;
+import javax.validation.constraints.Min;
+
+/**
+ * 意见反馈回复接口
+ *
+ * @author liude
+ * @date 2023/1/16
+ */
+@Validated
+@RestController
+@ResponseWrapping
+public class FeedbackReplyController {
+    @DubboReference
+    private FeedbackReplyService feedbackReplyService;
+
+    /**
+     * 新增意见反馈回复
+     *
+     * @param param 新增参数
+     * @return 意见反馈回复主键
+     */
+    @PostMapping("/feedbackReply")
+    public Long addFeedbackReply(@RequestBody @Valid FeedBackReplyModifyParam param) {
+        return this.feedbackReplyService.addFeedbackReply(param);
+    }
+
+    /**
+     * 修改意见反馈回复
+     *
+     * @param id    意见反馈主键
+     * @param param 修改参数
+     */
+    @PutMapping("/feedbackReply/{id}")
+    public void updateFeedbackReply(@PathVariable("id") @Min(value = 1, message = "商家主键不能小于1") Long id,
+                                   @RequestBody @Valid FeedBackReplyModifyParam param) {
+        this.feedbackReplyService.updateFeedbackReply(id, param);
+    }
+
+
+
+}

+ 0 - 1
src/main/java/com/chelvc/cloud/maintain/controller/MerchantController.java

@@ -3,7 +3,6 @@ package com.chelvc.cloud.maintain.controller;
 import com.chelvc.cloud.maintain.copier.MerchantCopier;
 import com.chelvc.cloud.maintain.copier.MerchantCopier;
 import com.chelvc.cloud.maintain.vo.SimpleMerchantVO;
 import com.chelvc.cloud.maintain.vo.SimpleMerchantVO;
 import com.chelvc.cloud.vehicle.api.dto.BalanceDetailDTO;
 import com.chelvc.cloud.vehicle.api.dto.BalanceDetailDTO;
-import com.chelvc.cloud.vehicle.api.dto.MerchantBalanceDetailDTO;
 import com.chelvc.cloud.vehicle.api.dto.MerchantDTO;
 import com.chelvc.cloud.vehicle.api.dto.MerchantDTO;
 import com.chelvc.cloud.vehicle.api.dto.MerchantDetailDTO;
 import com.chelvc.cloud.vehicle.api.dto.MerchantDetailDTO;
 import com.chelvc.cloud.vehicle.api.param.LocationQueryParam;
 import com.chelvc.cloud.vehicle.api.param.LocationQueryParam;

+ 6 - 0
src/main/java/com/chelvc/cloud/maintain/vo/SimpleMerchantVO.java

@@ -52,4 +52,10 @@ public class SimpleMerchantVO implements Serializable {
      * 距离(米)
      * 距离(米)
      */
      */
     private Double distance;
     private Double distance;
+
+    /**
+     * 营业状态 0-营业中 1-休息中
+     */
+    private String businessStatus;
+
 }
 }