瀏覽代碼

Merge branch 'master' into yun

yun
corala 2 年之前
父節點
當前提交
81a9c40621
共有 5 個文件被更改,包括 96 次插入75 次删除
  1. +7
    -0
      App.vue
  2. +9
    -8
      pages/center/Piabodata/Customerportrait/Receivedetailabout.vue
  3. +12
    -36
      pages/index/customer.vue
  4. +0
    -1
      pages/mine/details2.vue
  5. +68
    -30
      pages/mine/reception/addreception.vue

+ 7
- 0
App.vue 查看文件

@@ -77,6 +77,13 @@
}
return obj
},
// 检测权限
checkAuthority(name = '') {
let menu = uni.getStorageSync('weapp_session_Menu_data')
return menu.findIndex(item => item.name == name) != -1
},
},

filters: {


+ 9
- 8
pages/center/Piabodata/Customerportrait/Receivedetailabout.vue 查看文件

@@ -42,17 +42,21 @@
v-for="(item,index) in dialog.message" :key="index" :data-speaker="item.speaker">
<view class="avatar">
<view :style="[SPEAKERSTYLE(item.speaker)]">
<!-- <image v-if="item.isShow == 0" :src="Aimg.replace(/[\r\n]/g,'')" mode="widthFix"></image> -->
<text v-if="item.isShow == 0">顾</text>
<text v-else>{{ item.speaker | toCapital }}</text>
<text>{{ item.speaker | toCapital }}</text>
</view>
</view>


<view class="contentInfo">
<view class="info">
<text class="AudioUserName" v-if="item.isShow == 0">{{ item.username }}</text>
<text class="AudioUserName" v-else>{{ item.speaker | toCapital }}</text>
<text class="AudioUserName">
<template v-if="item.username">
{{ item.username }}
</template>
<template v-else>
{{ item.speaker | toCapital }}
</template>
</text>
<text>{{conversionTiame(item.bg/1000)}}</text>
</view>
<view class="content">
@@ -535,14 +539,11 @@
},

onHide() {
this.isAudio = 0
this.info = {}
this.isPageHide = true
},

// 销毁实例
onUnload() {
this.isAudio = 0
this.info = {}
//卸载不需要的业务和获取播放状态的业务,提高页面性能
this.$zaudio.off('seek', this.ACTION);


+ 12
- 36
pages/index/customer.vue 查看文件

@@ -43,9 +43,12 @@


</view>
<!-- checkAuthority('顾问指派顾问') -->
<view class="footer-button" v-if="item.status!=0">
<view class="footer1" @click.stop="addTime(item)">接待延时</view>
<view class="footer1" @click.stop="assign(item)">重新指派</view>
<template v-if="checkAuthority('顾问指派顾问')">
<view class="footer1" @click.stop="assign(item)">重新指派</view>
</template>
<template v-if="endReception">
<view class="footer3" @click.stop="changeEnd(item.id)">结束接待</view>
</template>
@@ -55,11 +58,13 @@
<view class="centerbox-che">手机号码:<text class="shizai">{{item.phone || "--"}}</text></view>
</view>
<view class="footer-button" v-if="item.status==0">
<view class="footer3" @click.stop="assign(item)">指派顾问</view>
<template v-if="checkAuthority('顾问指派顾问')">
<view class="footer3" @click.stop="assign(item)">指派顾问</view>
</template>
</view>

</view>
<image v-if="isAdd == 0 && (dataCode!=6||(dataCode==6&&addAccount==0))" @click="addreception()" class="add"
<image v-if="dataCode!=6||(dataCode==6&&addAccount==0)" @click="addreception()" class="add"
src="/static/images/add.png" mode=""></image>
<image class="add2" @click="reshCustom()" src="https://static.quhouse.com/zhikong_xcx_img/refresh.png" mode="">
</image>
@@ -87,7 +92,6 @@
current: 0,
buildingID: '',
waitCustomList: [],
isAdd: '',
dataCode: '',
addAccount: '',
endReception: true,
@@ -109,7 +113,6 @@
this.addAccount = addAccount;
this.dataCode = dataCode;
this.init()
this.queryHaveDept()
this.updateInit()
},
methods: {
@@ -182,14 +185,6 @@
}

},
queryHaveDept() {
return new Promise((resolve, reject) => {
this.$u.get("/user/queryHaveDept?houseId=" + this.buildingID).then(res => {
this.isAdd = res;
resolve();
})
})
},
init() {
this.waitCustomList = []
let parames = {
@@ -267,29 +262,10 @@
});
return
}
if (this.waitCustomList.length == 0) {
uni.navigateTo({
url: '/pages/mine/reception/addreception'
})
return
} else {
for (var i = 0; i < this.waitCustomList.length; i++) {
if (this.waitCustomList[i].status == 1) {
uni.showLoading({
title: '当前还有未完成的客户项'
});
setTimeout(function() {
uni.hideLoading();
}, 1000);
return
} else {
uni.navigateTo({
url: '/pages/mine/reception/addreception'
})
return
}
}
}
uni.navigateTo({
url: '/pages/mine/reception/addreception'
});

} else {
uni.navigateTo({
url: '/pages/mine/reception/addreception'


+ 0
- 1
pages/mine/details2.vue 查看文件

@@ -42,7 +42,6 @@
</view>
<view class="contentInfo">
<view class="info">
<text class="AudioUserName">
<template v-if="item.username">
{{ item.username }}


+ 68
- 30
pages/mine/reception/addreception.vue 查看文件

@@ -54,33 +54,30 @@
</view>

</view>
<template v-if="shifoinfo==0 && userInfo.dataCode != 6">
<view class="Pinspeak">顾问</view>
<view class="chented" @click="clickShowhid()">
<view class="title" style="border: none;">
<view class="titletext">接待顾问</view>
<view class="titletext2"
style="font-size: 30rpx;font-weight: 400;color: #B2B2B2;line-height: 90rpx;padding-left: 10rpx;">
<!-- {{text || '请选择接待顾问'}} -->
<text v-if="text" style="color: #333333;">{{text}}</text>
<text v-else>请选择接待顾问</text>
</view>
<view class="titleimg">
<image class="titleimg1" src="../../../static/images/arrow.png" mode=""></image>
</view>

<!-- <template v-if="shifoinfo==0 && userInfo.dataCode != 6"> -->
<view class="Pinspeak">顾问</view>
<view class="chented" @click="clickShowhid()">
<view class="title" style="border: none;">
<view class="titletext">接待顾问</view>
<view class="titletext2"
style="font-size: 30rpx;font-weight: 400;color: #B2B2B2;line-height: 90rpx;padding-left: 10rpx;">
<text v-if="text" style="color: #333333;">{{text}}</text>
<text v-else>请选择接待顾问</text>
</view>
<view class="titleimg">
<image class="titleimg1" src="../../../static/images/arrow.png" mode=""></image>
</view>
</view>
</template>
</view>
<!-- </template> -->


<view class="clive" @click.stop="$noMultipleClicks(save)" :style="{background:(isBand==false?'#2671E2':'#949494')}">确定</view>
<view class="clive" @click.stop="$noMultipleClicks(save)"
:style="{background:(isBand==false?'#2671E2':'#949494')}">确定</view>

<!-- <view v-if="Showhiddenunits"> -->
<!-- <u-select v-model="show" :list="list"></u-select> -->
<u-select :mask-close-able="false" label-name="sourceName" value-name="id" v-model="Showhiddenunits"
mode="single-column" :list="list" @cancel="cancel" @confirm="confirm"></u-select>
<!-- </view> -->
<u-select :mask-close-able="false" v-model="Showhid" mode="single-column" :list="freeList" @cancel="cancel1"
@confirm="confirm1"></u-select>
<u-modal v-model="show" :mask-close-able="true" :title="'代接待提醒'" :confirm-text="confirmtext"
@@ -115,7 +112,7 @@
replaceReception: 0
},
showSourceName: '', // 展示文字
shifoinfo: 0,
shifoinfo: 0, // 高级权限 项目是否能指派顾问
freeList: [],
Showhid: false,
text: null,
@@ -127,18 +124,18 @@
saveisshow: true,
isBand: false, // 阻止二次提交
tap: true,
fdFlag:null,
fdFlag: null,
isPass: false, // 当前顾问是否正在接待
};
},
computed: {
// 用户详情
userInfo() {
return uni.getStorageSync("weapp_session_userInfo_data")
}
},
},
onShow() {
this.parames.projectId = uni.getStorageSync('buildingID').id;
console.log(this.$u)
@@ -147,6 +144,7 @@
this.getFromSource();
},
methods: {

// 获取客户来源
getFromSource() {
uni.request({
@@ -189,8 +187,18 @@
if (this.isBand) return
this.save()
},
save() {

// 校验当前登录人是否是顾问
let obj = this.freeList.find(item => {
return item.agentId == this.userInfo.accountId
}) || null
if (!obj && this.userInfo.dataCode == 6) {
this.isPass = true
} else {
this.isPass = false
}
if (this.parames.name.length == 0) {
uni.showToast({
icon: "none",
@@ -205,6 +213,15 @@
})
return;
}

// 判断条件2是否选中顾问
if (this.isPass && !this.parames.agentId) {
uni.showToast({
icon: "none",
title: "请选择顾问~"
})
return;
}
const that = this;
this.isBand = true
this.$u.post("customer/daitiReception", {
@@ -233,7 +250,7 @@
that.confirmtext = res.replacement.name + "代接待", //确认文字
that.canceltext = res.owner.name + '接待', //取消文字
that.show = true;
this.isBand = false
this.isBand = false
} else {
that.daitiReceptionobj = res;
console.log(that.daitiReceptionobj)
@@ -242,7 +259,7 @@
that.confirmtext = res.replacement.name + "代接待", //确认文字
that.canceltext = res.assign.name + '接待', //取消文字
that.show = true;
this.isBand = false
this.isBand = false
}
}
}
@@ -296,6 +313,23 @@
this.parames.howMany = num;
},
clickShowhid() {
if (this.shifoinfo != 0) {
uni.showToast({
icon: 'none',
title: '您没有指派权限~',
duration: 2000
});
return
}

if (this.userInfo.dataCode == 6 && !this.checkAuthority('顾问指派顾问')) {
uni.showToast({
icon: "none",
title: "您没有指派权限~",
duration: 2000
})
return
}
if (this.freeList.length == 0) {
uni.showToast({
icon: 'none',
@@ -355,6 +389,10 @@
item.label = item.name + "(无设备)";
}
item.value = item.agentId
if (this.userInfo.accountId == item.agentId) {
this.text = item.label
this.parames.agentId = item.agentId;
}
})
})
},


Loading…
取消
儲存