diff --git a/src/api/stockTask/index.js b/src/api/stockTask/index.js index c4dd0de..d1bbba5 100644 --- a/src/api/stockTask/index.js +++ b/src/api/stockTask/index.js @@ -164,4 +164,13 @@ export function FetchNewBillByGridId(params) { }) } -export default { add, edit, del, FetchUpdateStockTaskStatus, FetchInitSuggestTilting, FetchInitSetting, FetchEditSetting, FetchInitHomeInfo, FetchInitStockInfo, FetchInitHotBookList, FetchInitHotShelfList, FetchInitBookDetailsByGrids, FetchAITerminalStatusQuery, FetchBillByShelfIdAndGridShelf, FetchIsGoodcutByBillNoAndGridId, FetchInitErrorProbaDesc, FetchShowByBillIdAndShelfIdAndGridShelf, FetchStartStopBookAIService, FetchMoveBills, FetchNewBillByGridId } +// 手动上架 +export function FetchManualShelving(data) { + return request({ + url: 'api/stocktask-task/manualShelving', + method: 'post', + data + }) +} + +export default { add, edit, del, FetchUpdateStockTaskStatus, FetchInitSuggestTilting, FetchInitSetting, FetchEditSetting, FetchInitHomeInfo, FetchInitStockInfo, FetchInitHotBookList, FetchInitHotShelfList, FetchInitBookDetailsByGrids, FetchAITerminalStatusQuery, FetchBillByShelfIdAndGridShelf, FetchIsGoodcutByBillNoAndGridId, FetchInitErrorProbaDesc, FetchShowByBillIdAndShelfIdAndGridShelf, FetchStartStopBookAIService, FetchMoveBills, FetchNewBillByGridId, FetchManualShelving } diff --git a/src/views/dashboard/PanelGroup.vue b/src/views/dashboard/PanelGroup.vue index 2a9e520..11541fd 100644 --- a/src/views/dashboard/PanelGroup.vue +++ b/src/views/dashboard/PanelGroup.vue @@ -63,7 +63,10 @@
离线设备
- +
+ + +
@@ -73,6 +76,7 @@ diff --git a/src/views/visualCheck/checkManage/bookSearch/index.vue b/src/views/visualCheck/checkManage/bookSearch/index.vue index 7b192df..8af77c4 100644 --- a/src/views/visualCheck/checkManage/bookSearch/index.vue +++ b/src/views/visualCheck/checkManage/bookSearch/index.vue @@ -237,6 +237,8 @@ import { FetchLibraryFloorListAll } from '@/api/floor/index' import { FetchRegionAllByFloor } from '@/api/area/index' import { FetchShelfAllByRegionId, FetchShelfGridAllByShelfId } from '@/api/shelf/index' import crudBook from '@/api/book/index' +import { FetchManualShelving } from '@/api/stockTask/index' + import CRUD, { presenter, header, form, crud } from '@crud/crud' import crudOperation from '@crud/CRUD.operation' import rrOperation from '@crud/RR.operation' @@ -300,8 +302,8 @@ export default { imageUrl: defaultImg, selectBookData: [], selectShelfVal: '', - selectGridVal: null - + selectGridVal: null, + positionVisible: false } }, computed: { @@ -407,18 +409,23 @@ export default { saveBatchUp() { this.$refs.form.validate((valid) => { if (valid) { + const ids = [] + this.selectBookData.forEach(val => { + ids.push(val.id) + }) const params = { 'gridId': this.selectGridVal.id, - 'stockRegion': this.selectShelfVal + '-' + removeQUPrefix(this.selectGridVal.gridName) + 'ids': ids } console.log('params', params) - - // crudBook.FetchFastDownShelf(params).then(() => { - // this.$message({ message: '批量上架成功', type: 'success', offset: 8 }) - // this.crud.refresh() - // }).catch(err => { - // console.log(err) - // }) + FetchManualShelving(params).then(() => { + this.$message({ message: '批量上架成功', type: 'success', offset: 8 }) + this.crud.refresh() + this.handleCloseDialog() + }).catch(err => { + console.log(err) + this.addBookShelfVisible = false + }) } else { console.log('error submit!!') return false @@ -471,6 +478,15 @@ export default { }, handleCloseDialog() { this.addBookShelfVisible = false + this.positionVisible = false + this.detailVisible = false + this.clearFormData() + }, + clearFormData() { + if (this.$refs.form) { + this.crud.cancelCU() + this.$refs.form.resetFields() + } } }