Browse Source

HL-5257计划外出库撤销

hella_online_20240803
zhaoyiran 3 months ago
parent
commit
06ec1011ae
  1. 5
      src/api/wms/unplannedissueRecordMain/index.ts
  2. 20
      src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRecordMain/index.vue
  3. 10
      src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRecordMain/unplannedissueRecordMain.data.ts

5
src/api/wms/unplannedissueRecordMain/index.ts

@ -59,3 +59,8 @@ export const exportUnplannedissueRecordMain = async (params) => {
export const importTemplate = () => {
return request.download({ url: '/wms/unplannedissue-record-main/get-import-template' })
}
// 撤销
export const revoke = async (id: number) => {
return await request.get({ url: `/wms/unplannedissue-record-main/revoke?id=` + id })
}

20
src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRecordMain/index.vue

@ -128,17 +128,33 @@ const buttonBaseClick = (val, item) => {
}
}
const isShowRevokeButton = (row,val) => {
if (val.indexOf(row.revokeFlag) > -1) {
return false
} else {
return true
}
}
// -
const butttondata = (row,$index) => {
const findIndex = row['masterId']?tableObject.tableList.findIndex(item=>item['masterId'] == row['masterId']):-1
if(findIndex>-1&&findIndex<$index){
return []
return [
defaultButtons.backoutBtn({hide:isShowRevokeButton(row,['FALSE'])}) //
]
}
return []
return [
defaultButtons.backoutBtn({hide:isShowRevokeButton(row,['FALSE'])}) //
]
}
// -
const buttonTableClick = async (val, row) => {
if (val == 'backout') { //
await UnplannedissueRecordMainApi.revoke(row.masterId)
buttonBaseClick('refresh',null)
}
}
//
const { wsCache } = useCache()

10
src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRecordMain/unplannedissueRecordMain.data.ts

@ -481,6 +481,16 @@ export const UnplannedissueRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
}
}
},
{
label: '操作',
field: 'action',
isDetail: false,
isForm: false,
table: {
width: 120,
fixed: 'right'
},
}
]))
//表单校验

Loading…
Cancel
Save