From be5c87afd82e50b6ef58a24e06a7a6cb36fb5007 Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期四, 19 三月 2026 17:54:46 +0800
Subject: [PATCH] #仿真优化
---
src/main/webapp/components/DevpCard.js | 26 ++++++++++++++++++++++++++
1 files changed, 26 insertions(+), 0 deletions(-)
diff --git a/src/main/webapp/components/DevpCard.js b/src/main/webapp/components/DevpCard.js
index c2a89b3..d8daf18 100644
--- a/src/main/webapp/components/DevpCard.js
+++ b/src/main/webapp/components/DevpCard.js
@@ -32,6 +32,7 @@
<div class="mc-action-row">
<button type="button" class="mc-btn" @click="controlCommand">涓嬪彂</button>
<button type="button" class="mc-btn mc-btn-soft" @click="resetCommand">澶嶄綅</button>
+ <button v-if="showFakeTraceEntry" type="button" class="mc-btn mc-btn-ghost" @click="openFakeTracePage">浠跨湡杞ㄨ抗</button>
</div>
</div>
</div>
@@ -113,6 +114,7 @@
targetStationId: ""
},
barcodePreviewCache: {},
+ showFakeTraceEntry: false,
pageSize: this.readOnly ? 24 : 12,
currentPage: 1,
timer: null
@@ -155,6 +157,7 @@
},
created: function () {
MonitorCardKit.ensureStyles();
+ this.loadFakeProcessStatus();
if (this.autoRefresh) {
this.timer = setInterval(this.getDevpStateInfo, 1000);
}
@@ -223,9 +226,32 @@
this.afterDataRefresh();
}
},
+ loadFakeProcessStatus: function () {
+ if (this.readOnly || !window.$ || typeof baseUrl === "undefined") {
+ this.showFakeTraceEntry = false;
+ return;
+ }
+ $.ajax({
+ url: baseUrl + "/openapi/getFakeSystemRunStatus",
+ method: "get",
+ success: function (res) {
+ var data = res && res.data ? res.data : null;
+ this.showFakeTraceEntry = !!(data && data.isFake);
+ }.bind(this),
+ error: function () {
+ this.showFakeTraceEntry = false;
+ }.bind(this)
+ });
+ },
openControl: function () {
this.showControl = !this.showControl;
},
+ openFakeTracePage: function () {
+ if (!this.showFakeTraceEntry) {
+ return;
+ }
+ window.open(baseUrl + "/views/watch/fakeTrace.html", "_blank");
+ },
buildDetailEntries: function (item) {
return [
{ label: "缂栧彿", value: this.orDash(item.stationId) },
--
Gitblit v1.9.1