Prechádzať zdrojové kódy

Merge branch 'master' of ssh://git.web.ximengnaikang.com:2222/daweiboshi/admin

lxs 4 rokov pred
rodič
commit
ca3772690a

+ 1 - 1
src/api/data.js

@@ -21,7 +21,7 @@ export const dataDataAna = params => request({ url: '/data/all_data', method: 'g
 export const dataWarRank = params => request({ url: '/data/service_sale', method: 'get', params })
 
 export const api_Data1 = params => request({ url: '/data/sign_up', method: 'get', params })
-export const api_Data2 = params => request({ url: '/data/season_sale', method: 'get', params })
+export const api_Data2 = params => request({ url: '/season/season_sale', method: 'get', params })
 export const api_Data3 = params => request({ url: '/data/per_capita', method: 'get', params })
 export const api_Data4 = params => request({ url: '/data/sale_per_capita', method: 'get', params })
 export const api_Data5 = params => request({ url: '/data/level_capita', method: 'get', params })

+ 7 - 2
src/components/Charts/SignupLineChart.vue

@@ -82,7 +82,7 @@ export default {
           bottom: 8,
           containLabel: true
         },
-        color: ['#4C9ECD', '#D970D0'],
+        color: ['#4C9ECD', '#D970D0', '#5AC4B6'],
         tooltip: {
           trigger: 'axis',
           axisPointer: {
@@ -92,7 +92,7 @@ export default {
         legend: {
           top: 8,
           right: 8,
-          data: ['销售经理', '销售主管']
+          data: ['销售经理', '销售主管', '代理公司']
         },
         toolbox: {
           show: false
@@ -127,6 +127,11 @@ export default {
             name: '销售主管',
             type: this.type,
             data: this.chartData.tj
+          },
+          {
+            name: '代理公司',
+            type: this.type,
+            data: this.chartData.crown
           }
         ]
       })

+ 8 - 3
src/components/Charts/SignupLineChart1.vue

@@ -82,7 +82,7 @@ export default {
           bottom: 8,
           containLabel: true
         },
-        color: ['#4C9ECD', '#D970D0'],
+        color: ['#4C9ECD', '#D970D0', '#5AC4B6'],
         tooltip: {
           trigger: 'axis',
           axisPointer: {
@@ -91,8 +91,8 @@ export default {
         },
         legend: {
           top: 8,
-          right: 8,
-          data: ['销售经理', '销售主管']
+          right: 0,
+          data: ['销售经理', '销售主管', '代理公司']
         },
         toolbox: {
           show: false
@@ -127,6 +127,11 @@ export default {
             name: '销售主管',
             type: this.type,
             data: this.chartData.tj
+          },
+          {
+            name: '代理公司',
+            type: this.type,
+            data: this.chartData.crown
           }
         ],
         animation: true

+ 15 - 0
src/views/DataScreen1/index.vue

@@ -9,6 +9,8 @@
       <div class="total-item">{{ superNum }}</div>
       <div class="total-item">销售经理人数</div>
       <div class="total-item">{{ topNum }}</div>
+      <div class="total-item">代理公司人数</div>
+      <div class="total-item">{{ crownNum }}</div>
     </div>
     <div class="map">
       <div v-if="mapChartData.length > 0" id="china1" style="width:100%;height:100%;" />
@@ -27,6 +29,7 @@
         <el-table-column label="地区" prop="name" align="center" />
         <el-table-column label="销售主管" prop="tj" align="center" />
         <el-table-column label="销售经理" prop="top" align="center" />
+        <el-table-column label="代理公司" prop="crown" align="center" />
         <el-table-column label="合计" align="center">
           <template slot-scope="scope">{{ scope.row.top + scope.row.tj }}</template>
         </el-table-column>
@@ -38,6 +41,7 @@
               <el-table-column label="城市" prop="name" align="center" />
               <el-table-column label="销售主管" prop="tj" align="center" />
               <el-table-column label="销售经理" prop="top" align="center" />
+              <el-table-column label="代理公司" prop="crown" align="center" />
               <el-table-column label="合计" prop="value" align="center" />
             </el-table>
           </template>
@@ -117,6 +121,7 @@ export default {
       total: 0,
       topNum: 0,
       superNum: 0,
+      crownNum: 0,
       timer: null,
       opened: false,
       mapChartData: [],
@@ -160,6 +165,13 @@ export default {
           female: '/'
         },
         {
+          level: '代理公司',
+          num: this.superNum,
+          percent: (this.crownNum / this.total * 100).toFixed(2) + '%',
+          male: '/',
+          female: '/'
+        },
+        {
           level: '合计',
           num: this.total,
           percent: (this.total / this.total * 100).toFixed(2) + '%',
@@ -214,11 +226,13 @@ export default {
         this.lineChartData = {
           top: res.data.list1,
           tj: res.data.list2,
+          crown: res.data.list7,
           time: res.data.list3
         }
         if (!this.opened) {
           this.tabbleChartData = res.data.list.sort((a, b) => b.value - a.value)
         }
+        this.crownNum = res.data.crown
         this.topNum = res.data.top
         this.superNum = res.data.tj
         this.total = res.data.total
@@ -251,6 +265,7 @@ export default {
                   总报名人数:${params.value} <br />
                   销售主管报名人数:${this.mapChartData[params.dataIndex].tj} <br />
                   销售经理报名人数:${this.mapChartData[params.dataIndex].top} <br />
+                  代理公司报名人数:${this.mapChartData[params.dataIndex].crown} <br />
                 `
               }
             },

+ 27 - 12
src/views/DataScreen2/index.vue

@@ -7,11 +7,13 @@
         <div class="item">累计报名人数</div>
         <div class="item">销售主管人数</div>
         <div class="item">销售经理人数</div>
+        <div class="item">代理公司人数</div>
       </div>
       <div class="bot">
         <div class="item">{{ total }}</div>
         <div class="item">{{ superNum }}</div>
         <div class="item">{{ topNum }}</div>
+        <div class="item">{{ crownNum }}</div>
       </div>
     </div>
     <div class="map">
@@ -27,22 +29,24 @@
     </div>
     <div id="table-wrapper" class="table-wrapper">
       <el-table ref="table" :data="tabbleChartData" style="width: 100%" header-cell-class-name="fsdfasdfas" @expand-change="open">
-        <el-table-column label="排名" :width="width / 11 * 2" type="index" align="center" :index="index => index + 1" />
-        <el-table-column label="地区" :width="width / 11 * 2" prop="name" align="center" />
-        <el-table-column label="销售主管" :width="width / 11 * 2" prop="tj" align="center" />
-        <el-table-column label="销售经理" :width="width / 11 * 2" prop="top" align="center" />
-        <el-table-column label="合计" :width="width / 11 * 2" align="center">
+        <el-table-column label="排名" :width="width / 13 * 2" type="index" align="center" :index="index => index + 1" />
+        <el-table-column label="地区" :width="width / 13 * 2" prop="name" align="center" />
+        <el-table-column label="销售主管" :width="width / 13 * 2" prop="tj" align="center" />
+        <el-table-column label="销售经理" :width="width / 13 * 2" prop="top" align="center" />
+        <el-table-column label="代理公司" :width="width / 13 * 2" prop="crown" align="center" />
+        <el-table-column label="合计" :width="width / 13 * 2" align="center">
           <template slot-scope="scope">{{ scope.row.top + scope.row.tj }}</template>
         </el-table-column>
-        <el-table-column type="expand" :width="width / 11 * 1">
+        <el-table-column type="expand" :width="width / 13 * 1">
           <template slot-scope="props">
             <signup-line-chart1 v-if="props.row.chart" :chart-data="props.row.chart" />
             <el-table v-if="props.row.list" :data="props.row.list" border style="width: 100%">
-              <el-table-column label="排名" type="index" align="center" :width="(width - 16 ) / 5" :index="index => index + 1" />
-              <el-table-column label="城市" prop="name" align="center" :width="(width - 16 ) / 5" />
-              <el-table-column label="销售主管" prop="tj" align="center" :width="(width - 16 ) / 5" />
-              <el-table-column label="销售经理" prop="top" align="center" :width="(width - 16 ) / 5" />
-              <el-table-column label="合计" prop="value" align="center" :width="(width - 16 ) / 5" />
+              <el-table-column label="排名" type="index" align="center" :width="(width - 16 ) / 6" :index="index => index + 1" />
+              <el-table-column label="城市" prop="name" align="center" :width="(width - 16 ) / 6" />
+              <el-table-column label="销售主管" prop="tj" align="center" :width="(width - 16 ) / 6" />
+              <el-table-column label="销售经理" prop="top" align="center" :width="(width - 16 ) / 6" />
+              <el-table-column label="代理公司" prop="crown" align="center" :width="(width - 16 ) / 6" />
+              <el-table-column label="合计" prop="value" align="center" :width="(width - 16 ) / 6" />
             </el-table>
           </template>
         </el-table-column>
@@ -120,6 +124,7 @@ export default {
       width: document.body.offsetWidth,
       total: 0,
       topNum: 0,
+      crownNum: 0,
       superNum: 0,
       timer: null,
       opened: false,
@@ -164,6 +169,13 @@ export default {
           female: '/'
         },
         {
+          level: '代理公司',
+          num: this.superNum,
+          percent: (this.crownNum / this.total * 100).toFixed(2) + '%',
+          male: '/',
+          female: '/'
+        },
+        {
           level: '合计',
           num: this.total,
           percent: (this.total / this.total * 100).toFixed(2) + '%',
@@ -254,12 +266,14 @@ export default {
         this.lineChartData = {
           top: res.data.list1,
           tj: res.data.list2,
+          crown: res.data.list7,
           time: res.data.list3
         }
         if (!this.opened) {
           this.tabbleChartData = res.data.list.sort((a, b) => b.value - a.value)
         }
         this.topNum = res.data.top
+        this.crownNum = res.data.crown
         this.superNum = res.data.tj
         this.total = res.data.total
         res.data.list4.forEach(e => {
@@ -290,13 +304,14 @@ export default {
               formatter: params => {
                 this.$emit('renderDetail', params.dataIndex)
                 return `
-                  <div style="min-width: 123px; height: 60px; display:flex; align-items: center;">
+                  <div style="min-width: 123px; height: 75px; display:flex; align-items: center;">
                     <div id="TooltipInfo" style="flex: 1; height: 100%; font-size: 8px; line-height: 12px; padding-right: 6px; border-right: 0.4px solid #FFFFFF;">
                       <div>省份:${params.name}</div>
                       <div>排名:${params.dataIndex + 1}</div>
                       <div>总报名人数:${params.value}</div>
                       <div>销售主管报名人数:${this.mapChartData[params.dataIndex].tj}</div>
                       <div>销售经理报名人数:${this.mapChartData[params.dataIndex].top}</div>
+                      代理公司报名人数:${this.mapChartData[params.dataIndex].crown} <br />
                     </div>
                     <div id="TooltipDetail" style="height: 100%; line-height: 60px; margin-left: 8px;">详情 ></div>
                   </div>

+ 7 - 44
src/views/SignupManage.vue

@@ -1,31 +1,13 @@
 <template>
   <div class="zbssignupmanage">
     <div class="header">
-      <el-input
-        v-model="search"
-        clearable
-        maxlength="11"
-        placeholder="输入手机号 / 用户昵称搜索"
-        prefix-icon="el-icon-search"
-        @keyup.enter.native="handleSearch()"
-      />
+      <el-input v-model="search" clearable maxlength="11" placeholder="输入手机号 / 用户昵称搜索" prefix-icon="el-icon-search" @keyup.enter.native="handleSearch()" />
       <el-button type="primary" icon="el-icon-search" :loading="loading" @click="handleSearch()">搜索/刷新</el-button>
       <el-button style="margin:0 20px;" @click="download"><i class="el-icon-document" />&nbsp;导出报名名单</el-button>
       <switchseason class="switchseason" @switchseason="switchseason" />
     </div>
-    <el-table
-      v-loading="loading"
-      border
-      stripe
-      :data="list"
-      style="width: 100%"
-    >
-      <el-table-column
-        label="序号"
-        type="index"
-        width="60"
-        :index="index => 15 * (page - 1) + index + 1"
-      />
+    <el-table v-loading="loading" border stripe :data="list" style="width: 100%">
+      <el-table-column label="序号" type="index" width="60" :index="index => 15 * (page - 1) + index + 1" />
       <el-table-column
         label="报名时间"
         width="140"
@@ -47,12 +29,7 @@
           <img width="34" height="34" :src="scope.row.avatar">
         </template>
       </el-table-column>
-      <el-table-column
-        label="昵称"
-        width="200"
-        prop="nickname"
-        label-class-name="label"
-      />
+      <el-table-column label="昵称" width="200" prop="nickname" label-class-name="label" />
       <el-table-column
         label="手机号"
         width="120"
@@ -91,16 +68,8 @@
           <div :style="{ color: scope.row.refunded ? 'green' : '#f40' }">{{ scope.row.refunded ? '已退款' : '未退款' }}</div>
         </template>
       </el-table-column>
-      <el-table-column
-        label="微信付款流水号"
-        prop="pay_order_num"
-        label-class-name="label"
-      />
-      <el-table-column
-        label="微信退款流水号"
-        prop="refund_order_num"
-        label-class-name="label"
-      />
+      <el-table-column label="微信付款流水号" prop="pay_order_num" label-class-name="label" />
+      <el-table-column label="微信退款流水号" prop="refund_order_num" label-class-name="label" />
       <el-table-column
         label="操作"
         prop="status"
@@ -140,13 +109,7 @@
         </template>
       </el-table-column>
     </el-table>
-    <el-pagination
-      background
-      :total="total"
-      :page-size="15"
-      layout="total, prev, pager, next, jumper"
-      @current-change="handleCurrentChange"
-    />
+    <el-pagination background :total="total" :page-size="15" layout="total, prev, pager, next, jumper" @current-change="handleCurrentChange" />
 
     <el-dialog title="取消用户比赛资格" :visible.sync="dialogFormVisible" :close-on-click-modal="false">
       <el-form :model="form" autocomplete="off">

+ 2 - 2
vue.config.js

@@ -19,8 +19,8 @@ module.exports = {
     },
     proxy: {
       [process.env.VUE_APP_BASE_API]: {
-        // target: 'https://api.admin.jiuweiyun.cn/api',
-        target: 'http://192.168.0.15:8016/api',
+        target: 'https://api.admin.jiuweiyun.cn/api',
+        // target: 'http://192.168.0.4:8090/api',
         changeOrigin: true,
         pathRewrite: {
           ['^' + process.env.VUE_APP_BASE_API]: ''