郑永安
2023-06-19 7a6abd05683528032687c75e80e0bd2030a3e46c
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
package com.gkhy.safePlatform.riskCtrl.service.baseService.impl;
 
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.gkhy.safePlatform.riskCtrl.entity.RiskMonthReport;
import com.gkhy.safePlatform.riskCtrl.model.vo.db.MonthReportSearchParamVO;
import com.gkhy.safePlatform.riskCtrl.repository.RiskMonthReportRepository;
import com.gkhy.safePlatform.riskCtrl.service.baseService.RiskMonthReportService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
 
import java.util.List;
 
@Service
public class RiskMonthReportServiceImpl extends ServiceImpl<RiskMonthReportRepository, RiskMonthReport> implements RiskMonthReportService {
 
    @Autowired
    private RiskMonthReportRepository riskMonthReportRepository;
 
 
    @Override
    public RiskMonthReport findByMonth(Byte biz, Long depId, Integer year, Integer month) {
        if(biz == null || depId == null || year == null || month == null)
            return null;
        if(year < 2000 || year > 9999 || month < 1 || month > 12 || depId < 1)
            return null;
        return riskMonthReportRepository.findByMonth(biz,depId,year,month);
    }
 
    @Override
    public List<RiskMonthReport> listByConditions(MonthReportSearchParamVO params) {
        return riskMonthReportRepository.listByConditions(params);
    }
}