4/2 youhua 1.3

dev2.5_scan
wangwei 3 months ago
parent f3fc70fdbc
commit f1178e4472

@ -5,7 +5,7 @@
:cell-style="{ padding: '0' }" :cell-style="{ padding: '0' }"
v-loading="preLoading" v-loading="preLoading"
> >
<el-table-column label="赋码状态" prop="cpmctymc"> <el-table-column label="赋码状态" prop="cpmctymc" width="120">
<template v-slot="scope"> <template v-slot="scope">
<div style="text-align: center;"> <div style="text-align: center;">
<el-tag :type="getStatusType(scope.row)" size="26"> <el-tag :type="getStatusType(scope.row)" size="26">
@ -14,32 +14,32 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="产品通用名" prop="cpmctymc"> <el-table-column label="产品通用名" prop="cpmctymc" width="220">
<template v-slot="scope"> <template v-slot="scope">
<div class="table-cell">{{ scope.row.cpmctymc }}</div> <div class="table-cell">{{ scope.row.cpmctymc }}</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="单据数量" prop="count"> <el-table-column label="单据数量" prop="count" width="100">
<template v-slot="scope"> <template v-slot="scope">
<div class="table-cell count">{{ scope.row.count }}</div> <div class="table-cell count">{{ scope.row.count }}</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="应扫码数量" prop="scanActCount" :min-width="120"> <el-table-column label="应扫码数量" prop="scanActCount" :min-width="120" width="180">
<template v-slot="scope"> <template v-slot="scope">
<div v-if="scope.row.autoTagStatus === 2" class="table-cell warning"> <div v-if="scope.row.autoTagStatus === 2" class="table-cell warning">
无需扫码 无需扫码
</div> </div>
<div v-else :class="getScanCountClass(scope.row)" class="table-cell"> <div v-else :class="getScanCountClass(scope.row)" class="table-cell">
{{ scope.row.scanCount }}/{{ scope.row.shouldCount }} {{ scope.row.scanCount }}/200
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="制剂规格" prop="prepnSpec"> <el-table-column label="制剂规格" prop="prepnSpec" width="200">
<template v-slot="scope"> <template v-slot="scope">
<div class="table-cell">{{ scope.row.prepnSpec }}</div> <div class="table-cell">{{ scope.row.prepnSpec }}</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="包装规格" prop="spec"> <el-table-column label="包装规格" prop="spec" width="200">
<template v-slot="scope"> <template v-slot="scope">
<div class="table-cell">{{ scope.row.spec }}</div> <div class="table-cell">{{ scope.row.spec }}</div>
</template> </template>
@ -51,13 +51,12 @@
<div class="table-cell">{{ scope.row.ybbm }}</div> <div class="table-cell">{{ scope.row.ybbm }}</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="批次号" prop="batchNo"> <el-table-column label="批次号" prop="batchNo" width="140">
<template v-slot="scope"> <template v-slot="scope">
<div class="table-cell">{{ scope.row.batchNo }}</div> <div class="table-cell">{{ scope.row.batchNo }}</div>
</template> </template>
</el-table-column> </el-table-column>
>
<el-table-column <el-table-column
fixed="right" fixed="right"
label="操作" label="操作"
@ -166,11 +165,11 @@ export default {
methods: { methods: {
async getPrescribeDetail() { async getPrescribeDetail() {
if (!this.hasPrescribeData) return if (!this.hasPrescribeData) return
this.preQuery.page = 1 this.preQuery.page = 1
this.preQuery.orderIdFk = this.prescribeData.billNo this.preQuery.orderIdFk = this.prescribeData.billNo
this.preLoading = true this.preLoading = true
try { try {
const res = await orderDetail(this.preQuery) const res = await orderDetail(this.preQuery)
if (res.code !== 20000) { if (res.code !== 20000) {
@ -203,8 +202,24 @@ export default {
getStatusType(row) { getStatusType(row) {
if (row.autoTagStatus === 2) return 'warning' if (row.autoTagStatus === 2) return 'warning'
if (row.scanActCount == null) return 'danger' if (row.scanActCount == null) return 'danger'
return row.scanActCount < row.count ? 'danger' : 'success' if (row.scanActCount < row.count) return 'danger'
if (row.scanActCount >= row.count) return 'success'
return "danger"
}, },
// getTagColor(row) {
// if (row.autoTagStatus === 2) {
// return 'warning' //
// }
// if (row.scanActCount == null){
// return 'danger' //
// }
// if (row.scanActCount < row.count) {
// return 'danger' //
// }
// if (row.scanActCount >= row.count) {
// return 'success' // 绿
// }
// },
getStatusText(row) { getStatusText(row) {
if (row.autoTagStatus === 2) return '预赋码' if (row.autoTagStatus === 2) return '预赋码'
@ -271,7 +286,7 @@ export default {
display: flex; display: flex;
align-items: center; align-items: center;
height: 100%; height: 100%;
min-height: 40px; min-height: 60px;
} }
.table-cell.count { .table-cell.count {

Loading…
Cancel
Save