Browse Source

指标权重

gks 1 year ago
parent
commit
e9b422f05c

+ 6 - 1
.env.development

@@ -5,7 +5,12 @@ VUE_APP_TITLE = 综合保税区管理系统
 ENV = 'development'
 
 # 综合保税区管理系统/开发环境
-VUE_APP_BASE_API = 'http://localhost:9527/zhbsq-service'
+# VUE_APP_BASE_API = 'http://192.168.0.111:9527/zhbsq-service'
+
+# VUE_APP_BASE_API = 'http://106.55.241.82:9527/zhbsq-service'
+
+VUE_APP_BASE_API = 'http://192.168.1.24:9527/zhbsq-service'
+
 # 请求、响应数据加密
 VUE_APP_AES_ENCRYPT_ENABLED = 'false'
 # 请求数据加密秘钥串

File diff suppressed because it is too large
+ 515 - 189
package-lock.json


+ 1 - 1
package.json

@@ -39,7 +39,7 @@
     "@riophae/vue-treeselect": "0.4.0",
     "axios": "0.24.0",
     "clipboard": "2.0.8",
-    "core-js": "^3.25.0",
+    "core-js": "^3.32.1",
     "crypto-js": "^4.1.1",
     "echarts": "4.9.0",
     "element-ui": "2.15.8",

+ 8 - 0
src/api/norm/NORM.js

@@ -51,3 +51,11 @@ export function delNORM(id) {
     method: 'get'
   })
 }
+
+// 删除指标分类
+export function exportNORM(id) {
+  return request({
+    url: '/norm/export',
+    method: 'post'
+  })
+}

+ 6 - 6
src/api/norm/NORMFEE.js

@@ -3,7 +3,7 @@ import request from '@/utils/request'
 // 查询指标权重明细列表
 export function listNORMFEE(query) {
   return request({
-    url: '/business/NORMFEE/list',
+    url: '/normFee/list',
     method: 'get',
     params: query
   })
@@ -12,7 +12,7 @@ export function listNORMFEE(query) {
 // 查询指标权重明细所有列表
 export function listAllNORMFEE(query) {
   return request({
-    url: '/business/NORMFEE/listAll',
+    url: '/normFee/listAll',
     method: 'get',
     params: query
   })
@@ -21,7 +21,7 @@ export function listAllNORMFEE(query) {
 // 查询指标权重明细详细
 export function getNORMFEE(id) {
   return request({
-    url: '/business/NORMFEE/getInfo/' + id,
+    url: '/normFee/getInfo/' + id,
     method: 'get'
   })
 }
@@ -29,7 +29,7 @@ export function getNORMFEE(id) {
 // 新增指标权重明细
 export function addNORMFEE(data) {
   return request({
-    url: '/business/NORMFEE/add',
+    url: '/normFee/add',
     method: 'post',
     data: data
   })
@@ -38,7 +38,7 @@ export function addNORMFEE(data) {
 // 修改指标权重明细
 export function updateNORMFEE(data) {
   return request({
-    url: '/business/NORMFEE/edit',
+    url: '/normFee/edit',
     method: 'post',
     data: data
   })
@@ -47,7 +47,7 @@ export function updateNORMFEE(data) {
 // 删除指标权重明细
 export function delNORMFEE(id) {
   return request({
-    url: '/business/NORMFEE/remove/' + id,
+    url: '/normFee/remove/' + id,
     method: 'get'
   })
 }

+ 6 - 0
src/assets/route_images/u211.svg

@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="22px" height="22px" xmlns="http://www.w3.org/2000/svg">
+  <g transform="matrix(1 0 0 1 -49 -34 )">
+    <path d="M 8.60000000000002 12.2  C 6.97662056158634 12.199934132478  5.55388841480578 13.2860267212121  5.12599999999998 14.852  C 6.49870485799852 15.3961475625936  7.40012847841706 16.7231409205093  7.40012847841706 18.1997638233011  C 7.40012847841706 20.1886516643917  5.78781631950773 21.8009638233011  3.79892847841705 21.8009638233011  C 1.81004063732644 21.8009638233011  0.197728478417105 20.1886516643917  0.197728478417105 18.1997638233011  C 0.197728478417105 16.6730637123811  1.16039292300007 15.3122761970967  2.60000000000002 14.804  L 2.60000000000002 7.19600000000003  C 1.16094663946939 6.68740852297174  0.198800000000006 5.32689770716672  0.198800000000006 3.80061468460502  C 0.198800000000006 1.81172684351435  1.81111215890934 0.199414684605017  3.80000000000001 0.199414684605017  C 5.78888784109063 0.199414684605017  7.40120000000002 1.81172684351435  7.40120000000002 3.80061468460502  C 7.40120000000002 5.32689770716672  6.43905336053064 6.68740852297174  5 7.19600000000003  L 5 11  C 6.00319999999999 10.2464  7.24880000000002 9.80000000000001  8.60000000000002 9.80000000000001  L 13.4 9.80000000000001  C 15.0233794384137 9.80006586752199  16.4461115851942 8.71397327878793  16.874 7.14800000000002  C 15.5006593449395 6.60417258812214  14.5986658739312 5.27685457564388  14.5986658739312 3.79975850268465  C 14.5986658739312 1.81087066159398  16.2109780328406 0.198558502684648  18.1998658739312 0.198558502684648  C 20.1887537150218 0.198558502684648  21.8010658739312 1.81087066159398  21.8010658739312 3.79975850268465  C 21.8010658739312 5.36000833833219  20.796327700009 6.742785341733  19.3124 7.22480000000002  C 18.8134624672641 10.1001800186535  16.3183469407529 12.1997840318289  13.4 12.2  L 8.60000000000002 12.2  Z " fill-rule="nonzero" fill="#6c76f4" stroke="none" transform="matrix(1 0 0 1 49 34 )" />
+  </g>
+</svg>

File diff suppressed because it is too large
+ 3 - 0
src/assets/route_images/u214.svg


+ 6 - 0
src/assets/route_images/u217.svg

@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="23px" height="22px" xmlns="http://www.w3.org/2000/svg">
+  <g transform="matrix(1 0 0 1 -139 -34 )">
+    <path d="M 1.09316770186335 0  L 18.583850931677 0  C 19.1872795031056 0  19.6770186335404 0.489739130434785  19.6770186335404 1.09316770186335  L 19.6770186335404 5.20019875776399  L 9.83960248447205 15.0387080745342  L 9.83304347826088 19.6715527950311  L 14.4746335403727 19.6781118012422  L 19.6770186335404 14.4757267080745  L 19.6770186335404 20.7701863354037  C 19.6770186335404 21.3736149068323  19.1872795031056 21.8633540372671  18.583850931677 21.8633540372671  L 1.09316770186335 21.8633540372671  C 0.489739130434785 21.8633540372671  0 21.3736149068323  0 20.7701863354037  L 0 1.09316770186335  C 0 0.489739130434785  0.489739130434785 0  1.09316770186335 0  Z M 12.0248447204969 15.9449440993789  L 20.5275031055901 7.4422857142857  L 22.0732422360249 8.98802484472051  L 13.5705838509317 17.4906832298137  L 12.0226583850932 17.4884968944099  L 12.0248447204969 15.9449440993789  Z M 9.83850931677018 13.1180124223603  L 9.83850931677018 10.9316770186336  L 4.37267080745343 10.9316770186336  L 4.37267080745343 13.1180124223603  L 9.83850931677018 13.1180124223603  Z M 13.1180124223603 8.74534161490683  L 13.1180124223603 6.55900621118013  L 4.37267080745343 6.55900621118013  L 4.37267080745343 8.74534161490683  L 13.1180124223603 8.74534161490683  Z " fill-rule="nonzero" fill="#fddb78" stroke="none" transform="matrix(1 0 0 1 139 34 )" />
+  </g>
+</svg>

+ 6 - 0
src/assets/route_images/u220.svg

@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="22px" height="21px" xmlns="http://www.w3.org/2000/svg">
+  <g transform="matrix(1 0 0 1 -239 -109 )">
+    <path d="M 20.9 16.5  L 12.1 16.5  L 12.1 18.7  L 16.5 18.7  L 16.5 21  L 5.5 21  L 5.5 18.7  L 9.90000000000003 18.7  L 9.90000000000003 16.5  L 1.09999999999997 16.5  C 0.492486775186137 16.5  0 16.0075132248139  0 15.4  L 0 1.09999999999998  C 0 0.492486775186137  0.492486775186137 0  1.09999999999997 0  L 20.9 0  C 21.5075132248139 0  22 0.492486775186137  22 1.09999999999998  L 22 15.4  C 22 16.0075132248139  21.5075132248139 16.5  20.9 16.5  Z M 14.3 8.25  L 8.80000000000001 4.95000000000002  L 8.80000000000001 11.55  L 14.3 8.25  Z " fill-rule="nonzero" fill="#6c76f4" stroke="none" transform="matrix(1 0 0 1 239 109 )" />
+  </g>
+</svg>

+ 6 - 0
src/assets/route_images/u223.svg

@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="20px" height="23px" xmlns="http://www.w3.org/2000/svg">
+  <g transform="matrix(1 0 0 1 -44 -109 )">
+    <path d="M 20 21.1111111111111  C 20 21.7247608331454  19.5025386109231 22.2222222222222  18.8888888888889 22  L 1.11111111111111 22  C 0.497461389076904 22.2222222222222  0 21.7247608331454  0 21.1111111111111  L 0 1.11111111111111  C 0 0.497461389076904  0.497461389076904 0  1.11111111111111 0  L 18.8888888888889 0  C 19.5025386109231 0  20 0.497461389076904  20 1.11111111111111  L 20 21.1111111111111  Z M 8.88888888888889 4.44444444444446  L 4.44444444444446 4.44444444444446  L 4.44444444444446 8.88888888888889  L 8.88888888888889 8.88888888888889  L 8.88888888888889 4.44444444444446  Z M 15.5555555555555 11  L 4.44444444444446 11  L 4.44444444444446 13  L 15.5555555555555 13  L 15.5555555555555 11  Z M 15.5555555555555 15.5555555555555  L 4.44444444444446 15.5555555555555  L 4.44444444444446 17.7777777777778  L 15.5555555555555 17.7777777777778  L 15.5555555555555 15.5555555555555  Z M 15.5555555555555 5.55555555555554  L 11.1111111111111 5.55555555555554  L 11.1111111111111 7.77777777777777  L 15.5555555555555 7.77777777777777  L 15.5555555555555 5.55555555555554  Z " fill-rule="nonzero" fill="#28d094" stroke="none" transform="matrix(1 0 0 1 44 109 )" />
+  </g>
+</svg>

+ 6 - 0
src/assets/route_images/u226.svg

@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="20px" height="23px" xmlns="http://www.w3.org/2000/svg">
+  <g transform="matrix(1 0 0 1 -239 -32 )">
+    <path d="M 1.12222222222223 4.44444444444446  L 4.44444444444446 4.44444444444446  L 4.44444444444446 1.11111111111111  C 4.44444444444446 0.497461389076904  4.94190583352133 0  5.55555555555554 0  L 18.8888888888889 0  C 19.5025386109231 0  20 0.497461389076904  20 1.11111111111111  L 20 16.6666666666667  C 20 17.2803163887009  19.5025386109231 17.7777777777778  18.8888888888889 17.7777777777778  L 15.5555555555555 17.7777777777778  L 15.5555555555555 21.1111111111111  C 15.5555555555555 21.7244444444445  15.0555555555555 22.2222222222222  14.4366666666667 22  L 1.11888888888888 22  C 1.11666651321747 22.2222355444641  1.11444410260722 22.22224220563  1.11222168700547 22.22224220563  C 0.498384383915607 22.22224220563  0.000602195202901612 21.7249481188139  0 21.1111111111111  L 0.0033333333333303 5.55555555555554  C 0.0033333333333303 4.94222222222223  0.50333333333333 4.44444444444446  1.12222222222223 4.44444444444446  Z M 6.66666666666666 2.22222222222223  L 6.66666666666666 4.44444444444446  L 15.5555555555555 4.44444444444446  L 15.5555555555555 15.5555555555556  L 17.7777777777778 15.5555555555556  L 17.7777777777778 2.22222222222223  L 6.66666666666666 2.22222222222223  Z M 11.1111111111111 10  L 4.44444444444446 10  L 4.44444444444446 12.2222222222222  L 11.1111111111111 12.2222222222222  L 11.1111111111111 10  Z M 11.1111111111111 14.4444444444445  L 4.44444444444446 14.4444444444445  L 4.44444444444446 16.6666666666667  L 11.1111111111111 16.6666666666667  L 11.1111111111111 14.4444444444445  Z " fill-rule="nonzero" fill="#fa746b" stroke="none" transform="matrix(1 0 0 1 239 32 )" />
+  </g>
+</svg>

+ 6 - 0
src/assets/route_images/u229.svg

@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="23px" height="17px" xmlns="http://www.w3.org/2000/svg">
+  <g transform="matrix(1 0 0 1 -139 -113 )">
+    <path d="M 11.5 14.6363636363636  C 17.8511363636364 14.6363636363636  23 11.8282727272727  23 8.36363636363637  L 23 10.4545454545455  C 23 13.9191818181818  17.8511363636364 16.7272727272727  11.5 16.7272727272727  C 5.26177272727273 16.7272727272727  0.184000000000026 14.0185  0.00522727272726797 10.6395909090909  L 0 10.4545454545455  L 0 8.36363636363637  C 0 11.8282727272727  5.14886363636361 14.6363636363636  11.5 14.6363636363636  Z M 0 6.27272727272725  C 0 2.80809090909094  5.14886363636361 0  11.5 0  C 17.8511363636364 0  23 2.80809090909094  23 6.27272727272725  C 23 9.73736363636363  17.8511363636364 12.5454545454546  11.5 12.5454545454546  C 5.14886363636361 12.5454545454546  0 9.73736363636363  0 6.27272727272725  Z " fill-rule="nonzero" fill="#6c76f4" stroke="none" transform="matrix(1 0 0 1 139 113 )" />
+  </g>
+</svg>

File diff suppressed because it is too large
+ 3 - 0
src/assets/route_images/u232.svg


File diff suppressed because it is too large
+ 3 - 0
src/assets/route_images/u238.svg


+ 6 - 0
src/assets/route_images/u243.svg

@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<svg version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="20px" height="20px" xmlns="http://www.w3.org/2000/svg">
+  <g transform="matrix(1 0 0 1 -20 -15 )">
+    <path d="M 20 10  C 20 15.523  15.523 20  10 20  C 4.477 20  0 15.523  0 10  C 0 4.477  4.477 0  10 0  C 15.523 0  20 4.477  20 10  Z M 10 18  C 14.4182779986463 18  18 14.4182779986463  18 10  C 18 5.58172200135365  14.4182779986463 2.00000000000001  10 2.00000000000001  C 5.58172200135365 2.00000000000001  2 5.58172200135365  2 10  C 2 14.4182779986463  5.58172200135365 18  10 18  Z M 16.074 6.929  L 9.003 14  L 4.76 9.75699999999999  L 6.174 8.343  L 9.003 11.172  L 14.659 5.515  L 16.074 6.929  Z " fill-rule="nonzero" fill="#28d094" stroke="none" transform="matrix(1 0 0 1 20 15 )" />
+  </g>
+</svg>

+ 44 - 34
src/components/TopNav/index.vue

@@ -1,30 +1,23 @@
 <template>
-  <el-menu
-    :default-active="activeMenu"
-    mode="horizontal"
-    @select="handleSelect"
-  >
-    <template v-for="(item, index) in topMenus">
-      <el-menu-item :style="{'--theme': theme}" :index="item.path" :key="index" v-if="index < visibleNumber"
-        ><svg-icon :icon-class="item.meta.icon" />
-        {{ item.meta.title }}</el-menu-item
-      >
-    </template>
-
-    <!-- 顶部菜单超出数量折叠 -->
-    <el-submenu :style="{'--theme': theme}" index="more" v-if="topMenus.length > visibleNumber">
-      <template slot="title">更多菜单</template>
+  <el-dialog :modal="false" :before-close="closeMenuHandler" :visible.sync="isShowMenu" :fullscreen="true">
+    <el-menu :default-active="activeMenu" mode="horizontal" @select="handleSelect">
       <template v-for="(item, index) in topMenus">
-        <el-menu-item
-          :index="item.path"
-          :key="index"
-          v-if="index >= visibleNumber"
-          ><svg-icon :icon-class="item.meta.icon" />
-          {{ item.meta.title }}</el-menu-item
-        >
+        <el-menu-item :style="{ '--theme': theme }" :index="item.path" :key="index" v-if="index < visibleNumber"><svg-icon
+            :icon-class="item.meta.icon" />
+          {{ item.meta.title }}</el-menu-item>
       </template>
-    </el-submenu>
-  </el-menu>
+
+      <!-- 顶部菜单超出数量折叠 -->
+      <el-submenu :style="{ '--theme': theme }" index="more" v-if="topMenus.length > visibleNumber">
+        <template slot="title">更多菜单</template>
+        <template v-for="(item, index) in topMenus">
+          <el-menu-item :index="item.path" :key="index" v-if="index >= visibleNumber"><svg-icon
+              :icon-class="item.meta.icon" />
+            {{ item.meta.title }}</el-menu-item>
+        </template>
+      </el-submenu>
+    </el-menu>
+  </el-dialog>
 </template>
 
 <script>
@@ -34,6 +27,12 @@ import { constantRoutes } from "@/router";
 const hideList = ['/index', '/user/profile'];
 
 export default {
+  props: {
+    isShowMenu: {
+      type: Boolean,
+      default: false,
+    }
+  },
   data() {
     return {
       // 顶部栏初始数
@@ -53,9 +52,9 @@ export default {
         if (menu.hidden !== true) {
           // 兼容顶部栏一级菜单内部跳转
           if (menu.path === "/") {
-              topMenus.push(menu.children[0]);
+            topMenus.push(menu.children[0]);
           } else {
-              topMenus.push(menu);
+            topMenus.push(menu);
           }
         }
       });
@@ -71,10 +70,10 @@ export default {
       this.routers.map((router) => {
         for (var item in router.children) {
           if (router.children[item].parentPath === undefined) {
-            if(router.path === "/") {
+            if (router.path === "/") {
               router.children[item].path = "/" + router.children[item].path;
             } else {
-              if(!this.ishttp(router.children[item].path)) {
+              if (!this.ishttp(router.children[item].path)) {
                 router.children[item].path = router.path + "/" + router.children[item].path;
               }
             }
@@ -93,7 +92,7 @@ export default {
         const tmpPath = path.substring(1, path.length);
         activePath = "/" + tmpPath.substring(0, tmpPath.indexOf("/"));
         this.$store.dispatch('app/toggleSideBarHide', false);
-      } else if(!this.$route.children) {
+      } else if (!this.$route.children) {
         activePath = path;
         this.$store.dispatch('app/toggleSideBarHide', true);
       }
@@ -111,6 +110,12 @@ export default {
     this.setVisibleNumber();
   },
   methods: {
+
+    closeMenuHandler(){
+      console.log("close");
+      this.$emit("closeMenuHandler");
+    },
+
     // 根据宽度计算设置显示栏数
     setVisibleNumber() {
       const width = document.body.getBoundingClientRect().width / 3;
@@ -143,7 +148,7 @@ export default {
           }
         });
       }
-      if(routes.length > 0) {
+      if (routes.length > 0) {
         this.$store.commit("SET_SIDEBAR_ROUTERS", routes);
       }
     },
@@ -154,8 +159,8 @@ export default {
 };
 </script>
 
-<style lang="scss">
-.topmenu-container.el-menu--horizontal > .el-menu-item {
+<style scoped lang="scss">
+.topmenu-container.el-menu--horizontal>.el-menu-item {
   float: left;
   height: 50px !important;
   line-height: 50px !important;
@@ -164,13 +169,14 @@ export default {
   margin: 0 10px !important;
 }
 
-.topmenu-container.el-menu--horizontal > .el-menu-item.is-active, .el-menu--horizontal > .el-submenu.is-active .el-submenu__title {
+.topmenu-container.el-menu--horizontal>.el-menu-item.is-active,
+.el-menu--horizontal>.el-submenu.is-active .el-submenu__title {
   border-bottom: 2px solid #{'var(--theme)'} !important;
   color: #303133;
 }
 
 /* submenu item */
-.topmenu-container.el-menu--horizontal > .el-submenu .el-submenu__title {
+.topmenu-container.el-menu--horizontal>.el-submenu .el-submenu__title {
   float: left;
   height: 50px !important;
   line-height: 50px !important;
@@ -178,4 +184,8 @@ export default {
   padding: 0 5px !important;
   margin: 0 10px !important;
 }
+
+.el-dialog > .el-dialog__body{
+  padding: 0 !important;
+}
 </style>

+ 112 - 10
src/layout/components/Navbar.vue

@@ -1,12 +1,30 @@
 <template>
   <div class="navbar">
-    <hamburger id="hamburger-container" :is-active="sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" />
+    <div style="display: flex; justify-content: center;">
+      <div class="cursor index menu-hover" @click="handlerIndex">首页</div>
+      <div class="cursor menu menu-hover" @click="handlerShowMenu">数据接口</div>
+      <div style="margin: 0 20px; position: relative;">
+        <!-- <ul v-show="isShowMenu" class="menu-list"> -->
+          <top-nav class="menu-list" @closeMenuHandler="handlerShowMenu" :isShowMenu="isShowMenu"></top-nav>
+          <!--           
+          <div class="manu-item-container cursor" @click="handlerRouteData(item,index)" v-for="(item, index) in routeData">
+            <img :src="routeImgs[index]" class="menu-item-img" alt="" srcset="">
+            <li :key="item.path + index" class="menu-item ">{{ item.meta.title }}
+            </li>
+          </div> -->
+        <!-- </ul> -->
+      </div>
+    </div>
+
+    <!-- 伸缩按钮 -->
+    <hamburger id="hamburger-container" :is-active="sidebar.opened" class="hamburger-container"
+      @toggleClick="toggleSideBar" />
 
-    <breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!topNav"/>
-    <top-nav id="topmenu-container" class="topmenu-container" v-if="topNav"/>
+    <breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!topNav" />
+    <!-- <top-nav id="topmenu-container" class="topmenu-container" v-if="topNav" /> -->
 
     <div class="right-menu">
-      <template v-if="device!=='mobile'">
+      <template v-if="device !== 'mobile'">
         <search id="header-search" class="right-menu-item" />
 
         <screenfull id="screenfull" class="right-menu-item hover-effect" />
@@ -49,7 +67,15 @@ import Search from '@/components/HeaderSearch'
 import RuoYiGit from '@/components/RuoYi/Git'
 import RuoYiDoc from '@/components/RuoYi/Doc'
 
+
+
 export default {
+  data() {
+    return {
+      isShowMenu: false,
+      routeImgs: [require('@/assets/route_images/u211.svg'), require('@/assets/route_images/u217.svg'), require('@/assets/route_images/u226.svg'), require('@/assets/route_images/u214.svg'), require('@/assets/route_images/u223.svg'), require('@/assets/route_images/u229.svg'), require('@/assets/route_images/u220.svg'), require('@/assets/route_images/u232.svg')],
+    }
+  },
   components: {
     Breadcrumb,
     TopNav,
@@ -64,7 +90,8 @@ export default {
     ...mapGetters([
       'sidebar',
       'avatar',
-      'device'
+      'device',
+      'sidebarRouters'
     ]),
     setting: {
       get() {
@@ -96,19 +123,94 @@ export default {
         this.$store.dispatch('LogOut').then(() => {
           location.href = '/ruoyi-vue-web/index';
         })
-      }).catch(() => {});
+      }).catch(() => { });
+    },
+    handlerShowMenu() {
+      console.log(123);
+      this.isShowMenu = !this.isShowMenu;
+    },
+    handlerRouteData(item, index) {
+    },
+
+    handlerIndex() {
+      this.$router.push("/index")
     }
-  }
+  },
 }
 </script>
 
 <style lang="scss" scoped>
 .navbar {
   height: 50px;
-  overflow: hidden;
+  // overflow: hidden;
   position: relative;
   background: #fff;
-  box-shadow: 0 1px 4px rgba(0,21,41,.08);
+  box-shadow: 0 1px 4px rgba(0, 21, 41, .08);
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+
+  .index {
+    width: 80px;
+    text-align: center;
+  }
+
+  .cursor {
+    cursor: pointer;
+  }
+
+  .menu-hover {
+    padding: 10px;
+
+    &:hover {
+      background-color: rgb(221, 235, 248);
+    }
+  }
+
+  .menu-list {
+    overflow: hidden;
+    padding: 10px;
+    position: absolute;
+    top: 30px;
+    background-color: rgba(255, 255, 255, 1);
+    box-sizing: border-box;
+    // border-width: 1px;
+    // border-style: solid;
+    // border-color: rgba(228, 228, 228, 1);
+    // border-radius: 10px;
+    left: -100px;
+    z-index: 1;
+    list-style: none;
+    display: flex;
+    flex-wrap: wrap;
+    flex-direction: row;
+    width: 365px;
+    height: 50vh;
+    justify-content: start;
+
+    .manu-item-container {
+      width: 80px;
+      height: 80px;
+      font-size: 14px;
+      // background-color: rgb(0, 140, 140);
+      margin-left: 4px;
+      display: flex;
+      align-items: center;
+      justify-content: center;
+      flex-direction: column;
+      border-radius: 10px;
+
+      &:hover {
+        background-color: rgb(221, 235, 248);
+      }
+    }
+
+    .menu-item-img {
+      width: 22px;
+      height: 22px;
+      margin-bottom: 10px;
+    }
+  }
 
   .hamburger-container {
     line-height: 46px;
@@ -116,7 +218,7 @@ export default {
     float: left;
     cursor: pointer;
     transition: background .3s;
-    -webkit-tap-highlight-color:transparent;
+    -webkit-tap-highlight-color: transparent;
 
     &:hover {
       background: rgba(0, 0, 0, .025)

+ 32 - 0
src/layout/components/NormDialog/index.vue

@@ -0,0 +1,32 @@
+<template>
+    <!-- 指标详情模态框 -->
+    <el-dialog :title="title" :visible.sync="openDetail" append-to-body>
+        <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+            <el-form-item label-width="100px" label="指标分类编号">
+                <el-input v-model="form.code"></el-input>
+            </el-form-item>
+            <el-form-item label-width="100px" label="指标分类名称">
+                <el-input v-model="form.name"></el-input>
+            </el-form-item>
+            <el-form-item label-width="100px" label="备注">
+                <el-input type="textarea" v-model="form.remark"></el-input>
+            </el-form-item>
+            <el-form-item label-width="100px" prop="status" label="状态">
+                <el-radio-group v-model="form.status">
+                    <el-radio label="1">启用</el-radio>
+                    <el-radio label="0">不启用</el-radio>
+                </el-radio-group>
+            </el-form-item>
+        </el-form>
+        <div slot="footer" class="dialog-footer">
+            <el-button type="primary" @click="submitForm">确 定</el-button>
+            <el-button @click="cancel">取 消</el-button>
+        </div>
+    </el-dialog>
+</template>
+
+<script>
+export default
+</script>
+
+<style lang="scss"></style>

+ 1 - 1
src/settings.js

@@ -12,7 +12,7 @@ module.exports = {
   /**
    * 是否显示顶部导航
    */
-  topNav: false,
+  topNav: true,
 
   /**
    * 是否显示 tagsView

+ 234 - 189
src/views/norm/feeindex.vue

@@ -1,143 +1,164 @@
 <template>
-  <div class="app-container">
-    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
-      <el-form-item label="是否启用(1=启用,0不启用)" prop="status">
-        <el-select v-model="queryParams.status" placeholder="请选择是否启用(1=启用,0不启用)" clearable filterable>
-          <el-option
-            v-for="dict in dict.type.dictType"
-            :key="dict.value"
-            :label="dict.label"
-            :value="dict.value"
-          />
-        </el-select>
-      </el-form-item>
-      <el-form-item>
-        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
-        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
-      </el-form-item>
-    </el-form>
+  <el-dialog title="指标权重明细" :visible.sync="isShowNormDialog" width="80vw" :before-close="closeHandler">
+    <div class="app-container">
+      <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+        <el-form-item label="是否启用" prop="status">
+          <el-select v-model="queryParams.status" placeholder="请选择是否启用" clearable filterable>
+            <el-option v-for="dict in dict.type.dictType" :key="dict.value" :label="dict.label" :value="dict.value" />
+          </el-select>
+        </el-form-item>
+        <el-form-item>
+          <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+          <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+        </el-form-item>
+      </el-form>
 
-    <el-row :gutter="10" class="mb8">
-      <el-col :span="1.5">
-        <el-button
-          type="primary"
-          plain
-          icon="el-icon-plus"
-          size="mini"
-          @click="handleAdd"
-          v-hasPermi="['business:NORMFEE:add']"
-        >新增</el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="success"
-          plain
-          icon="el-icon-edit"
-          size="mini"
-          :disabled="single"
-          @click="handleUpdate"
-          v-hasPermi="['business:NORMFEE:edit']"
-        >修改</el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="danger"
-          plain
-          icon="el-icon-delete"
-          size="mini"
-          :disabled="multiple"
-          @click="handleDelete"
-          v-hasPermi="['business:NORMFEE:remove']"
-        >删除</el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="warning"
-          plain
-          icon="el-icon-download"
-          size="mini"
-          @click="handleExport"
-          v-hasPermi="['business:NORMFEE:export']"
-        >导出</el-button>
-      </el-col>
-      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
-    </el-row>
+      <el-row :gutter="10" class="mb8">
+        <el-col :span="1.5">
+          <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
+            v-hasPermi="['business:NORMFEE:add']">新增</el-button>
+        </el-col>
+        <el-col :span="1.5">
+          <el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
+            v-hasPermi="['business:NORMFEE:edit']">修改</el-button>
+        </el-col>
+        <el-col :span="1.5">
+          <el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
+            v-hasPermi="['business:NORMFEE:remove']">删除</el-button>
+        </el-col>
+        <el-col :span="1.5">
+          <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
+            v-hasPermi="['business:NORMFEE:export']">导出</el-button>
+        </el-col>
+        <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+      </el-row>
 
-    <el-table v-loading="loading" :data="NORMFEEList" @selection-change="handleSelectionChange">
-      <el-table-column type="selection" width="55" align="center" />
-      <el-table-column label="${comment}" align="center" prop="id"/>
-      <el-table-column label="创建时间" align="center" prop="createTime"/>
-      <el-table-column label="创建人" align="center" prop="createBy"/>
-      <el-table-column label="修改时间" align="center" prop="updateTime"/>
-      <el-table-column label="修改人" align="center" prop="updateBy"/>
-      <el-table-column label="删除标识" align="center" prop="delFlag"/>
-      <el-table-column label="部门id" align="center" prop="deptId"/>
-      <el-table-column label="指标分类id" align="center" prop="normId"/>
-      <el-table-column label="分类占比" align="center" prop="normRatio"/>
-      <el-table-column label="指标参数名称" align="center" prop="fname"/>
-      <el-table-column label="计量单位" align="center" prop="funit"/>
-      <el-table-column label="权数" align="center" prop="fnumber"/>
-      <el-table-column label="指标参数" align="center" prop="fvalue"/>
-      <el-table-column label="是否启用(1=启用,0不启用)" align="center" prop="status"/>
-      <el-table-column label="启用时间" align="center" prop="startTime"/>
-      <el-table-column label="停用时间" align="center" prop="stopTime"/>
-      <el-table-column label="备注" align="center" prop="remark"/>
-      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
-        <template slot-scope="scope">
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-edit"
-            @click="handleUpdate(scope.row)"
-            v-hasPermi="['business:NORMFEE:edit']"
-          >修改</el-button>
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-delete"
-            @click="handleDelete(scope.row)"
-            v-hasPermi="['business:NORMFEE:remove']"
-          >删除</el-button>
-        </template>
-      </el-table-column>
-    </el-table>
+      <el-table  v-loading="loading" :data="normData" @selection-change="handleSelectionChange">
+        <el-table-column type="selection" width="55" align="center" />
+        <el-table-column label="分类占比" align="center" prop="normRatio" />
+        <el-table-column label="指标参数名称" align="center" prop="fname" />
+        <el-table-column label="计量单位" align="center" prop="funit" />
+        <el-table-column label="权数" align="center" prop="fnumber" />
+        <el-table-column label="指标参数" align="center" prop="fvalue" />
+        <el-table-column label="是否启用" align="center" prop="status">
+          <template slot-scope="scope">
+            <el-switch v-model="scope.row.status" @change="changeSwitchHandler(scope.row)" active-color="#13ce66"
+              inactive-color="#ff4949">
+            </el-switch>
+          </template>
+        </el-table-column>
+        <el-table-column label="启用时间" align="center" prop="startTime" />
+        <el-table-column label="停用时间" align="center" prop="stopTime" />
+        <el-table-column label="备注" align="center" prop="remark" />
+        <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+          <template slot-scope="scope">
+            <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
+              v-hasPermi="['business:NORMFEE:edit']">修改</el-button>
+            <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
+              v-hasPermi="['business:NORMFEE:remove']">删除</el-button>
+          </template>
+        </el-table-column>
+      </el-table>
 
-    <pagination
-      v-show="total>0"
-      :total="total"
-      :page.sync="queryParams.pageNum"
-      :limit.sync="queryParams.pageSize"
-      @pagination="getList"
-    />
+      <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
+        @pagination="getList" />
 
-    <!-- 添加或修改指标权重明细对话框 -->
-    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
-      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
-        <el-form-item label="是否启用(1=启用,0不启用)">
-          <el-radio-group v-model="form.status">
-            <el-radio
-              v-for="dict in dict.type.dictType"
-              :key="dict.value"
-:label="dict.value"
-            >{{dict.label}}</el-radio>
-          </el-radio-group>
-        </el-form-item>
-      </el-form>
-      <div slot="footer" class="dialog-footer">
-        <el-button type="primary" @click="submitForm">确 定</el-button>
-        <el-button @click="cancel">取 消</el-button>
-      </div>
-    </el-dialog>
-  </div>
+      <!-- 添加或修改指标权重明细对话框 -->
+      <el-dialog :title="title" :visible.sync="open" width="60%" append-to-body>
+        <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+          <el-form-item label="权数" prop="fnumber">
+            <el-input v-model.number="form.fnumber"></el-input>
+          </el-form-item>
+
+          <el-form-item label="分类占比" prop="normRatio">
+            <el-input v-model="form.normRatio"></el-input>
+          </el-form-item>
+
+          <el-form-item label="计量单位" prop='funit'>
+
+            <el-select v-model="form.funit" @change="selUnitHandler" placeholder="请选择">
+              <el-option v-for="dict in unitSel" :key="dict.dictCode" :label="dict.dictLabel"
+                :value="dict.dictValue"></el-option>
+            </el-select>
+
+          </el-form-item>
+
+          <el-form-item label="指标参数名称" prop='fname'>
+            <el-input v-model="form.fname"></el-input>
+          </el-form-item>
+          <el-form-item label="指标参数" prop='fvalue'>
+            <el-input v-model="form.fvalue"></el-input>
+          </el-form-item>
+
+
+
+          <el-form-item label="上下公差占比" prop='dfRetio'>
+            <el-input v-model="form.dfRetio"></el-input>
+          </el-form-item>
+
+          <el-form-item label="明细类型" prop='type'>
+            <template>
+              <el-radio  v-model="form.type" label="1">采集分类</el-radio>
+              <el-radio  v-model="form.type" label="2">绩效分类</el-radio>
+            </template>
+          </el-form-item>
+
+          <el-form-item  :label="form.type == 2 ? '绩效参考值' : '采集参考值'">
+            <el-input v-model="form.meritsValue" key="2"  v-if="form.type == 2"></el-input>
+            <el-input v-model="form.collValue" key="11"  v-if="form.type == 1"></el-input>
+          </el-form-item>
+
+          <!-- <el-form-item v-if="form.type == 1" key="1" label="采集参考值">
+            <el-input v-model="form.collValue"></el-input>
+          </el-form-item> -->
+
+          <el-form-item label="备注">
+            <el-input type="textarea" v-model="form.remark"></el-input>
+          </el-form-item>
+        </el-form>
+        <div slot="footer" class="dialog-footer">
+          <el-button type="primary" @click="submitForm">确 定</el-button>
+          <el-button @click="cancel">取 消</el-button>
+        </div>
+      </el-dialog>
+    </div>
+  </el-dialog>
 </template>
 
 <script>
 import { listNORMFEE, getNORMFEE, delNORMFEE, addNORMFEE, updateNORMFEE } from "@/api/norm/NORMFEE";
 
+import { listData } from '@/api/system/dict/data';
+
 export default {
   name: "NORMFEE",
+  props: {
+    isShowNormDialog: {
+      type: Boolean,
+      default: () => {
+        return false
+      }
+    },
+    normId: {
+      type: String,
+      default: () => {
+        return null
+      }
+    },
+    normData: {
+      type: Array,
+      defaultL: () => {
+        return []
+      }
+    }
+  },
   data() {
     return {
+      dict: {
+        type: {
+          dictType: ""
+        }
+      },
       // 根路径
       baseURL: process.env.VUE_APP_BASE_API,
       // 遮罩层
@@ -152,8 +173,7 @@ export default {
       showSearch: true,
       // 总条数
       total: 0,
-      // 指标权重明细表格数据
-      NORMFEEList: [],
+
       // 弹出层标题
       title: "",
       // 是否显示弹出层
@@ -163,38 +183,29 @@ export default {
         pageNum: 1,
         pageSize: 10,
         id: null,
-        createTime: null,
-        createBy: null,
-        updateTime: null,
-        updateBy: null,
-        delFlag: null,
-        deptId: null,
-        normId: null,
-        normRatio: null,
-        fname: null,
-        funit: null,
-        fnumber: null,
-        fvalue: null,
-        status: null,
-        startTime: null,
-        stopTime: null,
-        remark: null
+        // createTime: null,
+        // createBy: null,
+        // updateTime: null,
+        // updateBy: null,
+        // delFlag: null,
+        // deptId: null,
+        // normId: null,
+        // normRatio: null,
+        // fname: null,
+        // funit: null,
+        // fnumber: null,
+        // fvalue: null,
+        // status: null,
+        // startTime: null,
+        // stopTime: null,
+        // remark: null
       },
       // 表单参数
       form: {},
       // 表单校验
       rules: {
-        id: [
-          { required: true, message: "$comment不能为空", trigger: "blur" }
-        ],
-        delFlag: [
-          { required: true, message: "删除标识不能为空", trigger: "blur" }
-        ],
-        deptId: [
-          { required: true, message: "部门id不能为空", trigger: "blur" }
-        ],
-        normId: [
-          { required: true, message: "指标分类id不能为空", trigger: "blur" }
+        fnumber: [
+          { required: true, type: "number", message: "权数为数值", trigger: "blur" }
         ],
         normRatio: [
           { required: true, message: "分类占比不能为空", trigger: "blur" }
@@ -205,34 +216,35 @@ export default {
         funit: [
           { required: true, message: "计量单位不能为空", trigger: "blur" }
         ],
-        fnumber: [
-          { required: true, message: "权数不能为空", trigger: "blur" }
-        ],
         fvalue: [
           { required: true, message: "指标参数不能为空", trigger: "blur" }
         ],
-        status: [
-          { required: true, message: "是否启用(1=启用,0不启用)不能为空", trigger: "blur" }
-        ],
-        startTime: [
-          { required: true, message: "启用时间不能为空", trigger: "blur" }
-        ],
-        stopTime: [
-          { required: true, message: "停用时间不能为空", trigger: "blur" }
+        dfRetio: [
+          { required: true,  message: "公差占比", trigger: "blur" }
         ],
-        remark: [
-          { required: true, message: "备注不能为空", trigger: "blur" }
+        type: [
+          { required: true, message: "明细类型", trigger: "blur" }
         ]
-      }
+      },
+      unitSel: null,
     };
   },
-  created() {
+
+  mounted() {
+    listData({
+      pageNum: 1,
+      pageSize: 10,
+      dictType: 'norm_uint'
+    }).then(res => {
+      this.unitSel = res.rows;
+    })
     this.getList();
   },
   methods: {
     /** 查询指标权重明细列表 */
     getList() {
       this.loading = true;
+      this.queryParams.id = this.normId;
       listNORMFEE(this.queryParams).then(response => {
         this.NORMFEEList = response.rows;
         this.total = response.total;
@@ -276,14 +288,20 @@ export default {
     // 多选框选中数据
     handleSelectionChange(selection) {
       this.ids = selection.map(item => item.id)
-      this.single = selection.length!==1
+      this.single = selection.length !== 1
       this.multiple = !selection.length
     },
     /** 新增按钮操作 */
     handleAdd() {
-      this.reset();
       this.open = true;
-      this.title = "添加指标权重明细";
+
+
+
+      // addNORMFEE().then(() => {
+      //   console.log("res");
+      // })
+      // this.reset();
+      // this.title = "添加指标权重明细";
     },
     /** 修改按钮操作 */
     handleUpdate(row) {
@@ -292,45 +310,72 @@ export default {
       getNORMFEE(id).then(response => {
         this.form = response.data;
         this.open = true;
+        this.form = row;
+        console.log(this.form);
+
         this.title = "修改指标权重明细";
       });
     },
     /** 提交按钮 */
     submitForm() {
       this.$refs["form"].validate(valid => {
+        this.form.status = 1;
+        if(this.form.type ==2){
+          this.form.collValue=null;
+        }else{
+          this.form.meritsValue=null;
+        }
         if (valid) {
-          if (this.form.id != null) {
-            updateNORMFEE(this.form).then(response => {
-              this.$modal.msgSuccess("修改成功");
-              this.open = false;
-              this.getList();
-            });
-          } else {
-            addNORMFEE(this.form).then(response => {
-              this.$modal.msgSuccess("新增成功");
-              this.open = false;
-              this.getList();
-            });
-          }
+          this.form.id = this.normId;
+          this.form.status = 1;
+          // if (this.form.id != null) {
+          //   updateNORMFEE(this.form).then(response => {
+          //     this.$modal.msgSuccess("修改成功");
+          //     this.open = false;
+          //     this.getList();
+          //   });
+          // } else {
+          addNORMFEE(this.form).then(response => {
+            this.$modal.msgSuccess("新增成功");
+            this.open = false;
+            this.getList();
+          });
+          // }
         }
       });
     },
     /** 删除按钮操作 */
     handleDelete(row) {
       const ids = row.id || this.ids;
-      this.$modal.confirm('是否确认删除指标权重明细编号为"' + ids + '"的数据项?').then(function() {
+      this.$modal.confirm('是否确认删除指标权重明细编号为"' + ids + '"的数据项?').then(function () {
         return delNORMFEE(ids);
       }).then(() => {
         this.getList();
         this.$modal.msgSuccess("删除成功");
-      }).catch(() => {});
+      }).catch(() => { });
     },
     /** 导出按钮操作 */
     handleExport() {
       this.download('business/NORMFEE/export', {
         ...this.queryParams
       }, `NORMFEE_${new Date().getTime()}.xlsx`)
+    },
+
+    // 关闭Dialog窗口
+    closeHandler() {
+      this.$emit("closeHandler");
+    },
+
+
+    // 选择单位处理
+    selUnitHandler(val) {
+      this.form.funit = val;
     }
-  }
+  },
+  // watch:{
+  //   normId:(newV)=>{
+  //     console.log(newV,"---");
+  //   }
+  // }
 };
 </script>

+ 136 - 137
src/views/norm/index.vue

@@ -1,161 +1,89 @@
 <template>
   <div class="app-container">
-    <el-form
-      :model="queryParams"
-      ref="queryForm"
-      size="small"
-      :inline="true"
-      v-show="showSearch"
-      label-width="68px"
-    >
-      <el-form-item label="状态(1启用,0不启用)" prop="status">
-        <el-select
-          v-model="queryParams.status"
-          placeholder="请选择状态(1启用,0不启用)"
-          clearable
-          filterable
-        >
-          <el-option
-            v-for="dict in statusArr"
-            :key="dict.value"
-            :label="dict.label"
-            :value="dict.value"
-          />
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="状态" prop="status">
+        <el-select v-model="queryParams.status" placeholder="请选择状态(1启用,0不启用)" clearable filterable>
+          <el-option v-for="dict in statusArr" :key="dict.value" :label="dict.label" :value="dict.value" />
         </el-select>
       </el-form-item>
       <el-form-item>
-        <el-button
-          type="primary"
-          icon="el-icon-search"
-          size="mini"
-          @click="handleQuery"
-          >搜索</el-button
-        >
-        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
-          >重置</el-button
-        >
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
       </el-form-item>
     </el-form>
 
     <el-row :gutter="10" class="mb8">
       <el-col :span="1.5">
-        <el-button
-          type="primary"
-          plain
-          icon="el-icon-plus"
-          size="mini"
-          @click="handleAdd"
-          v-hasPermi="['business:NORM:add']"
-          >新增</el-button
-        >
+        <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
+          v-hasPermi="['business:NORM:add']">新增</el-button>
       </el-col>
       <el-col :span="1.5">
-        <el-button
-          type="success"
-          plain
-          icon="el-icon-edit"
-          size="mini"
-          :disabled="single"
-          @click="handleUpdate"
-          v-hasPermi="['business:NORM:edit']"
-          >修改</el-button
-        >
+        <el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
+          v-hasPermi="['business:NORM:edit']">修改</el-button>
       </el-col>
       <el-col :span="1.5">
-        <el-button
-          type="danger"
-          plain
-          icon="el-icon-delete"
-          size="mini"
-          :disabled="multiple"
-          @click="handleDelete"
-          v-hasPermi="['business:NORM:remove']"
-          >删除</el-button
-        >
+        <el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
+          v-hasPermi="['business:NORM:remove']">删除</el-button>
       </el-col>
       <el-col :span="1.5">
-        <el-button
-          type="warning"
-          plain
-          icon="el-icon-download"
-          size="mini"
-          @click="handleExport"
-          v-hasPermi="['business:NORM:export']"
-          >导出</el-button
-        >
+        <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
+          v-hasPermi="['business:NORM:export']">导出</el-button>
       </el-col>
-      <right-toolbar
-        :showSearch.sync="showSearch"
-        @queryTable="getList"
-      ></right-toolbar>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
     </el-row>
 
-    <el-table
-      v-loading="loading"
-      :data="NORMList"
-      @selection-change="handleSelectionChange"
-    >
+    <el-table v-loading="loading"  :data="NORMList" @selection-change="handleSelectionChange">
       <el-table-column type="selection" width="55" align="center" />
-      <el-table-column label="id" align="center" prop="id" />
-      <el-table-column label="创建时间" align="center" prop="createTime" />
-      <el-table-column label="创建人" align="center" prop="createBy" />
+      <!-- <el-table-column label="id" align="center" prop="id" /> -->
+      <!-- <el-table-column label="创建时间" align="center" prop="createTime" /> -->
+      <!-- <el-table-column label="创建人" align="center" prop="createBy" />
       <el-table-column label="修改时间" align="center" prop="updateTime" />
-      <el-table-column label="修改人" align="center" prop="updateBy" />
-      <el-table-column label="删除标识" align="center" prop="delFlag" />
-      <el-table-column label="部门id" align="center" prop="deptId" />
-      <el-table-column label="指标分类名称" align="center" prop="name" />
+      <el-table-column label="修改人" align="center" prop="updateBy" /> -->
+      <!-- <el-table-column label="删除标识" align="center" prop="delFlag" /> -->
+      <!-- <el-table-column label="部门id" align="center" prop="deptId" /> -->
+      <el-table-column label="指标分类名称" align="center">
+        <template slot-scope="scope">
+          <el-link @click="tableBdClick(scope.row)" class="text-color" type="primaty">{{ scope.row.name }}</el-link>
+        </template>
+      </el-table-column>
       <el-table-column label="指标分类编号" align="center" prop="code" />
-      <el-table-column
-        label="状态(1启用,0不启用)"
-        align="center"
-        prop="status"
-      />
+      <el-table-column label="状态" align="center" prop="status">
+        <template slot-scope="scope">
+          <el-switch v-model="scope.row.status" @change="changeSwitchHandler(scope.row)" active-color="#13ce66"
+            inactive-color="#ff4949">
+          </el-switch>
+        </template>
+      </el-table-column>
       <el-table-column label="备注" align="center" prop="remark" />
-      <el-table-column
-        label="操作"
-        align="center"
-        class-name="small-padding fixed-width"
-      >
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
         <template slot-scope="scope">
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-edit"
-            @click="handleUpdate(scope.row)"
-            v-hasPermi="['business:NORM:edit']"
-            >修改</el-button
-          >
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-delete"
-            @click="handleDelete(scope.row)"
-            v-hasPermi="['business:NORM:remove']"
-            >删除</el-button
-          >
+          <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
+            v-hasPermi="['business:NORM:edit']">修改</el-button>
+          <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
+            v-hasPermi="['business:NORM:remove']">删除</el-button>
         </template>
       </el-table-column>
     </el-table>
 
-    <pagination
-      v-show="total > 0"
-      :total="total"
-      :page.sync="queryParams.pageNum"
-      :limit.sync="queryParams.pageSize"
-      @pagination="getList"
-    />
+    <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
+      @pagination="getList" />
 
     <!-- 添加或修改指标分类对话框 -->
     <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
       <el-form ref="form" :model="form" :rules="rules" label-width="80px">
-        <el-form-item label="状态(1启用,0不启用)">
+        <el-form-item label-width="100px" label="指标分类编号">
+          <el-input v-model="form.code"></el-input>
+        </el-form-item>
+        <el-form-item label-width="100px" label="指标分类名称">
+          <el-input v-model="form.name"></el-input>
+        </el-form-item>
+        <el-form-item label-width="100px" label="备注">
+          <el-input type="textarea" v-model="form.remark"></el-input>
+        </el-form-item>
+        <el-form-item label-width="100px" prop="status" label="状态">
           <el-radio-group v-model="form.status">
-            <el-radio
-              v-for="dict in statusArr"
-              :key="dict.value"
-              :label="dict.value"
-              >{{ dict.label }}</el-radio
-            >
+            <el-radio label="1">启用</el-radio>
+            <el-radio label="0">不启用</el-radio>
           </el-radio-group>
         </el-form-item>
       </el-form>
@@ -164,6 +92,10 @@
         <el-button @click="cancel">取 消</el-button>
       </div>
     </el-dialog>
+
+    <feeindex @closeHandler="closeHandler" :normData="normData" :normId="normId" :isShowNormDialog="isShowNormDialog" />
+
+
   </div>
 </template>
 
@@ -174,10 +106,19 @@ import {
   delNORM,
   addNORM,
   updateNORM,
+  exportNORM,
 } from "@/api/norm/NORM";
 
+import { listNORMFEE, getNORMFEE, delNORMFEE, addNORMFEE, updateNORMFEE } from "@/api/norm/NORMFEE";
+
+
+import feeindex from "./feeindex.vue";
+
 export default {
   name: "NORM",
+  components: {
+    feeindex
+  },
   data() {
     return {
       // 根路径
@@ -216,6 +157,17 @@ export default {
         status: null,
         remark: null,
       },
+
+      pageParams: {
+        page: 1,
+        pageSize: 10,
+      },
+
+      // 指标列表每项Id获取到的数据集合
+      normData: [],
+
+      // 指标列表每项Id
+      normId: null,
       // 表单参数
       form: {},
       // 表单校验
@@ -242,7 +194,10 @@ export default {
         ],
         remark: [{ required: true, message: "备注不能为空", trigger: "blur" }],
       },
-      statusArr:[{value : 0,label:"不启用"},{value : 1,label:"启用"}]
+      statusArr: [{ value: 0, label: "不启用" }, { value: 1, label: "启用" }],
+
+      // 点击列表展示模态框
+      isShowNormDialog: false,
     };
   },
   created() {
@@ -253,22 +208,26 @@ export default {
     getList() {
       this.loading = true;
       listNORM(this.queryParams).then((response) => {
+        response.rows.forEach((item, index) => {
+          response.rows[index].status = item.status == 0 ? false : true;
+        });
         this.NORMList = response.rows;
         this.total = response.total;
         this.loading = false;
+
+
+
       });
     },
     // 取消按钮
     cancel() {
       this.open = false;
+      this.isShowNormDialog = false;
       this.reset();
     },
     // 表单重置
     reset() {
       this.form = {
-        id: null,
-        delFlag: null,
-        deptId: null,
         name: null,
         code: null,
         status: "0",
@@ -318,6 +277,7 @@ export default {
               this.open = false;
               this.getList();
             });
+
           } else {
             addNORM(this.form).then((response) => {
               this.$modal.msgSuccess("新增成功");
@@ -340,18 +300,57 @@ export default {
           this.getList();
           this.$modal.msgSuccess("删除成功");
         })
-        .catch(() => {});
+        .catch(() => { });
     },
     /** 导出按钮操作 */
     handleExport() {
-      this.download(
-        "business/NORM/export",
-        {
-          ...this.queryParams,
-        },
-        `NORM_${new Date().getTime()}.xlsx`
-      );
+      exportNORM().then((res) => {
+        this.download(
+          "/norm/export",
+          {
+            ...this.queryParams,
+          },
+          `NORM_${new Date().getTime()}.xlsx`
+        );
+      });
+      // this.download(
+      //   "business/NORM/export",
+      //   {
+      //     ...this.queryParams,
+      //   },
+      //   `NORM_${new Date().getTime()}.xlsx`
+      // );
+    },
+
+    // 关闭Dialog窗口
+    closeHandler() {
+      this.isShowNormDialog = false;
+    },
+
+    // 表格行点击事件处理
+    tableBdClick(row) {
+      this.normId = row.id;
+      listNORMFEE({ id: this.normId, ...this.pageParams }).then((res) => {
+        this.normData = res.rows;
+        console.log(res);
+      })
+      this.isShowNormDialog = !this.isShowNormDialog;
     },
+
+    // 启动开关事件处理
+    changeSwitchHandler(data) {
+      let status = data.status === true ? 1 : 0;
+
+      updateNORM({ id: data.id, status }).then((res) => {
+
+      });
+    }
   },
 };
 </script>
+
+<style lang="scss">
+  .text-color{
+    color: #409eff;
+  }
+</style>

+ 1 - 0
src/views/system/user/index.vue

@@ -573,6 +573,7 @@ export default {
       this.reset();
       const userId = row.userId || this.ids;
       getUser(userId).then(response => {
+        console.log(response);
         this.form = response.data;
         this.postOptions = response.posts;
         this.roleOptions = response.roles;

+ 5 - 1
vue.config.js

@@ -35,7 +35,11 @@ module.exports = {
     proxy: {
       // detail: https://cli.vuejs.org/config/#devserver-proxy
       [process.env.VUE_APP_BASE_API]: {
-        target: `http://localhost:9527`,
+        // target: `http://192.168.0.111:9527`,
+        // target:"http://106.55.241.82:9527",
+        target:`http://192.168.1.24:9527`,
+        
+        
         changeOrigin: true,
         pathRewrite: {
           ['^' + process.env.VUE_APP_BASE_API]: ''

File diff suppressed because it is too large
+ 194 - 187
yarn.lock


Some files were not shown because too many files changed in this diff