|
|
@@ -16,7 +16,7 @@
|
|
|
:datasource="[form]"
|
|
|
>
|
|
|
<template v-slot:toolbar>
|
|
|
- 剩余样品总数:{{ form.remainingSampleCount }}
|
|
|
+ 剩余样品总数:{{ form.remainingSampleCount }}{{ form.measureUnit }}
|
|
|
</template>
|
|
|
|
|
|
<template v-slot:isRequired="{ column }">
|
|
|
@@ -48,6 +48,7 @@
|
|
|
@input="formSampleQuantityChange"
|
|
|
:disabled="type == 'detail'"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
<template v-slot:sampleNoQualifiedNumber="{ row }">
|
|
|
@@ -58,6 +59,7 @@
|
|
|
type="number"
|
|
|
:disabled="type == 'detail'"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
</ele-pro-table>
|
|
|
@@ -67,7 +69,7 @@
|
|
|
:datasource="tableData"
|
|
|
>
|
|
|
<template v-slot:toolbar>
|
|
|
- 当前质检剩余样品数:{{ getSampleQuantityCount }}
|
|
|
+ 当前质检剩余样品数:{{ getSampleQuantityCount }}{{ form.measureUnit }}
|
|
|
</template>
|
|
|
<template v-slot:qualityStandardType="{ row }">
|
|
|
{{ getDictValue('质检标准类型', row.qualityStandardType) }}
|
|
|
@@ -105,6 +107,7 @@
|
|
|
type="number"
|
|
|
@input="inputValue('sampleQuantity', row, $index)"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
|
|
|
@@ -116,6 +119,7 @@
|
|
|
type="number"
|
|
|
@input="inputValue('qualifiedQuantity', row, $index)"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
<template v-slot:noQualifiedQuantity="{ row, $index }">
|
|
|
@@ -126,6 +130,7 @@
|
|
|
type="number"
|
|
|
@input="inputValue('noQualifiedQuantity', row, $index)"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
<template v-slot:lossNumber="{ row, $index }">
|
|
|
@@ -137,6 +142,7 @@
|
|
|
@input="inputValue('lossNumber', row, $index)"
|
|
|
@click.native="curretNum = row.lossNumber"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
<template v-slot:lossNumberUnqualified="{ row, $index }">
|
|
|
@@ -148,6 +154,7 @@
|
|
|
@input="inputValue('lossNumberUnqualified', row, $index)"
|
|
|
@click.native="curretNum = row.lossNumberUnqualified"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
<template v-slot:retainedSampleQuantity="{ row, $index }">
|
|
|
@@ -159,6 +166,7 @@
|
|
|
@input="inputValue('retainedSampleQuantity', row, $index)"
|
|
|
@click.native="curretNum = row.retainedSampleQuantity"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
<template v-slot:retainedSampleUnqualified="{ row, $index }">
|
|
|
@@ -170,6 +178,7 @@
|
|
|
@input="inputValue('retainedSampleUnqualified', row, $index)"
|
|
|
@click.native="curretNum = row.retainedSampleUnqualified"
|
|
|
>
|
|
|
+ <template slot="append">{{ form.measureUnit }}</template>
|
|
|
</el-input>
|
|
|
</template>
|
|
|
<template v-slot:qualityResults="{ row, $index }">
|
|
|
@@ -343,10 +352,15 @@
|
|
|
prop: 'total',
|
|
|
align: 'center',
|
|
|
label: '总数量',
|
|
|
+ formatter: (row) => {
|
|
|
+ if (row.total) {
|
|
|
+ return row.total + this.form.measureUnit || '';
|
|
|
+ }
|
|
|
+ },
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 140,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'sampleQuantity',
|
|
|
headerSlot: 'isRequired',
|
|
|
slot: 'sampleQuantity',
|
|
|
@@ -355,7 +369,7 @@
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 140,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'sampleNoQualifiedNumber',
|
|
|
slot: 'sampleNoQualifiedNumber',
|
|
|
align: 'center',
|
|
|
@@ -368,6 +382,11 @@
|
|
|
headerSlot: 'isRequired',
|
|
|
slot: 'sampleQualifiedNumber',
|
|
|
align: 'center',
|
|
|
+ formatter: (row) => {
|
|
|
+ if (row.sampleQualifiedNumber) {
|
|
|
+ return row.sampleQualifiedNumber +(this.form.measureUnit || '')
|
|
|
+ }
|
|
|
+ },
|
|
|
label: '样品合格数',
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
@@ -376,6 +395,11 @@
|
|
|
prop: 'lossNumber',
|
|
|
slot: 'lossNumber',
|
|
|
align: 'center',
|
|
|
+ formatter: (row) => {
|
|
|
+ if (row.lossNumber) {
|
|
|
+ return row.lossNumber + (this.form.measureUnit || '')
|
|
|
+ }
|
|
|
+ },
|
|
|
label: '损耗数(合格品)',
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
@@ -384,6 +408,11 @@
|
|
|
prop: 'lossNumberUnqualified',
|
|
|
slot: 'lossNumberUnqualified',
|
|
|
align: 'center',
|
|
|
+ formatter: (row) => {
|
|
|
+ if (row.lossNumberUnqualified) {
|
|
|
+ return row.lossNumberUnqualified + (this.form.measureUnit || '')
|
|
|
+ }
|
|
|
+ },
|
|
|
label: '损耗数(不合格品)',
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
@@ -392,6 +421,11 @@
|
|
|
prop: 'retainedSampleQuantity',
|
|
|
slot: 'retainedSampleQuantity',
|
|
|
align: 'center',
|
|
|
+ formatter: (row) => {
|
|
|
+ if (row.retainedSampleQuantity) {
|
|
|
+ return row.retainedSampleQuantity +(this.form.measureUnit || '')
|
|
|
+ }
|
|
|
+ },
|
|
|
label: '留样数(合格品)',
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
@@ -400,6 +434,11 @@
|
|
|
prop: 'retainedSampleUnqualified',
|
|
|
slot: 'retainedSampleUnqualified',
|
|
|
align: 'center',
|
|
|
+ formatter: (row) => {
|
|
|
+ if (row.retainedSampleUnqualified) {
|
|
|
+ return row.retainedSampleUnqualified + (this.form.measureUnit || '')
|
|
|
+ }
|
|
|
+ },
|
|
|
label: '留样数(不合格品)',
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
@@ -521,7 +560,7 @@
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 120,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'sampleQuantity',
|
|
|
slot: 'sampleQuantity',
|
|
|
align: 'center',
|
|
|
@@ -529,7 +568,7 @@
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 120,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'qualifiedQuantity',
|
|
|
align: 'center',
|
|
|
slot: 'qualifiedQuantity',
|
|
|
@@ -537,7 +576,7 @@
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 130,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'noQualifiedQuantity',
|
|
|
slot: 'noQualifiedQuantity',
|
|
|
align: 'center',
|
|
|
@@ -545,7 +584,7 @@
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 140,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'lossNumber',
|
|
|
slot: 'lossNumber',
|
|
|
align: 'center',
|
|
|
@@ -553,7 +592,7 @@
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 150,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'lossNumberUnqualified',
|
|
|
slot: 'lossNumberUnqualified',
|
|
|
align: 'center',
|
|
|
@@ -561,7 +600,7 @@
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 140,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'retainedSampleQuantity',
|
|
|
slot: 'retainedSampleQuantity',
|
|
|
align: 'center',
|
|
|
@@ -569,7 +608,7 @@
|
|
|
showOverflowTooltip: true
|
|
|
},
|
|
|
{
|
|
|
- minWidth: 150,
|
|
|
+ minWidth: 180,
|
|
|
prop: 'retainedSampleUnqualified',
|
|
|
slot: 'retainedSampleUnqualified',
|
|
|
align: 'center',
|
|
|
@@ -640,11 +679,12 @@
|
|
|
computed: {
|
|
|
getSampleQuantityCount() {
|
|
|
return (
|
|
|
- this.form.sampleQuantity -
|
|
|
- (this.form.lossNumber || 0) -
|
|
|
- (this.form.lossNumberUnqualified || 0) -
|
|
|
- (this.form.retainedSampleQuantity || 0) -
|
|
|
- (this.form.retainedSampleUnqualified || 0)
|
|
|
+ (this.form.sampleQuantity * 100 -
|
|
|
+ (this.form.lossNumber * 100 || 0) -
|
|
|
+ (this.form.lossNumberUnqualified * 100 || 0) -
|
|
|
+ (this.form.retainedSampleQuantity * 100 || 0) -
|
|
|
+ (this.form.retainedSampleUnqualified * 100 || 0)) /
|
|
|
+ 100
|
|
|
);
|
|
|
}
|
|
|
},
|
|
|
@@ -697,6 +737,7 @@
|
|
|
data.sampleQuantity - data.sampleNoQualifiedNumber ||
|
|
|
0;
|
|
|
this.$set(this, 'form', JSON.parse(JSON.stringify(data)));
|
|
|
+ console.log(this.form, 'this.form');
|
|
|
this.tableData = JSON.parse(JSON.stringify(list));
|
|
|
this.tableData.forEach((item, index) => {
|
|
|
if (item.experimentCode) {
|