package com.docus.server.issubmit.service.impl;

import com.docus.server.constants.DSKeyConstants;
import com.docus.server.issubmit.infrastructure.mapper.IssubmitDeptMapper;
import com.docus.server.issubmit.service.IIssubmitService;
import lombok.AllArgsConstructor;
import org.springframework.stereotype.Component;

import java.util.Date;
import java.util.List;
import java.util.Map;

@Component(DSKeyConstants.ISSUBMIT_DS_KEY + "ServiceImpl")
@AllArgsConstructor
public class IssubmitServiceImpl implements IIssubmitService {

    private final IssubmitDeptMapper issubmitDeptMapper;

    @Override
    public List<Map<String, Object>> page(Date startDate, Date endDate, int pageNum, int pageSize) {
        return issubmitDeptMapper.page(startDate, endDate, (pageNum - 1) * pageSize, pageSize);
    }

    @Override
    public List<Map<String, Object>> BatchForJZH(List<String> jzhs) {
        return issubmitDeptMapper.BatchForJZH(jzhs);
    }

    @Override
    public List<Map<String, Object>> BatchForJZHAndAdmissTimes(List<Map<String, Object>> datas) {
        return issubmitDeptMapper.BatchForJZHAndAdmissTimes(datas);
    }

    @Override
    public List<Map<String, Object>> BatchForZYHAndAdmissTimes(List<Map<String, Object>> datas) {
        return issubmitDeptMapper.BatchForZYHAndAdmissTimes(datas);
    }

    @Override
    public List<Map<String, Object>> BatchForEXAMTIME(List<Map<String, Object>> datas) {
        return issubmitDeptMapper.BatchForEXAMTIME(datas);
    }

}
