diff --git a/src/api/wms/expectin/index.ts b/src/api/wms/expectin/index.ts index 895ea616b..ab98fbc19 100644 --- a/src/api/wms/expectin/index.ts +++ b/src/api/wms/expectin/index.ts @@ -44,6 +44,11 @@ export const deleteExpectin = async (id: number) => { return await request.delete({ url: `/wms/expectin/delete?id=` + id }) } +// 批量删除预计出库存 +export const deleteExpectinIds = async (ids: string) => { + return await request.delete({ url: `/wms/expectin/deleteIds?ids=` + ids }) +} + // 导出预计入库存 Excel export const exportExpectin = async (params) => { if (params.isSearch) { diff --git a/src/api/wms/expectout/index.ts b/src/api/wms/expectout/index.ts index 819320553..64329d4d5 100644 --- a/src/api/wms/expectout/index.ts +++ b/src/api/wms/expectout/index.ts @@ -46,8 +46,8 @@ export const deleteExpectout = async (id: number) => { } // 批量删除预计出库存 -export const deleteExpectoutIds = async (ids: String) => { - return await request.delete({ url: `/wms/expectout/delete?ids=` + ids }) +export const deleteExpectoutIds = async (ids: string) => { + return await request.delete({ url: `/wms/expectout/deleteIds?ids=` + ids }) } // 导出预计出库存 Excel diff --git a/src/views/wms/inventoryManage/expectin/index.vue b/src/views/wms/inventoryManage/expectin/index.vue index b85574fd7..98e4ec8bd 100644 --- a/src/views/wms/inventoryManage/expectin/index.vue +++ b/src/views/wms/inventoryManage/expectin/index.vue @@ -160,9 +160,18 @@ const handleSelectionDelete = async ()=>{ if(rows.length==0){ return } - console.log('批量删除',rows) - // await ExpectoutApi.deleteExpectoutIds(rows.join(',')) //换入库接口 + try { + // 删除的二次确认 + await message.delConfirm() + tableObject.loading = true + // 发起删除 + console.log('批量删除',rows.join(',')) + await ExpectinApi.deleteExpectinIds(rows.join(',')) + message.success(t('common.delSuccess')) + tableObject.loading = false + // 刷新列表 getList() + } catch {} } // 列表-操作按钮 diff --git a/src/views/wms/inventoryManage/expectout/index.vue b/src/views/wms/inventoryManage/expectout/index.vue index 3adf1c7a4..973c12b43 100644 --- a/src/views/wms/inventoryManage/expectout/index.vue +++ b/src/views/wms/inventoryManage/expectout/index.vue @@ -160,10 +160,18 @@ const handleSelectionDelete = async ()=>{ if(rows.length==0){ return } - console.log('批量删除',rows) + try { + // 删除的二次确认 + await message.delConfirm() + tableObject.loading = true + // 发起删除 + console.log('批量删除',rows.join(',')) await ExpectoutApi.deleteExpectoutIds(rows.join(',')) + message.success(t('common.delSuccess')) + tableObject.loading = false + // 刷新列表 getList() - + } catch {} } // 列表-操作按钮 const butttondata = [