From a8e8b92a28fd7b48b6eeae2f2f859ba381a39614 Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期六, 07 三月 2026 09:58:47 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/asrs/controller/WatchStationColorController.java | 2
src/main/webapp/components/MapCanvas.js | 5
/dev/null | 661 -------------------------------------------------------
src/main/webapp/views/watch/console.html | 1
src/main/webapp/static/js/watch/stationColorConfig.js | 2
5 files changed, 4 insertions(+), 667 deletions(-)
diff --git a/src/main/java/com/zy/asrs/controller/WatchStationColorController.java b/src/main/java/com/zy/asrs/controller/WatchStationColorController.java
index e8bd67b..ce0c190 100644
--- a/src/main/java/com/zy/asrs/controller/WatchStationColorController.java
+++ b/src/main/java/com/zy/asrs/controller/WatchStationColorController.java
@@ -103,7 +103,7 @@
defaults.put("site-auto-run", "#FA51F6");
defaults.put("site-auto-id", "#C4C400");
defaults.put("site-auto-run-id", "#30BFFC");
- defaults.put("site-enable-in", "#18C7B8");
+ defaults.put("site-enable-in", "#A81DEE");
defaults.put("site-unauto", "#B8B8B8");
defaults.put("machine-pakin", "#30BFFC");
defaults.put("machine-pakout", "#97B400");
diff --git a/src/main/webapp/components/MapCanvas.js b/src/main/webapp/components/MapCanvas.js
index 05d703b..be2b7d8 100644
--- a/src/main/webapp/components/MapCanvas.js
+++ b/src/main/webapp/components/MapCanvas.js
@@ -138,7 +138,7 @@
'site-auto-run': 0xfa51f6,
'site-auto-id': 0xc4c400,
'site-auto-run-id': 0x30bffc,
- 'site-enable-in': 0x18c7b8,
+ 'site-enable-in': 0xA81DEE,
'site-unauto': 0xb8b8b8,
'machine-pakin': 0x30bffc,
'machine-pakout': 0x97b400,
@@ -2452,7 +2452,7 @@
'site-auto-run': 0xfa51f6,
'site-auto-id': 0xc4c400,
'site-auto-run-id': 0x30bffc,
- 'site-enable-in': 0x18c7b8,
+ 'site-enable-in': 0xA81DEE,
'site-unauto': 0xb8b8b8,
'machine-pakin': 0x30bffc,
'machine-pakout': 0x97b400,
@@ -2640,7 +2640,6 @@
}
}
});
-
diff --git a/src/main/webapp/components/MonitorWorkbench.js b/src/main/webapp/components/MonitorWorkbench.js
deleted file mode 100644
index a532d1f..0000000
--- a/src/main/webapp/components/MonitorWorkbench.js
+++ /dev/null
@@ -1,661 +0,0 @@
-Vue.component("monitor-workbench", {
- template: `
- <div class="wb-root">
- <div class="wb-tabs" role="tablist">
- <button
- v-for="tab in tabs"
- :key="tab.key"
- type="button"
- :class="['wb-tab', { 'is-active': activeCard === tab.key }]"
- @click="changeTab(tab.key)"
- >{{ tab.label }}</button>
- </div>
-
- <div class="wb-toolbar">
- <input
- class="wb-input"
- :value="currentSearch"
- :placeholder="currentSearchPlaceholder()"
- @input="updateSearch($event.target.value)"
- />
- <div class="wb-toolbar-actions">
- <button type="button" class="wb-btn wb-btn-ghost" @click="refreshCurrent">鍒锋柊</button>
- <button type="button" class="wb-btn" @click="toggleControl">
- {{ currentShowControl ? '鏀惰捣鎿嶄綔' : '灞曞紑鎿嶄綔' }}
- </button>
- </div>
- </div>
-
- <div class="wb-main">
- <div class="wb-side">
- <div class="wb-list-card">
- <div class="wb-side-title">璁惧閫夋嫨</div>
- <div class="wb-list">
- <button
- v-for="item in filteredList"
- :key="activeCard + '-' + getItemId(activeCard, item)"
- type="button"
- :class="['wb-list-item', { 'is-active': isSelected(activeCard, item) }]"
- @click="selectItem(activeCard, item)"
- >
- <span :class="['wb-badge', 'is-' + getStatusTone(activeCard, item)]">{{ getStatusLabel(activeCard, item) }}</span>
- <div class="wb-list-main">
- <div class="wb-list-title">{{ getItemTitle(activeCard, item) }}</div>
- <div class="wb-list-meta">{{ getItemMeta(activeCard, item) }}</div>
- </div>
- </button>
- <div v-if="filteredList.length === 0" class="wb-empty">褰撳墠娌℃湁鍙睍绀虹殑鏁版嵁</div>
- </div>
- </div>
-
- <div v-if="currentShowControl" class="wb-control-card">
- <div class="wb-side-title">蹇嵎鎿嶄綔</div>
- <div class="wb-control-target">{{ controlTargetText }}</div>
- <div class="wb-control-subtitle">{{ controlPanelHint }}</div>
-
- <div v-if="activeCard === 'crn'" class="wb-form-grid">
- <label class="wb-field">
- <span class="wb-field-label">鍫嗗灈鏈哄彿</span>
- <input class="wb-input" v-model="controlForms.crn.crnNo" placeholder="1" />
- </label>
- <label class="wb-field">
- <span class="wb-field-label">婧愬簱浣�</span>
- <input class="wb-input" v-model="controlForms.crn.sourceLocNo" placeholder="婧愮偣" />
- </label>
- <label class="wb-field wb-field-span-2">
- <span class="wb-field-label">鐩爣搴撲綅</span>
- <input class="wb-input" v-model="controlForms.crn.targetLocNo" placeholder="鐩爣鐐�" />
- </label>
- <div class="wb-action-row">
- <button type="button" class="wb-btn wb-btn-primary" @click="submitControl('transport')">鍙栨斁璐�</button>
- <button type="button" class="wb-btn wb-btn-ghost" @click="submitControl('move')">绉诲姩</button>
- <button type="button" class="wb-btn wb-btn-soft" @click="submitControl('taskComplete')">瀹屾垚</button>
- </div>
- </div>
-
- <div v-else-if="activeCard === 'dualCrn'" class="wb-form-grid">
- <label class="wb-field">
- <span class="wb-field-label">鍫嗗灈鏈哄彿</span>
- <input class="wb-input" v-model="controlForms.dualCrn.crnNo" placeholder="2" />
- </label>
- <label class="wb-field">
- <span class="wb-field-label">宸ヤ綅</span>
- <select class="wb-select" v-model="controlForms.dualCrn.station">
- <option :value="1">宸ヤ綅1</option>
- <option :value="2">宸ヤ綅2</option>
- </select>
- </label>
- <label class="wb-field">
- <span class="wb-field-label">婧愬簱浣�</span>
- <input class="wb-input" v-model="controlForms.dualCrn.sourceLocNo" placeholder="婧愮偣" />
- </label>
- <label class="wb-field">
- <span class="wb-field-label">鐩爣搴撲綅</span>
- <input class="wb-input" v-model="controlForms.dualCrn.targetLocNo" placeholder="鐩爣鐐�" />
- </label>
- <div class="wb-action-row">
- <button type="button" class="wb-btn wb-btn-primary" @click="submitControl('transport')">鍙栨斁璐�</button>
- <button type="button" class="wb-btn wb-btn-ghost" @click="submitControl('pickup')">鍙栬揣</button>
- <button type="button" class="wb-btn wb-btn-ghost" @click="submitControl('putdown')">鏀捐揣</button>
- <button type="button" class="wb-btn wb-btn-ghost" @click="submitControl('move')">绉诲姩</button>
- <button type="button" class="wb-btn wb-btn-soft" @click="submitControl('taskComplete')">瀹屾垚</button>
- </div>
- </div>
-
- <div v-else-if="activeCard === 'devp'" class="wb-form-grid">
- <label class="wb-field">
- <span class="wb-field-label">绔欏彿</span>
- <input class="wb-input" v-model="controlForms.devp.stationId" placeholder="101" />
- </label>
- <label class="wb-field">
- <span class="wb-field-label">宸ヤ綔鍙�</span>
- <input class="wb-input" v-model="controlForms.devp.taskNo" placeholder="宸ヤ綔鍙�" />
- </label>
- <label class="wb-field wb-field-span-2">
- <span class="wb-field-label">鐩爣绔�</span>
- <input class="wb-input" v-model="controlForms.devp.targetStationId" placeholder="鐩爣绔欏彿" />
- </label>
- <div class="wb-action-row">
- <button type="button" class="wb-btn wb-btn-primary" @click="submitControl('move')">涓嬪彂</button>
- <button type="button" class="wb-btn wb-btn-soft" @click="submitControl('reset')">澶嶄綅</button>
- <button
- v-if="selectedItem"
- type="button"
- class="wb-btn wb-btn-ghost"
- @click="editBarcode"
- >鏉$爜</button>
- </div>
- </div>
-
- <div v-else-if="activeCard === 'rgv'" class="wb-form-grid">
- <label class="wb-field">
- <span class="wb-field-label">RGV鍙�</span>
- <input class="wb-input" v-model="controlForms.rgv.rgvNo" placeholder="1" />
- </label>
- <label class="wb-field">
- <span class="wb-field-label">婧愮偣</span>
- <input class="wb-input" v-model="controlForms.rgv.sourcePos" placeholder="婧愮偣" />
- </label>
- <label class="wb-field wb-field-span-2">
- <span class="wb-field-label">鐩爣鐐�</span>
- <input class="wb-input" v-model="controlForms.rgv.targetPos" placeholder="鐩爣鐐�" />
- </label>
- <div class="wb-action-row">
- <button type="button" class="wb-btn wb-btn-primary" @click="submitControl('transport')">鍙栨斁璐�</button>
- <button type="button" class="wb-btn wb-btn-ghost" @click="submitControl('move')">绉诲姩</button>
- <button type="button" class="wb-btn wb-btn-soft" @click="submitControl('taskComplete')">瀹屾垚</button>
- </div>
- </div>
- </div>
- </div>
-
- <div class="wb-detail-panel">
- <div class="wb-detail" v-if="selectedItem">
- <div class="wb-detail-header">
- <div>
- <div class="wb-section-title">{{ getItemTitle(activeCard, selectedItem) }}</div>
- <div class="wb-detail-subtitle">{{ getItemMeta(activeCard, selectedItem) }}</div>
- </div>
- <div class="wb-detail-actions">
- <button
- v-if="activeCard === 'dualCrn'"
- type="button"
- class="wb-link"
- @click="editDualTask(1)"
- >宸ヤ綅1浠诲姟鍙�</button>
- <button
- v-if="activeCard === 'dualCrn'"
- type="button"
- class="wb-link"
- @click="editDualTask(2)"
- >宸ヤ綅2浠诲姟鍙�</button>
- </div>
- </div>
-
- <div class="wb-detail-grid">
- <div v-for="entry in detailEntries" :key="entry.label" class="wb-detail-cell">
- <div class="wb-detail-label">{{ entry.label }}</div>
- <div class="wb-detail-value">{{ entry.value }}</div>
- </div>
- </div>
- </div>
- <div class="wb-detail wb-detail-empty" v-else>
- <div class="wb-empty">璇峰厛浠庡乏渚ч�夋嫨涓�涓澶�</div>
- </div>
- </div>
- </div>
-
- <div v-if="noticeMessage" :class="['wb-notice', 'is-' + noticeType]">{{ noticeMessage }}</div>
- </div>
- `,
- props: {
- activeCard: { type: String, default: "crn" },
- crnParam: { type: Object, default: function () { return {}; } },
- dualCrnParam: { type: Object, default: function () { return {}; } },
- devpParam: { type: Object, default: function () { return {}; } },
- rgvParam: { type: Object, default: function () { return {}; } },
- crnList: { type: Array, default: function () { return []; } },
- dualCrnList: { type: Array, default: function () { return []; } },
- stationList: { type: Array, default: function () { return []; } },
- rgvList: { type: Array, default: function () { return []; } }
- },
- data() {
- return {
- tabs: [
- { key: "crn", label: "鍫嗗灈鏈�" },
- { key: "dualCrn", label: "鍙屽伐浣�" },
- { key: "devp", label: "杈撻�佺珯" },
- { key: "rgv", label: "RGV" }
- ],
- searchMap: {
- crn: "",
- dualCrn: "",
- devp: "",
- rgv: ""
- },
- selectedIdMap: {
- crn: null,
- dualCrn: null,
- devp: null,
- rgv: null
- },
- showControlMap: {
- crn: false,
- dualCrn: false,
- devp: false,
- rgv: false
- },
- controlForms: {
- crn: { crnNo: "", sourceLocNo: "", targetLocNo: "" },
- dualCrn: { crnNo: "", sourceLocNo: "", targetLocNo: "", station: 1 },
- devp: { stationId: "", taskNo: "", targetStationId: "" },
- rgv: { rgvNo: "", sourcePos: "", targetPos: "" }
- },
- noticeMessage: "",
- noticeType: "info",
- noticeTimer: null
- };
- },
- computed: {
- currentSearch() {
- return this.searchMap[this.activeCard] || "";
- },
- currentShowControl() {
- return !!this.showControlMap[this.activeCard];
- },
- currentList() {
- return this.getListByType(this.activeCard);
- },
- filteredList() {
- const keyword = String(this.currentSearch || "").trim().toLowerCase();
- if (!keyword) { return this.currentList; }
- return this.currentList.filter((item) => this.matchesKeyword(this.activeCard, item, keyword));
- },
- selectedItem() {
- return this.getSelectedItem(this.activeCard);
- },
- detailEntries() {
- return this.buildDetailEntries(this.activeCard, this.selectedItem);
- },
- controlPanelTitle() {
- if (this.activeCard === "crn") { return "鍫嗗灈鏈烘帶鍒�"; }
- if (this.activeCard === "dualCrn") { return "鍙屽伐浣嶆帶鍒�"; }
- if (this.activeCard === "devp") { return "杈撻�佺珯鎺у埗"; }
- if (this.activeCard === "rgv") { return "RGV鎺у埗"; }
- return "鎺у埗鎿嶄綔";
- },
- controlPanelHint() {
- if (this.activeCard === "crn") { return "鍏堢‘璁よ澶囧彿锛屽啀濉啓婧愬簱浣嶅拰鐩爣搴撲綅銆�"; }
- if (this.activeCard === "dualCrn") { return "鍏堥�夋嫨宸ヤ綅锛屽啀涓嬪彂鍙栬揣銆佹斁璐ф垨绉诲姩鎸囦护銆�"; }
- if (this.activeCard === "devp") { return "鐢ㄤ簬绔欑偣涓嬪彂銆佸浣嶅拰鏉$爜缁存姢銆�"; }
- if (this.activeCard === "rgv") { return "鐢ㄤ簬杞ㄩ亾杞﹀彇鏀捐揣銆佺Щ鍔ㄥ拰浠诲姟瀹屾垚銆�"; }
- return "";
- },
- controlTargetText() {
- if (!this.selectedItem) { return "鏈�変腑璁惧"; }
- return "褰撳墠鐩爣: " + this.getItemTitle(this.activeCard, this.selectedItem);
- }
- },
- watch: {
- activeCard: {
- immediate: true,
- handler(type) {
- this.ensureSelection(type);
- }
- },
- crnList() { this.ensureSelection("crn"); },
- dualCrnList() { this.ensureSelection("dualCrn"); },
- stationList() { this.ensureSelection("devp"); },
- rgvList() { this.ensureSelection("rgv"); },
- crnParam: {
- deep: true,
- handler(v) { this.applyExternalFocus("crn", v && v.crnNo); }
- },
- dualCrnParam: {
- deep: true,
- handler(v) { this.applyExternalFocus("dualCrn", v && v.crnNo); }
- },
- devpParam: {
- deep: true,
- handler(v) { this.applyExternalFocus("devp", v && v.stationId); }
- },
- rgvParam: {
- deep: true,
- handler(v) { this.applyExternalFocus("rgv", v && v.rgvNo); }
- }
- },
- beforeDestroy() {
- if (this.noticeTimer) {
- clearTimeout(this.noticeTimer);
- this.noticeTimer = null;
- }
- },
- methods: {
- changeTab(type) {
- if (type === this.activeCard) { return; }
- this.$emit("change-tab", type);
- },
- updateSearch(value) {
- this.$set(this.searchMap, this.activeCard, value);
- this.ensureSelection(this.activeCard);
- },
- refreshCurrent() {
- this.$emit("refresh-request", this.activeCard);
- },
- toggleControl() {
- this.$set(this.showControlMap, this.activeCard, !this.currentShowControl);
- if (this.currentShowControl && this.selectedItem) {
- this.hydrateControlForm(this.activeCard, this.selectedItem);
- }
- },
- getListByType(type) {
- if (type === "crn") { return this.crnList || []; }
- if (type === "dualCrn") { return this.dualCrnList || []; }
- if (type === "devp") { return this.stationList || []; }
- if (type === "rgv") { return this.rgvList || []; }
- return [];
- },
- getItemId(type, item) {
- if (!item) { return null; }
- if (type === "crn" || type === "dualCrn") { return item.crnNo; }
- if (type === "devp") { return item.stationId; }
- if (type === "rgv") { return item.rgvNo; }
- return null;
- },
- getSelectedItem(type) {
- const list = this.filteredListForType(type);
- if (!list.length) { return null; }
- const selectedId = this.selectedIdMap[type];
- for (let i = 0; i < list.length; i++) {
- if (String(this.getItemId(type, list[i])) === String(selectedId)) {
- return list[i];
- }
- }
- return list[0];
- },
- filteredListForType(type) {
- const keyword = String(this.searchMap[type] || "").trim().toLowerCase();
- const list = this.getListByType(type);
- if (!keyword) { return list; }
- return list.filter((item) => this.matchesKeyword(type, item, keyword));
- },
- ensureSelection(type) {
- const list = this.filteredListForType(type);
- if (!list.length) {
- this.$set(this.selectedIdMap, type, null);
- return;
- }
- const currentId = this.selectedIdMap[type];
- const exists = list.some((item) => String(this.getItemId(type, item)) === String(currentId));
- if (!exists) {
- this.$set(this.selectedIdMap, type, this.getItemId(type, list[0]));
- }
- },
- applyExternalFocus(type, rawId) {
- if (rawId == null || rawId === "" || rawId === 0) { return; }
- this.$set(this.selectedIdMap, type, rawId);
- if (this.activeCard === type) {
- const item = this.getSelectedItem(type);
- if (item) { this.hydrateControlForm(type, item); }
- }
- },
- selectItem(type, item) {
- this.$set(this.selectedIdMap, type, this.getItemId(type, item));
- this.hydrateControlForm(type, item);
- },
- hydrateControlForm(type, item) {
- if (!item) { return; }
- if (type === "crn") {
- this.controlForms.crn.crnNo = this.orEmpty(item.crnNo);
- } else if (type === "dualCrn") {
- this.controlForms.dualCrn.crnNo = this.orEmpty(item.crnNo);
- } else if (type === "devp") {
- this.controlForms.devp.stationId = this.orEmpty(item.stationId);
- this.controlForms.devp.taskNo = this.orEmpty(item.taskNo);
- this.controlForms.devp.targetStationId = this.orEmpty(item.targetStaNo);
- } else if (type === "rgv") {
- this.controlForms.rgv.rgvNo = this.orEmpty(item.rgvNo);
- }
- },
- matchesKeyword(type, item, keyword) {
- const fields = [];
- if (type === "crn" || type === "dualCrn") {
- fields.push(item.crnNo, item.taskNo, item.taskNoTwo, item.locNo, item.sourceLocNo, item.status, item.mode);
- } else if (type === "devp") {
- fields.push(item.stationId, item.taskNo, item.targetStaNo, item.barcode, item.errorMsg, item.extend);
- } else if (type === "rgv") {
- fields.push(item.rgvNo, item.taskNo, item.trackSiteNo, item.status, item.mode, item.alarm);
- }
- return fields.some((field) => String(field == null ? "" : field).toLowerCase().indexOf(keyword) !== -1);
- },
- currentSearchPlaceholder() {
- if (this.activeCard === "crn") { return "鎼滅储鍫嗗灈鏈哄彿"; }
- if (this.activeCard === "dualCrn") { return "鎼滅储鍙屽伐浣嶅爢鍨涙満鍙�"; }
- if (this.activeCard === "devp") { return "鎼滅储绔欏彿 / 鏉$爜"; }
- if (this.activeCard === "rgv") { return "鎼滅储RGV鍙�"; }
- return "鎼滅储";
- },
- getItemTitle(type, item) {
- if (!item) { return "-"; }
- if (type === "crn") { return item.crnNo + "鍙峰爢鍨涙満"; }
- if (type === "dualCrn") { return item.crnNo + "鍙峰弻宸ヤ綅鍫嗗灈鏈�"; }
- if (type === "devp") { return item.stationId + "鍙风珯鐐�"; }
- if (type === "rgv") { return item.rgvNo + "鍙稲GV"; }
- return "-";
- },
- getItemMeta(type, item) {
- if (!item) { return "-"; }
- if (type === "crn") { return "浠诲姟 " + this.orDash(item.workNo) + " | 鐩爣 " + this.orDash(item.locNo); }
- if (type === "dualCrn") { return "宸ヤ綅1 " + this.orDash(item.taskNo) + " | 宸ヤ綅2 " + this.orDash(item.taskNoTwo); }
- if (type === "devp") { return "浠诲姟 " + this.orDash(item.taskNo) + " | 鐩爣绔� " + this.orDash(item.targetStaNo); }
- if (type === "rgv") { return "杞ㄩ亾浣� " + this.orDash(item.trackSiteNo) + " | 浠诲姟 " + this.orDash(item.taskNo); }
- return "-";
- },
- getStatusLabel(type, item) {
- if (!item) { return "鏈煡"; }
- if (type === "devp") { return item.autoing ? "鑷姩" : "鎵嬪姩"; }
- const status = String(item.deviceStatus || "").toUpperCase();
- if (status === "AUTO") { return "鑷姩"; }
- if (status === "WORKING") { return "浣滀笟涓�"; }
- if (status === "ERROR") { return "鏁呴殰"; }
- return "绂荤嚎";
- },
- getStatusTone(type, item) {
- const label = this.getStatusLabel(type, item);
- if (label === "鑷姩") { return "success"; }
- if (label === "浣滀笟涓�") { return "working"; }
- if (label === "鎵嬪姩") { return "warning"; }
- if (label === "鏁呴殰") { return "danger"; }
- return "muted";
- },
- isSelected(type, item) {
- return String(this.getItemId(type, item)) === String(this.selectedIdMap[type]);
- },
- buildDetailEntries(type, item) {
- if (!item) { return []; }
- if (type === "crn") {
- return [
- { label: "缂栧彿", value: this.orDash(item.crnNo) },
- { label: "宸ヤ綔鍙�", value: this.orDash(item.workNo) },
- { label: "妯″紡", value: this.orDash(item.mode) },
- { label: "鐘舵��", value: this.orDash(item.status) },
- { label: "婧愬簱浣�", value: this.orDash(item.sourceLocNo) },
- { label: "鐩爣搴撲綅", value: this.orDash(item.locNo) },
- { label: "鏄惁鏈夌墿", value: this.yesNo(item.loading) },
- { label: "浠诲姟鎺ユ敹", value: this.orDash(item.taskReceive) },
- { label: "鍒�", value: this.orDash(item.bay) },
- { label: "灞�", value: this.orDash(item.lev) },
- { label: "璐у弶瀹氫綅", value: this.orDash(item.forkOffset) },
- { label: "杞借揣鍙板畾浣�", value: this.orDash(item.liftPos) },
- { label: "璧拌瀹氫綅", value: this.orDash(item.walkPos) },
- { label: "璧拌閫熷害", value: this.orDash(item.xspeed) },
- { label: "鍗囬檷閫熷害", value: this.orDash(item.yspeed) },
- { label: "鍙夌墮閫熷害", value: this.orDash(item.zspeed) },
- { label: "绉伴噸鏁版嵁", value: this.orDash(item.weight) },
- { label: "鏉$爜鏁版嵁", value: this.orDash(item.barcode) },
- { label: "鏁呴殰浠g爜", value: this.orDash(item.warnCode) },
- { label: "鏁呴殰鎻忚堪", value: this.orDash(item.alarm) }
- ];
- }
- if (type === "dualCrn") {
- return [
- { label: "妯″紡", value: this.orDash(item.mode) },
- { label: "寮傚父鐮�", value: this.orDash(item.warnCode) },
- { label: "宸ヤ綅1浠诲姟鍙�", value: this.orDash(item.taskNo) },
- { label: "宸ヤ綅2浠诲姟鍙�", value: this.orDash(item.taskNoTwo) },
- { label: "宸ヤ綅1鐘舵��", value: this.orDash(item.status) },
- { label: "宸ヤ綅2鐘舵��", value: this.orDash(item.statusTwo) },
- { label: "宸ヤ綅1鏈夌墿", value: this.yesNo(item.loading) },
- { label: "宸ヤ綅2鏈夌墿", value: this.yesNo(item.loadingTwo) },
- { label: "鍒�", value: this.orDash(item.bay) },
- { label: "灞�", value: this.orDash(item.lev) },
- { label: "杞借揣鍙板畾浣�", value: this.orDash(item.liftPos) },
- { label: "璧拌瀹氫綅", value: this.orDash(item.walkPos) },
- { label: "璧拌閫熷害", value: this.orDash(item.xspeed) },
- { label: "鍗囬檷閫熷害", value: this.orDash(item.yspeed) },
- { label: "鍙夌墮閫熷害", value: this.orDash(item.zspeed) },
- { label: "鎵╁睍鏁版嵁", value: this.orDash(item.extend) }
- ];
- }
- if (type === "devp") {
- return [
- { label: "缂栧彿", value: this.orDash(item.stationId) },
- { label: "宸ヤ綔鍙�", value: this.orDash(item.taskNo) },
- { label: "鐩爣绔�", value: this.orDash(item.targetStaNo) },
- { label: "妯″紡", value: item.autoing ? "鑷姩" : "鎵嬪姩" },
- { label: "鏈夌墿", value: this.yesNo(item.loading) },
- { label: "鍙叆", value: this.yesNo(item.inEnable) },
- { label: "鍙嚭", value: this.yesNo(item.outEnable) },
- { label: "绌烘澘淇″彿", value: this.yesNo(item.emptyMk) },
- { label: "婊℃澘淇″彿", value: this.yesNo(item.fullPlt) },
- { label: "杩愯闃诲", value: this.yesNo(item.runBlock) },
- { label: "鍚姩鍏ュ簱", value: this.yesNo(item.enableIn) },
- { label: "鎵樼洏楂樺害", value: this.orDash(item.palletHeight) },
- { label: "鏉$爜", value: this.orDash(item.barcode) },
- { label: "閲嶉噺", value: this.orDash(item.weight) },
- { label: "浠诲姟鍙啓鍖�", value: this.orDash(item.taskWriteIdx) },
- { label: "鏁呴殰浠g爜", value: this.orDash(item.error) },
- { label: "鏁呴殰淇℃伅", value: this.orDash(item.errorMsg) }
- ];
- }
- if (type === "rgv") {
- return [
- { label: "缂栧彿", value: this.orDash(item.rgvNo) },
- { label: "宸ヤ綔鍙�", value: this.orDash(item.taskNo) },
- { label: "妯″紡", value: this.orDash(item.mode) },
- { label: "鐘舵��", value: this.orDash(item.status) },
- { label: "杞ㄩ亾浣�", value: this.orDash(item.trackSiteNo) },
- { label: "鏄惁鏈夌墿", value: this.yesNo(item.loading) },
- { label: "鏁呴殰浠g爜", value: this.orDash(item.warnCode) },
- { label: "鏁呴殰鎻忚堪", value: this.orDash(item.alarm) },
- { label: "鎵╁睍鏁版嵁", value: this.orDash(item.extend) }
- ];
- }
- return [];
- },
- submitControl(action) {
- const config = this.getControlConfig(this.activeCard, action);
- if (!config) { return; }
- $.ajax({
- url: baseUrl + config.url,
- headers: { token: localStorage.getItem("token") },
- contentType: "application/json",
- method: "post",
- data: JSON.stringify(config.payload),
- success: (res) => {
- if (res && res.code === 200) {
- this.showNotice(res.msg || "鎿嶄綔鎴愬姛", "success");
- this.$emit("refresh-request", this.activeCard);
- } else {
- this.showNotice((res && res.msg) || "鎿嶄綔澶辫触", "warning");
- }
- },
- error: () => {
- this.showNotice("璇锋眰澶辫触", "danger");
- }
- });
- },
- getControlConfig(type, action) {
- if (type === "crn") {
- return {
- url: { transport: "/crn/command/take", move: "/crn/command/move", taskComplete: "/crn/command/taskComplete" }[action],
- payload: this.controlForms.crn
- };
- }
- if (type === "dualCrn") {
- return {
- url: {
- transport: "/dualcrn/command/take",
- pickup: "/dualcrn/command/pick",
- putdown: "/dualcrn/command/put",
- move: "/dualcrn/command/move",
- taskComplete: "/dualcrn/command/taskComplete"
- }[action],
- payload: this.controlForms.dualCrn
- };
- }
- if (type === "devp") {
- return {
- url: { move: "/station/command/move", reset: "/station/command/reset" }[action],
- payload: this.controlForms.devp
- };
- }
- if (type === "rgv") {
- return {
- url: { transport: "/rgv/command/transport", move: "/rgv/command/move", taskComplete: "/rgv/command/taskComplete" }[action],
- payload: this.controlForms.rgv
- };
- }
- return null;
- },
- editBarcode() {
- const item = this.selectedItem;
- if (!item || item.stationId == null) { return; }
- const barcode = window.prompt("璇疯緭鍏ユ柊鐨勬潯鐮佸�硷紙鍙暀绌烘竻绌猴級", item.barcode || "");
- if (barcode === null) { return; }
- $.ajax({
- url: baseUrl + "/station/command/barcode",
- headers: { token: localStorage.getItem("token") },
- contentType: "application/json",
- method: "post",
- data: JSON.stringify({ stationId: item.stationId, barcode: String(barcode).trim() }),
- success: (res) => {
- if (res && res.code === 200) {
- this.showNotice("鏉$爜淇敼鎴愬姛", "success");
- this.$emit("refresh-request", "devp");
- } else {
- this.showNotice((res && res.msg) || "鏉$爜淇敼澶辫触", "warning");
- }
- },
- error: () => { this.showNotice("鏉$爜淇敼澶辫触", "danger"); }
- });
- },
- editDualTask(station) {
- const item = this.selectedItem;
- if (!item || item.crnNo == null) { return; }
- const currentValue = station === 1 ? item.taskNo : item.taskNoTwo;
- const value = window.prompt("璇疯緭鍏ュ伐浣�" + station + "浠诲姟鍙�", currentValue == null ? "" : String(currentValue));
- if (value === null) { return; }
- if (!/^\d+$/.test(String(value).trim())) {
- this.showNotice("浠诲姟鍙峰繀椤绘槸闈炶礋鏁存暟", "warning");
- return;
- }
- $.ajax({
- url: baseUrl + "/dualcrn/command/updateTaskNo",
- headers: { token: localStorage.getItem("token") },
- contentType: "application/json",
- method: "post",
- data: JSON.stringify({ crnNo: item.crnNo, station: station, taskNo: Number(value) }),
- success: (res) => {
- if (res && res.code === 200) {
- this.showNotice("浠诲姟鍙锋洿鏂版垚鍔�", "success");
- this.$emit("refresh-request", "dualCrn");
- } else {
- this.showNotice((res && res.msg) || "浠诲姟鍙锋洿鏂板け璐�", "warning");
- }
- },
- error: () => { this.showNotice("浠诲姟鍙锋洿鏂板け璐�", "danger"); }
- });
- },
- showNotice(message, type) {
- this.noticeMessage = message;
- this.noticeType = type || "info";
- if (this.noticeTimer) { clearTimeout(this.noticeTimer); }
- this.noticeTimer = setTimeout(() => {
- this.noticeMessage = "";
- this.noticeTimer = null;
- }, 2200);
- },
- yesNo(value) {
- if (value === true || value === "Y" || value === "y" || value === 1 || value === "1") { return "Y"; }
- if (value === false || value === 0 || value === "0") { return "N"; }
- return value ? "Y" : "N";
- },
- orDash(value) {
- return value == null || value === "" ? "-" : String(value);
- },
- orEmpty(value) {
- return value == null ? "" : String(value);
- }
- }
-});
diff --git a/src/main/webapp/static/js/watch/stationColorConfig.js b/src/main/webapp/static/js/watch/stationColorConfig.js
index d2450ea..26df789 100644
--- a/src/main/webapp/static/js/watch/stationColorConfig.js
+++ b/src/main/webapp/static/js/watch/stationColorConfig.js
@@ -9,7 +9,7 @@
'#FA51F6',
'#C4C400',
'#30BFFC',
- '#18C7B8',
+ '#A81DEE',
'#97B400',
'#E69138',
'#B8B8B8',
diff --git a/src/main/webapp/views/watch/console.html b/src/main/webapp/views/watch/console.html
index a1229ae..1a568dd 100644
--- a/src/main/webapp/views/watch/console.html
+++ b/src/main/webapp/views/watch/console.html
@@ -524,7 +524,6 @@
<div class="monitor-panel" ref="monitorPanel" :class="{ 'is-collapsed': panelCollapsed }">
<div class="monitor-panel-header">
<div class="monitor-panel-title">鐩戞帶宸ヤ綔鍙�</div>
- <div class="monitor-panel-desc">鍥寸粫鍦板浘鍋氭搷浣滐紝璁惧鐐瑰嚮鍚庤嚜鍔ㄥ垏鎹㈠埌瀵瑰簲闈㈡澘</div>
</div>
<div class="monitor-panel-body">
<div class="wb-tabs" role="tablist">
--
Gitblit v1.9.1