package com.fdkankan.platform.goods.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.fdkankan.platform.goods.entity.Camera;
import com.baomidou.mybatisplus.extension.service.IService;
import com.fdkankan.platform.goods.entity.CameraDetail;
import com.fdkankan.platform.user.request.RequestCamera;
import com.fdkankan.platform.user.vo.ResponseCamera;
import com.fdkankan.platform.user.vo.ResponseCameraSpace;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * <p>
 * 相机主表 服务类
 * </p>
 *
 * @author 
 * @since 2021-12-24
 */
public interface ICameraService extends IService<Camera> {

    Camera saveByAgent(String childName, String wifiName, String agentId, String balance);

    Page<ResponseCamera> getPageByUser(RequestCamera param, Long id) throws Exception;

    Camera getByChildName(String childName);

    List<ResponseCamera> getByUser(Long userId, Integer type);

    String addCamera(RequestCamera camera, String token);

    List<ResponseCameraSpace> cameraSpaceList(RequestCamera camera);

    ResponseCamera findCameraBySn(RequestCamera camera);

    HSSFWorkbook export(String token, HttpServletResponse response,RequestCamera param) throws Exception;

    List<Camera> getCameraLikeSnCode(String trim);

    Camera getBySnCode(String snCode);

    Camera getByChildNameAndChildPassword(String appUserName, String appPassword);

    Camera getAvailableById(Long id);

    Camera addCameraByManager(RequestCamera param);

    Camera updateCameraByManager(RequestCamera param);

    String deleteCamera(RequestCamera param);

    String deleteCameraNew(RequestCamera param);

    List<ResponseCamera>  convert(List<CameraDetail> list);

    List<Camera> findByIds(List<Long> ids);
}
