Commit bce76ad6 by 前端

弹框

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