From 71fc2c24359c747c84b92fa45f542141e5678eb2 Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期一, 13 六月 2022 17:29:58 +0800
Subject: [PATCH] 1.项目全局配置(部分)

---
 src/views/jcsz/zzjg.vue                  |   25 +++--
 /dev/null                                |   30 ------
 src/views/jcsz/wldw.vue                  |    6 
 src/views/zzmx/gylx.vue                  |   97 ++++++++++---------
 src/views/jcsz/yhqd.vue                  |    6 
 src/main.js                              |    5 +
 src/views/jcsz/jsqd.vue                  |    6 
 src/views/login/index.vue                |   21 ++--
 src/layout/components/Sidebar/index.vue  |   13 +-
 src/store/modules/permission.js          |   46 +++-----
 src/layout/components/TagsView/index.vue |    5 
 src/utils/global.js                      |   19 +++
 12 files changed, 140 insertions(+), 139 deletions(-)

diff --git a/src/layout/components/Sidebar/index.vue b/src/layout/components/Sidebar/index.vue
index 027d1b2..ec50cdc 100644
--- a/src/layout/components/Sidebar/index.vue
+++ b/src/layout/components/Sidebar/index.vue
@@ -69,6 +69,7 @@
 }
 </script>
 <style lang="scss">
+$main_color :#42b983;
 .el-button--text, .el-button--text.is-disabled, .el-button--text.is-disabled:focus, .el-button--text.is-disabled:hover, .el-button--text:active{
   color: white ;
   font-size: 18px ;
@@ -78,11 +79,11 @@
 }
 
 #app .sidebar-container .el-submenu .el-menu-item.is-active{
-  background: #42b983 !important;
+  background: $main_color !important;
   color: #fff !important;
 }
 #app .sidebar-container .el-submenu .el-menu-item:hover{
-  background: #42b983 !important;
+  background: $main_color !important;
   //color: #fff !important;
 }
 
@@ -91,20 +92,20 @@
 }
 
 .sub-el-icon::before{
-  color: #42b983;
+  color: $main_color;
 }
 .svg-icon{
-  color: #42b983;
+  color: $main_color;
 }
 .submenu-title-noDropdown{
   font-weight: bolder;
 }
 .router-link-exact-active>.submenu-title-noDropdown{
-  color: #42b983 !important;
+  color: $main_color !important;
 }
 
 .el-menu-item.is-active{
-  color: #42b983 !important;
+  color: $main_color !important;
 }
 
 .el-button--text:hover{
diff --git a/src/layout/components/TagsView/index.vue b/src/layout/components/TagsView/index.vue
index 96acacc..18d4a2c 100644
--- a/src/layout/components/TagsView/index.vue
+++ b/src/layout/components/TagsView/index.vue
@@ -198,6 +198,7 @@
 </script>
 
 <style lang="scss" scoped>
+$main_color :#42b983;
 .tags-view-container {
   height: 34px;
   width: 100%;
@@ -225,9 +226,9 @@
         margin-right: 15px;
       }
       &.active {
-        background-color: #42b983;
+        background-color:$main_color;
         color: #fff;
-        border-color: #42b983;
+        border-color:$main_color;
         &::before {
           content: '';
           background: #fff;
diff --git a/src/main.js b/src/main.js
index a19df87..ecbc333 100644
--- a/src/main.js
+++ b/src/main.js
@@ -37,6 +37,11 @@
 
 // 瀵煎叆鍏ㄥ眬鏍峰紡琛�
 import './styles/global.css'
+import { getGlobalColor, headerCellStyle, cellStyle } from './utils/global.js'
+
+Vue.prototype.$getGlobalColor = getGlobalColor().globalColor // 璁剧疆鍏ㄥ眬棰滆壊
+Vue.prototype.$headerCellStyle = headerCellStyle() // 璁剧疆鍏ㄥ眬琛ㄥご鏍峰紡
+Vue.prototype.$cellStyle = cellStyle() // 璁剧疆鍏ㄥ眬琛ㄤ綋鏍峰紡
 
 new Vue({
   el: '#app',
diff --git a/src/store/modules/permission.js b/src/store/modules/permission.js
index c324d4d..63ba5fd 100644
--- a/src/store/modules/permission.js
+++ b/src/store/modules/permission.js
@@ -123,29 +123,6 @@
             meta: { title: '绯荤粺棣栭〉', icon: 'el-icon-house', affix: '1' }
           }]
         },
-        // {
-        //   path: '/',
-        //   component: 'Layout',
-        //   redirect: '/dashboard',
-        //   children: [{
-        //     path: 'dashboard',
-        //     name: 'Dashboard',
-        //     component: '/dashboard/index'
-        //   }]
-        // },
-        // {
-        //   path: '/xtsy',
-        //   component: 'Layout',
-        //   redirect: '/stxy/index',
-        //   children: [
-        //     {
-        //       path: 'index',
-        //       name: 'Form',
-        //       component: '/xtsy/index',
-        //       meta: { title: '绯荤粺棣栭〉', icon: 'form', affix: '1' }
-        //     }
-        //   ]
-        // },
         {
           path: '/jcsz',
           component: 'Layout',
@@ -160,11 +137,23 @@
               meta: { title: '缁勭粐鏋舵瀯', icon: '' }
             },
             {
-              path: 'rwgl',
-              name: 'rwgl',
-              component: '/jcsz/rwgl',
-              meta: { title: '浠诲姟绠$悊', icon: '' }
-            }
+              path: 'yhqd',
+              name: 'yhqd',
+              component: '/jcsz/yhqd',
+              meta: { title: '鐢ㄦ埛娓呭崟', icon: '' }
+            },
+            {
+              path: 'jsqd',
+              name: 'jsqd',
+              component: '/jcsz/jsqd',
+              meta: { title: '瑙掕壊娓呭崟', icon: '' }
+            },
+            {
+              path: 'wldw',
+              name: 'wldw',
+              component: '/jcsz/wldw',
+              meta: { title: '寰�鏉ュ崟浣�', icon: '' }
+            },
           ]
         },
         {
@@ -194,7 +183,6 @@
             }
           ]
         }
-
       ]
       const asyncRoutes = getAsyncRoutes(routes)
       asyncRoutes.push({ path: '*', redirect: '/404', hidden: true })
diff --git a/src/utils/glabal.js b/src/utils/glabal.js
deleted file mode 100644
index e69de29..0000000
--- a/src/utils/glabal.js
+++ /dev/null
diff --git a/src/utils/global.js b/src/utils/global.js
new file mode 100644
index 0000000..f636c90
--- /dev/null
+++ b/src/utils/global.js
@@ -0,0 +1,19 @@
+// 鍏ㄥ眬涓昏棰滆壊
+export function getGlobalColor() {
+  return { globalColor: `#42b983` }
+}
+
+// 澶勭悊琛ㄥご鍗曞厓鏍兼牱寮�
+export function headerCellStyle() {
+  const option = {
+    background: '#eee', padding: '5px 0'
+  }
+  return option
+}
+// 澶勭悊琛ㄦ牸鍗曞厓鏍兼牱寮�
+export function cellStyle() {
+  const option = {
+    padding: '5px 0'
+  }
+  return option
+}
diff --git a/src/views/dashboard/index.vue b/src/views/dashboard/index.vue
deleted file mode 100644
index f6ab5e3..0000000
--- a/src/views/dashboard/index.vue
+++ /dev/null
@@ -1,30 +0,0 @@
-<template>
-  <div class="dashboard-container">
-    <div class="dashboard-text">娆㈣繋{{ name }}鐧诲綍锛�</div>
-  </div>
-</template>
-
-<script>
-import { mapGetters } from 'vuex'
-
-export default {
-  name: 'Dashboard',
-  computed: {
-    ...mapGetters([
-      'name'
-    ])
-  }
-}
-</script>
-
-<style lang="scss" scoped>
-.dashboard {
-  &-container {
-    margin: 30px;
-  }
-  &-text {
-    font-size: 30px;
-    line-height: 46px;
-  }
-}
-</style>
diff --git a/src/views/jcsz/rwgl.vue b/src/views/jcsz/jsqd.vue
similarity index 62%
copy from src/views/jcsz/rwgl.vue
copy to src/views/jcsz/jsqd.vue
index 3cc03ba..12b088a 100644
--- a/src/views/jcsz/rwgl.vue
+++ b/src/views/jcsz/jsqd.vue
@@ -1,8 +1,10 @@
-<template />
+<template>
+
+</template>
 
 <script>
 export default {
-  name: 'Rwgl'
+  name: "jsqd"
 }
 </script>
 
diff --git a/src/views/jcsz/rwgl.vue b/src/views/jcsz/wldw.vue
similarity index 62%
rename from src/views/jcsz/rwgl.vue
rename to src/views/jcsz/wldw.vue
index 3cc03ba..63380ba 100644
--- a/src/views/jcsz/rwgl.vue
+++ b/src/views/jcsz/wldw.vue
@@ -1,8 +1,10 @@
-<template />
+<template>
+
+</template>
 
 <script>
 export default {
-  name: 'Rwgl'
+  name: "wldw"
 }
 </script>
 
diff --git a/src/views/jcsz/rwgl.vue b/src/views/jcsz/yhqd.vue
similarity index 62%
copy from src/views/jcsz/rwgl.vue
copy to src/views/jcsz/yhqd.vue
index 3cc03ba..654cc72 100644
--- a/src/views/jcsz/rwgl.vue
+++ b/src/views/jcsz/yhqd.vue
@@ -1,8 +1,10 @@
-<template />
+<template>
+
+</template>
 
 <script>
 export default {
-  name: 'Rwgl'
+  name: "yhqd"
 }
 </script>
 
diff --git a/src/views/jcsz/zzjg.vue b/src/views/jcsz/zzjg.vue
index 536a8ca..4a057bb 100644
--- a/src/views/jcsz/zzjg.vue
+++ b/src/views/jcsz/zzjg.vue
@@ -22,7 +22,7 @@
 
           <el-tree
             ref="tree"
-            style="margin-left: 10px;"
+            style="margin-left: 10px;overflow-y: scroll;height: 230px"
             :icon-class="iconClass"
             :data="treeData"
             default-expand-all
@@ -59,8 +59,8 @@
           :data="tableData"
           border
           style="width: 72%"
-          :header-cell-style="headerCellStyle"
-          :cell-style="cellStyle"
+          :header-cell-style="this.$headerCellStyle"
+          :cell-style="this.$cellStyle"
         >
           <!--          <el-table-column-->
           <!--            label="缁勭粐鍒嗙被"-->
@@ -186,6 +186,9 @@
           }, {
             id: 8,
             label: '浜岀骇 3-2'
+          }, {
+            id: 19,
+            label: '浜岀骇 3-2'
           }]
         }],
       defaultProps: {
@@ -240,25 +243,27 @@
 }
 </script>
 
-<style scoped>
+<style lang="scss" scoped>
+$main_color: #42b983;
 ::v-deep .el-button--primary {
-  background-color: #42b983 !important;
+  background-color: $main_color !important;
   height: 30px;
   display: flex;
   align-items: center;
 }
 
 ::v-deep .el-pagination.is-background .el-pager li:not(.disabled).active {
-  background-color: #42b983 !important;
+  background-color: $main_color !important;
 }
 
-.zzflStyle{
+.zzflStyle {
   line-height: 35px;
-  font-family:'Helvetica Neue';
+  font-family: 'Helvetica Neue';
   background-color: #eee;
-  font-weight:400;
+  font-weight: 400;
   padding-left: 10px;
-  color:rgb(144, 147, 153); font-size: 14px
+  color: rgb(144, 147, 153);
+  font-size: 14px
 }
 
 /*::v-deep*/
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index e09f0ef..97268b0 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -7,7 +7,7 @@
         :autoplay="false"
         indicator-position="outside"
         height="580px"
-        interval="3000"
+        :interval="3000"
         style="width: 500px;margin-left: 20px"
       >
         <el-carousel-item v-for="item in carouselArr" :key="item.title">
@@ -217,7 +217,7 @@
       //padding: 12px 5px 12px 15px;
       color: #000;;
       height: 47px;
-      caret-color: $cursor;//鏀瑰彉鍏夋爣棰滆壊
+      caret-color: $cursor; //鏀瑰彉鍏夋爣棰滆壊
 
       &:-webkit-autofill {
         box-shadow: 0 0 0px 1000px $bg inset !important;
@@ -240,6 +240,7 @@
 $bg: #2d3a4b;
 $dark_gray: #889aa4;
 $light_gray: #eee;
+$main_color:#42b983;
 
 .login-container {
   min-height: 100%;
@@ -348,27 +349,27 @@
   //  border: 1px solid red;
   //}
 
-  ::v-deep .el-input__inner{
+  ::v-deep .el-input__inner {
     border-radius: 5px;
     background: #ffffff;
     padding-left: 35px;
     line-height: 40px;
-    border:  1px solid #eee;
+    border: 1px solid #eee;
   }
 
-  ::v-deep .el-input__icon{
+  ::v-deep .el-input__icon {
     color: #000;
   }
 
-  ::v-deep .el-input__inner:focus{
-    border:  1px solid #42b983;
+  ::v-deep .el-input__inner:focus {
+    border: 1px solid $main_color;
   }
 
-  ::v-deep .el-input__icon:focus{
-    color: #42b983;
+  ::v-deep .el-input__icon:focus {
+    color: $main_color;
   }
 
-  ::v-deep .el-input input:-webkit-autofill{
+  ::v-deep .el-input input:-webkit-autofill {
     -webkit-box-shadow: 0 0 0px 1000px #fff inset !important;
     box-shadow: 0 0 0px 1000px #fff inset !important;
     -webkit-text-fill-color: #000 !important;
diff --git a/src/views/zzmx/gylx.vue b/src/views/zzmx/gylx.vue
index deca4b5..2e33e49 100644
--- a/src/views/zzmx/gylx.vue
+++ b/src/views/zzmx/gylx.vue
@@ -22,7 +22,8 @@
           </div>
           <div style="display: flex;">
             <el-button type="primary" icon="el-icon-search" @click="search">鏌ヨ</el-button>
-            <el-button type="text" style="display: flex;align-items: start;padding-top: 10px;" @click="reset">閲嶇疆</el-button>
+            <el-button type="text" style="display: flex;align-items: start;padding-top: 10px;" @click="reset">閲嶇疆
+            </el-button>
           </div>
         </el-form>
         <div style="display: flex;justify-content: space-between">
@@ -46,9 +47,8 @@
           <el-table
             :data="tableData1"
             style="width: 100%;border: 1px solid #eee"
-            :header-cell-style="headerCellStyle"
-            :header-row-style="headerRowStyle"
-            :cell-style="cellStyle"
+            :header-cell-style="this.$headerCellStyle"
+            :cell-style="this.$cellStyle"
           >
             <el-table-column type="selection">
               <!--              <template slot-scope="{row}">-->
@@ -59,8 +59,8 @@
               <!--              </template>-->
             </el-table-column>
             <el-table-column label="宸ヨ壓璺嚎" prop="gylx" />
-            <el-table-column label="鐗╂枡缂栫爜" prop="wlbm" />
-            <el-table-column label="鐗╂枡鍚嶇О" prop="wlmc" />
+            <el-table-column show-overflow-tooltip label="鐗╂枡缂栫爜" prop="wlbm" />
+            <el-table-column show-overflow-tooltip label="鐗╂枡鍚嶇О" prop="wlmc" />
             <el-table-column label="鐗╂枡瑙勬牸" prop="wlgg" />
             <el-table-column label="缁撴潫瑁呯" prop="jszx">
               <template slot-scope="{row}">
@@ -87,8 +87,8 @@
             border
             height="500px"
             style="width: 100%;"
-            :header-cell-style="headerCellStyle"
-            :cell-style="cellStyle"
+            :header-cell-style="this.$headerCellStyle"
+            :cell-style="this.$cellStyle"
           >
             <el-table-column label="" prop="" type="index" />
             <el-table-column label="宸ュ簭缂栫爜" prop="gxbm" />
@@ -128,7 +128,7 @@
             <div>
               <el-steps
                 style="display:flex;
-              margin-top: -25px;
+                margin-top: -25px;
                 justify-content: center;"
                 :space="400"
                 :active="3"
@@ -203,6 +203,7 @@
 <script>
 
 import Pagination from '@/components/Pagination'
+import { cellStyle } from '@/utils/global'
 
 export default {
   name: 'Gylx',
@@ -340,6 +341,7 @@
     }
   },
   created() {
+
   },
   methods: {
     // 瀵煎叆
@@ -365,7 +367,7 @@
       // })
     },
     // 瀵煎嚭
-    async  downLoad() {
+    async downLoad() {
       // const res = await downFile(row.id)
       // if (res) {
       //   // console.log(res)
@@ -433,22 +435,22 @@
       this.form.wlbm = ''
       this.form.wlmc = ''
     },
-    // 澶勭悊琛ㄥご鍗曞厓鏍兼牱寮�
-    headerCellStyle() {
-      const option = {
-        background: '#eee', padding: '5px 0'
-        // border: '1px solid #fff'
-      }
-      return option
-    },
-    // 澶勭悊琛ㄥご琛屾牱寮�
-    headerRowStyle() {
-
-    },
-    // 澶勭悊琛ㄦ牸鍗曞厓鏍兼牱寮�
-    cellStyle() {
-      return { padding: '5px 0' }
-    },
+    // // 澶勭悊琛ㄥご鍗曞厓鏍兼牱寮�
+    // headerCellStyle() {
+    //   const option = {
+    //     background: '#eee', padding: '5px 0'
+    //   }
+    //   return option
+    // },
+    // // 澶勭悊琛ㄥご琛屾牱寮�
+    // headerRowStyle() {
+    //
+    // },
+    // // 澶勭悊琛ㄦ牸鍗曞厓鏍兼牱寮�
+    // cellStyle() {
+    //   // return {padding: '5px 0'}
+    //   return { padding: '0' }
+    // },
     // 鏌ヨ浜嬩欢
     async search() {
       const data = this.form
@@ -459,30 +461,31 @@
 }
 </script>
 
-<style scoped>
+<style lang="scss" scoped>
+$main_color: #42b983;
 ::v-deep .el-button--primary {
-  background-color: #42b983 !important;
+  background-color: $main_color !important;
   height: 30px;
   display: flex;
   align-items: center;
 }
 
 ::v-deep .el-pagination.is-background .el-pager li:not(.disabled).active {
-  background-color: #42b983 !important;
+  background-color: $main_color !important;
 }
 
 ::v-deep .el-button--text {
-  color: #42b983;
+  color: $main_color;
   font-size: 14px;
 }
 
 ::v-deep .el-step__head.is-finish {
-  color: #42b983;
-  border-color: #42b983;;
+  color: $main_color;
+  border-color: $main_color;;
 }
 
 ::v-deep .el-step__title.is-finish {
-  color: #42b983;
+  color: $main_color;
 }
 
 ::v-deep .el-radio.is-bordered + .el-radio.is-bordered {
@@ -494,27 +497,29 @@
   content: '' !important;
 }
 
-::v-deep .el-radio__input.is-checked+.el-radio__label{
-  color: #42b983;
+::v-deep .el-radio__input.is-checked + .el-radio__label {
+  color: $main_color;
 }
 
-::v-deep .el-radio.is-bordered.is-checked{
-  border-color: #42b983;
+::v-deep .el-radio.is-bordered.is-checked {
+  border-color: $main_color;
 }
 
-::v-deep .el-radio__input.is-checked .el-radio__inner{
-  border-color: #42b983;
-  background: #42b983;
+::v-deep .el-radio__input.is-checked .el-radio__inner {
+  border-color: $main_color;
+  background: $main_color;
 }
 
-::v-deep .el-checkbox__input.is-checked .el-checkbox__inner{
-  border-color: #42b983;
-  background-color: #42b983;
+::v-deep .el-checkbox__input.is-checked .el-checkbox__inner {
+  border-color: $main_color;
+  background-color: $main_color;
 }
-::v-deep .el-checkbox__input.is-indeterminate .el-checkbox__inner{
-  border-color: #42b983;
-  background-color: #42b983;
+
+::v-deep .el-checkbox__input.is-indeterminate .el-checkbox__inner {
+  border-color: $main_color;
+  background-color: $main_color;
 }
+
 /*::v-deep .el-divider--horizontal{*/
 /*  margin:0 0 10px 0;*/
 /*}*/

--
Gitblit v1.9.3