package cn.com.ty.lift.batch.applet.controller;

import cn.com.ty.lift.batch.applet.dao.model.request.PaymentDataRequest;
import cn.com.ty.lift.batch.applet.service.PaymentDataService;
import cn.com.xwy.boot.web.dto.RestResponse;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author huangyuan
 * @date 2020/2/3
 * @description 小程序收款数据统计
 */
@RestController
@RequestMapping("/applet/payment")
public class PaymentDataStatisticsController {

    @Resource
    private PaymentDataService paymentDataService;

    @RequestMapping("/paymentMonthOverView")
    public RestResponse paymentMonthOverView(@RequestBody PaymentDataRequest paymentDataRequest){
        return paymentDataService.paymentMonthOverView(paymentDataRequest);
    }

    /**
     * @param
     * @return
     * @description 收款数据总览
     * @date 2020/2/5 4:58 下午
     */
    @RequestMapping("/paymentOverView")
    public RestResponse paymentOverView(@RequestBody PaymentDataRequest paymentDataRequest) {
        return paymentDataService.paymentOverView(paymentDataRequest);
    }

    /**
     * @param
     * @return
     * @description 站点排名
     * @date 2020/2/5 4:59 下午
     */
    @RequestMapping("/regionRank")
    public RestResponse regionRank(@RequestBody PaymentDataRequest paymentDataRequest) {
        return paymentDataService.regionRank(paymentDataRequest);
    }

    /**
     * @param
     * @return
     * @description 超期项目统计
     * @date 2020/2/5 5:01 下午
     */
    @RequestMapping("dueToProject")
    public RestResponse dueToProject(@RequestBody PaymentDataRequest paymentDataRequest) {
        return paymentDataService.dueToProject(paymentDataRequest);
    }

}
