Przeglądaj źródła

Merge branch 'deploy_baobiao' of http://git.chelingzhu.com/chelingzhu-web/zxyj-admin-html into deploy_baobiao

lilei 4 lat temu
rodzic
commit
4d1b5df0ef

+ 18 - 2
package-lock.json

@@ -5698,6 +5698,15 @@
         "safer-buffer": "^2.1.0"
       }
     },
+    "echarts": {
+      "version": "5.0.0",
+      "resolved": "https://registry.npmjs.org/echarts/-/echarts-5.0.0.tgz",
+      "integrity": "sha512-6SDcJbLVOcfQyjPg+spNU1+JVrkU1B9fzUa5tpbP/mMNUPyigCOJwcEIQAJSbp9jt5UP3EXvQR0vtYXIo9AjyA==",
+      "requires": {
+        "tslib": "1.10.0",
+        "zrender": "5.0.1"
+      }
+    },
     "editorconfig": {
       "version": "0.15.3",
       "resolved": "https://registry.npmjs.org/editorconfig/-/editorconfig-0.15.3.tgz",
@@ -16202,8 +16211,7 @@
     "tslib": {
       "version": "1.10.0",
       "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.10.0.tgz",
-      "integrity": "sha512-qOebF53frne81cf0S9B41ByenJ3/IuH8yJKngAX35CmiZySA0khhkovshKK+jGCaMnVomla7gVlIcc3EvKPbTQ==",
-      "dev": true
+      "integrity": "sha512-qOebF53frne81cf0S9B41ByenJ3/IuH8yJKngAX35CmiZySA0khhkovshKK+jGCaMnVomla7gVlIcc3EvKPbTQ=="
     },
     "tty-browserify": {
       "version": "0.0.0",
@@ -17562,6 +17570,14 @@
           "dev": true
         }
       }
+    },
+    "zrender": {
+      "version": "5.0.1",
+      "resolved": "https://registry.npmjs.org/zrender/-/zrender-5.0.1.tgz",
+      "integrity": "sha512-i8FNCKAKfF0EfZFJ6w2p30umBrCyy481/PePFQqPdtNgCl5Hp5z7/dovqb7soEoFkhNvhjJ/J4W9zFALeae6yA==",
+      "requires": {
+        "tslib": "1.10.0"
+      }
     }
   }
 }

+ 1 - 0
package.json

@@ -19,6 +19,7 @@
     "axios": "^0.19.0",
     "china-division": "^2.3.1",
     "core-js": "2.6.9",
+    "echarts": "^5.0.0",
     "enquire.js": "^2.1.6",
     "lodash.get": "^4.4.2",
     "lodash.pick": "^4.4.0",

+ 1 - 0
public/index.html

@@ -30,3 +30,4 @@
     <!-- built files will be auto injected -->
   </body>
 </html>
+<script charset="utf-8" src="https://map.qq.com/api/gljs?v=1.exp&key=KJTBZ-2BIAI-DUNGY-5WJXV-XLGN7-ZHFQ7"></script>

+ 0 - 1
src/App.vue

@@ -5,7 +5,6 @@
     </div>
   </a-config-provider>
 </template>
-
 <script>
 import zhCN from 'ant-design-vue/lib/locale-provider/zh_CN'
 import { AppDeviceEnquire } from '@/utils/mixin'

+ 184 - 0
src/components/Echarts/bar.vue

@@ -0,0 +1,184 @@
+<template>
+  <div ref="dom" class="charts chart-bar"></div>
+</template>
+
+<script>
+import echarts from 'echarts'
+import tdTheme from './theme.json'
+import {
+  on,
+  off
+} from '@/libs/tools'
+
+echarts.registerTheme('tdTheme', tdTheme)
+export default {
+  name: 'ChartBar',
+  props: {
+    value: Object, // 单列柱状图,key为x轴,value为y轴
+    text: String,
+    subtext: String,
+    color: String,
+    // 当有多列柱状图展示时的X轴坐标数据
+    xAxisData: {
+      type: Array,
+      default: function () {
+        return []
+      }
+    },
+    // y轴坐标最大值
+    yMax: {
+      type: [Number, String],
+      default: 100
+    },
+    // y轴坐标单位
+    yUnit: {
+      type: String,
+      default: ''
+    },
+    // 当有多列柱状图展示时的y轴坐标数据
+    seriesData: {
+      type: Array,
+      default: function () {
+        return []
+      }
+    },
+    // x轴标签旋转角度
+    xAxisRotate: {
+      type: Number,
+      default: 0
+    }
+  },
+  watch: {
+    xAxisData: {
+      handler (nVal, oVal) {
+        // console.log(nVal, 'nnnnnnnn')
+        if (nVal) {
+          // 根据x轴时间长度控制滚动条位置及显示状态 x轴长度大于25时,显示滚动条并且滚动条结束位置在80%
+          if (nVal.length > 25) {
+            this.isShowZoom = true
+            this.xZoomEnd = 80
+          } else {
+            this.isShowZoom = false
+            this.xZoomEnd = 100
+          }
+          if (nVal.length > 30) {
+            this.xZoomEnd = 70
+          }
+          if (nVal.length > 35) {
+            this.xZoomEnd = 60
+          }
+          if (nVal.length > 40) {
+            this.xZoomEnd = 50
+          }
+          if (nVal.length > 45) {
+            this.xZoomEnd = 40
+          }
+          if (nVal.length > 50) {
+            this.xZoomEnd = 30
+          }
+          this.pageInit()
+        }
+      },
+      deep: true,
+      immediate: true // 代表如果在 wacth 里声明了 xAxisData 之后,就会立即先去执行里面的handler方法,如果为 false就跟我们以前的效果一样,不会在绑定的时候就执行
+    },
+    xAxisRotate: {
+      handler (nVal, oVal) {
+        if (nVal !== '') {
+          this.pageInit()
+        }
+      },
+      deep: true,
+      immediate: true
+    }
+  },
+  data () {
+    return {
+      dom: null,
+      isShowZoom: false, // 是否展示滚动条
+      xZoomEnd: 100 // x轴滚动条结束位置
+    }
+  },
+  methods: {
+    resize () {
+      this.dom.resize()
+    },
+    pageInit () {
+      const legend = this.seriesData.map(_ => _.name)
+      this.$nextTick(() => {
+        const xAxisData = this.value ? Object.keys(this.value) : this.xAxisData
+        const seriesData = this.value ? Object.values(this.value) : this.seriesData
+        const option = {
+          color: [this.color],
+          title: {
+            text: this.text,
+            subtext: this.subtext,
+            x: 'left'
+          },
+          legend: {
+            data: legend
+          },
+          tooltip: {
+            trigger: 'axis'
+          },
+          dataZoom: [{
+            type: 'slider',
+            show: this.isShowZoom, // flase直接隐藏图形
+            xAxisIndex: [0],
+            left: '9%', // 滚动条靠左侧的百分比
+            bottom: -5,
+            start: 0, // 滚动条的起始位置
+            end: this.xZoomEnd, // 滚动条的截止位置(按比例分割你的柱状图x轴长度)
+            zoomLock: true // 锁定区域禁止缩放(鼠标滚动会缩放,所以禁止)
+          }],
+          xAxis: {
+            type: 'category',
+            data: xAxisData,
+            axisLabel: {
+              interval: 0,
+              rotate: this.xAxisRotate // 刻度标签旋转的角度,在类目轴的类目标签显示不下的时候可以通过旋转防止标签之间重叠。旋转的角度从 -90 度到 90 度。
+            }
+          },
+          yAxis: {
+            type: 'value',
+            min: 0,
+            max: this.yMax,
+            axisLabel: {
+              formatter: `{value} ${this.yUnit}`
+            },
+            // interval: 2,
+            position: 'left'
+          }
+        }
+        if (this.value) {
+          option.series = [{
+            data: seriesData,
+            type: 'bar',
+            barWidth: 35,
+            label: {
+              normal: {
+                show: true,
+                position: 'top'
+              }
+            }
+          }]
+        } else {
+          // console.log(this.seriesData, '111111111')
+          option.series = this.seriesData
+        }
+        // console.log(option.series, 'ppppppp')
+        this.dom = echarts.init(this.$refs.dom, 'tdTheme')
+        this.dom.setOption(option)
+        this.dom.resize() // 解决首次加载宽度超出容器bug
+        on(window, 'resize', this.resize)
+      })
+    }
+  },
+  mounted () {
+    this.pageInit()
+  },
+  beforeDestroy () {
+    off(window, 'resize', this.resize)
+  }
+}
+</script>

+ 4 - 0
src/components/Echarts/index.js

@@ -0,0 +1,4 @@
+import ChartPie from './pie.vue'
+import ChartBar from './bar.vue'
+import ChartLine from './line.vue'
+export { ChartPie, ChartBar, ChartLine }

+ 191 - 0
src/components/Echarts/line.vue

@@ -0,0 +1,191 @@
+<template>
+  <div ref="dom" class="charts chart-line"></div>
+</template>
+
+<script>
+import echarts from 'echarts'
+import tdTheme from './theme.json'
+import {
+  on,
+  off
+} from '@/libs/tools'
+
+echarts.registerTheme('tdTheme', tdTheme)
+export default {
+  name: 'ChartLine',
+  props: {
+    value: Object, // 单列折线图,key为x轴,value为y轴
+    text: String,
+    subtext: String,
+    color: String,
+    // 当有多列折线图展示时的X轴坐标数据
+    xAxisData: {
+      type: Array,
+      default: function () {
+        return []
+      }
+    },
+    // 当有多列折线图展示时的y轴坐标数据
+    seriesData: {
+      type: Array,
+      default: function () {
+        return []
+      }
+    },
+    // y轴坐标最大值
+    yMax: {
+      type: Number,
+      default: 100
+    },
+    // y轴坐标单位
+    yUnit: {
+      type: String,
+      default: ''
+    },
+    // x轴标签旋转角度
+    xAxisRotate: {
+      type: Number,
+      default: 0
+    }
+  },
+  watch: {
+    xAxisData: {
+      handler (nVal, oVal) {
+        console.log(nVal, 'nnnnnnnn')
+        if (nVal) {
+          // 根据x轴时间长度控制滚动条位置及显示状态 x轴长度大于25时,显示滚动条并且滚动条结束位置在80%
+          if (nVal.length > 25) {
+            this.isShowZoom = true
+            this.xZoomEnd = 80
+          } else {
+            this.isShowZoom = false
+            this.xZoomEnd = 100
+          }
+          if (nVal.length > 30) {
+            this.xZoomEnd = 70
+          }
+          if (nVal.length > 35) {
+            this.xZoomEnd = 60
+          }
+          if (nVal.length > 40) {
+            this.xZoomEnd = 50
+          }
+          if (nVal.length > 45) {
+            this.xZoomEnd = 40
+          }
+          if (nVal.length > 50) {
+            this.xZoomEnd = 30
+          }
+          this.pageInit()
+        }
+      },
+      deep: true,
+      immediate: true // 代表如果在 wacth 里声明了 xAxisData 之后,就会立即先去执行里面的handler方法,如果为 false就跟我们以前的效果一样,不会在绑定的时候就执行
+    },
+    xAxisRotate: {
+      handler (nVal, oVal) {
+        if (nVal !== '') {
+          this.pageInit()
+        }
+      },
+      deep: true,
+      immediate: true
+    }
+  },
+  data () {
+    return {
+      dom: null, // echarts实例对象
+      isShowZoom: false, // 是否展示滚动条
+      xZoomEnd: 100 // x轴滚动条结束位置
+    }
+  },
+  methods: {
+    resize () {
+      this.dom.resize()
+    },
+    pageInit () {
+      const legend = this.seriesData.map(_ => _.name)
+      this.$nextTick(() => {
+        const xAxisData = this.value ? Object.keys(this.value) : this.xAxisData
+        console.log(xAxisData, 'xAxisData')
+        const seriesData = this.value ? Object.values(this.value) : this.seriesData
+        const option = {
+          color: [this.color],
+          title: {
+            text: this.text,
+            subtext: this.subtext,
+            x: 'left'
+          },
+          legend: {
+            data: legend
+          },
+          // 鼠标放上去遮罩层提示信息
+          tooltip: {
+            trigger: 'axis'
+          },
+          dataZoom: [{ // Y轴固定,让内容滚动
+            type: 'slider',
+            show: this.isShowZoom, // flase直接隐藏图形
+            xAxisIndex: [0],
+            left: '9%', // 滚动条靠左侧的百分比
+            bottom: -5,
+            start: 0, // 滚动条的起始位置
+            end: this.xZoomEnd, // 滚动条的截止位置(按比例分割你的柱状图x轴长度)
+            zoomLock: true // 锁定区域禁止缩放(鼠标滚动会缩放,所以禁止)
+          }],
+          xAxis: {
+            type: 'category',
+            boundaryGap: false, // 两边是否留白
+            data: xAxisData,
+            axisLabel: {
+              interval: 0,
+              rotate: this.xAxisRotate
+            },
+            axisTick: {
+              inside: true,
+              lignWithLabel: true // 这两行代码可以让刻度正对刻度名
+            }
+          },
+          yAxis: {
+            type: 'value',
+            min: 0,
+            max: this.yMax,
+            axisLabel: {
+              formatter: `{value} ${this.yUnit}`
+            },
+            // interval: 2,
+            position: 'left'
+          }
+        }
+        if (this.value) {
+          option.series = [{
+            data: seriesData,
+            type: 'line',
+            barWidth: 35,
+            label: {
+              normal: {
+                show: true,
+                position: 'top'
+              }
+            }
+          }]
+        } else {
+          // console.log(this.seriesData, '111111111')
+          option.series = this.seriesData
+        }
+        // console.log(option.series, 'ppppppp')
+        this.dom = echarts.init(this.$refs.dom, 'tdTheme')
+        this.dom.setOption(option)
+        this.dom.resize()
+        on(window, 'resize', this.resize)
+      })
+    }
+  },
+  mounted () {
+    this.pageInit()
+  },
+  beforeDestroy () {
+    off(window, 'resize', this.resize)
+  }
+}
+</script>

+ 191 - 0
src/components/Echarts/pie.vue

@@ -0,0 +1,191 @@
+<template>
+  <div ref="dom" class="charts chart-pie"></div>
+</template>
+
+<script>
+import echarts from 'echarts'
+import tdTheme from './theme.json'
+import { on, off } from '@/libs/tools'
+echarts.registerTheme('tdTheme', tdTheme)
+export default {
+  name: 'ChartPie',
+  props: {
+    subtext: String,
+    // 图表标题
+    text: {
+      type: String,
+      default: ''
+    },
+    // 数据值
+    value: {
+      type: Array,
+      default: function () {
+        return []
+      }
+    },
+    // 查询时间
+    searchData: {
+      type: Array,
+      default: function () {
+        return []
+      }
+    },
+    // 圆环中心标题
+    title: {
+      type: String,
+      default: ''
+    },
+    // 圆环中心金额
+    total: {
+      type: [Number, String],
+      default: 0
+    },
+    // 圆环各类型颜色
+    color: {
+      type: Array,
+      default: function () {
+        return []
+      }
+    },
+    // x轴标签旋转角度
+    xAxisRotate: {
+      type: Number,
+      default: 0
+    }
+  },
+  watch: {
+    total: {
+      handler (nVal, oVal) {
+        // console.log(nVal, 'total111111111')
+        // 为防止当为0时不执行函数
+        if (nVal !== '') {
+          this.pageInit()
+        }
+      },
+      deep: true,
+      immediate: true // 代表如果在 wacth 里声明了 xAxisData 之后,就会立即先去执行里面的handler方法,如果为 false就跟我们以前的效果一样,不会在绑定的时候就执行
+    }
+  },
+  data () {
+    return {
+      dom: null // echarts实例
+    }
+  },
+  methods: {
+    resize () {
+      this.dom.resize()
+    },
+    pageInit () {
+      this.$nextTick(() => {
+        const legend = this.value.map(_ => _.name)
+        const option = {
+          color: this.color,
+          title: [{
+            text: '{name|' + this.title + '}\n{val|' + this.formatNumber(this.total) + '}',
+            top: 'center',
+            left: 'center',
+            textStyle: {
+              rich: {
+                name: {
+                  fontSize: 14,
+                  fontWeight: 'normal',
+                  color: '#666666',
+                  padding: [10, 0]
+                },
+                val: {
+                  fontSize: 24,
+                  fontWeight: 'bold',
+                  color: '#333333'
+                }
+              }
+            }
+          }],
+          tooltip: {
+            trigger: 'item',
+            formatter: '{b} : {c} ({d}%)'
+          },
+          legend: {
+            orient: 'horizontal',
+            left: 'center',
+            bottom: 'bottom',
+            padding: 5,
+            data: legend
+          },
+          series: [
+            {
+              type: 'pie',
+              radius: ['35%', '50%'],
+              center: ['50%', '50%'],
+              avoidLabelOverlap: true, // 在标签拥挤重叠的情况下会挪动各个标签的位置,防止标签间的重叠
+              hoverAnimation: false,
+              label: {
+                normal: {
+                  formatter: params => {
+                    return (
+                      '{icon|●}{name|' + params.name + '}{value|' +
+                            this.formatNumber(params.value) + '}'
+                    )
+                  },
+                  padding: [0, -100, 25, -130],
+                  rich: {
+                    icon: {
+                      fontSize: 12
+                    },
+                    name: {
+                      fontSize: 14,
+                      padding: [0, 10, 0, 4],
+                      color: '#666666'
+                    },
+                    value: {
+                      fontSize: 16,
+                      fontWeight: 'bold',
+                      color: '#333333'
+                    }
+                  }
+                }
+              },
+              labelLine: {
+                normal: {
+                  length: 20,
+                  length2: 120,
+                  lineStyle: {
+                    color: '#e6e6e6'
+                  }
+                }
+              },
+              data: this.value,
+              itemStyle: {
+                emphasis: {
+                  shadowBlur: 10,
+                  shadowOffsetX: 0,
+                  shadowColor: 'rgba(255, 170, 0, 0.5)'
+                },
+                normal: {
+                  borderColor: '#fff',
+                  borderWidth: 2
+                }
+              }
+            }
+          ]
+        }
+        this.dom = echarts.init(this.$refs.dom, 'tdTheme')
+        console.log(option, 'option')
+        this.dom.setOption(option)
+        this.dom.resize()
+        on(window, 'resize', this.resize)
+      })
+    },
+    // 格式化金额
+    formatNumber (num) {
+      const reg = /(?=(\B)(\d{3})+$)/g
+      return num.toString().replace(reg, ',')
+    }
+  },
+  mounted () {
+    this.pageInit()
+  },
+  beforeDestroy () {
+    off(window, 'resize', this.resize)
+  }
+}
+</script>

+ 491 - 0
src/components/Echarts/theme.json

@@ -0,0 +1,491 @@
+
+{
+    "color": [
+        "#2d8cf0",
+        "#19be6b",
+        "#ff9900",
+        "#E46CBB",
+        "#9A66E4",
+        "#ed3f14"
+    ],
+    "backgroundColor": "rgba(0,0,0,0)",
+    "textStyle": {},
+    "title": {
+        "textStyle": {
+            "color": "#516b91"
+        },
+        "subtextStyle": {
+            "color": "#93b7e3"
+        }
+    },
+    "line": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": "2"
+            }
+        },
+        "lineStyle": {
+            "normal": {
+                "width": "2"
+            }
+        },
+        "symbolSize": "6",
+        "symbol": "emptyCircle",
+        "smooth": true
+    },
+    "radar": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": "2"
+            }
+        },
+        "lineStyle": {
+            "normal": {
+                "width": "2"
+            }
+        },
+        "symbolSize": "6",
+        "symbol": "emptyCircle",
+        "smooth": true
+    },
+    "bar": {
+        "itemStyle": {
+            "normal": {
+                "barBorderWidth": 0,
+                "barBorderColor": "#ccc"
+            },
+            "emphasis": {
+                "barBorderWidth": 0,
+                "barBorderColor": "#ccc"
+            }
+        }
+    },
+    "pie": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            },
+            "emphasis": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            }
+        }
+    },
+    "scatter": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            },
+            "emphasis": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            }
+        }
+    },
+    "boxplot": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            },
+            "emphasis": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            }
+        }
+    },
+    "parallel": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            },
+            "emphasis": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            }
+        }
+    },
+    "sankey": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            },
+            "emphasis": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            }
+        }
+    },
+    "funnel": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            },
+            "emphasis": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            }
+        }
+    },
+    "gauge": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            },
+            "emphasis": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            }
+        }
+    },
+    "candlestick": {
+        "itemStyle": {
+            "normal": {
+                "color": "#edafda",
+                "color0": "transparent",
+                "borderColor": "#d680bc",
+                "borderColor0": "#8fd3e8",
+                "borderWidth": "2"
+            }
+        }
+    },
+    "graph": {
+        "itemStyle": {
+            "normal": {
+                "borderWidth": 0,
+                "borderColor": "#ccc"
+            }
+        },
+        "lineStyle": {
+            "normal": {
+                "width": 1,
+                "color": "#aaa"
+            }
+        },
+        "symbolSize": "6",
+        "symbol": "emptyCircle",
+        "smooth": true,
+        "color": [
+            "#2d8cf0",
+            "#19be6b",
+            "#f5ae4a",
+            "#9189d5",
+            "#56cae2",
+            "#cbb0e3"
+        ],
+        "label": {
+            "normal": {
+                "textStyle": {
+                    "color": "#eee"
+                }
+            }
+        }
+    },
+    "map": {
+        "itemStyle": {
+            "normal": {
+                "areaColor": "#f3f3f3",
+                "borderColor": "#516b91",
+                "borderWidth": 0.5
+            },
+            "emphasis": {
+                "areaColor": "rgba(165,231,240,1)",
+                "borderColor": "#516b91",
+                "borderWidth": 1
+            }
+        },
+        "label": {
+            "normal": {
+                "textStyle": {
+                    "color": "#000"
+                }
+            },
+            "emphasis": {
+                "textStyle": {
+                    "color": "rgb(81,107,145)"
+                }
+            }
+        }
+    },
+    "geo": {
+        "itemStyle": {
+            "normal": {
+                "areaColor": "#f3f3f3",
+                "borderColor": "#516b91",
+                "borderWidth": 0.5
+            },
+            "emphasis": {
+                "areaColor": "rgba(165,231,240,1)",
+                "borderColor": "#516b91",
+                "borderWidth": 1
+            }
+        },
+        "label": {
+            "normal": {
+                "textStyle": {
+                    "color": "#000"
+                }
+            },
+            "emphasis": {
+                "textStyle": {
+                    "color": "rgb(81,107,145)"
+                }
+            }
+        }
+    },
+    "categoryAxis": {
+        "axisLine": {
+            "show": true,
+            "lineStyle": {
+                "color": "#cccccc"
+            }
+        },
+        "axisTick": {
+            "show": false,
+            "lineStyle": {
+                "color": "#333"
+            }
+        },
+        "axisLabel": {
+            "show": true,
+            "textStyle": {
+                "color": "#999999"
+            }
+        },
+        "splitLine": {
+            "show": true,
+            "lineStyle": {
+                "color": [
+                    "#eeeeee"
+                ]
+            }
+        },
+        "splitArea": {
+            "show": false,
+            "areaStyle": {
+                "color": [
+                    "rgba(250,250,250,0.05)",
+                    "rgba(200,200,200,0.02)"
+                ]
+            }
+        }
+    },
+    "valueAxis": {
+        "axisLine": {
+            "show": true,
+            "lineStyle": {
+                "color": "#cccccc"
+            }
+        },
+        "axisTick": {
+            "show": false,
+            "lineStyle": {
+                "color": "#333"
+            }
+        },
+        "axisLabel": {
+            "show": true,
+            "textStyle": {
+                "color": "#999999"
+            }
+        },
+        "splitLine": {
+            "show": true,
+            "lineStyle": {
+                "color": [
+                    "#eeeeee"
+                ]
+            }
+        },
+        "splitArea": {
+            "show": false,
+            "areaStyle": {
+                "color": [
+                    "rgba(250,250,250,0.05)",
+                    "rgba(200,200,200,0.02)"
+                ]
+            }
+        }
+    },
+    "logAxis": {
+        "axisLine": {
+            "show": true,
+            "lineStyle": {
+                "color": "#cccccc"
+            }
+        },
+        "axisTick": {
+            "show": false,
+            "lineStyle": {
+                "color": "#333"
+            }
+        },
+        "axisLabel": {
+            "show": true,
+            "textStyle": {
+                "color": "#999999"
+            }
+        },
+        "splitLine": {
+            "show": true,
+            "lineStyle": {
+                "color": [
+                    "#eeeeee"
+                ]
+            }
+        },
+        "splitArea": {
+            "show": false,
+            "areaStyle": {
+                "color": [
+                    "rgba(250,250,250,0.05)",
+                    "rgba(200,200,200,0.02)"
+                ]
+            }
+        }
+    },
+    "timeAxis": {
+        "axisLine": {
+            "show": true,
+            "lineStyle": {
+                "color": "#cccccc"
+            }
+        },
+        "axisTick": {
+            "show": false,
+            "lineStyle": {
+                "color": "#333"
+            }
+        },
+        "axisLabel": {
+            "show": true,
+            "textStyle": {
+                "color": "#999999"
+            }
+        },
+        "splitLine": {
+            "show": true,
+            "lineStyle": {
+                "color": [
+                    "#eeeeee"
+                ]
+            }
+        },
+        "splitArea": {
+            "show": false,
+            "areaStyle": {
+                "color": [
+                    "rgba(250,250,250,0.05)",
+                    "rgba(200,200,200,0.02)"
+                ]
+            }
+        }
+    },
+    "toolbox": {
+        "iconStyle": {
+            "normal": {
+                "borderColor": "#999"
+            },
+            "emphasis": {
+                "borderColor": "#666"
+            }
+        }
+    },
+    "legend": {
+        "textStyle": {
+            "color": "#999999"
+        }
+    },
+    "tooltip": {
+        "axisPointer": {
+            "lineStyle": {
+                "color": "#ccc",
+                "width": 1
+            },
+            "crossStyle": {
+                "color": "#ccc",
+                "width": 1
+            }
+        }
+    },
+    "timeline": {
+        "lineStyle": {
+            "color": "#8fd3e8",
+            "width": 1
+        },
+        "itemStyle": {
+            "normal": {
+                "color": "#8fd3e8",
+                "borderWidth": 1
+            },
+            "emphasis": {
+                "color": "#8fd3e8"
+            }
+        },
+        "controlStyle": {
+            "normal": {
+                "color": "#8fd3e8",
+                "borderColor": "#8fd3e8",
+                "borderWidth": 0.5
+            },
+            "emphasis": {
+                "color": "#8fd3e8",
+                "borderColor": "#8fd3e8",
+                "borderWidth": 0.5
+            }
+        },
+        "checkpointStyle": {
+            "color": "#8fd3e8",
+            "borderColor": "rgba(138,124,168,0.37)"
+        },
+        "label": {
+            "normal": {
+                "textStyle": {
+                    "color": "#8fd3e8"
+                }
+            },
+            "emphasis": {
+                "textStyle": {
+                    "color": "#8fd3e8"
+                }
+            }
+        }
+    },
+    "visualMap": {
+        "color": [
+            "#516b91",
+            "#59c4e6",
+            "#a5e7f0"
+        ]
+    },
+    "dataZoom": {
+        "backgroundColor": "rgba(0,0,0,0)",
+        "dataBackgroundColor": "rgba(255,255,255,0.3)",
+        "fillerColor": "rgba(167,183,204,0.4)",
+        "handleColor": "#a7b7cc",
+        "handleSize": "100%",
+        "textStyle": {
+            "color": "#333"
+        }
+    },
+    "markPoint": {
+        "label": {
+            "normal": {
+                "textStyle": {
+                    "color": "#eee"
+                }
+            },
+            "emphasis": {
+                "textStyle": {
+                    "color": "#eee"
+                }
+            }
+        }
+    }
+}

+ 287 - 272
src/config/router.config.js

@@ -46,6 +46,27 @@ export const asyncRouterMap = [{
       icon: 'home'
     }
   },
+  {
+    path: '/map',
+    name: 'map',
+    redirect: '/map',
+    component: PageView,
+    meta: {
+      title: '网点地图',
+      icon: 'global'
+    },
+    hideChildrenInMenu: true,
+    children: [{
+      path: '/map',
+      name: 'map',
+      component: () => import(/* webpackChunkName: "map" */ '@/views/map/NodeMap.vue'),
+      meta: {
+        title: '网点地图',
+        icon: 'global',
+        hiddenHeaderContent: true
+      }
+    }]
+  },
   {
     path: '/shop',
     redirect: '/shop/goods',
@@ -55,73 +76,72 @@ export const asyncRouterMap = [{
       icon: 'shop',
       permission: 'M_shop'
     },
-    children: [
-      {
-        path: '/shop/goods',
-        redirect: '/shop/goods/list',
-        name: 'goodsList',
-        component: RouteView,
+    children: [{
+      path: '/shop/goods',
+      redirect: '/shop/goods/list',
+      name: 'goodsList',
+      component: RouteView,
+      meta: {
+        title: '商品管理',
+        icon: 'shopping',
+        permission: 'M_goodsManage_list'
+      },
+      hideChildrenInMenu: true,
+      children: [{
+        path: '/shop/goods/list',
+        name: 'goodsListList',
+        component: () => import(/* webpackChunkName: "shop" */ '@/views/shop/goodsList.vue'),
         meta: {
-          title: '商品管理',
+          title: '商品列表',
           icon: 'shopping',
+          hidden: true,
           permission: 'M_goodsManage_list'
-        },
-        hideChildrenInMenu: true,
-        children: [{
-          path: '/shop/goods/list',
-          name: 'goodsListList',
-          component: () => import(/* webpackChunkName: "shop" */ '@/views/shop/goodsList.vue'),
-          meta: {
-            title: '商品列表',
-            icon: 'shopping',
-            hidden: true,
-            permission: 'M_goodsManage_list'
-          }
-        },
-        {
-          path: '/shop/goods/add',
-          name: 'goodsListAdd',
-          component: () => import(/* webpackChunkName: "shop" */ '@/views/shop/goodsEdit.vue'),
-          meta: {
-            title: '新增商品',
-            icon: 'shopping',
-            hidden: true,
-            permission: 'B_goodsManage_add'
-          }
-        },
-        {
-          path: '/shop/goods/edit/:id',
-          name: 'goodsListEdit',
-          component: () => import(/* webpackChunkName: "shop" */ '@/views/shop/goodsEdit.vue'),
-          meta: {
-            title: '编辑商品',
-            icon: 'shopping',
-            hidden: true,
-            permission: 'B_goodsManage_edit'
-          }
         }
-        ]
       },
       {
-        path: '/shop/goodsShelves',
-        name: 'goodsShelves',
-        component: () => import(/* webpackChunkName: "shop" */ '@/views/shop/goodsShelves.vue'),
+        path: '/shop/goods/add',
+        name: 'goodsListAdd',
+        component: () => import(/* webpackChunkName: "shop" */ '@/views/shop/goodsEdit.vue'),
         meta: {
-          title: '商品排序',
-          icon: 'flag',
-          permission: 'M_goodsShelves_0'
+          title: '新增商品',
+          icon: 'shopping',
+          hidden: true,
+          permission: 'B_goodsManage_add'
         }
       },
       {
-        path: '/shopSetting/goodsClass',
-        name: 'goodsClass',
-        component: () => import(/* webpackChunkName: "shop" */ '@/views/shopSetting/goodsClass.vue'),
+        path: '/shop/goods/edit/:id',
+        name: 'goodsListEdit',
+        component: () => import(/* webpackChunkName: "shop" */ '@/views/shop/goodsEdit.vue'),
         meta: {
-          title: '商品分类管理',
-          icon: 'folder',
-          permission: 'M_goodsClass_list'
+          title: '编辑商品',
+          icon: 'shopping',
+          hidden: true,
+          permission: 'B_goodsManage_edit'
         }
       }
+      ]
+    },
+    {
+      path: '/shop/goodsShelves',
+      name: 'goodsShelves',
+      component: () => import(/* webpackChunkName: "shop" */ '@/views/shop/goodsShelves.vue'),
+      meta: {
+        title: '商品排序',
+        icon: 'flag',
+        permission: 'M_goodsShelves_0'
+      }
+    },
+    {
+      path: '/shopSetting/goodsClass',
+      name: 'goodsClass',
+      component: () => import(/* webpackChunkName: "shop" */ '@/views/shopSetting/goodsClass.vue'),
+      meta: {
+        title: '商品分类管理',
+        icon: 'folder',
+        permission: 'M_goodsClass_list'
+      }
+    }
     ]
   },
   {
@@ -133,44 +153,41 @@ export const asyncRouterMap = [{
       icon: 'profile',
       permission: 'M_orderManage_list'
     },
-    children: [
+    children: [{
+      path: '/order/orderManage',
+      redirect: '/order/orderManage/list',
+      name: 'orderManage',
+      component: RouteView,
+      meta: {
+        title: '订单管理',
+        icon: 'profile',
+        permission: 'M_orderManage_list'
+      },
+      hideChildrenInMenu: true,
+      children: [{
+        path: '/order/orderManage/list',
+        name: 'orderManageList',
+        component: () => import(/* webpackChunkName: "order" */ '@/views/shop/shopOrder.vue'),
+        meta: {
+          title: '订单列表',
+          icon: 'shopping',
+          hidden: true,
+          permission: 'M_orderManage_list'
+        }
+      },
       {
-        path: '/order/orderManage',
-        redirect: '/order/orderManage/list',
-        name: 'orderManage',
-        component: RouteView,
+        path: '/order/orderManage/detail/:id',
+        name: 'orderManageDetail',
+        component: () => import(/* webpackChunkName: "order" */ '@/views/shop/orderDetail.vue'),
         meta: {
-          title: '订单管理',
+          title: '订单详情',
           icon: 'profile',
-          permission: 'M_orderManage_list'
-        },
-        hideChildrenInMenu: true,
-        children: [
-          {
-            path: '/order/orderManage/list',
-            name: 'orderManageList',
-            component: () => import(/* webpackChunkName: "order" */ '@/views/shop/shopOrder.vue'),
-            meta: {
-              title: '订单列表',
-              icon: 'shopping',
-              hidden: true,
-              permission: 'M_orderManage_list'
-            }
-          },
-          {
-            path: '/order/orderManage/detail/:id',
-            name: 'orderManageDetail',
-            component: () => import(/* webpackChunkName: "order" */ '@/views/shop/orderDetail.vue'),
-            meta: {
-              title: '订单详情',
-              icon: 'profile',
-              hidden: true,
-              permission: 'B_orderManage_detail'
-            }
-          }
-        ]
+          hidden: true,
+          permission: 'B_orderManage_detail'
+        }
       }
-    ]
+      ]
+    }]
   },
   // 用户
   {
@@ -182,97 +199,95 @@ export const asyncRouterMap = [{
       icon: 'user',
       permission: 'M_user'
     },
-    children: [
+    children: [{
+      path: '/userInfo/userManage',
+      redirect: '/userInfo/userManageList/list',
+      name: 'userManageS',
+      component: RouteView,
+      meta: {
+        title: '用户管理',
+        icon: 'profile',
+        permission: 'M_user_userManage_list'
+      },
+      hideChildrenInMenu: true,
+      children: [{
+        path: '/userInfo/userManageList/list',
+        name: 'userManageList',
+        component: () => import(/* webpackChunkName: "userManageList" */ '@/views/userInfo/userManageList.vue'),
+        meta: {
+          title: '用户列表',
+          icon: 'team',
+          hidden: true,
+          permission: 'M_user_userManage_list'
+        }
+      },
       {
-        path: '/userInfo/userManage',
-        redirect: '/userInfo/userManageList/list',
-        name: 'userManageS',
-        component: RouteView,
+        path: '/userInfo/userManageList_user/detail/:id',
+        name: 'userManageDetail',
+        component: () => import(/* webpackChunkName: "userManageDetail" */ '@/views/userInfo/userDetails.vue'),
         meta: {
-          title: '用户管理',
+          title: '用户详情',
           icon: 'profile',
-          permission: 'M_user_userManage_list'
-        },
-        hideChildrenInMenu: true,
-        children: [{
-          path: '/userInfo/userManageList/list',
-          name: 'userManageList',
-          component: () => import(/* webpackChunkName: "userManageList" */ '@/views/userInfo/userManageList.vue'),
-          meta: {
-            title: '用户列表',
-            icon: 'team',
-            hidden: true,
-            permission: 'M_user_userManage_list'
-          }
-        },
-        {
-          path: '/userInfo/userManageList_user/detail/:id',
-          name: 'userManageDetail',
-          component: () => import(/* webpackChunkName: "userManageDetail" */ '@/views/userInfo/userDetails.vue'),
-          meta: {
-            title: '用户详情',
-            icon: 'profile',
-            hidden: true,
-            permission: 'B_user_userManage_userDetails'
-          }
-        },
-        {
-          path: '/userInfo/userManageList_Ld/detail',
-          name: 'ledouDetail',
-          component: () => import(/* webpackChunkName: "LdDetails" */ '@/views/userInfo/LdDetails.vue'),
-          meta: {
-            title: '乐豆明细',
-            icon: 'profile',
-            hidden: true,
-            permission: 'B_user_userManage_LdDetails'
-          }
+          hidden: true,
+          permission: 'B_user_userManage_userDetails'
         }
-        ]
       },
       {
-        path: '/userInfo/releaseRecord/list',
-        name: 'releaseRecordList',
-        component: () => import(/* webpackChunkName: "releaseRecord" */ '@/views/releaseRecord/releaseRecordList.vue'),
+        path: '/userInfo/userManageList_Ld/detail',
+        name: 'ledouDetail',
+        component: () => import(/* webpackChunkName: "LdDetails" */ '@/views/userInfo/LdDetails.vue'),
         meta: {
-          title: '投放记录',
-          icon: 'container',
-          permission: 'M_user_releaseRecord'
+          title: '乐豆明细',
+          icon: 'profile',
+          hidden: true,
+          permission: 'B_user_userManage_LdDetails'
         }
       }
+      ]
+    },
+    {
+      path: '/userInfo/releaseRecord/list',
+      name: 'releaseRecordList',
+      component: () => import(/* webpackChunkName: "releaseRecord" */ '@/views/releaseRecord/releaseRecordList.vue'),
+      meta: {
+        title: '投放记录',
+        icon: 'container',
+        permission: 'M_user_releaseRecord'
+      }
+    }
     ]
   },
   // 报表
   {
-	  path: '/reportForm',
-	  redirect: '/reportForm/rubbishDeliverySearchTime',
-	  component: PageView,
-	  meta: {
-	    title: '报表',
-	    icon: 'line-chart'
-	    // permission: 'M_market'
-	  },
-	  children: [
-	    {
-	      path: '/reportForm/rubbishDeliverySearchTime',
-	      name: 'rubbishDeliverySearchTime',
-	      component: () => import(/* webpackChunkName: "market" */ '@/views/reportForm/rubbishDeliverySearchTime.vue'),
-	      meta: {
-	        title: '垃圾投递分时查询表',
-	        icon: 'file-done'
-	        // permission: 'M_winingRecord'
-	      }
-	    },
-	    {
-	      path: '/reportForm/rubbishDeliveryTotal',
-	      name: 'rubbishDeliveryTotal',
-	      component: () => import(/* webpackChunkName: "market" */ '@/views/reportForm/rubbishDeliveryTotal.vue'),
-	      meta: {
-	        title: '垃圾投递汇总表',
-	        icon: 'snippets'
-	        // permission: 'M_lottery_list'
-	      }
-	    }
-	  ]
+    path: '/reportForm',
+    redirect: '/reportForm/rubbishDeliverySearchTime',
+    component: PageView,
+    meta: {
+      title: '报表',
+      icon: 'line-chart'
+      // permission: 'M_market'
+    },
+    children: [{
+      path: '/reportForm/rubbishDeliverySearchTime',
+      name: 'rubbishDeliverySearchTime',
+      component: () => import(/* webpackChunkName: "market" */ '@/views/reportForm/rubbishDeliverySearchTime.vue'),
+      meta: {
+        title: '垃圾投递分时查询表',
+        icon: 'file-done'
+        // permission: 'M_winingRecord'
+      }
+    },
+    {
+      path: '/reportForm/rubbishDeliveryTotal',
+      name: 'rubbishDeliveryTotal',
+      component: () => import(/* webpackChunkName: "market" */ '@/views/reportForm/rubbishDeliveryTotal.vue'),
+      meta: {
+        title: '垃圾投递汇总表',
+        icon: 'snippets'
+        // permission: 'M_lottery_list'
+      }
+    }
+    ]
   },
   {
     path: '/market',
@@ -283,27 +298,26 @@ export const asyncRouterMap = [{
       icon: 'gift',
       permission: 'M_market'
     },
-    children: [
-      {
-        path: '/market/winingRecord',
-        name: 'winingRecord',
-        component: () => import(/* webpackChunkName: "market" */ '@/views/market/winingRecord.vue'),
-        meta: {
-          title: '中奖记录',
-          icon: 'file-done',
-          permission: 'M_winingRecord'
-        }
-      },
-      {
-        path: '/market/lotterySettings',
-        name: 'lotterySettings',
-        component: () => import(/* webpackChunkName: "market" */ '@/views/market/lotterySettings.vue'),
-        meta: {
-          title: '大转盘设置',
-          icon: 'edit',
-          permission: 'M_lottery_list'
-        }
+    children: [{
+      path: '/market/winingRecord',
+      name: 'winingRecord',
+      component: () => import(/* webpackChunkName: "market" */ '@/views/market/winingRecord.vue'),
+      meta: {
+        title: '中奖记录',
+        icon: 'file-done',
+        permission: 'M_winingRecord'
       }
+    },
+    {
+      path: '/market/lotterySettings',
+      name: 'lotterySettings',
+      component: () => import(/* webpackChunkName: "market" */ '@/views/market/lotterySettings.vue'),
+      meta: {
+        title: '大转盘设置',
+        icon: 'edit',
+        permission: 'M_lottery_list'
+      }
+    }
     ]
   },
   {
@@ -315,18 +329,16 @@ export const asyncRouterMap = [{
       icon: 'appstore',
       permission: 'M_AdBanner_list'
     },
-    children: [
-      {
-        path: '/shopSetting/bannerSetting',
-        name: 'bannerSetting',
-        component: () => import(/* webpackChunkName: "shopSetting" */ '@/views/shop/bannerSetting.vue'),
-        meta: {
-          title: '推广位设置',
-          icon: 'picture',
-          permission: 'M_AdBanner_list'
-        }
+    children: [{
+      path: '/shopSetting/bannerSetting',
+      name: 'bannerSetting',
+      component: () => import(/* webpackChunkName: "shopSetting" */ '@/views/shop/bannerSetting.vue'),
+      meta: {
+        title: '推广位设置',
+        icon: 'picture',
+        permission: 'M_AdBanner_list'
       }
-    ]
+    }]
   },
   {
     path: '/equipmentManage',
@@ -340,7 +352,8 @@ export const asyncRouterMap = [{
     children: [{
       path: '/equipmentManage/network',
       name: 'network',
-      component: () => import(/* webpackChunkName: "equipmentManage" */ '@/views/equipmentManage/network/network.vue'),
+      component: () => import(/* webpackChunkName: "equipmentManage" */
+        '@/views/equipmentManage/network/network.vue'),
       meta: {
         title: '网点管理',
         icon: 'cluster',
@@ -350,7 +363,8 @@ export const asyncRouterMap = [{
     {
       path: '/equipmentManage/equipment',
       name: 'equipment',
-      component: () => import(/* webpackChunkName: "equipmentManage" */ '@/views/equipmentManage/equipment/equipment.vue'),
+      component: () => import(/* webpackChunkName: "equipmentManage" */
+        '@/views/equipmentManage/equipment/equipment.vue'),
       meta: {
         title: '设备管理',
         icon: 'usb',
@@ -360,7 +374,8 @@ export const asyncRouterMap = [{
     {
       path: '/equipmentManage/boxSetting',
       name: 'boxSetting',
-      component: () => import(/* webpackChunkName: "equipmentManage" */ '@/views/equipmentManage/boxSetting/boxSetting.vue'),
+      component: () => import(/* webpackChunkName: "equipmentManage" */
+        '@/views/equipmentManage/boxSetting/boxSetting.vue'),
       meta: {
         title: '箱体类型设置',
         icon: 'block',
@@ -381,7 +396,8 @@ export const asyncRouterMap = [{
     {
       path: '/equipmentManage/openTimeSetting',
       name: 'openTimeSetting',
-      component: () => import(/* webpackChunkName: "equipmentManage" */ '@/views/equipmentManage/openTimeSetting/OpenTimeSetting.vue'),
+      component: () => import(/* webpackChunkName: "equipmentManage" */
+        '@/views/equipmentManage/openTimeSetting/OpenTimeSetting.vue'),
       meta: {
         title: '投放时间设置',
         icon: 'dashboard',
@@ -399,37 +415,39 @@ export const asyncRouterMap = [{
       icon: 'bank',
       permission: 'M_businessManage'
     },
-    children: [
-      {
-        path: '/businessManage/partnerManage',
-        name: 'partnerManage',
-        component: () => import(/* webpackChunkName: "businessManage" */ '@/views/businessManage/partnerManage/partnerManage.vue'),
-        meta: {
-          title: '商户管理',
-          icon: 'solution',
-          permission: 'M_partnerManage_list'
-        }
-      },
-      {
-        path: '/businessManage/userManage',
-        name: 'userManage',
-        component: () => import(/* webpackChunkName: "businessManage" */ '@/views/businessManage/userManage/userManage.vue'),
-        meta: {
-          title: '用户管理',
-          icon: 'folder',
-          permission: 'M_userManage_list'
-        }
-      },
-      {
-        path: '/businessManage/leduQuery',
-        name: 'leduQuery',
-        component: () => import(/* webpackChunkName: "businessManage" */ '@/views/businessManage/leduQuery/leduQuery.vue'),
-        meta: {
-          title: '商户乐豆统计',
-          icon: 'search',
-          permission: 'M_ledouTjList'
-        }
+    children: [{
+      path: '/businessManage/partnerManage',
+      name: 'partnerManage',
+      component: () => import(/* webpackChunkName: "businessManage" */
+        '@/views/businessManage/partnerManage/partnerManage.vue'),
+      meta: {
+        title: '商户管理',
+        icon: 'solution',
+        permission: 'M_partnerManage_list'
+      }
+    },
+    {
+      path: '/businessManage/userManage',
+      name: 'userManage',
+      component: () => import(/* webpackChunkName: "businessManage" */
+        '@/views/businessManage/userManage/userManage.vue'),
+      meta: {
+        title: '用户管理',
+        icon: 'folder',
+        permission: 'M_userManage_list'
       }
+    },
+    {
+      path: '/businessManage/leduQuery',
+      name: 'leduQuery',
+      component: () => import(/* webpackChunkName: "businessManage" */
+        '@/views/businessManage/leduQuery/leduQuery.vue'),
+      meta: {
+        title: '商户乐豆统计',
+        icon: 'search',
+        permission: 'M_ledouTjList'
+      }
+    }
     ]
   },
   {
@@ -441,18 +459,16 @@ export const asyncRouterMap = [{
       icon: 'user-add',
       permission: 'M_supplier_list'
     },
-    children: [
-      {
-        path: '/supplier/list',
-        name: 'supplier',
-        component: () => import(/* webpackChunkName: "supplier" */ '@/views/shopSetting/supplier.vue'),
-        meta: {
-          title: '供货商管理',
-          icon: 'solution',
-          permission: 'M_supplier_list'
-        }
+    children: [{
+      path: '/supplier/list',
+      name: 'supplier',
+      component: () => import(/* webpackChunkName: "supplier" */ '@/views/shopSetting/supplier.vue'),
+      meta: {
+        title: '供货商管理',
+        icon: 'solution',
+        permission: 'M_supplier_list'
       }
-    ]
+    }]
   },
   // auth
   {
@@ -464,37 +480,36 @@ export const asyncRouterMap = [{
       icon: 'lock',
       permission: 'M_auth_0'
     },
-    children: [
-      {
-        path: '/auth/userList',
-        name: 'powerUserList',
-        component: () => import(/* webpackChunkName: "auth" */ '@/views/power/user/userList.vue'),
-        meta: {
-          title: '用户管理',
-          icon: 'user',
-          permission: 'M_power_user_list'
-        }
-      },
-      {
-        path: '/auth/roleList',
-        name: 'powerRoleList',
-        component: () => import(/* webpackChunkName: "auth" */ '@/views/power/role/roleList.vue'),
-        meta: {
-          title: '角色管理',
-          icon: 'solution',
-          permission: 'M_power_role_list'
-        }
-      },
-      {
-        path: '/menusAuth/menu',
-        name: 'powerMenu',
-        component: () => import(/* webpackChunkName: "auth" */ '@/views/power/menu/menu.vue'),
-        meta: {
-          title: '菜单管理',
-          icon: 'profile',
-          permission: 'M_power_menu_list'
-        }
+    children: [{
+      path: '/auth/userList',
+      name: 'powerUserList',
+      component: () => import(/* webpackChunkName: "auth" */ '@/views/power/user/userList.vue'),
+      meta: {
+        title: '用户管理',
+        icon: 'user',
+        permission: 'M_power_user_list'
       }
+    },
+    {
+      path: '/auth/roleList',
+      name: 'powerRoleList',
+      component: () => import(/* webpackChunkName: "auth" */ '@/views/power/role/roleList.vue'),
+      meta: {
+        title: '角色管理',
+        icon: 'solution',
+        permission: 'M_power_role_list'
+      }
+    },
+    {
+      path: '/menusAuth/menu',
+      name: 'powerMenu',
+      component: () => import(/* webpackChunkName: "auth" */ '@/views/power/menu/menu.vue'),
+      meta: {
+        title: '菜单管理',
+        icon: 'profile',
+        permission: 'M_power_menu_list'
+      }
+    }
     ]
   },
   {

+ 1 - 1
src/core/directives/hasPermission.js

@@ -16,7 +16,7 @@ import store from '@/store'
  */
 const hasPermission = Vue.directive('hasPermission', {
   inserted: function (el, binding, vnode) {
-    console.log(binding.value)
+    // console.log(binding.value)
     const roles = store.getters.roles
     const permissionList = roles.permissionList
     if (!permissionList.includes(binding.value)) {

+ 91 - 0
src/views/map/NodeMap.vue

@@ -0,0 +1,91 @@
+<template>
+	<div class="nodeMap-contenter">
+		<!-- 地图 -->
+		<a-row class="map-cont" id="container" :getter="24">
+
+		</a-row>
+		<div v-show="true" class="data-cont">
+			<!-- 实时轮播数据 -->
+			<a-row :gutter="48" class="swipter" type="flex" justify="space-around">
+				<a-col class="switper-cont" :span="11">
+				</a-col>
+				<a-col class="switper-cont" :span="11">
+				</a-col>
+			</a-row>
+			<!-- 图表数据 -->
+			<a-row :gutter="48" type="flex" justify="space-around">
+				<a-col class="chart-cont" :span="7">
+				</a-col>
+				<a-col class="chart-cont" :span="7">
+				</a-col>
+				<a-col class="chart-cont" :span="7">
+				</a-col>
+			</a-row>
+		</div>
+		
+	</div>
+</template>
+<script>
+	export default {
+		name: 'NodeMap',
+		data() {
+			return {}
+		},
+		methods: {
+			initMap() {
+				//定义地图中心点坐标
+				var center = new TMap.LatLng(39.984120, 116.307484)
+				//定义map变量,调用 TMap.Map() 构造函数创建地图
+				var map = new TMap.Map(document.getElementById('container'), {
+					center: center, //设置地图中心点坐标
+					zoom: 17.2, //设置地图缩放级别
+					pitch: 43.5, //设置俯仰角
+					rotation: 45 //设置地图旋转角度
+				});
+			}
+		},
+		mounted () {
+			this.initMap()
+		},
+		beforeRouteEnter(to, from, next) {
+			next(vm => {
+				// vm.initMap()
+			})
+		},
+	}
+</script>
+
+<style lang="less" scoped="scoped">
+	.nodeMap-contenter {
+		width: 100%;
+		min-height: 80vh;
+		display: flex;
+		flex-direction: column;
+
+		.map-cont {
+			width: 100%;
+			flex: 1;
+			margin-bottom: 20px;
+		}
+
+		.swipter {
+			margin-bottom: 20px;
+		}
+		.data-cont{
+			width: 100%;
+		}
+		.switper-cont {
+			height: 200px;
+			background-color: #fff;
+			border-radius: 10px;
+			box-shadow: 5px 5px 8px #888888;
+		}
+
+		.chart-cont {
+			height: 300px;
+			background-color: #fff;
+			border-radius: 20px;
+			box-shadow: 5px 5px 8px #888888;
+		}
+	}
+</style>

+ 16 - 6
src/views/reportForm/rubbishDeliverySearchTime.vue

@@ -37,9 +37,8 @@
               type="primary"
               id="releaseRecordList-refresh"
               v-hasPermission="'B_exportDeliveryLog'"
-              :loading="loading"
               @click="refresh">查询</a-button>
-            <a-button class="serach-btn" id="releaseRecordList-handleReset" v-hasPermission="'B_exportDeliveryLog'" :loading="loading" @click="handleReset">重置</a-button>
+            <a-button class="serach-btn" id="releaseRecordList-handleReset" v-hasPermission="'B_exportDeliveryLog'" @click="handleReset">重置</a-button>
             <a-button class="export-btn" id="releaseRecordList-export" v-hasPermission="'B_exportDeliveryLog'" :loading="loading" @click="handleExport">导出</a-button>
           </a-col>
         </a-row>
@@ -179,15 +178,26 @@ export default {
       }
       if (!params.beginDate && !params.endDate) {
         this.$message.error('请先选择需要导出的投放时间区间再进行导出!')
+        return
       }
       // 判断两个时间段是否相差m个月  第二个参数指相差单位,第三个参数指是否返回浮点形式(小数)
       if (moment(params.endDate).diff(moment(params.beginDate), 'months', true) > 3) {
         this.$message.error('单次最多只能导出3个月的数据,请缩小查询区间后再进行导出!')
+        return
       }
-      this.loading = true
-      exportTnTimeForm(params).then(res => {
-        this.loading = false
-        this.download(res)
+      this.$confirm({
+        title: '提示',
+        content: '导出过程可能需要一些时间,且导出期间不能进行其它操作,确定要导出吗?',
+        onOk: () => {
+          this.loading = true
+          exportTnTimeForm(params).then(res => {
+			  this.loading = false
+			  this.download(res)
+          })
+        },
+        onCancel () {
+          console.log('Cancel')
+        }
       })
     },
     download (data) {

+ 14 - 4
src/views/reportForm/rubbishDeliveryTotal.vue

@@ -346,11 +346,21 @@ export default {
       // 判断两个时间段是否相差m个月  第二个参数指相差单位,第三个参数指是否返回浮点形式(小数)
       if (moment(params.endDate).diff(moment(params.beginDate), 'months', true) > 3) {
         this.$message.error('单次最多只能导出3个月的数据,请缩小查询区间后再进行导出!')
+        return
       }
-      this.loading = true
-      exportSumForm(params).then(res => {
-        this.loading = false
-        this.download(res)
+      this.$confirm({
+		  title: '提示',
+		  content: '导出过程可能需要一些时间,且导出期间不能进行其它操作,确定要导出吗?',
+		  onOk: () => {
+			  this.loading = true
+			  exportSumForm(params).then(res => {
+				  this.loading = false
+				  this.download(res)
+			  })
+		  },
+		  onCancel () {
+          console.log('Cancel')
+		  }
       })
     },
     download (data) {

+ 36 - 63
src/views/userInfo/userManageList.vue

@@ -261,7 +261,9 @@ export default {
   },
   beforeRouteEnter (to, from, next) {
     next(vm => {
-      vm.handleReset()
+      vm.queryParam = {}
+	  vm.registerTime = []
+	  vm.lastDeliverTime = []
     })
   },
   methods: {
@@ -352,79 +354,50 @@ export default {
       this.queryParam.endDate = null // 最后投递时间的结束时间
       this.queryParam.beginRegisterTime = null //  注册时间最小值
       this.queryParam.endRegisterTime = null //  注册时间最大值
-      this.registerTime = [],
-      this.lastDeliverTime = [],
+      this.registerTime = []
+      this.lastDeliverTime = []
       this.$refs.table.refresh(true)
     },
     // 导出
     handleExport () {
       const params = this.queryParam
-      // 情况1  导出只选择注册时间段 没有选择最后投递时间段
-      if ((this.registerTime && this.registerTime.length) && (params.beginDate == null && params.endDate == null)) {
-        params.beginRegisterTime = moment(this.registerTime[0])
-        params.endRegisterTime = moment(this.registerTime[1])
-      }
-      // 判断两个时间段是否相差m个月  第二个参数指相差单位,第三个参数指是否返回浮点形式(小数)
-      if (moment(params.endRegisterTime).diff(moment(params.beginRegisterTime), 'months', true) > 3) {
-        this.$message.error('单次最多只能导出3个月的数据,请缩小注册时间区间后再进行导出!')
-      }
-      // 情况2 导出只选择最后投递时间段 没有注册时间段
-      if ((this.lastDeliverTime && this.lastDeliverTime.length) && (params.beginRegisterTime == null && params.endRegisterTime == null)) {
+      if (this.lastDeliverTime && this.lastDeliverTime.length) {
         params.beginDate = moment(this.lastDeliverTime[0])
         params.endDate = moment(this.lastDeliverTime[1])
+        if (!params.beginDate && !params.endDate) {
+          this.$message.error('请先选择需要导出的最后投递时间区间再进行导出!')
+          return
+        }
+        // 判断两个时间段是否相差m个月  第二个参数指相差单位,第三个参数指是否返回浮点形式(小数)
+        if (moment(params.endDate).diff(moment(params.beginDate), 'months', true) > 3) {
+          this.$message.error('单次最多只能导出3个月的数据,请缩小最后投递时间查询区间后再进行导出!')
+          return
+        }
+      } else {
+        params.beginDate = ''
+        params.endDate = ''
       }
-      if (moment(params.endDate).diff(moment(params.beginDate), 'months', true) > 3) {
-        this.$message.error('单次最多只能导出3个月的数据,请缩小最后投递时间区间后再进行导出!')
+
+      if (this.registerTime && this.registerTime.length) {
+        params.beginRegisterTime = moment(this.registerTime[0])
+        params.endRegisterTime = moment(this.registerTime[1])
+        if (!params.beginRegisterTime && !params.endRegisterTime) {
+          this.$message.error('请先选择需要导出的注册时间区间再进行导出!')
+          return
+        }
+        // 判断两个时间段是否相差m个月  第二个参数指相差单位,第三个参数指是否返回浮点形式(小数)
+        if (moment(params.endRegisterTime).diff(moment(params.beginRegisterTime), 'months', true) > 3) {
+          this.$message.error('单次最多只能导出3个月的数据,请缩小注册时间查询区间后再进行导出!')
+          return
+        }
+      } else {
+        params.beginRegisterTime = ''
+        params.endRegisterTime = ''
       }
-	  // 情况3 导出未选择任何时间段
-	  if ((params.beginRegisterTime == null && params.endRegisterTime == null) && (params.beginDate == null && params.endDate == null)) {
+      if (this.lastDeliverTime.length == 0 && this.registerTime.length == 0) {
         this.$message.error('请先选择需要导出的注册时间区间或最后投递时间区间再进行导出(3个月以内)!')
         return
-	  }
-	  // 情况4 注册时间与最后投递时间都选择
-	  if (!((params.beginRegisterTime == null && params.endRegisterTime == null) && (params.beginDate == null && params.endDate == null))) {
-        params.beginRegisterTime = moment(this.registerTime[0])
-        params.endRegisterTime = moment(this.registerTime[1])
-        params.beginDate = moment(this.lastDeliverTime[0])
-        params.endDate = moment(this.lastDeliverTime[1])
-	  }
-	  if (moment(params.endRegisterTime).diff(moment(params.beginRegisterTime), 'months', true) > 3) {
-	    this.$message.error('单次最多只能导出3个月的数据,请缩小注册时间区间后再进行导出!')
-	  }
-	  if (moment(params.endDate).diff(moment(params.beginDate), 'months', true) > 3) {
-	    this.$message.error('单次最多只能导出3个月的数据,请缩小最后投递时间区间后再进行导出!')
-	  }
-      // // 导出注册时间范围判断
-      // // if (this.registerTime && this.registerTime.length) {
-      // //   params.beginRegisterTime = moment(this.registerTime[0]).format('YYYY-MM-DD')
-      // //   params.endRegisterTime = moment(this.registerTime[1]).format('YYYY-MM-DD')
-      // // } else {
-      // //   params.beginRegisterTime = null
-      // //   params.endRegisterTime = null
-      // // }
-      // // if (!params.beginRegisterTime && !params.endRegisterTime) {
-      // //   this.$message.error('请先选择需要导出的注册时间区间再进行导出!')
-      // // }
-      // // // 判断两个时间段是否相差m个月  第二个参数指相差单位,第三个参数指是否返回浮点形式(小数)
-      // // if (moment(params.endRegisterTime).diff(moment(params.beginRegisterTime), 'months', true) > 3) {
-      // //   this.$message.error('单次最多只能导出3个月的数据,请缩小查询区间后再进行导出!')
-      // // }
-      // // // 导出最后投递时间范围判断哪
-      // // if (this.lastDeliverTime && this.lastDeliverTime.length) {
-      // //   params.beginDate = moment(this.lastDeliverTime[0]).format('YYYY-MM-DD')
-      // //   params.endDate = moment(this.lastDeliverTime[1]).format('YYYY-MM-DD')
-      // // } else {
-      // //   params.beginDate = null
-      // //   params.endDate = null
-      // // }
-      // // if (!params.beginDate && !params.endDate) {
-      // //   this.$message.error('请先选择需要导出的注册时间区间再进行导出!')
-      // // }
-      // // // 判断两个时间段是否相差m个月  第二个参数指相差单位,第三个参数指是否返回浮点形式(小数)
-      // // if (moment(params.endDate).diff(moment(params.beginDate), 'months', true) > 3) {
-      // //   this.$message.error('单次最多只能导出3个月的数据,请缩小查询区间后再进行导出!')
-      // // }
-      // console.log(params.beginRegisterTime, params.endRegisterTime, params.beginDate, params.endDate, '--------------导出参数')
+      }
       this.loading = true
       customeExport(params).then(res => {
         this.loading = false