diff --git a/config.js b/config.js index d159b65..81fad2e 100644 --- a/config.js +++ b/config.js @@ -2,9 +2,9 @@ * 小程序配置文件 */ // 此处主机域名修改成腾讯云解决方案分配的域名 -// var host = 'http://121.42.63.138:9091/autoSR/api'; // 测试站 +var host = 'http://121.42.63.138:9091/autoSR/api'; // 测试站 // var host = 'http://192.168.31.163:8080/autoSR/api'; // 长龙 -var host = 'http://192.168.31.128:8080/autoSR/api'; // 佳豪 +// var host = 'http://192.168.31.128:8080/autoSR/api'; // 佳豪 // var host = 'http://10.2.1.104:8081/autoSR/api'; // 刘敏 // var host = 'https://zkgj.quhouse.com/api'; // 质控正式 // var host = 'https://hfju.com/api'; // 数智正式 diff --git a/pages/center/Piabodata/Customerportrait/Receivedetailabout.vue b/pages/center/Piabodata/Customerportrait/Receivedetailabout.vue index 7f50b31..a4d14c5 100644 --- a/pages/center/Piabodata/Customerportrait/Receivedetailabout.vue +++ b/pages/center/Piabodata/Customerportrait/Receivedetailabout.vue @@ -247,33 +247,46 @@ - - - 总执行率 {{totalRate}}% - - - - {{item.name}} - - - - - {{((item.ratepercent/item.rate).toFixed(2)*100).toFixed()}}% - - + + 指标 + 执行率 + + + + {{item.name}} + + + + {{((item.ratepercent/item.rate).toFixed(2)*100).toFixed()}}% - - - {{subitem.name}} - - - + + + + + + + + + {{subitem.name}} + + 已执行 + 未执行 + + + + + + + 话术内容 + + {{inc+1}}.{{che.name}} + + + + @@ -1213,6 +1226,13 @@ item.show = false } }, + changeshow2(item, type){ + if (type == 1) { + item.show = true + } else { + item.show = false + } + }, // 获取评分 getRatelist() { if (this.ratelist.length == 0) { @@ -1224,7 +1244,6 @@ }).then(res => { if (res.length) { let level1 = [] - let level2rate = 0 res.forEach(item => { if (item.pid == 0) { level1.push({ @@ -1236,13 +1255,9 @@ ratepercent: 0, children: [] }) - } else { - if (item.selected == 0) { - level2rate += item.fraction - } - } + } }) - this.totalRate = level2rate + // this.totalRate = level2rate; res.forEach(subitem => { let subitempid = subitem.pid level1.forEach(item => { @@ -1255,12 +1270,31 @@ rate: subitem.fraction, selected: subitem.selected, name: subitem.name, - marketingId:subitem.marketingId + show: false, + marketingId:subitem.marketingId, + children: [] }) } }) }) + res.forEach(subitem => { + let subitempid = subitem.pid + level1.forEach(chen=>{ + chen.children.forEach(zxc=>{ + if(subitempid == zxc.marketingId){ + zxc.children.push({ + id: subitem.id, + rate: subitem.fraction, + selected: subitem.selected, + name: subitem.name, + marketingId:subitem.marketingId, + }) + } + }) + }) + }) level1[0].show = true; + level1[0].children[0].show = true; this.ratelist = level1 } setTimeout(function() { @@ -1866,103 +1900,6 @@ height: 34upx; } } -// 评分 -.rate-box { - padding: 10rpx 20rpx; - .date { - width: 300rpx; - height: 33rpx; - font-size: 24rpx; - font-weight: 400; - color: #333333; - line-height: 33rpx; - letter-spacing: 1rpx; - margin-bottom: 8rpx; - } - .title { - width: 100%; - height: 42rpx; - font-size: 30rpx; - font-weight: 500; - color: #333333; - line-height: 42rpx; - letter-spacing: 2rpx; - margin-bottom: 20rpx; - } - .level1 { - display: flex; - align-items: center; - .level-name { - width: 104rpx; - height: 33rpx; - font-size: 24rpx; - font-weight: 500; - color: #333333; - line-height: 33rpx; - letter-spacing: 1rpx; - margin-right: 10rpx; - } - .level-progress { - flex: 1; - border-radius: 11rpx; - height: 21rpx; - background-color: #F2F2F2; - position: relative; - .color { - width: 0; - position: absolute; - top: 0; - left: 0; - height: 21rpx; - border-radius: 11rpx 0 0 11rpx; - background-color: #60D7A0; - } - } - .level-rate { - width: 65rpx; - height: 33rpx; - font-size: 24rpx; - font-weight: 500; - color: #333333; - line-height: 33rpx; - letter-spacing: 1rpx; - margin: 0 20rpx 0 15rpx; - } - .arrow { - width: 34rpx; - height:26rpx; - padding: 5rpx 20rpx; - } - .rotatearrow { - transform: rotate(270deg); - } - } - .level1-subbox { - display: flex; - margin-top: 20rpx; - flex-wrap: wrap; - - .sub-name { - width: 50%; - display: flex; - margin-bottom: 18rpx; - .subitem-name { - width: 104rpx; - height: 33rpx; - font-size: 24rpx; - font-weight: 400; - color: #999999; - line-height: 33rpx; - letter-spacing: 1rpx; - margin-right: 12rpx; - } - .checkimg { - width: 27rpx; - height: 27rpx; - } - } - } -} .jiangshang{ color: #2671E2; background: #F4F8FD; @@ -2025,4 +1962,148 @@ color: #FFFFFF; border: none; } + .Level-box{ + padding-bottom: 2rpx; + .hhhbox{ + width:100%; + padding-left: 30rpx; + padding-right: 30rpx; + border-bottom: 1rpx solid #E0E0E0; + background: #FFFFFF; + // padding-bottom: 32rpx; + .hsnrtest{ + height: 24rpx; + font-size: 24rpx; + font-weight: 400; + color: #666666; + line-height: 24rpx; + } + .Level3che{ + width:100%; + height:28rpx; + display: flex; + line-height: 28rpx; + align-items: center; + margin-top: 30rpx; + .title1{ + flex: 1; + font-size: 28rpx; + color:#2671E2; + font-weight: 400; + } + .jiantobox{ + width: 30rpx; + height: 30rpx; + display: flex; + align-items: center; + .arrow{ + width: 28rpx; + height:28rpx; + } + } + } + } + .Level2che{ + width:100%; + height: 88rpx; + display: flex; + line-height: 88rpx; + align-items: center; + .title1{ + flex: 2; + font-size: 28rpx; + color: #333333; + font-weight: 400; + } + .leve1-jindu{ + flex: 3; + display: flex; + justify-content: center; + align-items: center; + .zhixing{ + width: 108rpx; + height: 44rpx; + background: #2671E2; + border-radius: 4rpx; + font-size: 28rpx; + text-align: center; + line-height: 44rpx; + color: #FFFFFF; + } + .zhixing2{ + width: 108rpx; + height: 44rpx; + background: #F8F8F8; + border-radius: 4rpx; + font-size: 28rpx; + text-align: center; + line-height: 44rpx; + color: #999999; + } + } + .jiantobox{ + width: 30rpx; + height: 30rpx; + display: flex; + align-items: center; + .arrow{ + width: 30rpx; + height:18rpx; + } + } + } + .Level1che{ + width:100%; + height: 94rpx; + background: #E0E0E0; + display: flex; + line-height: 94rpx; + align-items: center; + padding-left: 30rpx; + padding-right: 30rpx; + .title1{ + flex: 2; + font-size: 30rpx; + color: #333333; + font-weight: 400; + } + .leve1-jindu{ + flex: 3; + .jindutiao{ + width: 96%; + height: 28rpx; + background: #D5EEE2; + line-height: 28rpx; + border-radius: 14rpx; + position: relative; + .huanxing{ + height: 100%; + background: #4FC78F; + border-radius: 14rpx; + } + .text{ + position: absolute; + top: 0rpx; + right: 0rpx; + font-size: 28rpx; + font-weight: 400; + color: #333333; + } + } + } + .jiantobox{ + width: 30rpx; + height: 30rpx; + display: flex; + align-items: center; + .arrow{ + width: 30rpx; + height:18rpx; + } + } + } + } + .rotatearrow { + transform: rotate(270deg); + } diff --git a/pages/center/consumer/consumerDetail.vue b/pages/center/consumer/consumerDetail.vue index 9f08495..d2b750b 100644 --- a/pages/center/consumer/consumerDetail.vue +++ b/pages/center/consumer/consumerDetail.vue @@ -157,6 +157,7 @@ 指标 执行率 + @@ -165,33 +166,45 @@ 暂无数据 - - - - - - {{item.name}} + + + + {{item.name}} + + + + {{((item.ratepercent/item.rate).toFixed(2)*100).toFixed()}}% - - + + + + + + + + + {{subitem.name}} + + 已执行 + 未执行 + + + + - {{((item.ratepercent/item.rate).toFixed(2)*100).toFixed()}}% - - - - - {{subitem.name}} - - + 话术内容 + + {{inc+1}}.{{che.name}} + + + - - - + + @@ -382,6 +395,13 @@ item.show = false } }, + changeshow2(item, type){ + if (type == 1) { + item.show = true + } else { + item.show = false + } + }, // 获取评分 getRatelist() { this.$u.get("/customer/findzkMByCusId", { @@ -389,7 +409,6 @@ }).then(res => { if (res.length) { let level1 = [] - let level2rate = 0 res.forEach(item => { if (item.pid == 0) { level1.push({ @@ -401,13 +420,9 @@ ratepercent: 0, children: [] }) - } else { - if (item.selected == 0) { - level2rate += item.fraction - } - } + } }) - this.totalRate = level2rate + // this.totalRate = level2rate; res.forEach(subitem => { let subitempid = subitem.pid level1.forEach(item => { @@ -420,12 +435,31 @@ rate: subitem.fraction, selected: subitem.selected, name: subitem.name, - marketingId:subitem.marketingId + show: false, + marketingId:subitem.marketingId, + children: [] }) } }) }) + res.forEach(subitem => { + let subitempid = subitem.pid + level1.forEach(chen=>{ + chen.children.forEach(zxc=>{ + if(subitempid == zxc.marketingId){ + zxc.children.push({ + id: subitem.id, + rate: subitem.fraction, + selected: subitem.selected, + name: subitem.name, + marketingId:subitem.marketingId, + }) + } + }) + }) + }) level1[0].show = true; + level1[0].children[0].show = true; this.ratelist = level1 } }) @@ -435,6 +469,263 @@ \ No newline at end of file diff --git a/utils/http.js b/utils/http.js index b418c26..6b26aeb 100644 --- a/utils/http.js +++ b/utils/http.js @@ -1,7 +1,7 @@ -// const baseUrl = 'http://121.42.63.138:9091/autoSR/api';// 测试站 +const baseUrl = 'http://121.42.63.138:9091/autoSR/api';// 测试站 // const baseUrl = 'http://192.168.31.161:8080/autoSR/api'; // 长龙 -const baseUrl = 'http://192.168.31.128:8080/autoSR/api'; // 佳豪 +// const baseUrl = 'http://192.168.31.128:8080/autoSR/api'; // 佳豪 // const baseUrl = 'http://10.2.1.104:8081/autoSR/api'; // 刘敏 // const baseUrl = 'https://zkgj.quhouse.com/api'; // 质控正式 // const baseUrl = 'https://hfju.com/api'; // 数智正式