From 5b243fd5e21fd1277801746765a490bad2b05f75 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E9=A3=8E=E7=BB=A7=E7=BB=AD=E5=90=B9?= <17611323298@163.com>
Date: Fri, 20 Oct 2023 10:07:04 +0800
Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
App.vue | 38 +++++++++--
manifest.json | 4 +-
pages/center/Piabodata/Userinsightinto.vue | 37 +++++++++--
pages/index/consumer/index.vue | 16 +++++
pages/mine/details2.vue | 76 ++++++++++++++++++----
5 files changed, 148 insertions(+), 23 deletions(-)
diff --git a/App.vue b/App.vue
index 0aba66a..63c0fe3 100644
--- a/App.vue
+++ b/App.vue
@@ -5,6 +5,10 @@
var config = require("./config");
export default {
onLaunch(options) {
+ uni.$on('sendStayTime', (data) => {
+ this.getTimeChecks(data)
+ })
+
this.setTabbarItems() // 设置tabbar
// 获取用户信息
uni.getSystemInfo({
@@ -27,11 +31,11 @@
bulidIngObj: uni.getStorageSync('buildingID'),
};
},
-
+
onLoad() {
this.setTabbarItems()
},
-
+
methods: {
// 设置底部导航栏
@@ -152,8 +156,7 @@
serviceId: "test",
recordId: data.id
},
- success: (data) => {
- }
+ success: (data) => {}
})
},
// 时分秒转换为秒
@@ -342,10 +345,37 @@
if (typeof token.token != "string") {
return
} else {}
+
+ // 中途杀死进程退出小程序后重新进入需要重新提交
+ if (uni.getStorageSync('StayTimeDetails2-star') && uni.getStorageSync(
+ 'StayTimeDetails2-end') && uni.getStorageSync('StayTimeDetails2-watch')) {
+ this.getTimeChecks(uni.getStorageSync('StayTimeDetails2-watch'))
+ }
},
+ onHide() {},
methods: {
+ // 纪录当前停留时间details2页面
+ getTimeChecks(data) {
+ console.log('sendStayTime', data)
+ let [a, b] = [uni.getStorageSync('StayTimeDetails2-star'), uni.getStorageSync(
+ 'StayTimeDetails2-end')]
+ let time = (Number(b) - Number(a)) / 1000 / 60
+ this.$u.post('/customer/getCheckTheTime', {
+ cusId: data, //接待id
+ standingTime: time //停留时间
+ }).then(res => {
+ uni.removeStorageSync('StayTimeDetails2-star')
+ uni.removeStorageSync('StayTimeDetails2-end')
+ uni.removeStorageSync('StayTimeDetails2-watch')
+ }).catch(() => {
+ uni.removeStorageSync('StayTimeDetails2-star')
+ uni.removeStorageSync('StayTimeDetails2-end')
+ uni.removeStorageSync('StayTimeDetails2-watch')
+ })
+ },
+
// 设置底部导航栏
setTabbarItems() {
const tabbarList = [{
diff --git a/manifest.json b/manifest.json
index 374cacc..d71c108 100644
--- a/manifest.json
+++ b/manifest.json
@@ -1,5 +1,5 @@
{
- "name" : "AI销讲助手",
+ "name" : "云筑数智助手",
"appid" : "__UNI__7A1611D",
"description" : "AI销讲助手",
"versionName" : "1.1.0",
@@ -72,7 +72,7 @@
},
"quickapp" : {},
"mp-weixin" : {
- "appid" : "wx83fec12ec03d9349",
+ "appid" : "wx3c3f25187e6b6176",
"setting" : {
"urlCheck" : false,
"es6" : true,
diff --git a/pages/center/Piabodata/Userinsightinto.vue b/pages/center/Piabodata/Userinsightinto.vue
index 160aea7..81f0ab1 100644
--- a/pages/center/Piabodata/Userinsightinto.vue
+++ b/pages/center/Piabodata/Userinsightinto.vue
@@ -7,6 +7,9 @@
{{ showBeText }}
+ {{ showBeTexts }}
+
+
@@ -121,6 +124,10 @@
+
+
+
@@ -151,9 +158,22 @@
screenShow: false, // 时间筛选弹窗
showTimeText: '近一周', // 展示文字
showBeText: '全部业务', //
+ showBeTexts: '未成交', //
templateList: [], // 销讲业务
+ templateLists: [
+ {
+ templateName: '未成交',
+ id: 0,
+ },
+ {
+ templateName: '已成交',
+ id: 1
+ },
+ ], // 销讲业务
showTemplate: false, // 展示选择销讲业务弹窗
+ showTemplates: false, // 展示选择销讲业务弹窗
marketingBusiness: '', // 选择的业务id
+ deliveryStatus: 0, // 默认未成交
};
},
onPageScroll(e) {
@@ -182,6 +202,18 @@
this.showBeText = e[0].label
this.gitinit()
},
+ // 销讲业务方法
+ templateCancels() {
+ this.showTemplates = false;
+ },
+
+ // 确认选择销讲业务
+ templateConfirms(e) {
+ this.showTemplates = false;
+ this.deliveryStatus = e[0].value
+ this.showBeTexts = e[0].label
+ this.gitinit()
+ },
// 获取销讲业务
@@ -247,12 +279,9 @@
statDateEnd: this.timeobj.statDateEnd,
houseId: this.buildingID,
marketingBusiness: this.marketingBusiness,
+ deliveryStatus: this.deliveryStatus,
}
this.$u.post("/matchKeywords/findmatchdata", parames).then(data => {
- // this.numlist.push({
- // name:"有效接待",
- // num:data.total
- // })
data.list.forEach((item, index) => {
this.numlist.push({
name: item.name,
diff --git a/pages/index/consumer/index.vue b/pages/index/consumer/index.vue
index 3d31253..84dd0d5 100644
--- a/pages/index/consumer/index.vue
+++ b/pages/index/consumer/index.vue
@@ -82,6 +82,7 @@
负责顾问:{{ item.agentName || "--" }}
+ 成交状态:{{ item.deliveryStatus | deliveryStatusText }}
@@ -1278,6 +1279,21 @@
},
filters: {
+ deliveryStatusText(level) {
+ let str = '';
+ switch (Number(level)) {
+ case 0:
+ str = "未成交"
+ break;
+ case 1:
+ str = "已成交"
+ break;
+ default:
+ str = '-'
+ break;
+ }
+ return str
+ },
// 筛选等级展示文字
levelText(level) {
let str = '';
diff --git a/pages/mine/details2.vue b/pages/mine/details2.vue
index d359dd1..4a9449c 100644
--- a/pages/mine/details2.vue
+++ b/pages/mine/details2.vue
@@ -142,12 +142,7 @@
-
-
+
更换销讲业务
@@ -373,7 +368,8 @@
{{index+1}}.{{item}}
-
+
暂无数据
@@ -619,6 +615,26 @@
mode="single-column" :list="effectiveitems" @cancel="effectiveIndexCancel" @confirm="effectiveIndexConfirm">
+
+
+
+ 更换销讲业务
+
+
+
+
+ {{item.name}}
+
+
+
+
+
+ 取消
+ 确认
+
+
+
+
@@ -761,6 +777,19 @@
eventParams: '', // 触发的事件
consultant: '', // 顾问身份id字符串
+
+ templateStatus: 0, // 模板类型0 首访模板 1复访模板
+
+ showTemplateStatus: false, // 模板类型
+ templateListType: [{
+ name: '首访模板',
+ value: 0,
+ },
+ {
+ name: '复访模板',
+ value: 1
+ },
+ ],
};
},
computed: {
@@ -773,6 +802,7 @@
},
onLoad(options) {
+ uni.setStorageSync('StayTimeDetails2-star', new Date().getTime())
this.LOADING = true
this.status = options.status;
this.customerId = options.customerId;
@@ -829,8 +859,6 @@
if (this.stateisshow == 2) {
var info = this.itemobj;
}!this.isPageHide && this.init(info);
-
- this.getMarketingBusiness()
},
onHide() {
@@ -838,6 +866,9 @@
},
onUnload() {
+ uni.setStorageSync('StayTimeDetails2-end', new Date().getTime())
+ uni.setStorageSync('StayTimeDetails2-watch', this.customerId)
+ uni.$emit('sendStayTime', this.customerId)
uni.$off('DETAILS2INIT')
uni.$off('newobjStatus')
// uni.$off('consumerDetail')
@@ -848,6 +879,18 @@
},
methods: {
+ // 更换销讲业务
+ changeTemplate() {
+ this.Thetapeidisshow = false;
+ this.showTemplateStatus = true;
+ },
+
+ // 选择销讲业务模板类型
+ radioGroupChange() {
+ this.templateList = []
+ this.getMarketingBusiness()
+ this.showTemplateStatus = false;
+ },
// 客户第几次到访 -
reduce() {
if (this.visitParams.visitRecordNum == 1) {
@@ -905,13 +948,20 @@
this.effectiveindex = e[0].value
},
+
// 获取销讲业务
getMarketingBusiness() {
this.$u.get('/customer/marketingBusiness', {
houseId: this.buildingID,
status: 0,
+ templateStatus: this.templateStatus
}).then(res => {
- this.templateList = res
+ console.log(res)
+ if (res) {
+ this.templateList = res
+ this.showTemplate = true;
+ }
+ this.$forceUpdate()
})
},
@@ -1025,7 +1075,6 @@
})
this.init(this.infos);
this.gituserlist()
- this.getMarketingBusiness()
}).catch(e => {
uni.showToast({
title: e.data.message,
@@ -1111,7 +1160,7 @@
item.speaker = this.roleindexrow + 1
}
})
-
+
this.$u.post("/corpus/batchUpdateRole", {
corpusId: this.luyinList.id,
transferContent: JSON.stringify(this.dialogList),
@@ -1789,7 +1838,8 @@
translateHtmlContent: this.messagelisy,
}
this.isshow2 = false;
- this.dialogList[this.argtextindex2].onebest = this.textItself.replace(this.thewrongword, this.reswrongword)
+ this.dialogList[this.argtextindex2].onebest = this.textItself.replace(this.thewrongword,
+ this.reswrongword)
this.cancelBeast()
this.$u.post("/corpus/addCorrectWord", parames).then(data => {
this.thewrongword = "";