package com.zksy.base.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.zksy.base.domain.EquipmentBase;
import com.zksy.manhole.dto.in.ManholeDevicePageInDTO;
import com.zksy.manhole.dto.out.EquipmentBaseOutDTO;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public interface EquipmentBaseService extends IService<EquipmentBase> {

    Page<EquipmentBase> findByPage(long pageNum, long pageSize,
                                   String equipmentCode,String equipmentName,
                                   String equipmentModel,String manufacturer);

    /**
     * 新增仪器信息
     * @param entity
     * @return
     */
    boolean saveWithCheck(EquipmentBase entity);

    /**
     * 新增仪器信息
     * @param entityList
     * @return
     */
    boolean saveBatchWithCheck(List<EquipmentBase> entityList);

    /**
     * 修改仪器信息
     * @param entity
     * @return
     */
    boolean updateWithCheck(EquipmentBase entity);

    /**
     * 删除设备基础信息
     * @param id
     * @return
     */
    boolean removeWithCheck(String id);

    /**
     * 设备基础信息批量删除
     * @param ids
     * @return
     */
    boolean removeBatchWithCheck(List<String> ids);

//    EquipmentBase getByIdTest(String id);

    /**
     * 分页查询监测设备台账列表
     * @param pageInDTO
     * @return
     */
    Page<EquipmentBaseOutDTO> findManholeDeviceByPage(ManholeDevicePageInDTO pageInDTO);
}
