package com.zcxk.rmcp.core.dao;

import com.zcxk.core.common.pojo.UserCondition;
import com.zcxk.rmcp.api.dto.install.InstallDetailDto;
import com.zcxk.rmcp.api.query.InstallPlanQueryCondition;
import com.zcxk.rmcp.api.vo.InstallPlanVo;
import com.zcxk.rmcp.api.vo.StatisticsDeviceStatusVo;
import com.zcxk.rmcp.api.vo.StatusStatisticsVo;
import com.zcxk.rmcp.core.entity.InstallPlan;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author linqingwei
 * @date 2021-07-21 10:03
 */
@Mapper
public interface InstallPlanMapper {
    int insertSelective(InstallPlan record);

    int updateByPrimaryKeySelective(InstallPlan record);

    InstallPlan findById(@Param("planId") Integer planId);

    List<InstallPlanVo> findList(@Param("condition") InstallPlanQueryCondition condition, @Param("userCondition") UserCondition userCondition);

    int batchDelete(@Param("ids") List<Integer> ids);

    StatisticsDeviceStatusVo totalDeviceStatus(@Param("planId") Integer planId);

    InstallDetailDto findDetail(@Param("planId")Integer planId);
}