xuhy
2024-12-13 4d84802f381a447171c5dda28d44a0e53e93f3f4
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
package com.jilongda.manage.controller;
 
 
import com.jilongda.common.basic.ApiResult;
import com.jilongda.common.basic.PageInfo;
import com.jilongda.common.constants.WarehousingConstant;
import com.jilongda.common.utils.CodeGenerateUtils;
import com.jilongda.manage.model.TOptometrist;
import com.jilongda.manage.model.TOrderAftersales;
import com.jilongda.manage.query.TOptometristQuery;
import com.jilongda.manage.query.TOrderAftersalesQuery;
import com.jilongda.manage.service.TOrderAftersalesService;
import com.jilongda.manage.vo.TOptometristVO;
import com.jilongda.manage.vo.TOrderAftersalesVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
 
import org.springframework.web.bind.annotation.RestController;
 
/**
 * <p>
 * 订单售后表 前端控制器
 * </p>
 *
 * @author 无关风月
 * @since 2024-12-09
 */
@Api(tags = "订单售后管理")
@RestController
@RequestMapping("/t-order-aftersales")
public class TOrderAftersalesController {
 
 
    @Autowired
    private TOrderAftersalesService orderAftersalesService;
 
 
    @ApiOperation(value = "订单售后列表")
    @PostMapping(value = "/pageList")
    public ApiResult<PageInfo<TOrderAftersalesVO>> pageList(@RequestBody TOrderAftersalesQuery query) {
        PageInfo<TOrderAftersalesVO> orderAftersalesVOPageInfo = orderAftersalesService.pageList(query);
        return ApiResult.success(orderAftersalesVOPageInfo);
    }
 
    @ApiOperation(value = "订单售后添加")
    @PostMapping(value = "/add")
    public ApiResult<String> add(@RequestBody TOrderAftersales dto) {
        dto.setCode(WarehousingConstant.ASTER_SALES+ CodeGenerateUtils.generateVolumeSn());
        orderAftersalesService.save(dto);
        return ApiResult.success();
    }
 
 
}