Browse Source

新增组件及页面

liuqiwen 4 years ago
parent
commit
af9deb595e

+ 10 - 1
dgtis-ui/src/api/customerInformation/customerInformation.js

@@ -9,7 +9,7 @@ export function listCustomer(query) {
   })
 }
 
-// 查询用户详
+// 查询用户详
 export function getCustomerById(query) {
   return request({
     url: '/data/customer/getCustomerById',
@@ -18,4 +18,13 @@ export function getCustomerById(query) {
   })
 }
 
+// 查询用户概览
+export function getCustomerOverViewById(query) {
+  return request({
+    url: '/data/customer/getCustomerOverViewById',
+    method: 'get',
+    params: query
+  })
+}
+
 

+ 1 - 0
dgtis-ui/src/assets/styles/index.scss

@@ -125,6 +125,7 @@ aside {
   padding: 10px 20px;
   min-height: calc(100vh - 94px);
   box-sizing: border-box;
+  display: grid;
   .panelCol{
     min-height: calc(100vh - 126px);
     box-sizing: border-box;

+ 2 - 1
dgtis-ui/src/main.js

@@ -19,7 +19,7 @@ import './assets/icons' // icon
 import './permission' // permission control
 import { getDicts } from "@/api/system/dict/data";
 import { getConfigKey } from "@/api/system/config";
-import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, handleTree } from "@/utils/ruoyi";
+import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, handleTree,levelText } from "@/utils/ruoyi";
 import Pagination from "@/components/Pagination";
 //自定义表格工具扩展
 import RightToolbar from "@/components/RightToolbar"
@@ -34,6 +34,7 @@ Vue.prototype.selectDictLabel = selectDictLabel
 Vue.prototype.selectDictLabels = selectDictLabels
 Vue.prototype.download = download
 Vue.prototype.handleTree = handleTree
+Vue.prototype.levelText = levelText
 
 Vue.prototype.msgSuccess = function (msg) {
   this.$message({ showClose: true, message: msg, type: "success" });

+ 22 - 0
dgtis-ui/src/utils/ruoyi.js

@@ -160,3 +160,25 @@ export function tansParams(params) {
 	})
 	return result
 }
+// 客户等级
+export function levelText(val){
+  let text = '';
+  switch (val){
+    case 0:
+      text = '无';
+      break;
+    case 1:
+      text = '钻石';
+      break;
+    case 2:
+      text = '白金';
+      break;
+    case 3:
+      text = '黄金';
+      break;
+    case 4:
+      text = '普通';
+      break;
+  }
+  return text;
+}

+ 2 - 1
dgtis-ui/src/views/dashboard/BarChart3.vue

@@ -85,7 +85,8 @@
             trigger: 'axis',
             axisPointer: { // 坐标轴指示器,坐标轴触发有效
               type: 'shadow' // 默认为直线,可选为:'line' | 'shadow'
-            }
+            },
+            formatter:'{b}<br />{a0}: {c0}万<br />{a1}: {c1}万'
           },
           color:that.data.color,
           legend: {

+ 3 - 2
dgtis-ui/src/views/dashboard/BarTwoWayChart.vue

@@ -66,10 +66,11 @@
             trigger: 'axis',
             axisPointer: {
               type: 'shadow'
-            }
+            },
+            formatter:'{b}<br />{a}: {c}万'
           },
           legend: {
-            left: '17%',
+            left: 'center',
             top: 3,
             data: that.data.legendData
           },

+ 35 - 18
dgtis-ui/src/views/index.vue

@@ -66,34 +66,34 @@
                   <el-input v-model="conditionData.name"></el-input>
                 </el-form-item>
                 <el-form-item class="formItem" label="性别:" size="mini">
-                  <el-select v-model="conditionData.num">
+                  <el-select v-model="conditionData.sex">
                     <el-option label="男" value="男"></el-option>
                     <el-option label="女" value="女"></el-option>
                   </el-select>
                 </el-form-item>
                 <el-form-item class="formItem" label="省份:" size="mini">
-                  <el-select v-model="conditionData.num">
-                    <el-option label="河南" value="河南"></el-option>
-                    <el-option label="河北" value="河北"></el-option>
-                  </el-select>
+                  <el-input v-model="conditionData.province"></el-input>
                 </el-form-item>
                 <el-form-item class="formItem" label="学历:" size="mini">
                   <el-input v-model="conditionData.name"></el-input>
                 </el-form-item>
                 <el-form-item class="formItem" label="保单件数:" size="mini">
-                  <el-select v-model="conditionData.num">
-                    <el-option label="3张以下" value="有效"></el-option>
-                    <el-option label="4-7张" value="无效"></el-option>
-                    <el-option label="8-10张" value="无效"></el-option>
-                    <el-option label="10张以上" value="无效"></el-option>
+                  <el-select v-model="conditionData.ndNum">
+                    <el-option label="无保单" value="无保单"></el-option>
+                    <el-option label="1件" value="1件"></el-option>
+                    <el-option label="2件" value="2件"></el-option>
+                    <el-option label="3-5件" value="3-5件"></el-option>
+                    <el-option label="6-10件" value="6-10件"></el-option>
+                    <el-option label="11-20件" value="11-20件"></el-option>
+                    <el-option label="21-50件" value="21-50件"></el-option>
+                    <el-option label="50件以上" value="50件以上"></el-option>
                   </el-select>
                 </el-form-item>
                 <el-form-item class="formItem" label="客户类型:" size="mini">
-                  <el-select v-model="conditionData.num">
-                    <el-option label="客户类型1" value="有效"></el-option>
-                    <el-option label="客户类型2" value="无效"></el-option>
-                    <el-option label="客户类型3" value="无效"></el-option>
-                    <el-option label="客户类型4" value="无效"></el-option>
+                  <el-select v-model="conditionData.khType">
+                    <el-option label="投保人" value="投保人"></el-option>
+                    <el-option label="被保人" value="被保人"></el-option>
+                    <el-option label="受益人" value="受益人"></el-option>
                   </el-select>
                 </el-form-item>
                 <el-form-item class="formItem" label="核心客户号:" size="mini">
@@ -102,10 +102,18 @@
                 <el-form-item class="formItem" label="客户层级:" size="mini">
                   <el-input v-model="conditionData.name"></el-input>
                 </el-form-item>
-                <el-form-item class="formItemFull labelM" label="参与方进入时间:" size="mini">
+                <el-form-item class="formItemFull labelM dateQj" label="参与方进入时间:" size="mini">
                   <el-date-picker
-                    v-model="cyfDate"
+                    v-model="cyfDateS"
                     type="date"
+                    style="width: 46%;"
+                    placeholder="选择日期">
+                  </el-date-picker>
+                  -
+                  <el-date-picker
+                    v-model="cyfDateE"
+                    type="date"
+                    style="width: 46%;"
                     placeholder="选择日期">
                   </el-date-picker>
                 </el-form-item>
@@ -360,6 +368,11 @@
             let that = this;
             ageSexDis().then(response => {
                     console.log(response);
+                    response.data.seriesData.forEach((item,index) => {
+                      item.forEach((num,i) => {
+                        item[i] = ((num-0)/10000).toFixed(2);
+                      })
+                    })
                     that.barTwoWayChartData.xAxisData =  response.data.xaxisData;
                     that.barTwoWayChartData.seriesData =  response.data.seriesData;
                     that.barTwoWayChartData.legendData =  response.data.legendData;
@@ -372,9 +385,13 @@
           let that = this;
             riskcode().then(response => {
                     console.log(response);
+                    response.data.seriesData.forEach((item,index) => {
+                      item.data.forEach((num,i) => {
+                        item.data[i] = ((num-0)/10000).toFixed(2);
+                      })
+                    })
                     that.barChartData.xAxisData =  response.data.xaxisData;
                     that.barChartData.seriesData =  response.data.seriesData;
-                    this.loading = false;
                 }
             );
         },

+ 113 - 0
dgtis-ui/src/views/system/sameCustomer/index.vue

@@ -0,0 +1,113 @@
+<!--疑似相同客户-->
+<template>
+  <div class="app-container">
+    <div class="sameCustomerPanel">
+      <el-row class="btnDiv">
+        <el-col :span="20">
+          <el-button type="cyan">四要素疑似相同客户</el-button>
+          <span class="info"><i class="el-icon-info"></i>四要素疑似相同指姓名、性别、证件类型、手机号一致</span>
+        </el-col>
+        <el-col class="export" :span="4">
+          <el-button
+            type="warning"
+            icon="el-icon-download"
+            size="mini"
+            @click="handleExport"
+            v-hasPermi="['system:user:export']"
+          >导出</el-button>
+        </el-col>
+      </el-row>
+      <el-row class="btnDiv">
+        <el-col :span="20">
+          <el-button type="cyan">三要素疑似相同客户</el-button>
+          <span class="info"><i class="el-icon-info"></i>三要素疑似相同指姓名、性别、出生日期一致</span>
+        </el-col>
+        <el-col class="export" :span="4">
+          <el-button
+            type="warning"
+            icon="el-icon-download"
+            size="mini"
+            @click="handleExport"
+            v-hasPermi="['system:user:export']"
+          >导出</el-button>
+        </el-col>
+      </el-row>
+      <el-row class="btnDiv">
+        <el-col :span="20">
+          <el-button type="cyan">两要素疑似相同客户</el-button>
+          <span class="info"><i class="el-icon-info"></i>两要素疑似相同指姓名、证件号码一致</span>
+        </el-col>
+        <el-col class="export" :span="4">
+          <el-button
+            type="warning"
+            icon="el-icon-download"
+            size="mini"
+            @click="handleExport"
+            v-hasPermi="['system:user:export']"
+          >导出</el-button>
+        </el-col>
+      </el-row>
+    </div>
+  </div>
+</template>
+
+<script>
+import { getCustomerById } from "@/api/customerInformation/customerInformation.js";
+
+export default {
+  name: "sameCustomer",
+  components: {
+
+  },
+  data() {
+    return {
+
+    }
+  },
+  created() {
+
+  },
+  mounted() {
+      // this.getCustomerByIdData();
+  },
+  methods: {
+      getCustomerByIdData(){
+          this.loading = true;
+          let id = this.$route.query.id;
+          getCustomerById({id:id}).then(response => {
+                  console.log(response);
+                  this.custInfo = response.data.custInfo
+                  this.loading = false;
+              }
+          );
+      },
+  }
+};
+</script>
+<style lang="scss" scope>
+  .sameCustomerPanel{
+    padding: 15px;
+    background: #FFF;
+    border-radius: 5px;
+    /*position: absolute;*/
+    /*width: 100%;*/
+    /*height: 100%;*/
+  }
+  .btnDiv{
+    line-height: 80px;
+    border-bottom: 1px dashed #E7E7E7;
+    padding: 0 15px;
+    .info{
+      font-size: 12px;
+      color: #6D6D6D;
+      margin-left: 10px;
+      vertical-align: middle;
+      i{
+        margin-right: 6px;
+      }
+    }
+    .export{
+      text-align: right;
+    }
+  }
+</style>

+ 4 - 6
dgtis-ui/src/views/system/userInfo/components/habit.vue

@@ -3,11 +3,11 @@
     <el-row class="userInfo">
       <el-col :span="12">
         <span class="name">首选联系方式</span>
-        <span class="value">电话拜访</span>
+        <span class="value">{{data.ctype}}</span>
       </el-col>
       <el-col :span="12">
         <span class="name">兴趣爱好</span>
-        <span class="value">运动、养生、手工、篮球</span>
+        <span class="value">{{data.Hobby}}</span>
       </el-col>
     </el-row>
   </div>
@@ -17,7 +17,7 @@
   export default {
     props: {
       data: {
-        type: Array,
+        type: Object,
         default: {}
       },
     },
@@ -27,12 +27,10 @@
       };
     },
     mounted() {
-      this.initChart();
+
     },
     methods: {
-      initChart() {
 
-      }
     }
   };
 </script>

+ 6 - 8
dgtis-ui/src/views/system/userInfo/components/health.vue

@@ -3,19 +3,19 @@
     <el-row class="userInfo">
       <el-col :span="12">
         <span class="name">评估日期</span>
-        <span class="value">2020-01-03</span>
+        <span class="value">{{data.evadate}}</span>
       </el-col>
       <el-col :span="12">
         <span class="name">身高</span>
-        <span class="value">180cm</span>
+        <span class="value">{{data.height}}</span>
       </el-col>
       <el-col :span="12">
         <span class="name">体重</span>
-        <span class="value">70kg</span>
+        <span class="value">{{data.weight}}</span>
       </el-col>
       <el-col :span="12">
         <span class="name">BMI体质指数</span>
-        <span class="value">19(正常)</span>
+        <span class="value">{{data.bmi}}</span>
       </el-col>
     </el-row>
   </div>
@@ -25,7 +25,7 @@
   export default {
     props: {
       data: {
-        type: Array,
+        type: Object,
         default: {}
       },
     },
@@ -35,12 +35,10 @@
       };
     },
     mounted() {
-      this.initChart();
+
     },
     methods: {
-      initChart() {
 
-      }
     }
   };
 </script>

+ 4 - 6
dgtis-ui/src/views/system/userInfo/components/relationship.vue

@@ -2,14 +2,14 @@
 <template>
   <div class="userInfoPanel mt10 pd15">
     <el-table v-loading="loading" :data="data">
-      <el-table-column label="关系类型" width="90" align="center" prop="type" />
+      <el-table-column label="关系类型" width="90" align="center" prop="rstype" />
       <el-table-column label="参与方甲姓名" align="center" prop="name1" />
       <el-table-column label="参与方甲角色" align="center" prop="role1" />
       <el-table-column label="参与方乙姓名" align="center" prop="name2" :show-overflow-tooltip="true" />
       <el-table-column label="参与方乙角色" align="center" prop="role2" />
 <!--      <el-table-column label="开始时间" align="center" prop="startTime"></el-table-column>-->
 <!--      <el-table-column label="结束时间" align="center" prop="endTime" />-->
-      <el-table-column label="关系描述" align="center" prop="des" :show-overflow-tooltip="true"  />
+<!--      <el-table-column label="关系描述" align="center" prop="des" :show-overflow-tooltip="true"  />-->
     </el-table>
   </div>
 </template>
@@ -19,7 +19,7 @@
     props: {
       data: {
         type: Array,
-        default: {}
+        default: []
       },
     },
     data() {
@@ -28,12 +28,10 @@
       };
     },
     mounted() {
-      this.initChart();
+
     },
     methods: {
-      initChart() {
 
-      }
     }
   };
 </script>

+ 39 - 78
dgtis-ui/src/views/system/userInfo/index.vue

@@ -18,39 +18,39 @@
           </el-col>
           <el-col :span="12">
             <span class="name">民族</span>
-            <span class="value"></span>
+            <span class="value">{{custInfo.ethnic}}</span>
           </el-col>
           <el-col :span="12">
             <span class="name">出生日期</span>
-            <span class="value">{{custInfo.birthday}}</span>
+            <span class="value">{{parseTime(custInfo.birthday,'{yy}-{mm}-{dd}')}}</span>
             <el-tag type="warning" effect="dark" size="mini" v-if="custInfo.label3 && custInfo.label3 !='' ">{{custInfo.label3}}</el-tag>
             <el-tag type="warning" effect="dark" size="mini" v-if="custInfo.label96 && custInfo.label96 !='' ">{{custInfo.label96}}</el-tag>
             <el-tag type="warning" effect="dark" size="mini" v-if="custInfo.label97 && custInfo.label97 !='' ">{{custInfo.label97}}</el-tag>
           </el-col>
           <el-col :span="12">
             <span class="name">国籍</span>
-            <span class="value">中国</span>
+            <span class="value">{{custInfo.nation}}</span>
           </el-col>
           <el-col :span="12">
             <span class="name">婚姻状况</span>
-            <span class="value">已婚</span>
+            <span class="value">{{custInfo.maritalstat}}</span>
           </el-col>
           <el-col :span="12">
             <span class="name">职业</span>
-            <span class="value">律师</span>
+            <span class="value">{{custInfo.occupation}}</span>
             <el-tag type="warning" effect="dark" size="mini" v-if="custInfo.label98 && custInfo.label98 !='' ">{{custInfo.label98}}</el-tag>
           </el-col>
           <el-col :span="12">
             <span class="name">工作单位</span>
-            <span class="value">神州通誉软件(上海)有限公司</span>
+            <span class="value">{{custInfo.employer}}</span>
           </el-col>
           <el-col :span="12">
             <span class="name">最高学历</span>
-            <span class="value">硕士</span>
+            <span class="value">{{custInfo.education}}</span>
           </el-col>
           <el-col :span="12">
             <span class="name">客户类型</span>
-            <span class="value">投保人</span>
+            <span class="value">{{custInfo.custtype}}</span>
           </el-col>
           <el-col :span="12">
             <span class="name">客户等级</span>
@@ -58,7 +58,7 @@
           </el-col>
           <el-col :span="12">
             <span class="name">社保情况</span>
-            <span class="value">有社保</span>
+            <span class="value">{{custInfo.SIStatus}}</span>
           </el-col>
           <el-col :span="12">
             <span class="name">官微积分</span>
@@ -70,7 +70,7 @@
           </el-col>
           <el-col :span="12">
             <span class="name">个人年收入</span>
-            <span class="value">6w-8w</span>
+            <span class="value">{{custInfo.PIncome}}</span>
             <el-tag type="warning" effect="dark" size="mini" v-if="custInfo.label21 && custInfo.label21 !='' ">{{custInfo.label21}}</el-tag>
           </el-col>
 <!--          <el-col :span="12">-->
@@ -79,11 +79,11 @@
 <!--          </el-col>-->
           <el-col :span="12">
             <span class="name">收入来源</span>
-            <span class="value">工资</span>
+            <span class="value">{{custInfo.IncomeSource}}</span>
           </el-col>
           <el-col :span="12">
             <span class="name">户籍所在地</span>
-            <span class="value">江苏省南京市江宁区天元东路***号a区*栋****</span>
+            <span class="value">{{custInfo.regresidence}}</span>
           </el-col>
         </el-row>
       </div>
@@ -145,8 +145,8 @@ export default {
     return {
         custInfo:{},
       tabActive:'hyxx',
-      habitData:[],
-      healthData:[],
+      habitData:{},
+      healthData:{},
       contractInformationData:[],
       claimData:[],
       contactData:[
@@ -190,32 +190,7 @@ export default {
           phone:'180***121',
         },
       ],
-      relationshipData:[
-        {
-          type:'父母',
-          name1:'张大川',
-          role1:'儿子',
-          name2:'张三',
-          role2:'父亲',
-          des:'父子关系,张三是张大川的父亲',
-        },
-        {
-          type:'子女',
-          name1:'张大川',
-          role1:'父亲',
-          name2:'张蕾',
-          role2:'女儿',
-          des:'父女关系,张蕾是张大川的女儿',
-        },
-        {
-          type:'夫妻',
-          name1:'张大川',
-          role1:'丈夫',
-          name2:'王美丽',
-          role2:'妻子',
-          des:'夫妻关系,王美丽是张大川的妻子',
-        },
-      ],
+      relationshipData:[],
       touchedData: {
         data:[
           {
@@ -263,7 +238,7 @@ export default {
         // color:"chocolate",
         dowload:false,
     },
-      tagsData:['有极短意保单','给本人投保','给父母投保','给配偶投保','仅有一年期短险保单','有续期缴费的保单'],
+      tagsData:[],
     }
   },
   created() {
@@ -275,49 +250,34 @@ export default {
   methods: {
       getCustomerByIdData(){
           this.loading = true;
-          let id = this.$route.query.id;
+          let that = this;
+          let id = that.$route.query.id;
           getCustomerById({id:id}).then(response => {
                   console.log(response);
-                  this.custInfo = response.data.custInfo
-                  this.loading = false;
+                  that.custInfo = response.data.custInfo;
+                  that.relationshipData = response.data.relationship;
+                  that.habitData.ctype = response.data.custInfo.ctype;
+                  response.data.Hobby1 ? response.data.custInfo.Hobby1 = response.data.custInfo.Hobby1+'、' : response.data.custInfo.Hobby1 ='';
+                  response.data.Hobby2 ? response.data.custInfo.Hobby2 = response.data.custInfo.Hobby2+'、' : response.data.custInfo.Hobby2 ='';
+                  response.data.Hobby3 ? response.data.custInfo.Hobby3 = response.data.custInfo.Hobby3 : response.data.custInfo.Hobby3 ='';
+                  that.habitData.Hobby = response.data.custInfo.Hobby1 + response.data.custInfo.Hobby2 +response.data.custInfo.Hobby3;
+                  that.healthData.evadate = response.data.custInfo.evadate;
+                  that.healthData.height = response.data.custInfo.height;
+                  that.healthData.weight = response.data.custInfo.weight;
+                  that.healthData.bmi = response.data.custInfo.bmi;
+                  that.labelAll();
               }
           );
       },
-      // 客户等级
-      levelText(val){
-        var text = '';
-        switch (val){
-          case 0:
-            text = '无';
-            break;
-          case 1:
-            text = '钻石';
-            break;
-          case 2:
-            text = '白金';
-            break;
-          case 3:
-            text = '黄金';
-            break;
-          case 4:
-            text = '普通';
-            break;
-        }
-        return text;
-      },
-      labelPD(index){
+      labelAll(){
           var that = this;
-          var label = 'label'+index;
-          if(that.custInfo[label] && that.custInfo[label] != ""){
-              return true;
-          }else{
-              return false;
+          for(var i=0;i<120;i++){
+            var label = 'label'+i;
+            if(that.custInfo[label] && that.custInfo[label] != ""){
+              that.tagsData.push(that.custInfo[label]);
+            }
           }
-      },
-      labeText(index){
-          var that = this;
-          var label = 'label'+index;
-          return that.custInfo[label];
+          console.log(that.tagsData)
       },
     tabChange(tab, event){
       console.log(tab, event);
@@ -358,12 +318,13 @@ export default {
     .userInfoTab{
       margin-top: 16px;
       .tagDiv{
-        padding: 20px 30px;
+        padding: 10px 30px 20px;
         border-radius: 5px;
         background: #FFF;
         box-sizing: border-box;
         .tag{
           margin-right: 16px;
+          margin-top: 10px;
         }
       }
     }

+ 29 - 142
dgtis-ui/src/views/system/userInfoDetails/index.vue

@@ -25,17 +25,17 @@
               <div class="chart">
                 <div class="topNumDiv">
                   <div class="numTitle">保单总数</div>
-                  <div class="num">1张</div>
+                  <div class="num">{{custInfo.bdTotalNum}}张</div>
                 </div>
 <!--                <div class="dashedLine"></div>-->
                 <div class="bottomNumDiv">
                   <div class="leftNumDiv">
                     <div class="numTitle">有效保单</div>
-                    <div class="num">10张</div>
+                    <div class="num">{{custInfo.novpolicy}}张</div>
                   </div>
                   <div class="rightNumDiv">
                     <div class="numTitle">失效保单</div>
-                    <div class="num">5张</div>
+                    <div class="num">{{custInfo.noivpolicy}}张</div>
                   </div>
                 </div>
               </div>
@@ -62,7 +62,7 @@
 <!--                  <img style="width: 100%;" src="../../../assets/image/levelBg.png" alt=""/>-->
 <!--                </div>-->
                 <div class="levelImgDiv">
-                  <div class="level">白金会员</div>
+                  <div class="level">{{levelText(custInfo.custclass)}}会员</div>
                   <div class="isPay">已交保费</div>
                   <div class="payNum">234,897.234</div>
                 </div>
@@ -125,15 +125,15 @@
               <div class="userInfo">
                 <el-row class="mt20" :gutter="10">
                   <el-col :span="12">
-                    <div>姓名:张大春</div>
+                    <div>姓名:{{custInfo.name}}</div>
                   </el-col>
                   <el-col :span="12">
-                    <div>手机:123****8912</div>
+                    <div>手机:{{custInfo.pmphone}}</div>
                   </el-col>
                 </el-row>
                 <el-row :gutter="10">
                   <el-col :span="12">
-                    <div>年龄:30岁</div>
+                    <div>年龄:{{custInfo.age}}岁</div>
                   </el-col>
                 </el-row>
                 <div class="dayDiv">
@@ -165,7 +165,7 @@
 </template>
 
 <script>
-  import { getCustomerById } from "@/api/customerInformation/customerInformation.js";
+  import { getCustomerById,getCustomerOverViewById } from "@/api/customerInformation/customerInformation.js";
   import WordCloudChart from '../../dashboard/WordCloudChart'
   import LineBarChart from '../../dashboard/LineBarChart'
   import PieChartHalf from '../../dashboard/PieChartHalf'
@@ -179,136 +179,8 @@ export default {
   data() {
     return {
       chartsTitle:'',
-      wordCloudChartData:[
-      //   {
-      //   "name": "美食",
-      //   "value": 12
-      // },
-      //   {
-      //     "name": "网红店",
-      //     "value": 10
-      //   },
-      //   {
-      //     "name": "新冠肺炎疫情表彰大会",
-      //     "value": 10
-      //   },
-      //   {
-      //     "name": "打卡",
-      //     "value": 14
-      //   },
-      //   {
-      //     "name": "十一长假",
-      //     "value": 14
-      //   },
-      //   {
-      //     "name": "自由行",
-      //     "value": 16
-      //   },
-      //   {
-      //     "name": "教师节",
-      //     "value": 17
-      //   },
-      //   {
-      //     "name": "旅游景点攻略",
-      //     "value": 13
-      //   },
-      //   {
-      //     "name": "坡子街",
-      //     "value": 13
-      //   },
-      //   {
-      //     "name": "体育",
-      //     "value": 11
-      //   },
-      //   {
-      //     "name": "综艺",
-      //     "value": 12
-      //   },
-      //   {
-      //     "name": "商场",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "衡山",
-      //     "value": 12
-      //   },
-      //   {
-      //     "name": "科学家座谈会",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "潇湘晨报",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "张家界",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "橘子洲",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "房价",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "开学",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "湘江",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "繁华",
-      //     "value": 15
-      //   },
-      //   {
-      //     "name": "湖南公考",
-      //     "value": 14
-      //   },
-      //   {
-      //     "name": "中秋节",
-      //     "value": 14
-      //   },
-      //   {
-      //     "name": "天气",
-      //     "value": 14
-      //   },
-      //   {
-      //     "name": "幸福感",
-      //     "value": 14
-      //   },
-      //   {
-      //     "name": "芒果台",
-      //     "value": 13
-      //   },
-      //   {
-      //     "name": "游戏",
-      //     "value": 13
-      //   },
-      //   {
-      //     "name": "宝藏小店",
-      //     "value": 13
-      //   },
-      //   {
-      //     "name": "动漫",
-      //     "value": 13
-      //   },
-      //   {
-      //     "name": "武汉",
-      //     "value": 13
-      //   },
-      //   {
-      //     "name": "湖南大学",
-      //     "value": 13
-      //   },
-      //   {
-      //     "name": "湘西",
-      //     "value": 12
-      //   }
-      ],
+      custInfo : {},
+      wordCloudChartData:[],
       lineBarChartData:{
         expectedData:{
           name:'',
@@ -330,30 +202,45 @@ export default {
   },
   mounted() {
     this.getCustomerByIdData();
+    this.getCustomerOverViewByIdData();
   },
   methods: {
+    // 客户标签
     getCustomerByIdData(){
       this.loading = true;
       var that = this;
       let id = this.$route.query.id;
       getCustomerById({id:id}).then(response => {
           console.log(response);
-          that.custInfo = response.data.custInfo
         for(var i =0 ;i< 120;i++){
           var label = 'label'+i;
-          if(that.custInfo[label] && that.custInfo[label] != ""){
+          if(response.data.custInfo[label] && response.data.custInfo[label] != ""){
             var data = {
-              name:that.custInfo[label],
+              name:response.data.custInfo[label],
               value:i,
             }
             that.wordCloudChartData.push(data)
           }
         }
-        console.log(that.wordCloudChartData)
           this.loading = false;
         }
       );
     },
+    // 客户标签
+    getCustomerOverViewByIdData(){
+      this.loading = true;
+      var that = this;
+      let id = this.$route.query.id;
+      getCustomerOverViewById({id:id}).then(response => {
+          console.log(response);
+          that.custInfo = response.data.custInfo;
+          that.custInfo.bdTotalNum = that.custInfo.noivpolicy + that.custInfo.novpolicy;
+          // that.custInfo = response.data.custInfo
+          // console.log(that.wordCloudChartData)
+          // this.loading = false;
+        }
+      );
+    },
   }
 };
 </script>

+ 1 - 22
dgtis-ui/src/views/system/userInfoList/index.vue

@@ -120,28 +120,7 @@ export default {
         }
       );
     },
-    // 客户等级
-    levelText(val){
-      var text = '';
-      switch (val){
-        case 0:
-          text = '无';
-          break;
-        case 1:
-          text = '钻石';
-          break;
-        case 2:
-          text = '白金';
-          break;
-        case 3:
-          text = '黄金';
-          break;
-        case 4:
-          text = '普通';
-          break;
-      }
-      return text;
-    },
+
     /** 导出按钮操作 */
     handleExport() {
       this.download('system/user/export', {