|
@@ -56,6 +56,7 @@
|
|
type="selection"
|
|
type="selection"
|
|
width="55"
|
|
width="55"
|
|
align="center"
|
|
align="center"
|
|
|
|
+ :selectable="tagSelectAble"
|
|
fixed
|
|
fixed
|
|
></el-table-column>
|
|
></el-table-column>
|
|
<el-table-column
|
|
<el-table-column
|
|
@@ -73,13 +74,6 @@
|
|
align="center"
|
|
align="center"
|
|
fixed
|
|
fixed
|
|
></el-table-column>
|
|
></el-table-column>
|
|
- <el-table-column
|
|
|
|
- label="流水号范围"
|
|
|
|
- prop="formatSerialNumberRange"
|
|
|
|
- min-width="200"
|
|
|
|
- header-align="center"
|
|
|
|
- align="center"
|
|
|
|
- ></el-table-column>
|
|
|
|
<el-table-column
|
|
<el-table-column
|
|
label="申领日期"
|
|
label="申领日期"
|
|
prop="formatDataTime"
|
|
prop="formatDataTime"
|
|
@@ -101,20 +95,6 @@
|
|
header-align="center"
|
|
header-align="center"
|
|
align="left"
|
|
align="left"
|
|
></el-table-column>
|
|
></el-table-column>
|
|
- <el-table-column
|
|
|
|
- label="标签类型"
|
|
|
|
- prop="tagTypeName"
|
|
|
|
- min-width="150"
|
|
|
|
- header-align="center"
|
|
|
|
- align="left"
|
|
|
|
- ></el-table-column>
|
|
|
|
- <el-table-column
|
|
|
|
- label="需求数量"
|
|
|
|
- prop="number"
|
|
|
|
- min-width="85"
|
|
|
|
- header-align="center"
|
|
|
|
- align="right"
|
|
|
|
- ></el-table-column>
|
|
|
|
<el-table-column
|
|
<el-table-column
|
|
label="费用(元)"
|
|
label="费用(元)"
|
|
prop="amount"
|
|
prop="amount"
|
|
@@ -145,8 +125,8 @@
|
|
<template v-slot="{ row }">
|
|
<template v-slot="{ row }">
|
|
<div class="flex center layout-gap">
|
|
<div class="flex center layout-gap">
|
|
<edit-button :data="row" :on-click="onOpenDetailEditorBtnClick" icon="el-icon-tickets">详情</edit-button>
|
|
<edit-button :data="row" :on-click="onOpenDetailEditorBtnClick" icon="el-icon-tickets">详情</edit-button>
|
|
- <edit-button :data="row" :on-click="onPreviewBtnClick" icon="el-icon-view">预览</edit-button>
|
|
|
|
- <edit-button :data="row" :on-click="onPrintBtnClick" icon="el-icon-view">
|
|
|
|
|
|
+ <edit-button :data="row" :on-click="onPreviewBtnClick" :disabled="row.tagApplyStateId ==='0'||row.tagApplyStateId ==='1'||row.tagApplyStateId ==='2'" icon="el-icon-view">预览</edit-button>
|
|
|
|
+ <edit-button :data="row" :on-click="onPrintBtnClick" :disabled="row.tagApplyStateId !=='3'" icon="el-icon-view">
|
|
<template #icon>
|
|
<template #icon>
|
|
<svg
|
|
<svg
|
|
viewBox="0 0 1024 1024"
|
|
viewBox="0 0 1024 1024"
|
|
@@ -188,14 +168,14 @@
|
|
<div class="tag-logo"><img src="@/assets/imgs/logo.png" width="100%" height="100%" /></div>
|
|
<div class="tag-logo"><img src="@/assets/imgs/logo.png" width="100%" height="100%" /></div>
|
|
<div class="flex column valign-center tag-materiel-info">
|
|
<div class="flex column valign-center tag-materiel-info">
|
|
<template v-if="qrData">
|
|
<template v-if="qrData">
|
|
- <div>{{ qrData.materielName }},</div>
|
|
|
|
- <div>{{ qrData.number }}</div>
|
|
|
|
|
|
+ <div>{{ qrData.materialName }},</div>
|
|
|
|
+ <div>{{ qrData.packageNumber }}</div>
|
|
</template>
|
|
</template>
|
|
</div>
|
|
</div>
|
|
<div class="flex center tag-provider-name">{{ qrData ? qrData.providerName : '' }}</div>
|
|
<div class="flex center tag-provider-name">{{ qrData ? qrData.providerName : '' }}</div>
|
|
</div>
|
|
</div>
|
|
<div class="tag-qr">
|
|
<div class="tag-qr">
|
|
- <qr-code-view v-if="qrData" :code="qrData.code"></qr-code-view>
|
|
|
|
|
|
+ <qr-code-view v-if="qrData" :code="qrData.qrCode"></qr-code-view>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -217,21 +197,73 @@ export default {
|
|
}),
|
|
}),
|
|
methods: {
|
|
methods: {
|
|
onOpenDetailEditorBtnClick (data) {
|
|
onOpenDetailEditorBtnClick (data) {
|
|
- this.onOpenEditorBtnClick(data, true)
|
|
|
|
|
|
+ this.$$request(TagCode.$$api.getDetail, data, this)
|
|
|
|
+ .then(data => {
|
|
|
|
+ if (data) {
|
|
|
|
+ this.$refs.editor.open(data)
|
|
|
|
+ }
|
|
|
|
+ }).catch(console.error).finally(() => {})
|
|
},
|
|
},
|
|
onCodeBtnClick () {
|
|
onCodeBtnClick () {
|
|
|
|
+ const { selectedList } = this
|
|
|
|
+ const { $$idProp } = this
|
|
|
|
|
|
|
|
+ const ids = selectedList
|
|
|
|
+ .filter(data => data.tagApplyStateId === '2')
|
|
|
|
+ .map(data => data[$$idProp])
|
|
|
|
+
|
|
|
|
+ this.$$request(this.$$api.setCode, ids).then((flag) => {
|
|
|
|
+ if (flag) {
|
|
|
|
+ this.$notify({
|
|
|
|
+ title: '成功',
|
|
|
|
+ message: '操作成功',
|
|
|
|
+ type: 'success',
|
|
|
|
+ position: 'bottom-right'
|
|
|
|
+ })
|
|
|
|
+ this.loadList()
|
|
|
|
+ }
|
|
|
|
+ }).catch(console.error).finally(() => {})
|
|
},
|
|
},
|
|
onBatchPrintBtnClick () {
|
|
onBatchPrintBtnClick () {
|
|
|
|
+ const { selectedList } = this
|
|
|
|
+ const { $$idProp } = this
|
|
|
|
|
|
|
|
+ const ids = selectedList
|
|
|
|
+ .filter(data => data.tagApplyStateId === '3')
|
|
|
|
+ .map(data => data[$$idProp])
|
|
|
|
+
|
|
|
|
+ this.$$request(this.$$api.print, ids).then((flag) => {
|
|
|
|
+ if (flag) {
|
|
|
|
+ this.$notify({
|
|
|
|
+ title: '成功',
|
|
|
|
+ message: '操作成功',
|
|
|
|
+ type: 'success',
|
|
|
|
+ position: 'bottom-right'
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ }).catch(console.error).finally(() => {})
|
|
},
|
|
},
|
|
onPreviewBtnClick (data) {
|
|
onPreviewBtnClick (data) {
|
|
this.$$request(this.$$api.getQrData, data[this.$$Target.$$idProp]).then(data => {
|
|
this.$$request(this.$$api.getQrData, data[this.$$Target.$$idProp]).then(data => {
|
|
this.qrData = Object.freeze(data)
|
|
this.qrData = Object.freeze(data)
|
|
}).catch(console.error).finally(() => {})
|
|
}).catch(console.error).finally(() => {})
|
|
},
|
|
},
|
|
- onPrintBtnClick () {
|
|
|
|
-
|
|
|
|
|
|
+ onPrintBtnClick (data) {
|
|
|
|
+ const ids = []
|
|
|
|
+ ids.push(data[this.$$Target.$$idProp])
|
|
|
|
+ this.$$request(this.$$api.print, ids).then((flag) => {
|
|
|
|
+ if (flag) {
|
|
|
|
+ this.$notify({
|
|
|
|
+ title: '成功',
|
|
|
|
+ message: '操作成功',
|
|
|
|
+ type: 'success',
|
|
|
|
+ position: 'bottom-right'
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ }).catch(console.error).finally(() => {})
|
|
|
|
+ },
|
|
|
|
+ tagSelectAble (row) {
|
|
|
|
+ return row.tagApplyStateId === '2' || row.tagApplyStateId === '3'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|