Browse Source

工程现场 大屏界面修改

zhanghao 2 months ago
parent
commit
0b0bd10294
2 changed files with 23 additions and 24 deletions
  1. 16 16
      src/views/loginPad.vue
  2. 7 8
      src/views/screen/map/map.vue

+ 16 - 16
src/views/loginPad.vue

@@ -11,7 +11,7 @@
             placeholder="账号"
           >
             <!-- <svg-icon slot="prefix" icon-class="user" class="el-input__icon input-icon" /> -->
-  
+
           </el-input>
         </label>
         </el-form-item>
@@ -28,7 +28,7 @@
           </el-input>
         </label>
         </el-form-item>
-        
+
         <!-- <el-checkbox v-model="loginForm.rememberMe" style="margin:0px 0px 25px 0px;">记住密码</el-checkbox> -->
         <el-form-item style="width:100%;margin-top: 40px;">
           <el-button
@@ -53,11 +53,11 @@
       </div>
     </div>
   </template>
-  
+
   <script>
   import Cookies from "js-cookie";
   import { encrypt, decrypt } from '@/utils/jsencrypt'
-  
+
   export default {
     name: "Login",
     data() {
@@ -67,7 +67,7 @@
           username: "",
           password: "",
           rememberMe: false,
-        
+
           uuid: ""
         },
         loginRules: {
@@ -77,10 +77,10 @@
           password: [
             { required: true, trigger: "blur", message: "请输入您的密码" }
           ],
-        
+
         },
         loading: false,
-    
+
         // 注册开关
         register: false,
         redirect: undefined
@@ -91,7 +91,7 @@
         handler: function(route) {
           this.redirect = route.query && route.query.redirect;
         },
-        
+
       }
     },
     created() {
@@ -99,7 +99,7 @@
       this.getCookie();
     },
     methods: {
- 
+
       getCookie() {
         const username = Cookies.get("username");
         const password = Cookies.get("password");
@@ -114,7 +114,7 @@
     this.$refs.loginForm.validate(valid => {
       if (valid) {
         this.loading = true;
-  
+
         // 设置记住密码逻辑
         if (this.loginForm.rememberMe) {
           Cookies.set("username", this.loginForm.username, { expires: 30 });
@@ -125,7 +125,7 @@
           Cookies.remove("password");
           Cookies.remove('rememberMe');
         }
-  
+
         this.$store.dispatch("Login", this.loginForm)
           .then(() => {
             this.$router.push({ path:"/pad" }).catch(() => {});
@@ -159,8 +159,8 @@
     }
   };
   </script>
-  
-  <style rel="stylesheet/scss" lang="scss">
+
+  <style rel="stylesheet/scss" lang="scss" scoped>
   .login {
     display: flex;
     justify-content: center;
@@ -178,7 +178,7 @@
       color: #A9FFFE;
       letter-spacing: 4.21px;
   }
-  
+
   .login-form {
     // border-radius: 6px;
     // background: #ffffff;
@@ -274,7 +274,7 @@
       background-color: #0FF9F7;
       border-color: #0FF9F7;
   }
-  
+
   .custom-label::before {
     content: '';
     position: absolute;
@@ -329,4 +329,4 @@
   .login-code-img {
     height: 38px;
   }
-  </style>
+  </style>

+ 7 - 8
src/views/screen/map/map.vue

@@ -490,6 +490,7 @@ export default {
                   obj.coordinate = coordinate
                   obj.name = it.projectName
                   obj.appOrg = it.appOrg
+                  obj.subdivision = it.subdivision
                   this.projectList.push(obj)
                 }
                 this.sign = 1
@@ -574,12 +575,9 @@ export default {
           {
             type: "scatter", // 散点图(用于标注特殊位置)
             coordinateSystem: "geo", // 使用 `geo` 作为坐标系
-            symbol: 'circle', // 自定义标记
-            symbolSize: 15, // 标记的大小
-            itemStyle: {
-              color: 'red'
-            },
-            data: this.projectList.filter(({ appOrg }) => appOrg === this.appOrg).map(({ name, coordinate }) => ({
+            symbol: "image://" + require("@/assets/images/main/map/xian.png"), // 自定义标记
+            symbolSize: 12, // 标记的大小
+            data: this.projectList.filter(({ subdivision }) => subdivision <= 10).map(({ name, coordinate }) => ({
               name, // 点名称
               value: coordinate // 经纬度坐标
             })),
@@ -588,11 +586,11 @@ export default {
             type: "scatter", // 散点图(用于标注特殊位置)
             coordinateSystem: "geo", // 使用 `geo` 作为坐标系
             symbol: 'circle', // 自定义标记
-            symbolSize: 15, // 标记的大小
+            symbolSize: 12, // 标记的大小
             itemStyle: {
               color: 'yellow'
             },
-            data: this.projectList.filter(({ appOrg }) => appOrg !== this.appOrg).map(({ name, coordinate }) => ({
+            data: this.projectList.filter(({ subdivision }) => subdivision > 10).map(({ name, coordinate }) => ({
               name, // 点名称
               value: coordinate // 经纬度坐标
             })),
@@ -741,6 +739,7 @@ export default {
                 obj.coordinate = coordinate
                 obj.name = it.projectName
                 obj.appOrg = it.appOrg
+                obj.subdivision = it.subdivision
                 this.projectList.push(obj)
               }
               this.sign = 1