质量管理修改

This commit is contained in:
hzz 2024-04-18 19:12:45 +08:00
parent 88f4928763
commit cefa2eb8cf
2 changed files with 13 additions and 7 deletions

View File

@ -173,6 +173,7 @@ let bar_option = ref({
itemStyle: {
color: '#91cc75'
},
barWidth:'30%',
data: [0]
},
{
@ -186,6 +187,7 @@ let bar_option = ref({
itemStyle: {
color: '#c81623'
},
barWidth:'30%',
data: [0],
label: {
show: true,

View File

@ -51,12 +51,12 @@
<el-col :span="2">
<el-statistic :title="tLang('quality', '产品合格率')" :value="qualifiedRate" :precision="1"
:value-style="{ color: 'green' }"
:formatter="(val) => { return (totalQuality == 0 ? '0' :(((val / totalQuality) * 100).toFixed(1)||0)) + '%' }" />
:formatter="(val) => { return (totalQuality == 0 ? '0' : (((val / totalQuality) * 100).toFixed(1) || 0)) + '%' }" />
</el-col>
<el-col :span="2">
<el-statistic :title="tLang('quality', '产品不合格率')" :value="unqualifiedRate" :precision="1"
:value-style="{ color: 'red' }"
:formatter="(val) => { return (totalQuality == 0 ? '0' :(((val / totalQuality) * 100).toFixed(1)||0)) + '%' }" />
:formatter="(val) => { return (totalQuality == 0 ? '0' : (((val / totalQuality) * 100).toFixed(1) || 0)) + '%' }" />
</el-col>
<el-col :span="2">
<el-statistic :title="tLang('quality', '产品完成量')" :value="totalQuality" />
@ -94,11 +94,15 @@
</el-table-column>
<el-table-column :label="tLang('quality', '状态')" v-if="columns[7].visible" align="center" prop="state">
<template #default="scope">
<div>
<el-tag type="success" size="mini" v-if="scope.row.state === '0'">{{tLang('common','合格')}}</el-tag>
<el-tag type="danger" size="mini" v-else-if="scope.row.state === '1'">{{tLang('common','不合格')}}</el-tag>
<el-tag type="warning" size="mini" v-else>{{tLang('common','未完成')}}</el-tag>
</div>
<el-tooltip :content="scope.row.errorMsg" :disabled="scope.row.state !== '1'" placement="top-start" v-if="scope.row.userId !== 1">
<div style="cursor: pointer;">
<el-tag type="success" size="mini"
v-if="scope.row.state === '0'">{{ tLang('common', '合格') }}</el-tag>
<el-tag type="danger" size="mini"
v-else-if="scope.row.state === '1'">{{ tLang('common', '不合格') }}</el-tag>
<el-tag type="warning" size="mini" v-else>{{ tLang('common', '未完成') }}</el-tag>
</div>
</el-tooltip>
</template>
</el-table-column>
<!-- <el-table-column :label="tLang('quality','')操作" align="center" class-name="small-padding fixed-width">