-
-
- {{ username }}
-
+
+
-
-
-
- {{ $t("header.personalData") }}
-
-
- {{ $t("header.changePassword") }}
-
-
- {{ $t("header.changeMode") }}
-
-
- {{ $t("header.versionRegister") }}
-
-
-
-
+
+ {{ username }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/frontend/src/views/login/components/LoginForm.vue b/frontend/src/views/login/components/LoginForm.vue
index 359d96a..81bad51 100644
--- a/frontend/src/views/login/components/LoginForm.vue
+++ b/frontend/src/views/login/components/LoginForm.vue
@@ -6,7 +6,7 @@
size='large'
>
-
+
@@ -21,6 +21,7 @@
placeholder='密码'
show-password
autocomplete='new-password'
+ disabled
>
@@ -87,8 +88,8 @@ const loginRules = reactive({
const loading = ref(false)
const loginForm = reactive({
- username: '',
- password: '',
+ username: 'user',
+ password: 'user12345.',
})
// login
From 0e6612f6bd69c384ca5d0a2aa212e6083129edc2 Mon Sep 17 00:00:00 2001
From: caozehui <2427765068@qq.com>
Date: Sat, 8 Mar 2025 10:15:11 +0800
Subject: [PATCH 2/5] =?UTF-8?q?=E5=BE=AE=E8=B0=83?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
frontend/src/views/machine/controlSource/index.vue | 1 +
1 file changed, 1 insertion(+)
diff --git a/frontend/src/views/machine/controlSource/index.vue b/frontend/src/views/machine/controlSource/index.vue
index ffec1f2..027ca9b 100644
--- a/frontend/src/views/machine/controlSource/index.vue
+++ b/frontend/src/views/machine/controlSource/index.vue
@@ -138,6 +138,7 @@ onMounted(async () => {
})
watch(webMsgSend, function (newValue, oldValue) {
+ console.log('webMsgSend:', newValue)
if (newValue.requestId.includes('formal_real&&' && newValue.operateCode === 'OPER_GATHER')) {
if (newValue.code === 10200) {
ElMessage.success('启动成功')
From 8f2882516242419c623016454c24e3a30d0539ee Mon Sep 17 00:00:00 2001
From: caozehui <2427765068@qq.com>
Date: Sat, 8 Mar 2025 10:47:19 +0800
Subject: [PATCH 3/5] =?UTF-8?q?=E5=BE=AE=E8=B0=83?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
frontend/src/views/machine/controlSource/index.vue | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/frontend/src/views/machine/controlSource/index.vue b/frontend/src/views/machine/controlSource/index.vue
index 027ca9b..39e1fd3 100644
--- a/frontend/src/views/machine/controlSource/index.vue
+++ b/frontend/src/views/machine/controlSource/index.vue
@@ -139,15 +139,15 @@ onMounted(async () => {
watch(webMsgSend, function (newValue, oldValue) {
console.log('webMsgSend:', newValue)
- if (newValue.requestId.includes('formal_real&&' && newValue.operateCode === 'OPER_GATHER')) {
+ if (newValue.requestId.includes('formal_real&&') && newValue.operateCode === 'OPER_GATHER') {
if (newValue.code === 10200) {
ElMessage.success('启动成功')
- } else {
+ }else if(newValue.code !== 10201){
ElMessage.error('启动失败')
console.log('错误信息:',webMsgSend)
}
}
- if (newValue.requestId.includes('close_source' && newValue.operateCode === 'CLOSE_GATHER')) {
+ if (newValue.requestId.includes('close_source') && newValue.operateCode === 'CLOSE_GATHER') {
if (newValue.code === 10200) {
ElMessage.success('停止成功')
} else {
@@ -161,13 +161,11 @@ watch(webMsgSend, function (newValue, oldValue) {
case 'INIT_GATHER':
if (newValue.code == 10200) {
ElMessage.success('源初始化成功')
- } else {
+ } else if(newValue.code !== 10201) {
ElMessage.error('源服务端连接失败')
console.log('错误信息:',webMsgSend)
}
break;
-
-
}
break;
case 'connect':
From 3021f7e4d3b2001ddd8cab5b9069c860b2327a66 Mon Sep 17 00:00:00 2001
From: caozehui <2427765068@qq.com>
Date: Sat, 8 Mar 2025 10:49:42 +0800
Subject: [PATCH 4/5] =?UTF-8?q?=E5=BE=AE=E8=B0=83?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
frontend/src/views/machine/controlSource/index.vue | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/frontend/src/views/machine/controlSource/index.vue b/frontend/src/views/machine/controlSource/index.vue
index 39e1fd3..b3786f9 100644
--- a/frontend/src/views/machine/controlSource/index.vue
+++ b/frontend/src/views/machine/controlSource/index.vue
@@ -160,9 +160,9 @@ watch(webMsgSend, function (newValue, oldValue) {
switch (newValue.operateCode) {
case 'INIT_GATHER':
if (newValue.code == 10200) {
- ElMessage.success('源初始化成功')
+ ElMessage.success('源连接成功')
} else if(newValue.code !== 10201) {
- ElMessage.error('源服务端连接失败')
+ ElMessage.error('源连接失败')
console.log('错误信息:',webMsgSend)
}
break;
@@ -171,7 +171,7 @@ watch(webMsgSend, function (newValue, oldValue) {
case 'connect':
switch (newValue.operateCode) {
case "Source":
- ElMessage.error('源服务端连接失败')
+ ElMessage.error('源连接失败')
}
break;
}
From 70531a0729279d85feb89da68d890d1931ea1886 Mon Sep 17 00:00:00 2001
From: caozehui <2427765068@qq.com>
Date: Sat, 8 Mar 2025 14:36:48 +0800
Subject: [PATCH 5/5] =?UTF-8?q?=E5=BE=AE=E8=B0=83?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../src/api/device/controlSource/index.ts | 4 +-
.../components/controlSourceDetail.vue | 26 ++++++++--
.../src/views/machine/controlSource/index.vue | 49 +++++++++++++++----
3 files changed, 65 insertions(+), 14 deletions(-)
diff --git a/frontend/src/api/device/controlSource/index.ts b/frontend/src/api/device/controlSource/index.ts
index 6dd154c..b47e9c5 100644
--- a/frontend/src/api/device/controlSource/index.ts
+++ b/frontend/src/api/device/controlSource/index.ts
@@ -13,12 +13,12 @@ export const checkSimulate = (params: controlSource.ResControl) => {
//启动
export const startSimulateTest = (params: controlSource.ResControl) => {
- return http.post(`prepare/startSimulateTest`,params)
+ return http.post(`prepare/startSimulateTest`,params,{loading:false})
}
//停止
export const closeSimulateTest = (params: controlSource.ResControl) => {
- return http.post(`/prepare/closeSimulateTest`,params)
+ return http.post(`/prepare/closeSimulateTest`,params,{loading:false})
}
diff --git a/frontend/src/views/machine/controlSource/components/controlSourceDetail.vue b/frontend/src/views/machine/controlSource/components/controlSourceDetail.vue
index 9ae539f..c77ac07 100644
--- a/frontend/src/views/machine/controlSource/components/controlSourceDetail.vue
+++ b/frontend/src/views/machine/controlSource/components/controlSourceDetail.vue
@@ -127,12 +127,14 @@
size="large"
@click="startLoading"
style="margin-left: 70px;margin-top: 10px;"
+ :disabled="startDisabeld"
>启动
停止
@@ -168,7 +170,7 @@
import { type PropType, ref, nextTick, onMounted, watch } from 'vue'
import Tree from './tree.vue'
import Commun from './communication.vue'
-import type { CascaderOption } from 'element-plus'
+import {type CascaderOption, ElMessage} from 'element-plus'
import { getTreeData } from '@/api/check/test'
import { CirclePlus, Delete, Check, CopyDocument, View, EditPen } from '@element-plus/icons-vue'
import type { TestScript } from '@/api/device/interface/testScript'
@@ -203,8 +205,18 @@ const props = defineProps({
formControl: {
type: Object,
required: true
- }
+ },
+ startDisabeld: {
+ type:Boolean,
+ required:true
+ },
+ pauseDisabled: {
+ type: Boolean,
+ required: true
+ }
})
+
+
const showDialog = ref(false)
const viewDialog = ref(false)
const dictStore = useDictStore()
@@ -234,7 +246,7 @@ const column = ref([
}
])
-const emit = defineEmits(['update:activeName','update:activeIndex'])
+const emit = defineEmits(['update:activeName','update:activeIndex','update:startDisabeld','update:pauseDisabled'])
const controlContent = ref