package com.skr.mdm.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.skr.mdm.entity.MdmAppStoreInstallDO;
import com.skr.mdm.bean.qo.app.MdmAppStoreInstallQO;
import com.skr.mdm.bean.vo.app.MdmAppStoreInstallVO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 应用商店安装记录(MdmAppStoreInstall)表数据库访问层
 *
 * @author nfq
 * @since 2022-11-22 10:47:23
 */
@Repository
public interface MdmAppStoreInstallDao extends BaseMapper<MdmAppStoreInstallDO> {

    /**
     * 根据设备ID删除
     * @param equipmentIdList 设备ID集合
     */
    void deleteByEquipmentIdList(@Param("equipmentIdList") List<Integer> equipmentIdList);


    /**
     * 批量新增数据（MyBatis原生foreach方法）
     *
     * @param entities List<MdmAppStoreInstall> 实例对象列表
     * @return 影响行数
     */
    int insertBatch(@Param("entities") List<MdmAppStoreInstallDO> entities);


    List<MdmAppStoreInstallVO> listMdmAppStoreInstallVO(MdmAppStoreInstallQO mdmAppStoreInstallQO);
}

