Commit 8d4291f5 authored by 刘用法's avatar 刘用法

强制添加客服

parent 631725d6
<template>
<view class="cus-wrap-component">
<image class="top-image" mode="widthFix" :src="minekefutuImage"></image>
<image class="top-image" mode="widthFix" v-if="!isPop" :src="minekefutuImage"></image>
<view class="content-view">
<view class="title-view" v-if="!isPop">
<text class="title-text">客服微信</text>
<text v-if="isMine">下载二维码添加官方客服微信</text>
<view :class="['title-view', {'is-mine': isMine}]">
<text :class="['title-text', {'is-mine': isMine}]">{{titleText[typeIndex]}}</text>
<text>{{tipText[typeIndex]}}</text>
</view>
<u-image :class="['qrcode', {'is-pop': isPop}]" :src="cusQrcode" mode="widthFix" :fade="true"
<u-image :class="['qrcode', {'is-mine': isMine}]" :src="cusQrcode" mode="widthFix" :fade="true"
duration="450">
<u-loading slot="loading"></u-loading>
<view slot="error" style="font-size: 24rpx;">加载失败</view>
</u-image>
<view v-if="isPop" class="pop-tip-view">
<text>请务必添加该微信号,后续工单相关通知均以微信消息形式通知</text>
</view>
<u-button class="settle-button" type="primary" shape="circle" @click="download" :custom-style="buttonStyle">
点击下载
<u-button class="settle-button" type="primary" :open-type="openTypes[typeIndex]" show-message-card send-message-title="点击下方客服会话添加订单助手" shape="circle" @click="download" :custom-style="buttonStyle">
{{buttonText[typeIndex]}}
</u-button>
<view class="bottom-view" v-if="isMine">
<view class="line-view"></view>
......@@ -28,9 +25,6 @@
</u-image>
</view>
</view>
<view v-else-if="isExclusive" class="tip-view">
<text>请务必添加该微信号,后续工单相关通知均以微信消息形式通知</text>
</view>
</view>
</view>
</template>
......@@ -38,7 +32,7 @@
<script>
export default {
props: {
type: { // exclusive:专属; mine:我的页面客服; pop: 弹窗客服
type: { // exclusive:专属; mine:我的页面客服; pop:弹窗;
type: String,
default: 'mine'
}
......@@ -49,7 +43,7 @@
},
computed: {
cusQrcode() {
return process.uniEnv.qn_base_url + (this.isMine ? 'erweima-rk.png' : 'erweima-bn.png')
return process.uniEnv.qn_base_url + (this.isMine ? 'erweima-rk.png' : 'dingdanzhushou.png')
},
minekefutuImage() {
return process.uniEnv.qn_base_url + this.imageName
......@@ -57,28 +51,51 @@
imageName() {
return this.isMine ? 'kefufuwu-n.png' : 'kefutuzs.png'
},
isMine() { // exclusive:专属; mine:我的页面客服; pop: 弹窗客服
isMine() { // exclusive:专属; mine:我的页面客服; pop:弹窗;
return this.type == 'mine'
},
isPop() {
return this.type == 'pop'
},
isExclusive() {
return this.type == 'exclusive'
},
isPop() {
return this.type == 'pop'
},
phoneIcon() {
return process.uniEnv.qn_base_url + 'dianhua.png'
},
buttonStyle() {
return {
width: "300rpx",
height: "80rpx",
return this.isMine ? {
'width': "300rpx",
'height': "80rpx",
"font-size": "32rpx",
"font-weight": "bold",
} : {
'width': "400rpx",
'height': "100rpx",
"font-size": "32rpx",
"font-weight": "bold",
};
},
types() {
return ['exclusive', 'pop', 'mine']
},
typeIndex() {
return this.types.indexOf(this.type)
},
phone() {
return '18124099271'
},
openTypes() {
return ['contact', 'contact', '']
},
buttonText() {
return ['追加','追加','点击下载']
},
titleText() {
return ['添加订单助手', '添加订单助手', '客服微信']
},
tipText() {
return ['在对话框输入“加入”,即可获取二维码,添加订单助手', '在对话框输入“加入”,即可获取二维码,添加订单助手', '下载二维码添加官方客服微信']
}
},
methods: {
......@@ -89,6 +106,10 @@
});
},
download() {
if (!this.isMine) {
this.$emit('click')
return
}
let self = this
uni.downloadFile({ //获得二维码的临时地址
url: self.cusQrcode,
......@@ -146,32 +167,46 @@
align-items: center;
.title-view {
text-align: center;
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
color: #999999;
font-size: 28rpx;
padding-left: 40rpx;
padding-right: 60rpx;
margin-top: 20rpx;
&.is-mine {
display: inline;
font-size: 24rpx;
color: #666666;
width: 100%;
margin-top: 10rpx;
}
.title-text {
font-weight: bold;
font-size: 32rpx;
color: #333333;
font-size: 40rpx;
margin: 0 0 30rpx 0;
&.is-mine {
font-size: 32rpx;
margin-right: 30rpx;
}
}
}
.qrcode {
width: 600rpx;
height: 440rpx;
margin-top: 30rpx;
margin-bottom: 40rpx;
&.is-mine {
margin-top: 60rpx;
margin-bottom: 60rpx;
width: 400rpx;
height: 400rpx;
&.is-pop {
width: 248rpx;
height: 248rpx;
padding: 24rpx;
border: 6rpx solid #2272FF;
border-radius: 32rpx;
margin-top: 10rpx;
margin-bottom: 40rpx;
}
}
......
......@@ -71,12 +71,6 @@
<!-- </TabBarPage> -->
</scroll-view>
</view>
<u-popup border-radius="12" v-model="visible" safe-area-inset-bottom mode="center" width="690rpx" closeable
:mask-close-able="false" close-icon-color="#FFFFFF">
<view class="order-pop-view">
<Customer type="pop" @click="handleDownload"></Customer>
</view>
</u-popup>
</TabBarPage>
</template>
......@@ -86,14 +80,12 @@
import NoOrder from "@/components/order/noOrder.vue"
const app = getApp();
import OrderCell from "@/components/order/index.vue";
import Customer from "@/components/mine/customer.vue"
export default {
components: {
OrderCell,
TabBarPage,
NoOrder,
Customer
},
data() {
return {
......@@ -116,7 +108,6 @@
waitInit: false, // 当token为空时,等待自动登录结束
triggered: false,
_freshing: false,
visible: false,
scrollTop: 0,
old: {
scrollTop: 0
......@@ -163,10 +154,6 @@
} else {
this.waitInit = true
}
// 第一次入驻成功弹出客服弹窗
if (e && e.visible) {
this.visible = e.visible
}
},
onShow() {
// 每次进入页面都刷新入驻状态
......@@ -403,9 +390,6 @@
url: "/pages/mine/customer/index" + '?type=exclusive',
});
},
handleDownload() {
this.visible = false
}
},
};
</script>
......
......@@ -181,7 +181,13 @@
</view>
</view>
<take-photo type="test" v-if="takeStatus" @close="closeTake" :upload="false" :num="1"></take-photo>
<PopView title="查看交互规范" message="为完善交付质量,请查看对应的交付规范" :visible.sync="visibale" @click="handleClick"/>
<!-- <PopView title="查看交互规范" message="为完善交付质量,请查看对应的交付规范" :visible.sync="visible" @click="handleClick"/> -->
<u-popup border-radius="12" v-model="visible" safe-area-inset-bottom mode="center" width="690rpx"
:mask-close-able="false" close-icon-color="#FFFFFF">
<view class="order-pop-view">
<Customer type="pop" @click="handleDownload"></Customer>
</view>
</u-popup>
</template>
</view>
</template>
......@@ -189,14 +195,17 @@
<script>
import appointTime from '@/components/appoint/appoint-time.vue'
import takePhoto from '@/components/take/index.vue'
import PopView from "@/components/popView/index.vue"
// import PopView from "@/components/popView/index.vue"
import baseFile from '@/components/upload/index'
import Customer from "@/components/mine/customer.vue"
let now = new Date(new Date().toLocaleDateString()).getTime();
export default {
components: {
appointTime,
'take-photo': takePhoto,
PopView
// PopView,
Customer
},
mixins: [baseFile],
data() {
......@@ -232,7 +241,7 @@
// backgroundSize: 'cover',
// 渐变色
},
visibale: false,
visible: false,
orderId: null,
order: {},
allowRejection: false, // 允许拒单
......@@ -440,7 +449,7 @@
this.btnClass='timeOut-btn'
}
if(self.order.isFirstOrder){
this.visibale = true
this.visible = true
}
// 格式化时间
this.settlementInfo.formatTime = this.order.settleCenterSyncDatetime ? this.$u.timeFormat(this.order.settleCenterSyncDatetime, 'yyyy.mm.dd hh:MM:ss') : '-'
......@@ -845,12 +854,16 @@
this.$refs['uCountDown'].seconds += 2
}
},
handleClick(){
this.visibale = false
// 交互规范
uni.switchTab({
url: 'pages/index/learn'
})
// handleClick(){
// this.visible = false
// // 交互规范
// uni.switchTab({
// url: 'pages/index/learn'
// })
// },
handleDownload() {
this.visible = false
// 添加客服
},
threeDays() {
return this.timestampDiff(this.order.currentOverTime) > 3600 * 24 * 3
......
......@@ -90,7 +90,7 @@
statusName: '已支付保证金',
txtArr: ['您已成功缴纳配件押金', " 成功缴纳配件押金后即前往接单"],
btnTxt: '去首页',
url: '/pages/index/index?visible=1'
url: '/pages/index/index'
}],
// 入驻状态:0=>'待提交',1=>'待审核',2=>'已通过',3=>'备选',4=>'已驳回',5=>'已签约',6=>'未支付保证金',7=>'已支付保证金',8=>'已通过考试',9=>'待提交'
status: '',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment