From af3f9aac7a437875da00aaffc628ff38dfc63e8f Mon Sep 17 00:00:00 2001
From: zouyu <2723363702@qq.com>
Date: 星期五, 25 七月 2025 17:14:09 +0800
Subject: [PATCH] Merge branch 'dev_ztns' into dev_y_ztns
---
src/api/business/unqualifiedHandler.js | 8 ++++
src/views/statisticalCharts/inspectionItemWarning/index.vue | 88 +++++++++++++++++++++++++++++++++++++++++++-
src/views/business/unpass/components/OAProcess.vue | 4 +
3 files changed, 97 insertions(+), 3 deletions(-)
diff --git a/src/api/business/unqualifiedHandler.js b/src/api/business/unqualifiedHandler.js
index 042d095..b736cc1 100644
--- a/src/api/business/unqualifiedHandler.js
+++ b/src/api/business/unqualifiedHandler.js
@@ -25,3 +25,11 @@
data: query,
});
}
+//鏌ョ湅OA娴佺▼
+export function getOaFlow(query) {
+ return request({
+ url: "/unqualifiedHandler/getOaFlow",
+ method: "get",
+ params: query,
+ });
+}
diff --git a/src/views/business/unpass/components/OAProcess.vue b/src/views/business/unpass/components/OAProcess.vue
index b26260c..5b0b616 100644
--- a/src/views/business/unpass/components/OAProcess.vue
+++ b/src/views/business/unpass/components/OAProcess.vue
@@ -101,6 +101,8 @@
</template>
<script>
+import {getOaFlow} from "../../../../api/business/unqualifiedHandler";
+
export default {
name: "OAProcess",
// import 寮曞叆鐨勭粍浠堕渶瑕佹敞鍏ュ埌瀵硅薄涓墠鑳戒娇鐢�
@@ -156,7 +158,7 @@
// 鏂规硶闆嗗悎
methods: {
getInfo (id) {
- this.$axios.post(this.$api.unqualifiedHandler.getOaFlow, {
+ getOaFlow({
id: id
}).then(res => {
if (res.code === 200) {
diff --git a/src/views/statisticalCharts/inspectionItemWarning/index.vue b/src/views/statisticalCharts/inspectionItemWarning/index.vue
index 448aa29..22585f5 100644
--- a/src/views/statisticalCharts/inspectionItemWarning/index.vue
+++ b/src/views/statisticalCharts/inspectionItemWarning/index.vue
@@ -10,12 +10,28 @@
<el-row>
<el-col :span="24">
<div class="inspection-card">
- <div class="title">妫�楠岄」鍋忓樊棰勮鏁版嵁璇︽儏</div>
+ <div class="title">妫�楠岄」骞冲潎鍊煎亸宸璀︽暟鎹鎯�</div>
<Echarts ref="chart"
:chartStyle="chartStyle"
:grid="grid"
:options="echartsOptions"
:series="echartsSeries"
+ :tooltip="tooltip"
+ :xAxis="xAxis"
+ :yAxis="yAxis"
+ style="height: 40vh;"></Echarts>
+ </div>
+ </el-col>
+ </el-row>
+ <el-row>
+ <el-col :span="24">
+ <div class="inspection-card">
+ <div class="title">妫�楠岄」瑕佹眰鍊煎亸宸璀︽暟鎹鎯�</div>
+ <Echarts ref="chart"
+ :chartStyle="chartStyle"
+ :grid="grid"
+ :options="echartsOptions"
+ :series="echartsSeries1"
:tooltip="tooltip"
:xAxis="xAxis"
:yAxis="yAxis"
@@ -138,6 +154,29 @@
markPoint: {}
},
],
+ echartsSeries1: [
+ {
+ name: '妫�娴嬪��',
+ type: 'line',
+ smooth: true,
+ tooltip: {
+ valueFormatter: function (value) {
+ return value;
+ }
+ },
+ label: {
+ show: true,
+ position: 'top',
+ formatter: function (value) {
+ return value.value;
+ },
+ distance: 14
+ },
+ data: [],
+ markArea: {},
+ markPoint: {}
+ },
+ ],
xAxis: [
{
type: 'category',
@@ -186,7 +225,6 @@
// 鏌ヨ鎶樼嚎鍥句俊鎭�
rowClick (row) {
selectDeviationWarning({deviationWarningId: row.deviationWarningId}).then(res => {
- console.log('res---', res)
if (res.data === null) {
this.$message.warning('鏆傛棤鏁版嵁')
return
@@ -194,7 +232,9 @@
let lineData = []
let xAxis = []
let markAreas = []; // 瀛樺偍 markArea 鐨勬暟缁�
+ let markAreas1 = [];
let markPoints = [];
+ let markPoints1 = [];
const sampleCodeCount = {};
res.data.forEach((item, index) => {
lineData.push(item.testValue)
@@ -242,6 +282,39 @@
borderRadius: 4
}
});
+ }// 濡傛灉 isIssueAsked 涓� 1锛屽垯鍦ㄦ绱㈠紩澶勬坊鍔犱竴涓� markAreas1
+ if (item.isIssueAsked == 1) {
+ const startColumn = index > 0 ? xAxis[index - 1] : xAxis[index]; // 璧风偣锛氬墠涓�鍒楁垨褰撳墠鍒�
+ const endColumn = xAxis[index]; // 缁堢偣锛氬綋鍓嶅垪
+
+ markAreas.push([
+ {
+ xAxis: startColumn, // 浠庡墠涓�鍒楀紑濮�
+ },
+ {
+ xAxis: endColumn, // 鍒板綋鍓嶅垪缁撴潫
+ }
+ ]);
+ markPoints1.push({
+ name: '闂鐐�',
+ coord: [item.sampleCode, item.testValue],
+ value: item.testValue,
+ itemStyle: {
+ color: 'rgba(255, 173, 177, 0.8)'
+ },
+ label: {
+ show: true,
+ formatter: function(params) {
+ return params.value; // 鑷畾涔夋爣绛惧唴瀹�
+ },
+ color: 'black', // 鏍囩鏂囧瓧棰滆壊
+ fontSize: 12,
+ distance: 5, // 璋冩暣鏍囩涓庢皵娉$殑璺濈
+ padding: [0,0],
+ backgroundColor: 'rgba(255, 173, 177, 0.8)', // 鏍囩鑳屾櫙鑹插強閫忔槑搴�
+ borderRadius: 4
+ }
+ });
}
})
this.xAxis[0].data = xAxis
@@ -256,6 +329,17 @@
this.echartsSeries[0].markPoint = {
data: markPoints
};
+ this.echartsSeries1[0].data = lineData
+ // 鏇存柊 markAreas1 閰嶇疆
+ this.echartsSeries1[0].markAreas1 = {
+ itemStyle: {
+ color: 'rgba(255, 173, 177, 0.4)' // 璁剧疆鑳屾櫙棰滆壊
+ },
+ data: markAreas1 // 鍔ㄦ�佺敓鎴愮殑 markAreas1 鏁版嵁
+ };
+ this.echartsSeries1[0].markPoint = {
+ data: markPoints1
+ };
})
},
// 閲嶇疆
--
Gitblit v1.9.3