import request from "@/utils/request";

// 获得入库业务 报废入库
export function getIncomingScrap(id) {
    return request({
        url: "/rtkwms/incoming-scrap/get?id=" + id,
        method: "get",
    });
}

// 获得入库业务 报废入库分页--待入库
export function getIncomingScrapPage(query) {
    return request({
        url: "/rtkwms/incoming-scrap/toStockPage",
        method: "get",
        params: query,
    });
}
// 获得入库业务 报废入库分页--已入库
export function getIncomingScrapStockedPage(query) {
    return request({
        url: "/rtkwms/incoming-scrap/stockedPage",
        method: "get",
        params: query,
    });
}
// 获得入库业务 报废入库明细分页--待入库
export function getIncomingScrapTostockDetailPage(query) {
    return request({
        url: "/rtkwms/incoming-scrap-detail/toStockPage",
        method: "get",
        params: query,
    });
}
// 获得入库业务 报废入库明细分页--已入库
export function getIncomingScrapStockedDetailPage(query) {
    return request({
        url: "/rtkwms/incoming-scrap-detail/stockedPage",
        method: "get",
        params: query,
    });
}
// 获得入库方案列表
export function getToStockListPage(query) {
    return request({
        url: "/rtkwms/incoming-scrap-detail/toStockListPage",
        method: "get",
        params: query,
    });
}

// 导出入库业务 报废入库 Excel
export function exportIncomingScrapExcel(query) {
    return request({
        url: "/rtkwms/incoming-scrap/export-excel",
        method: "get",
        params: query,
        responseType: "blob",
    });
}
// 确认入库
export function createBatchIncomingScrapStock(data) {
    return request({
        url: "/rtkwms/incoming-scrap-detail/createBatch",
        method: "post",
        data: data,
    });
}