Browse Source

调整运行状态上的设备名称位置

zhangchuang 3 months ago
parent
commit
c49c194578
4 changed files with 23 additions and 22 deletions
  1. 2 1
      .env.development
  2. 2 1
      .env.production
  3. 18 19
      src/views/HealthStatusAnalysis/mock.vue
  4. 1 1
      vite.config.ts

+ 2 - 1
.env.development

@@ -12,4 +12,5 @@
 #ws地址
 
 
-VITE_WS_URL=ws://localhost:8083/api/webSocket/{}
+VITE_WS_URL=ws://192.168.80.252:13002/api/webSocket/{}
+VITE_WS_MOCK_URL=ws://192.168.80.252:13002/api/ws/mock

+ 2 - 1
.env.production

@@ -10,4 +10,5 @@
 # baseURL 地址
    VITE_DEV_PATH=/api
    #ws地址
-VITE_WS_URL=ws://localhost:8083/api/webSocket/{}
+VITE_WS_URL=ws://192.168.80.252:13002/api/webSocket/{}
+VITE_WS_MOCK_URL=ws://192.168.80.252:13002/api/ws/mock

+ 18 - 19
src/views/HealthStatusAnalysis/mock.vue

@@ -69,34 +69,34 @@
             srcset=""
           />
           <!-- 添加注释和标签 -->
-          <div class="annotation" style="top: 25%; left: 10%">左DE活塞</div>
-          <div class="annotation" style="top: 24%; left: 24%">左DE燃油齿条</div>
-          <div class="annotation" style="top: 15.5%; left: 35.5%">
+          <div class="annotation" style="top: 60px; left: 120px">左DE活塞</div>
+          <div class="annotation" style="top: 50px; left: 280px">左DE燃油齿条</div>
+          <div class="annotation" style="top: 10px; left: 380px">
             左DE冷却水
           </div>
-          <div class="annotation" style="top: 24%; left: 38%">左DE箱装体</div>
-          <div class="annotation" style="top: 19%; left: 44%">左DE燃油齿条</div>
-          <div class="annotation" style="top: 14%; left: 54.5%">右齿轮箱</div>
-          <div class="annotation" style="top: 22%; left: 55.2%">
+          <div class="annotation" style="top: 50px; left: 420px">左DE箱装体</div>
+          <div class="annotation" style="top: 30px; left: 480px">左DE燃油齿条</div>
+          <div class="annotation" style="top: 0px; left: 555px">右齿轮箱</div>
+          <div class="annotation" style="top: 40px; left: 600px">
             右GT高压压气机
           </div>
-          <div class="annotation" style="top: 28%; left: 66%">
+          <div class="annotation" style="top: 65px; left: 670px">
             右GT脉冲温度调节器保护
           </div>
-          <div class="annotation" style="bottom: 17%; left: 14.5%">
+          <div class="annotation" style="bottom: 15px; left: 190px">
             右DE增压空气
           </div>
-          <div class="annotation" style="bottom: 18.4%; left: 26%">
+          <div class="annotation" style="bottom: 20px; left: 300px">
             右DE海水泵
           </div>
-          <div class="annotation" style="bottom: 12%; left: 25%">
+          <div class="annotation" style="bottom: -10px; left: 295px">
             右DE箱装体冷却风机
           </div>
-          <div class="annotation" style="bottom: 14%; left: 42.5%">
+          <div class="annotation" style="bottom: 5px; left: 445px">
             右DE滑油
           </div>
           <!-- 带有小边框的注释 -->
-          <div class="annotation bordered-box" style="top: 12%; left: 0.5%">
+          <div class="annotation bordered-box" style="top: 0px; left: 85px">
             <div>
               <div>压力A排</div>
 
@@ -121,7 +121,7 @@
               </div>
             </div>
           </div>
-          <div class="annotation bordered-box" style="top: 10%; right: 10%">
+          <div class="annotation bordered-box" style="top: -10px; right: 180px">
             <div>
               <div>海水压力</div>
               <div class="value">
@@ -147,7 +147,7 @@
           </div>
           <div
             class="annotation bordered-box"
-            style="bottom: 13.5%; left: -4.2%"
+            style="bottom: 0px; left: 40px"
           >
             <div>
               <div>后气压PP030</div>
@@ -172,8 +172,7 @@
               </div>
             </div>
           </div>
-
-          <div class="annotation bordered-box" style="top: 34.7%; right: 5%">
+          <div class="annotation bordered-box" style="top: 100px; right: 130px">
             <div>
               <div>压力(1)</div>
               <div class="value">
@@ -193,7 +192,7 @@
               </div>
             </div>
           </div>
-          <div class="annotation bordered-box" style="top: 77.8%; right: 9.8%">
+          <div class="annotation bordered-box" style="bottom: -10px; right: 180px">
             <div>
               <div>压力A排</div>
               <div class="value">
@@ -1413,7 +1412,7 @@ const healthColor = (status: string) => {
   background-color: rgba(0, 0, 0, 0.5);
   padding: 2px 5px;
   border-radius: 3px;
-  font-size: 16px;
+  font-size: 1rem;
 }
 .bordered-box div {
   font-size: 12px;

+ 1 - 1
vite.config.ts

@@ -22,7 +22,7 @@ export default defineConfig({
     proxy: {
       // 代理配置
       '/api': {
-        target: 'http://localhost:8083',  // 目标服务器
+        target: 'http://192.168.80.252:13002',  // 目标服务器
         changeOrigin: true,            // 需要虚拟主机站点
         rewrite: (path) => path.replace(/^\/api/, '/api/')  // 重写 API 请求
       }