package com.dy.pipIrrTemp.changeSome; 
 | 
  
 | 
import com.dy.common.aop.SsoAop; 
 | 
import com.dy.common.webUtil.BaseResponse; 
 | 
import com.dy.common.webUtil.BaseResponseUtils; 
 | 
import lombok.extern.slf4j.Slf4j; 
 | 
import org.springframework.beans.factory.annotation.Autowired; 
 | 
import org.springframework.web.bind.annotation.GetMapping; 
 | 
import org.springframework.web.bind.annotation.RequestMapping; 
 | 
import org.springframework.web.bind.annotation.RestController; 
 | 
  
 | 
/** 
 | 
 * @Author: liurunyu 
 | 
 * @Date: 2024/12/14 9:22 
 | 
 * @Description 
 | 
 */ 
 | 
@Slf4j 
 | 
@RestController 
 | 
@RequestMapping(path = "chSome") 
 | 
@SuppressWarnings("unchecked")//java版本越高,对泛型约束越严,所以配置SuppressWarnings("unchecked") 
 | 
public class ChSomeCtrl { 
 | 
  
 | 
    private ChSomeIntakeAmountSv intakeAmountSv; 
 | 
  
 | 
    @Autowired 
 | 
    private void setSv(ChSomeIntakeAmountSv sv) { 
 | 
        this.intakeAmountSv = sv; 
 | 
    } 
 | 
  
 | 
    /** 
 | 
     * 修改一些取水口取水量日统计 
 | 
     * @return 
 | 
     */ 
 | 
    @GetMapping(path = "changeSomeIntakeDayAmount") 
 | 
    @SsoAop() 
 | 
    public BaseResponse<Boolean> changeSomeIntakeDayAmount() throws Exception{ 
 | 
        this.intakeAmountSv.chIntakeAmountDay(); 
 | 
        return BaseResponseUtils.buildSuccess(true); 
 | 
    } 
 | 
  
 | 
  
 | 
    /** 
 | 
     * 重新统计取水口月取水量 
 | 
     * @return 
 | 
     */ 
 | 
    @GetMapping(path = "reStatisticsAllIntakeMonthAmount") 
 | 
    @SsoAop() 
 | 
    public BaseResponse<Boolean> reStatisticsAllIntakeMonthAmount() throws Exception{ 
 | 
        this.intakeAmountSv.deleteAllIntakeAmountMonth(); 
 | 
        this.intakeAmountSv.statisticsIntakeAmountMonth(); 
 | 
        return BaseResponseUtils.buildSuccess(true); 
 | 
    } 
 | 
  
 | 
    /** 
 | 
     * 重新统计取水口所取水量 
 | 
     * @return 
 | 
     */ 
 | 
    @GetMapping(path = "reStatisticsAllIntakeYearAmount") 
 | 
    @SsoAop() 
 | 
    public BaseResponse<Boolean> reStatisticsAllIntakeYearAmount() throws Exception{ 
 | 
        this.intakeAmountSv.deleteAllIntakeAmountYear(); 
 | 
        this.intakeAmountSv.statisticsIntakeAmountYear(); 
 | 
        return BaseResponseUtils.buildSuccess(true); 
 | 
    } 
 | 
} 
 |