package net.lab1024.sa.admin.module.business.wms.base.address.service;

import jakarta.servlet.http.HttpServletResponse;
import net.lab1024.sa.admin.module.business.wms.base.address.domain.entity.AddressEntity;
import net.lab1024.sa.admin.module.business.wms.base.address.domain.form.AddressQueryForm;
import net.lab1024.sa.admin.module.business.wms.base.address.domain.form.AddressSelect;
import net.lab1024.sa.admin.module.business.wms.base.address.domain.vo.AddressExcelVO;
import net.lab1024.sa.admin.module.business.wms.base.address.domain.vo.AddressVO;
import net.lab1024.sa.admin.module.business.wms.base.item.domain.form.ItemQueryForm;
import net.lab1024.sa.base.common.domain.PageResult;

import java.io.IOException;
import java.util.List;
import java.util.Map;

public interface AddressQueryService {
    /**
     * 分页查询
     *
     * @param queryForm 查询参数
     * @return PageResult<AddressVO>
     */
    PageResult<AddressVO> queryPage(AddressQueryForm queryForm);

    /**
     * 地址下拉查询
     *
     * @param addressSelect 入参
     * @return List<AddressEntity>
     */
    PageResult<AddressVO> queryAddress(AddressSelect addressSelect);

    /**
     * 根据地址id集合查询地址信息
     *
     * @param addressIdList 地址id集合
     * @return Map<Long, AreaEntity>
     */
    Map<Long, AddressEntity> queryByAddressIdsToMap(List<Long> addressIdList);

    /**
     * 根据地址name集合查询地址信息
     *
     * @param addressNameList 地址name集合
     * @return List<AddressEntity>
     */
    List<AddressEntity> queryByNames(List<String> addressNameList);


    /**
     * 根据地址name集合查询地址信息
     *
     * @param addressNameList 地址name集合
     * @return Map<Long, AddressEntity>
     */
    Map<String, AddressEntity> queryByNamesToMap(List<String> addressNameList);

    List<AddressExcelVO> queryAddressExcel();

    List<AddressExcelVO> queryAddressExcel2(String taskId);

    List<AddressExcelVO> queryAddressExcel3();

    /**
     * 统计数量
     * @param queryForm 查询参数
     * @return long
     */
    long addressCount(AddressQueryForm queryForm);

    /**
     * 导出
     * @param taskId 任务ID
     * @param queryForm 查询餐厨
     * @param response 请求
     */
    void exportAddress(String taskId,AddressQueryForm queryForm,HttpServletResponse response);

}
