From 38847671699154f97e4149bdf13c7284f1d1429a Mon Sep 17 00:00:00 2001 From: zhaoguoqiang <849348323@qq.com> Date: Fri, 13 Aug 2021 11:41:45 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E7=AD=89=E5=BE=85=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/data.js | 4 + src/router/index.js | 13 + src/views/dataOverview/index.vue | 46 +++- src/views/login.vue | 28 +- src/views/teamList/index.vue | 212 +++++++++++++++ src/views/teamPerformance/index.vue | 391 ++++++++++++++++++++++++++++ 6 files changed, 666 insertions(+), 28 deletions(-) create mode 100644 src/views/teamList/index.vue create mode 100644 src/views/teamPerformance/index.vue diff --git a/src/api/data.js b/src/api/data.js index ef71523..8daefaa 100644 --- a/src/api/data.js +++ b/src/api/data.js @@ -15,6 +15,10 @@ class data{ async dataDistribution(){ return await get("/admin/DataReport/ShopDataReport/dataDistribution") } + //全国服务商数据 + async poxyList(param){ + return await get("/admin/DataReport/ShopDataReport/poxyList",param) + } } export default new data() \ No newline at end of file diff --git a/src/router/index.js b/src/router/index.js index bbede3c..1fa032a 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -47,6 +47,19 @@ const routes = [{ name: 'dataOverview', component: () => import('../views/dataOverview/index.vue'), }, + { + path: "/teamList", + name: 'teamList', + component: () => import('../views/teamList/index.vue'), + meta: { + // title: '列表' + } + }, + { + path: "/teamPerformance", + name: 'teamPerformance', + component: () => import('../views/teamPerformance/index.vue'), + }, ]; const router = new VueRouter({ diff --git a/src/views/dataOverview/index.vue b/src/views/dataOverview/index.vue index 11520e1..8a844ba 100644 --- a/src/views/dataOverview/index.vue +++ b/src/views/dataOverview/index.vue @@ -9,7 +9,7 @@

服务商总数量

{{list.level_count | capitalize}}

-
+
@@ -18,7 +18,7 @@

{{list.level_5}}

-
+
@@ -27,7 +27,7 @@

{{list.level_4}}

-
+
@@ -36,7 +36,7 @@

{{list.level_3}}

-
+
@@ -45,7 +45,7 @@

{{list.level_2}}

-
+
@@ -59,7 +59,7 @@

本月新增服务商

-
+
@@ -68,7 +68,7 @@

{{list.month_add_level_5}}

-
+
@@ -77,7 +77,7 @@

{{list.month_add_level_4}}

-
+
@@ -86,7 +86,7 @@

{{list.month_add_level_3}}

-
+
@@ -95,7 +95,7 @@

{{list.month_add_level_2}}

-
+
@@ -110,7 +110,7 @@
本月团队业绩排名TOP
-
+

{{index+1}}

@@ -139,7 +139,7 @@ filters: { capitalize: function (val) { return (+val || 0).toFixed(0).replace(/\d{1,3}(?=(\d{3})+(\.\d*)?$)/g, '$&,') - } + }, }, created() { this.getData() @@ -150,6 +150,24 @@ this.list = res.data console.log(this.list, '---this.list'); }, + toTeamList(type, id) { + this.$router.push({ + path: '/teamList', + query: { + type: type, + level_id: id, + } + }) + }, + toTeamPerformance(){ + this.$router.push({ + path: '/teamPerformance', + query: { + // type: type, + // level_id: id, + } + }) + }, } } @@ -354,8 +372,8 @@ height: 26px; line-height: 26px; margin-bottom: 10px; - overflow: hidden; - width: 320px; + overflow: hidden; + width: 320px; } .teamMoney { diff --git a/src/views/login.vue b/src/views/login.vue index 5562e44..7b02c46 100644 --- a/src/views/login.vue +++ b/src/views/login.vue @@ -6,22 +6,22 @@ let url = this.$route.query; let token; let url_string = JSON.stringify(url); - if (url_string == "{}") { - this.$toast('请先登录') - } else { - token = url.token_type + " " + url.access_token; - this.$store.commit("user/setToken", token); - this.$router.push({ - path: "/home", - }); - } - - // token = - // "bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOlwvXC90ZXN0LnFpbmd3ZWlsYWk4ODgueHl6XC9hZG1pblwvbG9naW4iLCJpYXQiOjE2Mjc0NjU1ODksImV4cCI6MTk4NzQ2NTU4OSwibmJmIjoxNjI3NDY1NTg5LCJqdGkiOiJ6clVHYnJCOXlPWkpRanRUIiwic3ViIjoxNjEsInBydiI6IjBiMzZjMGUwMjMyZGVlZTlkOTZhZDA0NGY3YWE2MjQ2YTUwYTU3ZmEifQ.aFc5fCUffmDN7zBRn-D13kx1LuLNG1Ej7vQOu4O2_AA" - // this.$store.commit("user/setToken", token); - // this.$router.push({ + // if (url_string == "{}") { + // this.$toast('请先登录') + // } else { + // token = url.token_type + " " + url.access_token; + // this.$store.commit("user/setToken", token); + // this.$router.push({ // path: "/home", // }); + // } + + token = + "bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOlwvXC90ZXN0LnFpbmd3ZWlsYWk4ODgueHl6XC9hZG1pblwvbG9naW4iLCJpYXQiOjE2Mjc0NjU1ODksImV4cCI6MTk4NzQ2NTU4OSwibmJmIjoxNjI3NDY1NTg5LCJqdGkiOiJ6clVHYnJCOXlPWkpRanRUIiwic3ViIjoxNjEsInBydiI6IjBiMzZjMGUwMjMyZGVlZTlkOTZhZDA0NGY3YWE2MjQ2YTUwYTU3ZmEifQ.aFc5fCUffmDN7zBRn-D13kx1LuLNG1Ej7vQOu4O2_AA" + this.$store.commit("user/setToken", token); + this.$router.push({ + path: "/home", + }); }, }; diff --git a/src/views/teamList/index.vue b/src/views/teamList/index.vue new file mode 100644 index 0000000..141748e --- /dev/null +++ b/src/views/teamList/index.vue @@ -0,0 +1,212 @@ + + + + + \ No newline at end of file diff --git a/src/views/teamPerformance/index.vue b/src/views/teamPerformance/index.vue new file mode 100644 index 0000000..9137e2a --- /dev/null +++ b/src/views/teamPerformance/index.vue @@ -0,0 +1,391 @@ + + + \ No newline at end of file From bdfb7e51e46cb1b01091a19e37f9637df6db1bda Mon Sep 17 00:00:00 2001 From: zhaoguoqiang <849348323@qq.com> Date: Fri, 13 Aug 2021 15:59:34 +0800 Subject: [PATCH 2/2] 1 --- src/views/dataOverview/index.vue | 14 +++++++------- src/views/teamList/index.vue | 2 +- src/views/teamPerformance/index.vue | 14 +++++++------- 3 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/views/dataOverview/index.vue b/src/views/dataOverview/index.vue index 8a844ba..16fae43 100644 --- a/src/views/dataOverview/index.vue +++ b/src/views/dataOverview/index.vue @@ -160,13 +160,13 @@ }) }, toTeamPerformance(){ - this.$router.push({ - path: '/teamPerformance', - query: { - // type: type, - // level_id: id, - } - }) + // this.$router.push({ + // path: '/teamPerformance', + // query: { + // // type: type, + // // level_id: id, + // } + // }) }, } } diff --git a/src/views/teamList/index.vue b/src/views/teamList/index.vue index 141748e..4393296 100644 --- a/src/views/teamList/index.vue +++ b/src/views/teamList/index.vue @@ -1,7 +1,7 @@