Browse Source

盘点管理

master
xuhuajiao 6 months ago
parent
commit
4c30e63bfd
  1. 9
      src/assets/styles/archives-manage.scss
  2. 3
      src/main.js
  3. 2
      src/views/home.vue
  4. 52
      src/views/visualCheck/checkManage/dataScreening/girdList.vue
  5. 39
      src/views/visualCheck/checkManage/dataScreening/module/export.vue
  6. 6
      src/views/visualCheck/venueDevice/area/index.vue
  7. 6
      src/views/visualCheck/venueDevice/bookshelf/index.vue
  8. 8
      src/views/visualCheck/venueDevice/floor/index.vue

9
src/assets/styles/archives-manage.scss

@ -890,13 +890,14 @@
position: relative;
}
.double-click-btn{
position: absolute;
right: 0;
top: 0;
// position: absolute;
// right: 0;
// top: 0;
display: flex;
justify-content: flex-start;
justify-content: flex-end;
align-items: center;
line-height: 26px;
margin: -6px 0 4px 0;
span{
display: inline-block;
font-size: 12px;

3
src/main.js

@ -70,6 +70,9 @@ Vue.prototype.$x2js = new X2js() // 创建x2js对象,挂到vue原型上
Vue.config.productionTip = false
// 江夏图书馆馆代码
Vue.prototype.libcode = '1501'
new Vue({
el: '#app',
router,

2
src/views/home.vue

@ -91,7 +91,7 @@
<h3 class="home-item-title">
流通统计
</h3>
<div class="refresh-date">2024-11-28 09:46</div>
<!-- <div class="refresh-date">2024-11-28 09:46</div> -->
<div class="chart-wrapper" style="padding: 0 10px; margin-top: -10px;">
<bookSwiper ref="bookSwiperRefs" />
</div>

52
src/views/visualCheck/checkManage/dataScreening/girdList.vue

@ -65,7 +65,7 @@
</template>
<template v-slot:right>
<!-- @click="doExport(crud.selections)" -->
<el-button :loading="crud.downloadLoading" size="mini">
<el-button :loading="crud.downloadLoading" size="mini" @click="doExport(3)">
<i class="iconfont icon-daochu" />
导出
</el-button>
@ -149,8 +149,7 @@
<i class="iconfont icon-sulan" />
盘点照片
</el-button> -->
<div style="height: 260px; background-color: #ccc; overflow: hidden; position: relative;" @click="showAllImg">
<div v-if="detailCurrent && detailCurrent.onShelfNum" style="height: 260px; background-color: #ccc; overflow: hidden; position: relative;" @click="handleViewImg">
<img style="display:block; width: 100%;" :src="bigImg" alt="">
<span style="position: absolute; top: 0; right: 0; padding: 4px 6px; color: #fff; background-color: rgba(3,72,243,.8); border-radius: 4px;">单击可查看所有图片</span>
</div>
@ -216,6 +215,7 @@
</div>
</el-dialog>
<eForm ref="eform" />
<exportForm ref="exportform" />
</div>
</template>
@ -228,12 +228,12 @@ import CRUD, { presenter, header, crud } from '@crud/crud'
import crudOperation from '@crud/CRUD.operation'
import { mapGetters } from 'vuex'
import eForm from './module/form'
import exportForm from './module/export'
import { parseTime, saveAs, getBlob } from '@/utils/index'
// import qs from 'qs'
export default {
name: 'DataScreening',
components: { crudOperation, eForm },
components: { crudOperation, eForm, exportForm },
cruds() {
return CRUD({ title: '架位盘点', url: 'api/libraryRegion/initLibraryRegionList', crudMethod: { ...crudRegion }, sort: [], optShow: {
add: false,
@ -468,23 +468,27 @@ export default {
})
},
toAdd(type, item) {
if (item.isCheck) {
if (type === 5) {
this.$refs.eform.formVisible = true
if (type === 5) {
this.$refs.eform.form.shelfId = this.bookShelfDetails.id
this.$refs.eform.form.gridShelf = this.gridShelf
this.$refs.eform.form.stockRegion = this.floorName + this.regionName + this.bookShelfDetails.shelfName + this.gridShelf + '架'
} else {
this.$refs.eform.form.shelfId = this.bookShelfDetails.id
this.$refs.eform.form.gridShelf = this.gridShelf
this.$refs.eform.form.stockRegion = this.floorName + this.regionName + this.bookShelfDetails.shelfName + this.gridShelf + '架'
} else {
if (item.isCheck) {
this.$refs.eform.formVisible = true
this.$refs.eform.form.shelfId = null
this.$refs.eform.form.gridShelf = null
this.$refs.eform.form.gridId = item.id
this.$refs.eform.form.stockRegion = item.gridName
} else {
this.$message({ message: '当前层位不可盘点', type: 'error', offset: 8 })
}
this.$refs.eform.setData(type)
} else {
this.$message({ message: '当前层位不可盘点', type: 'error', offset: 8 })
}
this.$refs.eform.setData(type)
},
doExport(type) {
this.$refs.exportform.formExportVisible = true
this.$refs.exportform.type = 3
},
handleCellCurrent(item, index) {
this.cellIndex = index
@ -504,7 +508,11 @@ export default {
this.detailVisible = true
this.detailTable = item.books
this.detailCurrent = item
this.handleViewImg()
if (this.detailCurrent.onShelfNum) {
this.bigImg = `${this.baseApi}/api/fileRelevant/getImg?imgId=/${this.libcode}/${this.billNoImg}/${this.detailCurrent.gridCode}/img_result/result_LSD_compressed.jpg`
} else {
this.bigImg = ''
}
},
setActiveItem(index) {
this.$refs.carousel.setActiveItem(index)
@ -518,20 +526,20 @@ export default {
// http://192.168.99.67:12010/api/fileRelevant/getImg?imgId=/1501/PD20250108013/010011015/img_result/result_LSD.jpg
// http://192.168.99.67:12010/api/fileRelevant/getImg?imgId=/1501/PD20250108013/010011015/img_result/result_cut_1_compressed.jpg
this.bookImgData = []
// this.detailImgVisible = true
this.detailImgVisible = true
const params = {
'billNo': this.billNoImg,
'gridId': this.detailCurrent.id
}
FetchIsGoodcutByBillNoAndGridId(params)
.then(res => {
const baseUrl = `${this.baseApi}/api/fileRelevant/getImg?imgId=/${this.billNoImg}/${this.detailCurrent.gridCode}/img_result/`
const baseUrl = `${this.baseApi}/api/fileRelevant/getImg?imgId=/${this.libcode}/${this.billNoImg}/${this.detailCurrent.gridCode}/img_result/`
const commonImgs = [
`${baseUrl}result_LSD_compressed.jpg`,
`${baseUrl}result_cut_1_compressed.jpg`,
`${baseUrl}result_cut_2_compressed.jpg`
]
this.bigImg = commonImgs[0]
this.$refs.carousel.setActiveItem(0)
if (res) {
this.bookImgData = commonImgs
} else {
@ -542,10 +550,6 @@ export default {
console.error(error)
})
},
showAllImg() {
this.detailImgVisible = true
this.$refs.carousel.setActiveItem(0)
},
handleDownloadImg() {
this.downImgLoading = true
const idsArray = []
@ -635,7 +639,7 @@ export default {
}
.tab-content{
width: 100%;
min-height: calc(100vh - 196px) !important;
min-height: calc(100vh - 232px) !important;
.tab-nav{
flex: 1;
}

39
src/views/visualCheck/checkManage/dataScreening/module/export.vue

@ -1,5 +1,5 @@
<template>
<el-dialog append-to-body :close-on-click-modal="false" :modal-append-to-body="false" :before-close="handleCloseForm" :visible="formExportVisible" title="导出数据">
<el-dialog class="export-dialog" append-to-body :close-on-click-modal="false" :modal-append-to-body="false" :before-close="handleCloseForm" :visible="formExportVisible" title="导出数据">
<span class="dialog-right-top" />
<span class="dialog-left-bottom" />
<div class="setting-dialog">
@ -12,7 +12,7 @@
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="handleCloseForm">取消</el-button>
<el-button :loading="saveLoading" type="primary" @click="handleComfiredEditing">继续</el-button>
<el-button :loading="saveLoading" type="primary" @click="handleComfiredExport">继续</el-button>
</div>
</div>
</el-dialog>
@ -20,6 +20,7 @@
<script>
import CRUD, { form } from '@crud/crud'
// import { parseTime, saveAs, getBlob } from '@/utils/index'
const defaultForm = { exportRadio: 1 }
export default {
@ -49,36 +50,31 @@ export default {
regionId: null,
shelfId: null,
gridShelf: null,
gridId: null,
stockTypeName: '全量盘点'
gridId: null
},
2: {
regionId: this.form.regionId || null,
shelfId: null,
gridShelf: null,
gridId: null,
stockTypeName: '区域盘点'
gridId: null
},
4: {
regionId: null,
shelfId: this.form.shelfId || null,
gridShelf: null,
gridId: null,
stockTypeName: '书架盘点'
gridId: null
},
5: {
regionId: null,
shelfId: this.form.shelfId || null,
gridShelf: this.form.gridShelf || null,
gridId: null,
stockTypeName: '架位盘点'
gridId: null
},
6: {
regionId: null,
shelfId: null,
gridShelf: null,
gridId: this.form.gridId || null,
stockTypeName: '层位盘点'
gridId: this.form.gridId || null
}
}
console.log(typeMap)
@ -89,10 +85,22 @@ export default {
// this.form = {}
this.formExportVisible = false
},
handleComfiredEditing() {
handleComfiredExport() {
this.$refs['form'].validate((valid) => {
if (valid) {
this.saveLoading = true
// const params = {
// 'imgIds': idsArray
// }
// const url = this.baseApi + '/api/fileRelevant/uploadImgs' + '?' + new URLSearchParams(params).toString()
// getBlob(url, (blob) => {
// const fileName = this.billNoImg + '-' + parseTime(new Date()) + '.zip'
// saveAs(blob, fileName)
// this.saveLoading = false
// this.handleCloseForm()
// })
// crudStockTaskLog.add(this.form).then((res) => {
// if (res.code !== 500) {
// this.$message({ message: '', type: 'success', offset: 8 })
@ -120,4 +128,9 @@ export default {
</script>
<style lang="scss" scoped>
.export-dialog{
::v-deep .el-dialog{
width: 400px;
}
}
</style>

6
src/views/visualCheck/venueDevice/area/index.vue

@ -31,12 +31,13 @@
</crudOperation>
</div>
<div>
<div class="double-click-btn"><i class="iconfont icon-zhuyi-lan" /><span>双击列表数据查看对应书架</span></div>
<el-table
ref="table"
v-loading="crud.loading"
:data="crud.data"
style="width: 100%;"
height="540"
height="506"
@selection-change="crud.selectionChangeHandler"
@row-click="clickRowHandler"
@row-dblclick="onRowDblclick"
@ -521,4 +522,7 @@ export default {
</script>
<style lang="scss" scoped>
.tab-content{
min-height: calc(100vh - 232px) !important;
}
</style>

6
src/views/visualCheck/venueDevice/bookshelf/index.vue

@ -28,12 +28,13 @@
</crudOperation>
</div>
<div>
<div class="double-click-btn"><i class="iconfont icon-zhuyi-lan" /><span>双击列表数据查看对应架位</span></div>
<el-table
ref="table"
v-loading="crud.loading"
:data="crud.data"
style="width: 100%;"
height="540"
height="507"
@selection-change="selectionChangeHandler"
@row-dblclick="onRowDblclick"
@row-click="clickRowHandler"
@ -675,4 +676,7 @@ export default {
</script>
<style lang="scss" scoped>
.tab-content{
min-height: calc(100vh - 232px) !important;
}
</style>

8
src/views/visualCheck/venueDevice/floor/index.vue

@ -27,13 +27,14 @@
</template>
</crudOperation>
</div>
<div>
<div style="position: relative;">
<div class="double-click-btn"><i class="iconfont icon-zhuyi-lan" /><span>双击列表数据查看对应区域</span></div>
<el-table
ref="table"
v-loading="crud.loading"
:data="crud.data"
style="width: 100%;"
height="540"
height="506"
@selection-change="crud.selectionChangeHandler"
@row-click="clickRowHandler"
@row-dblclick="onRowDblclick"
@ -275,4 +276,7 @@ export default {
</script>
<style lang="scss" scoped>
.tab-content{
min-height: calc(100vh - 232px) !important;
}
</style>
Loading…
Cancel
Save