Commit bce76ad6 by 前端

弹框

1 parent 4e311bde
import http from "../request/http"; import http from "../request/http";
module.exports = { module.exports = {
search (data) { search(data) {
return http.post({ return http.post({
method: "scrm.api.carlife.weapp.homeSearch.search", method: "scrm.api.carlife.weapp.homeSearch.search",
pageSize: 10, pageSize: 10,
...@@ -9,14 +9,14 @@ module.exports = { ...@@ -9,14 +9,14 @@ module.exports = {
}); });
}, },
// 查询接待素材 // 查询接待素材
findSoureList () { findSoureList() {
return http.post({ return http.post({
method: "dj.api.smartcarlife.recepiton.soure.findSoureList", method: "dj.api.smartcarlife.recepiton.soure.findSoureList",
projectName: "boutique", projectName: "boutique",
}); });
}, },
// 查询门店支付配置 // 查询门店支付配置
findPayInfo (data) { findPayInfo(data) {
return http.post({ return http.post({
method: method:
"dj.api.smartcarlife.recepiton.pay.findPayInfoConfigListByMerchantId", "dj.api.smartcarlife.recepiton.pay.findPayInfoConfigListByMerchantId",
...@@ -25,14 +25,14 @@ module.exports = { ...@@ -25,14 +25,14 @@ module.exports = {
}); });
}, },
// 查询门店支付配置 // 查询门店支付配置
saveRecCustomer (data) { saveRecCustomer(data) {
return http.post({ return http.post({
method: "dj.api.smartcarlife.recepiton.customer.saveRecCustomer", method: "dj.api.smartcarlife.recepiton.customer.saveRecCustomer",
projectName: "boutique", projectName: "boutique",
...data, ...data,
}); });
}, },
getToken (data) { getToken(data) {
return http.post( return http.post(
{ {
method: "dj.api.smartcarlife.recepiton.customer.oss.getToken", method: "dj.api.smartcarlife.recepiton.customer.oss.getToken",
...@@ -43,40 +43,44 @@ module.exports = { ...@@ -43,40 +43,44 @@ module.exports = {
); );
}, },
/** 查询接待素材详情 */ /** 查询接待素材详情 */
getFindSoureDetail (data) { getFindSoureDetail(data) {
return http.post({ return http.post({
method: 'dj.api.smartcarlife.recepiton.soure.findSoureDetailList', method: "dj.api.smartcarlife.recepiton.soure.findSoureDetailList",
projectName: 'boutique', projectName: "boutique",
...data ...data,
}); });
}, },
// 历史订单列表 // 历史订单列表
getQuotationList (data) { getQuotationList(data) {
return http.post({ return http.post({
method: 'dj.api.smartcarlife.vehicle.damage.upgrade.quotation.page', method: "dj.api.smartcarlife.vehicle.damage.upgrade.quotation.page",
projectName: 'boutique', projectName: "boutique",
...data ...data,
}) });
}, },
/** /**
* 车型 * 车型
* *
*/ */
getCarBrandsList (data) { getCarBrandsList(data) {
return http.post({ return http.post(
method: 'scrm.api.carlife.common.getCarSeriesList', {
...data method: "scrm.api.carlife.common.getCarSeriesList",
}, false, 'scrm') ...data,
},
false,
"scrm"
);
}, },
/** /**
* 推荐人 * 推荐人
*/ */
getEmployeeList (data) { getEmployeeList(data) {
return http.post({ return http.post({
method: 'dj.api.smartcarlife.employee.getByMerchantId', method: "dj.api.smartcarlife.employee.getByMerchantId",
projectName: 'boutique', projectName: "boutique",
sceneList:[0], sceneList: [0],
...data ...data,
}) });
}, },
}; };
...@@ -71,12 +71,13 @@ export default { ...@@ -71,12 +71,13 @@ export default {
default: "取消", default: "取消",
}, },
}, },
mounted() {
this.$refs.tips.open();
},
methods: { methods: {
close() { close() {
this.$refs.tips.close(); this.$refs.tips.close();
this.$emit("close");
},
open() {
this.$refs.tips.open();
}, },
cancel() { cancel() {
this.$refs.tips.close(); this.$refs.tips.close();
......
...@@ -108,7 +108,7 @@ const pathEnum = { ...@@ -108,7 +108,7 @@ const pathEnum = {
drac: "/rop-scrm-entmicro/", drac: "/rop-scrm-entmicro/",
busassistant: "/rop-scrm-busassistant/", busassistant: "/rop-scrm-busassistant/",
boutique: "/rop-dj-car-boutique/", boutique: "/rop-dj-car-boutique/",
merchants:'/rop-merchants/' merchants: "/rop-merchants/",
}; };
const CONFIG_ENV_MAP = { const CONFIG_ENV_MAP = {
1: "develop", 1: "develop",
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: 前端 qianduan01@didihu.com.cn * @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2024-04-08 11:28:48 * @Date: 2024-04-08 11:28:48
* @LastEditors: 前端 qianduan01@didihu.com.cn * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-04-09 20:49:12 * @LastEditTime: 2024-04-10 09:34:49
* @FilePath: \gl_tape\mixin\click.js * @FilePath: \gl_tape\mixin\click.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
...@@ -12,7 +12,6 @@ import { mapMutations, mapState } from "vuex"; ...@@ -12,7 +12,6 @@ import { mapMutations, mapState } from "vuex";
export default { export default {
data() { data() {
return { return {
tipVisible: false,
voicePath: "", voicePath: "",
timer: null, timer: null,
times: 0, times: 0,
...@@ -45,12 +44,12 @@ export default { ...@@ -45,12 +44,12 @@ export default {
//关闭提示 //关闭提示
tipCancel() { tipCancel() {
this.times = 0; this.times = 0;
this.tipVisible = false; this.$refs.tipBox.close();
}, },
//结束提示 //结束提示
tipConfirm() { tipConfirm() {
this.times = 0; this.times = 0;
this.tipVisible = false; this.$refs.tipBox.close();
}, },
//检查缓存录音 //检查缓存录音
checkVoice() { checkVoice() {
...@@ -123,12 +122,12 @@ export default { ...@@ -123,12 +122,12 @@ export default {
this.timer = setInterval(() => { this.timer = setInterval(() => {
this.times++; this.times++;
if (this.times >= this.timeout) { if (this.times >= this.timeout) {
this.tipVisible = true; this.$refs.tipBox.open();
} }
if (this.times >= this.reaction + this.timeout) { if (this.times >= this.reaction + this.timeout) {
//结束接待 //结束接待
this.stopAudio(); this.stopAudio();
this.tipVisible = false; this.$refs.tipBox.close();
} }
}, 1000); }, 1000);
}, },
......
...@@ -2,82 +2,53 @@ ...@@ -2,82 +2,53 @@
* @Description: * @Description:
* @Author: huyue * @Author: huyue
* @Date: 2024-04-08 11:30:30 * @Date: 2024-04-08 11:30:30
* @LastEditors: huyue * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-04-09 20:54:28 * @LastEditTime: 2024-04-10 09:33:01
--> -->
<template> <template>
<view <view class="detail-box" @click="handleTouchStart()">
class="detail-box"
@click="handleTouchStart()"
>
<view class="nav-bar"> <view class="nav-bar">
<view <view class="back" @click="back">
class="back" <uni-icons type="left" :size="32"></uni-icons>
@click="back"
>
<uni-icons
type="left"
:size="32"
></uni-icons>
</view> </view>
</view> </view>
<tool-box <tool-box :type="type" @choose="choose" @finish="open" />
:type="type"
@choose="choose"
@finish="open"
/>
<view :class="['view', { showView: id == 1 }]"> <view :class="['view', { showView: id == 1 }]">
<media_1 <media_1 :views="media[1]" :penSwitch="type != 'preview' && drawStatus" />
:views="media[1]"
:penSwitch="type != 'preview' && drawStatus"
/>
</view> </view>
<view :class="['view', { showView: id == 2 }]"> <view :class="['view', { showView: id == 2 }]">
<media_2 <media_2 :views="media[2]" :penSwitch="type != 'preview' && drawStatus" />
:views="media[2]"
:penSwitch="type != 'preview' && drawStatus"
/>
</view> </view>
<view :class="['view', { showView: id == 3 }]" > <view :class="['view', { showView: id == 3 }]">
<media_3 <media_3 :views="media[3]" :penSwitch="type != 'preview' && drawStatus" />
:views="media[3]"
:penSwitch="type != 'preview' && drawStatus"
/>
</view> </view>
<view :class="['view', { showView: id == 4 }]" > <view :class="['view', { showView: id == 4 }]">
<media_4 <media_4 :views="media[4]" :penSwitch="type != 'preview' && drawStatus" />
:views="media[4]"
:penSwitch="type != 'preview' && drawStatus"
/>
</view> </view>
<view :class="['view', { showView: id == 5 }]" > <view :class="['view', { showView: id == 5 }]">
<media_5 <media_5 :views="media[5]" :penSwitch="type != 'preview' && drawStatus" />
:views="media[5]"
:penSwitch="type != 'preview' && drawStatus"
/>
</view> </view>
<view :class="['view', { showView: id == 6 }]"> <view :class="['view', { showView: id == 6 }]">
<media_6 ref="history" :views="media[id]" /> <media_6 ref="history" :views="media[id]" />
</view> </view>
<pay-pop ref="pay"></pay-pop> <pay-pop ref="pay"></pay-pop>
<template v-if="type != 'preview'"> <template v-if="type != 'preview'">
<view <view class="pen-box" @click="drawStatus = !drawStatus">
class="pen-box" <glsx-image
@click="drawStatus = !drawStatus" :src="!drawStatus ? 'media/pen.png' : 'media/pen-active.png'"
> />
<glsx-image :src="!drawStatus?'media/pen.png':'media/pen-active.png'" />
</view> </view>
</template> </template>
<MessageBox <MessageBox
v-if="finishVisible" v-if="finishVisible"
@cancel="finishVisible = false" @cancel="finishVisible = false"
@confirm="done" @confirm="done"
content="是否返回首页并结束本次接待" content="是否返回首页并结束本次接待"
confirmBtnText="确认" confirmBtnText="确认"
></MessageBox> ></MessageBox>
<MessageBox <MessageBox
v-if="tipVisible" ref="tipBox"
@cancel="tipCancel" @cancel="tipCancel"
@confirm="tipConfirm" @confirm="tipConfirm"
content="系统检测到您在当前页面停留较久,是否仍在客户接待中?" content="系统检测到您在当前页面停留较久,是否仍在客户接待中?"
...@@ -85,9 +56,11 @@ ...@@ -85,9 +56,11 @@
confirmBtnText="是" confirmBtnText="是"
></MessageBox> ></MessageBox>
<MessageBox <MessageBox
ref="payRef"
v-if="messageBoxVisible" v-if="messageBoxVisible"
@cancel="done" @cancel="done"
@confirm="toPay" @confirm="toPay"
@close="close"
content="若客户成交,请点击付款方式协助客户完成后续流程。" content="若客户成交,请点击付款方式协助客户完成后续流程。"
confirmBtnText="选择付款方式" confirmBtnText="选择付款方式"
cancelBtnText="完成接待" cancelBtnText="完成接待"
...@@ -98,72 +71,86 @@ ...@@ -98,72 +71,86 @@
import payPop from "./components/payPop.vue"; import payPop from "./components/payPop.vue";
import ToolBox from "./components/ToolBox.vue"; import ToolBox from "./components/ToolBox.vue";
import myClick from "@/mixin/click"; import myClick from "@/mixin/click";
import Media_1 from './components/Media_1.vue' import Media_1 from "./components/Media_1.vue";
import Media_2 from './components/Media_2.vue' import Media_2 from "./components/Media_2.vue";
import Media_3 from './components/Media_3.vue' import Media_3 from "./components/Media_3.vue";
import Media_4 from './components/Media_4.vue' import Media_4 from "./components/Media_4.vue";
import Media_5 from './components/Media_5.vue' import Media_5 from "./components/Media_5.vue";
import Media_6 from './components/Media_6.vue' import Media_6 from "./components/Media_6.vue";
export default { export default {
components: { ToolBox, payPop, Media_1, Media_2, Media_3, Media_4, Media_5, Media_6 }, components: {
ToolBox,
payPop,
Media_1,
Media_2,
Media_3,
Media_4,
Media_5,
Media_6,
},
mixins: [myClick], mixins: [myClick],
data () { data() {
return { return {
type: "preview", type: "preview",
id: '', id: "",
media: { media: {
1:[], 1: [],
2:[], 2: [],
3:[], 3: [],
4:[], 4: [],
5:[], 5: [],
}, },
drawStatus: false, drawStatus: false,
messageBoxVisible: false, messageBoxVisible: false,
finishVisible: false, finishVisible: false,
}; };
}, },
onLoad (options) { onLoad(options) {
console.log(options) console.log(options);
this.type = options.type; this.type = options.type;
this.id = options.id; this.id = options.id;
this.getFindSoureDetail(options.id); this.getFindSoureDetail(options.id);
}, },
async onReachBottom() { async onReachBottom() {
this.$refs.history.getQuotationList() this.$refs.history.getQuotationList();
}, },
methods: { methods: {
open () { open() {
// this.$refs.pay.show() // this.$refs.payRef.open();
this.messageBoxVisible = true; this.messageBoxVisible = true;
}, },
close() {
this.messageBoxVisible = false;
},
/**切换素材 */ /**切换素材 */
choose (e) { choose(e) {
this.id = e.id; this.id = e.id;
this.getFindSoureDetail(e.id); this.getFindSoureDetail(e.id);
}, },
async getFindSoureDetail (id) { async getFindSoureDetail(id) {
try { try {
if (!this.media[id].length) this.media[id] = (await uni.$api.commonApi.getFindSoureDetail({ id })) || []; if (!this.media[id].length)
this.media[id] =
(await uni.$api.commonApi.getFindSoureDetail({ id })) || [];
} catch (error) { } catch (error) {
console.log(error) console.log(error);
} }
}, },
// 完成接待 // 完成接待
done () { done() {
this.$store.dispatch('clearCustomerInfo') this.$store.dispatch("clearCustomerInfo");
this.stopAudio(); this.stopAudio();
uni.navigateBack(); uni.navigateBack();
}, },
// 选择付款方式 // 选择付款方式
toPay () { toPay() {
this.$refs.pay.show(); this.$refs.pay.show();
}, },
back () { back() {
if (this.type != 'preview') return this.finishVisible = true if (this.type != "preview") return (this.finishVisible = true);
this.$store.dispatch('clearCustomerInfo') this.$store.dispatch("clearCustomerInfo");
uni.navigateBack() uni.navigateBack();
} },
}, },
}; };
</script> </script>
......
...@@ -69,7 +69,7 @@ ...@@ -69,7 +69,7 @@
confirmBtnText="预览素材" confirmBtnText="预览素材"
></MessageBox> ></MessageBox>
<MessageBox <MessageBox
v-if="tipVisible" ref="tipBox"
@cancel="tipCancel" @cancel="tipCancel"
@confirm="tipConfirm" @confirm="tipConfirm"
content="系统检测到您在当前页面停留较久,是否仍在客户接待中?" content="系统检测到您在当前页面停留较久,是否仍在客户接待中?"
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @Author: huyue * @Author: huyue
* @Date: 2024-04-07 14:54:28 * @Date: 2024-04-07 14:54:28
* @LastEditors: 前端 qianduan01@didihu.com.cn * @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-04-09 20:46:24 * @LastEditTime: 2024-04-10 09:32:49
--> -->
<template> <template>
<view class="information-entry"> <view class="information-entry">
...@@ -87,7 +87,7 @@ ...@@ -87,7 +87,7 @@
</view> </view>
</MessageBox> </MessageBox>
<MessageBox <MessageBox
v-if="tipVisible" ref="tipBox"
@cancel="tipCancel" @cancel="tipCancel"
@confirm="tipConfirm" @confirm="tipConfirm"
content="系统检测到您在当前页面停留较久,是否仍在客户接待中?" content="系统检测到您在当前页面停留较久,是否仍在客户接待中?"
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!