Browse Source

档案管理 - 装盒

master
xuhuajiao 3 years ago
parent
commit
c497e58b58
  1. 18
      src/api/archivesManage/caseManage.js
  2. 17
      src/views/archivesManage/archivesList/module/archivesAnjuan/index.vue
  3. 77
      src/views/archivesManage/archivesList/module/packing/index.vue

18
src/api/archivesManage/caseManage.js

@ -37,4 +37,22 @@ export function barcodeIsRepeat(parameter) {
}) })
} }
// 档案盒列表
export function FetchInitCaseList(parameter) {
return request({
url: 'api/case/initCaseList',
method: 'get',
params: parameter
})
}
// 装盒
export function FetchCartoning(data) {
return request({
url: 'api/case/cartoning',
method: 'post',
data: data
})
}
export default { add, edit, del } export default { add, edit, del }

17
src/views/archivesManage/archivesList/module/archivesAnjuan/index.vue

@ -226,6 +226,11 @@ export default {
header(), header(),
form({}) form({})
], ],
provide() {
return {
caseData: this
}
},
inject: ['recycleMain'], inject: ['recycleMain'],
props: { props: {
selectedCategory: { selectedCategory: {
@ -395,7 +400,6 @@ export default {
this.query.archiveNo = this.anjuanQuery[this.anjuanInputSelect] this.query.archiveNo = this.anjuanQuery[this.anjuanInputSelect]
break break
} }
this.page.page = isNaN(page - 1) ? 0 : page - 1 this.page.page = isNaN(page - 1) ? 0 : page - 1
this.formVisible = false this.formVisible = false
this.getTableDisplayFieldsLoading = true this.getTableDisplayFieldsLoading = true
@ -515,15 +519,11 @@ export default {
toDelete(data) { toDelete(data) {
this.deleteData = data this.deleteData = data
this.deleteVisible = true this.deleteVisible = true
this.totalSumAll = 0
this.deleteData.map((item) => { if (!isNaN(item.children_num)) this.totalSumAll += item.children_num })
if (isNaN(this.totalSumAll)) {
return 0
}
this.getTotalSumAll()
}, },
getTotalSumAll() { getTotalSumAll() {
this.dataInfo.map((item) => { if (!isNaN(item.totalSum)) this.totalSumAll += item.totalSum })
this.totalSumAll = 0
this.selections.map((item) => { if (!isNaN(item.children_num)) this.totalSumAll += item.children_num })
if (isNaN(this.totalSumAll)) { if (isNaN(this.totalSumAll)) {
return 0 return 0
} }
@ -627,6 +627,7 @@ export default {
// //
handlePacking(data) { handlePacking(data) {
this.$refs.packing.packingVisible = true this.$refs.packing.packingVisible = true
this.getTotalSumAll()
}, },
// //
handlePartPacking(data) { handlePartPacking(data) {

77
src/views/archivesManage/archivesList/module/packing/index.vue

@ -7,7 +7,7 @@
<div class="head-container packing-head"> <div class="head-container packing-head">
<div class="head-search"> <div class="head-search">
<!-- 搜索 --> <!-- 搜索 -->
<el-input v-model="query[inputSelect]" clearable size="small" placeholder="请输入" style="width: 245px;" class="input-prepend filter-item" @keyup.enter.native="crud.toQuery">
<el-input v-model="caseQuery[inputSelect]" clearable size="small" placeholder="请输入" style="width: 245px;" class="input-prepend filter-item" @keyup.enter.native="getCaseList">
<el-select slot="prepend" v-model="inputSelect" style="width: 90px" @change="querySelect"> <el-select slot="prepend" v-model="inputSelect" style="width: 90px" @change="querySelect">
<el-option <el-option
v-for="item in queryOption" v-for="item in queryOption"
@ -17,10 +17,11 @@
/> />
</el-select> </el-select>
</el-input> </el-input>
<rrOperation />
<el-button class="filter-item" size="mini" type="success" icon="el-icon-search" @click="getCaseList">搜索</el-button>
</div> </div>
<div class="selct-data-head"> <div class="selct-data-head">
<p>数据来源文件 2条数据</p>
<p v-if="caseData.selectedCategory.isType === 5">数据来源文件 2条数据</p>
<p v-else>数据来源案卷 {{ caseData.selections.length }} 条数据 卷内 {{ caseData.totalSumAll }} 条数据</p>
</div> </div>
</div> </div>
<!--表格渲染--> <!--表格渲染-->
@ -33,13 +34,13 @@
@selection-change="selectionChangeHandler" @selection-change="selectionChangeHandler"
> >
<el-table-column type="index" label="序号" width="80" align="center" /> <el-table-column type="index" label="序号" width="80" align="center" />
<el-table-column prop="fileName" label="已装" min-width="100" align="center" />
<el-table-column prop="fileFormat" label="盒名称" min-width="60" align="center" />
<el-table-column prop="fileSize" label="TID" min-width="120" align="center" />
<el-table-column prop="fileDpi" label="条形码" min-width="120" align="center" />
<el-table-column prop="depositNum" label="已装" min-width="100" align="center" />
<el-table-column prop="caseName" label="盒名称" min-width="60" align="center" />
<el-table-column prop="tid" label="TID" min-width="120" align="center" />
<el-table-column prop="barcode" label="条形码" min-width="120" align="center" />
<el-table-column prop="create_date" label="操作" min-width="100" align="center"> <el-table-column prop="create_date" label="操作" min-width="100" align="center">
<template>
<el-button class="packing-handle-btn iconfont" @click="open"><svg-icon icon-class="zhuanghe" class="svg-arc-style" />装盒</el-button>
<template slot-scope="scope">
<el-button class="packing-handle-btn iconfont" @click="handleCartoning(scope.row)"><svg-icon icon-class="zhuanghe" class="svg-arc-style" />装盒</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -50,12 +51,14 @@
</template> </template>
<script> <script>
// FetchCartoning
import { FetchInitCaseList } from '@/api/archivesManage/caseManage'
import { header, form } from '@crud/crud' import { header, form } from '@crud/crud'
import rrOperation from '@crud/RR.operation'
import data from '../data.json'
// import data from '../data.json'
export default { export default {
name: 'Packing', name: 'Packing',
components: { rrOperation },
components: { },
inject: ['caseData'],
mixins: [ mixins: [
header(), header(),
form({}) form({})
@ -64,17 +67,20 @@ export default {
return { return {
tableData: [], tableData: [],
selections: [], selections: [],
tid: null,
caseName: null,
barcode: null,
caseQuery: {},
inputSelect: null, inputSelect: null,
queryOption: [ queryOption: [
{ value: '1', label: '盒名称' },
{ value: '2', label: 'TID' },
{ value: '3', label: '条形码' }
{ value: 'caseName', label: '盒名称' },
{ value: 'tid', label: 'TID' },
{ value: 'barcode', label: '条形码' }
], ],
packingVisible: false // packingVisible: false //
} }
}, },
created() { created() {
this.tableData = data.data
// select - // select -
this.inputSelect = this.queryOption[0].value this.inputSelect = this.queryOption[0].value
}, },
@ -83,6 +89,45 @@ export default {
querySelect(val) { querySelect(val) {
this.inputSelect = val this.inputSelect = val
}, },
getCaseList() {
switch (this.inputSelect) {
case 'caseName':
this.caseName = this.caseQuery[this.inputSelect]
break
case 'tid':
this.tid = this.caseQuery[this.inputSelect]
break
case 'barcode':
this.barcode = this.caseQuery[this.inputSelect]
break
}
const params = {
'tid': this.tid,
'caseName': this.caseName,
'barcode': this.barcode,
'page': 0,
'size': 10
}
FetchInitCaseList(params).then(res => {
console.log(res)
this.tableData = res.content
})
},
handleCartoning(row) {
console.log(this.caseData)
console.log(row)
const params = {
'archivesId': this.tid,
'archivesParentsId': this.caseName,
'caseId': row.id,
'caseName': row.caseName,
'categoryId': this.caseData.categoryId
}
console.log(params)
// FetchCartoning(params).then(res => {
// console.log(res)
// })
},
open() { open() {
this.$alert('装盒成功!', '提示', { this.$alert('装盒成功!', '提示', {
showConfirmButton: false showConfirmButton: false

Loading…
Cancel
Save