package com.rongwei.trainingcommon.sys.dao;

import com.rongwei.training.vo.DemandUserVo;
import com.rongwei.training.vo.WordEmpInfoVo;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * CommonDao class
 *
 * @author XH
 * @date 2020/12/18
 */
public interface DangerousDao {
    @Select("SELECT a.*, b.JOBTYPE, b.ASSIGNMENTTIMESTART, b.ASSIGNMENTTIMEEND FROM asp_inspectrecords a LEFT JOIN asp_job_management b ON a.JOBID = b.ID WHERE a.deleted = 0 AND a.PUNISHPERSONNELID IS NOT NULL AND a.STATUS = '1' AND a.GENERATEPENALTYORNOT = 'y'")
    List<Map<String, Object>> getDangerousDailyNotify();

    @Select("SELECT a.*, b.JOBTYPE, b.ASSIGNMENTTIMESTART, b.ASSIGNMENTTIMEEND FROM asp_inspectrecords a LEFT JOIN asp_job_management b ON a.JOBID = b.ID WHERE a.deleted = 0 AND a.ID = #{id}")
    Map<String, Object> getDangerousNotify(@Param("id") String id);


}
