package com.dsk.jsk.controller;

import com.dsk.common.core.domain.AjaxResult;
import com.dsk.jsk.domain.bo.UrbanInvestmentPlatformDto;
import com.dsk.jsk.service.service.UrbanInvestmentPlatformService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @ClassName UrbanInvestmentPlatformController
 * @Description 城投平台
 * @Author Dgm
 * @Date 2023/5/18 10:09
 * @Version 1.0.0
 */
@RestController
@RequestMapping(value ="/urbanInvestment")
public class UrbanInvestmentPlatformController {

    @Autowired
    private UrbanInvestmentPlatformService urbanInvestmentPlatformService;

    /***
     *@Description: 城投平台分页列表
     *@Param:
     *@return: com.dsk.common.core.domain.AjaxResult
     *@Author: Dgm
     *@date: 2023/5/18 10:29
     */
    @PostMapping("/page")
    public AjaxResult page(@RequestBody UrbanInvestmentPlatformDto dto) {
        return urbanInvestmentPlatformService.page(dto);
    }

    /***
     *@Description: 城投平台详情
     *@Param:
     *@return: com.dsk.common.core.domain.AjaxResult
     *@Author: Dgm
     *@date: 2023/5/18 10:29
     */
    @PostMapping("/details/{id}")
    public AjaxResult details(@PathVariable("id") String id) {
        return urbanInvestmentPlatformService.details(id);
    }


    /***
     *@Description: 城投平台统计
     *@Param:
     *@return: com.dsk.common.core.domain.AjaxResult
     *@Author: Dgm
     *@date: 2023/5/18 10:29
     */
    @PostMapping("/statistics")
    public AjaxResult statistics(@RequestBody UrbanInvestmentPlatformDto dto) {
        return urbanInvestmentPlatformService.statistics(dto);
    }
}
