huliguo
2 天以前 5d7b65670282a4fad015e37d567cfa171b162052
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
package com.ruoyi.web.controller.errand;
 
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.ruoyi.common.core.domain.R;
import com.ruoyi.errand.object.dto.sys.FeedbackPageListDTO;
import com.ruoyi.errand.object.dto.sys.OrderPageListDTO;
import com.ruoyi.errand.object.vo.sys.FeedbackPageListVO;
import com.ruoyi.errand.object.vo.sys.OrderPageListVO;
import com.ruoyi.errand.service.FeedbackService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.security.core.parameters.P;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
 
import javax.validation.Valid;
 
@Validated
@RestController
@RequestMapping(value = "/app/feedback")
@Api(value = "用户反馈", tags = "用户反馈操作控制器")
@Slf4j
public class FeedbackController {
    @Autowired
    private FeedbackService feedbackService;
 
    /**
     * 意见反馈
     */
    @PostMapping("/add")
    @ApiOperation(value = "意见反馈",tags = "app用户端-意见反馈")
    public R<Integer> add(@RequestParam String content) {
        feedbackService.add(content);
        return R.ok();
    }
 
 
    /**
     * 分页列表
     */
    @PostMapping("/list")
    @PreAuthorize("@ss.hasPermi('system:feedback:list')")
    @ApiOperation(value = "反馈管理-分页列表", tags = "系统后台-订单管理")
    public R<IPage<FeedbackPageListVO>> getFeedbackPageList(@RequestBody @Valid FeedbackPageListDTO feedbackPageListDTO) {
        return R.ok(feedbackService.getFeedbackPageList(feedbackPageListDTO));
    }
    /**
     * 删除
     */
    @DeleteMapping("/delete")
    @PreAuthorize("@ss.hasPermi('system:feedback:list')")
    @ApiOperation(value = "反馈管理-删除", tags = "系统后台-订单管理")
    public R delete(@RequestParam("id")Integer id) {
        feedbackService.delete(id);
        return R.ok();
    }
 
    /**
     * 处理
     */
    @PutMapping("/dispose")
    @PreAuthorize("@ss.hasPermi('system:feedback:list')")
    @ApiOperation(value = "反馈管理-处理", tags = "系统后台-订单管理")
    public R dispose(@RequestParam("id")Integer id) {
        feedbackService.dispose(id);
        return R.ok();
    }
}