Commit fbb978e1 by liaoym

Merge branch 'SAAS+V5.5.0' of http://192.168.3.233:8090/glsx/gl_tape into SAAS+V5.5.0

# Conflicts:
#	components/HomeFrame/index.vue
2 parents fcdbebe1 f10973ab
Showing 88 changed files with 3967 additions and 235 deletions
import http from '../request/http'
module.exports = {
/**活动列表 */
activityPage(data) {
return http.post({
method: 'risk.manage.api.activity.pad.page',
projectName: 'pad',
...data
})
},
/**荣誉墙 */
activityReward(data) {
return http.post({
method: 'risk.manage.api.activity.reward',
projectName: 'pad',
...data
})
}
}
...@@ -441,5 +441,21 @@ module.exports = { ...@@ -441,5 +441,21 @@ module.exports = {
projectName: 'pad', projectName: 'pad',
...data ...data
}) })
} },
// 活动消息列表
getActivityMessageList(data) {
return http.post({
method: 'dj.pad.api.page.activity.message.list',
projectName: 'pad',
...data
})
},
// 更新活动消息状态
updateActivityMessageStatus(data) {
return http.post({
method: 'dj.pad.api.activity.message.update',
projectName: 'pad',
...data
})
},
} }
...@@ -3,6 +3,7 @@ import systemApi from './systemApi' ...@@ -3,6 +3,7 @@ import systemApi from './systemApi'
import userApi from './userApi' import userApi from './userApi'
import boutiqueApi from './boutique' import boutiqueApi from './boutique'
import evaluationApi from './evaluation' import evaluationApi from './evaluation'
import activityApi from './activity'
import customerApi from './customerApi' import customerApi from './customerApi'
import pointApi from './point' import pointApi from './point'
import receptionApi from './receptionApi' import receptionApi from './receptionApi'
...@@ -23,5 +24,6 @@ module.exports = { ...@@ -23,5 +24,6 @@ module.exports = {
interceptionApi, interceptionApi,
popupApi, popupApi,
evaluationApi, evaluationApi,
usedCarApi usedCarApi,
activityApi
} }
...@@ -31,4 +31,42 @@ module.exports = { ...@@ -31,4 +31,42 @@ module.exports = {
...data ...data
}) })
}, },
/**
* 交付单列表
*/
getDeliveryOrderPageList (data) {
return gscPost('/deliveryOrderManage/getDeliveryOrderPageList', data ,{
returnAll: true
})
},
/**
* 交付单列表按照支付状态统计数量
*/
getDeliveryOrderListCount (data) {
return gscPost('/deliveryOrderManage/getDeliveryOrderListCount', data)
},
/**
* 交付单详情
*/
getDeliveryOrderDetail (data) {
return gscPost('/deliveryOrderManage/getDeliveryOrderDetail', data)
},
/**
* 交付单操作日志
*/
getDeliveryOrderOpLog (data) {
return gscPost('/deliveryOrderManage/getDeliveryOrderOpLog', data)
},
/**
* 客户确认到店
*/
confirmArrive (data) {
return gscPost('/deliveryOrderManage/confirmArrive', data, { returnAll: true })
},
/**
* 客户确认提车
*/
confirmDelivery (data) {
return gscPost('/deliveryOrderManage/confirmDelivery', data, { returnAll: true })
},
} }
...@@ -158,6 +158,9 @@ ...@@ -158,6 +158,9 @@
.mt-20 { .mt-20 {
margin-top: toRpx(20); margin-top: toRpx(20);
} }
.mb-6 {
margin-bottom: toRpx(6);
}
.mb-12 { .mb-12 {
margin-bottom: toRpx(12); margin-bottom: toRpx(12);
} }
......

2.79 MB | W: | H:

2.91 MB | W: | H:

assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
  • 2-up
  • Swipe
  • Onion skin
...@@ -206,6 +206,13 @@ export default { ...@@ -206,6 +206,13 @@ export default {
oneCarBrand: selectItem.carBrand, oneCarBrand: selectItem.carBrand,
oneCarBrandId: selectItem.carBrandId oneCarBrandId: selectItem.carBrandId
}) })
uni.$logger.local.info(`选择车:
carModel:${item.name},
carModelId: ${item.id},
carBrand:${customerInfo.carBrand},
carBrandId:${customerInfo.carBrandId},
oneCarBrand:${customerInfo.oneCarBrand},
oneCarBrandId:${customerInfo.oneCarBrandId}`)
if (linkage) { if (linkage) {
this.$store.dispatch('setCustomerInfo', customerInfo) this.$store.dispatch('setCustomerInfo', customerInfo)
this.$store.dispatch('updateViewKey') this.$store.dispatch('updateViewKey')
......
...@@ -42,37 +42,48 @@ export default { ...@@ -42,37 +42,48 @@ export default {
{ {
icon: 'daily-report', icon: 'daily-report',
label: '驻店日报', label: '驻店日报',
name: 'DailyReport' name: 'DailyReport',
sceneType: [0, 1, 7]
}, },
{ {
icon: 'create-order', icon: 'create-order',
label: '新建工单', label: '新建工单',
name: 'CreateOrder' name: 'CreateOrder',
sceneType: [0, 1]
},
{
icon: 'equity-order',
label: '权益提单',
name: 'EquityOrder',
sceneType: [0]
}, },
{ {
icon: 'defeat-order', icon: 'defeat-order',
label: '战败下单', label: '战败下单',
name: 'DefeatOrder' name: 'DefeatOrder',
sceneType: [0, 1]
}, },
{ {
icon: 'order-management', icon: 'order-management',
label: '工单列表', label: '工单列表',
name: 'OrderManagement' name: 'OrderManagement',
sceneType: [0, 1]
}, },
{ {
icon: 'evaluation-management', icon: 'evaluation-management',
label: '评估单管理', label: '评估单管理',
name: 'EvaluationFormList' name: 'EvaluationFormList',
sceneType: [7]
},
{
icon: 'delivery-management',
label: '交付管理',
name: 'DeliveryManagement',
page: '/pages/usedCar/deliveryManagement/index',
sceneType: [7]
} }
] ]
if (sceneType == 0) return [] return entranceList.filter(e => e.sceneType.includes(sceneType))
else if (sceneType === 7) {
return entranceList.filter(e => ['DailyReport', 'EvaluationFormList'].includes(e.name));
}
if (sceneType === 1) {
return entranceList.filter(e => e.name !== 'EvaluationFormList');
}
} }
}, },
methods: { methods: {
......
<template>
<view class="card" @click="handleAvtivityItemClick()">
<view v-if="tabIndex === 1" class="time-limit-countdown">
<template v-if="countdownObj._timeout">
<view class="countdown-label timeout-label">活动开始</view>
</template>
<template v-else-if="countdownObj._remainSeconds < 3600">
<!-- 小于1小时,显示分钟/秒 -->
<view class="countdown-label">即将开始</view>
<view class="countdown-num">{{ countdownObj._countdownMinute }}</view>
<view class="countdown-label">分</view>
<view class="countdown-num">{{ countdownObj._countdownSecond }}</view>
<view class="countdown-label">秒</view>
</template>
<template v-else-if="countdownObj._remainSeconds < 86400">
<!-- 小于24小时,显示小时/分钟 -->
<view class="countdown-label">即将开始</view>
<view class="countdown-num">{{ countdownObj._countdownHour }}</view>
<view class="countdown-label">时</view>
<view class="countdown-num">{{ countdownObj._countdownMinute }}</view>
<view class="countdown-label">分</view>
</template>
<template v-else-if="countdownObj._showDays">
<!-- 大于24小时,显示天/小时 -->
<view class="countdown-label">即将开始</view>
<view class="countdown-num">{{ countdownObj._leftDays }}</view>
<view class="countdown-separator">天</view>
<view class="countdown-num">{{ countdownObj._leftHours }}</view>
<view class="countdown-separator">时</view>
</template>
<template v-else>
<view class="countdown-label">即将开始</view>
<view class="countdown-num">--</view>
<view class="countdown-separator">:</view>
<view class="countdown-num">--</view>
<view class="countdown-separator">:</view>
<view class="countdown-num">--</view>
</template>
</view>
<image class="card-item-img" :src="item.activityCover" mode="aspectFit" />
<view class="card-item-content">
<view class="card-item-title">{{ item.name }}</view>
<view class="card-item-text" v-if="tabIndex !== 1">
<view class="card-item-label">活动进度</view>
<view class="card-item-progress" v-if="tabIndex !== 2">
<view class="card-item-progress-bar" :style="{ width: Math.floor(Number(item.process) || 0) + '%' }"></view>
<view class="card-item-progress-text">{{ Math.floor(Number(item.process) || 0) }}%</view>
</view>
<view class="card-item-value" v-else>
<view class="gray">已结束</view>
</view>
</view>
<view class="card-item-text">
<view class="card-item-label">活动时间</view>
<view class="card-item-value">{{ dayjs(item.startTime).format('YYYY.MM.DD HH:mm') }} - {{ dayjs(item.endTime).format('YYYY.MM.DD HH:mm') }}</view>
</view>
<view class="card-item-text" @click.stop="rulesShow(item)">
<view class="card-item-label">评选规则</view>
<view class="card-item-value blueValue">查看</view>
</view>
<!-- <view class="card-item-status">{{ item.status }}</view> -->
</view>
</view>
</template>
<script>
import dayjs from 'dayjs'
export default {
name: 'ActivityCard',
props: {
item: {
type: Object,
default: () => ({})
},
tabIndex: {
type: Number,
default: 0
}
},
data() {
return {
dayjs,
isShowActivityDetails: false,
countdownTimer: null,
countdownObj: null
}
},
mounted() {
this.countdownObj = {
_timeout: false,
_showCountdown: true,
_showDays: false,
_remainSeconds: 0,
_countdownHour: '00',
_countdownMinute: '00',
_countdownSecond: '00',
_leftDays: '00',
_leftHours: '00'
}
// 初始化倒计时
if (this.tabIndex === 1 && this.item.startTime) {
this.updateCountdown()
this.countdownTimer = setInterval(() => {
this.updateCountdown()
}, 1000)
}
},
beforeDestroy() {
// 清除定时器
if (this.countdownTimer) {
clearInterval(this.countdownTimer)
}
},
methods: {
handleAvtivityItemClick() {
if (this.tabIndex !== 1) {
this.$emit('handleAvtivityItemClick')
}
},
rulesShow(item) {
this.$emit('rulesShow', item)
},
// 更新倒计时逻辑
updateCountdown() {
const now = Date.now()
const startTime = new Date(this.item.startTime).getTime()
const diff = startTime - now
// 如果活动已经开始,显示"活动开始"
if (diff <= 0) {
this.$set(this.countdownObj, '_timeout', true)
this.$set(this.countdownObj, '_showCountdown', false)
this.$set(this.countdownObj, '_showDays', false)
return
}
this.$set(this.countdownObj, '_timeout', false)
// 计算剩余秒数
const _remainSeconds = Math.floor(diff / 1000)
this.$set(this.countdownObj, '_remainSeconds', _remainSeconds)
// 根据剩余时间设置不同的显示格式
if (_remainSeconds < 3600) {
// 小于1小时,显示分钟/秒
this.$set(this.countdownObj, '_showCountdown', true)
this.$set(this.countdownObj, '_showDays', false)
this.$set(this.countdownObj, '_countdownHour', this.formatTwoDigits(Math.floor(_remainSeconds / 60)))
this.$set(this.countdownObj, '_countdownMinute', this.formatTwoDigits(Math.floor(_remainSeconds / 60)))
this.$set(this.countdownObj, '_countdownSecond', this.formatTwoDigits(Math.floor(_remainSeconds % 60)))
} else if (_remainSeconds < 86400) {
// 小于24小时,显示小时/分钟
this.$set(this.countdownObj, '_showCountdown', true)
this.$set(this.countdownObj, '_showDays', false)
this.$set(this.countdownObj, '_countdownHour', this.formatTwoDigits(Math.floor(_remainSeconds / 3600)))
this.$set(this.countdownObj, '_countdownMinute', this.formatTwoDigits(Math.floor((_remainSeconds % 3600) / 60)))
this.$set(this.countdownObj, '_countdownSecond', this.formatTwoDigits(Math.floor(_remainSeconds % 60)))
} else {
// 大于24小时,显示天/小时
this.$set(this.countdownObj, '_showCountdown', false)
this.$set(this.countdownObj, '_showDays', true)
this.$set(this.countdownObj, '_leftDays', Math.floor(_remainSeconds / 86400))
this.$set(this.countdownObj, '_leftHours', this.formatTwoDigits(Math.floor((_remainSeconds % 86400) / 3600)))
}
},
// 格式化数字为两位数
formatTwoDigits(num) {
return num < 10 ? `0${num}` : `${num}`
}
}
}
</script>
<style lang="scss" scoped>
.card {
position: relative;
width: 100%;
// height: toRpx(516);
background-color: #fff;
border-radius: toRpx(24);
font-size: 0;
box-shadow: 0 toRpx(8) toRpx(24) 0 #2a61eb1a;
overflow: hidden;
.time-limit-tag {
position: absolute;
top: 0;
left: 0;
width: toRpx(122);
height: toRpx(48);
background-image: url('../../../../assets/images/common/limit-page.png');
background-size: cover;
background-repeat: no-repeat;
background-position: center;
z-index: 1;
color: #fff;
}
.time-limit-countdown {
position: absolute;
right: toRpx(18);
top: toRpx(16);
display: flex;
align-items: center;
justify-content: center;
font-size: toRpx(24);
z-index: 1;
.countdown-num {
display: flex;
align-items: center;
justify-content: center;
color: #fff;
width: toRpx(40);
height: toRpx(40);
border-radius: toRpx(4);
background: #00000059;
margin: 0 toRpx(4);
}
.countdown-separator {
color: #0000004d;
}
.countdown-label,
.countdown-unit {
color: #00000059;
margin: 0 toRpx(4);
}
.timeout-label {
height: toRpx(40);
line-height: toRpx(44);
border-radius: toRpx(4);
background: #00000059;
color: #fff;
padding: toRpx(4) toRpx(8);
padding: 0 toRpx(12);
font-size: toRpx(24);
}
}
.card-item-img {
width: 100%;
height: toRpx(312);
border-radius: toRpx(16) toRpx(16) 0 0;
}
.card-item-content {
padding: toRpx(32);
}
.card-item-title {
font-size: toRpx(30);
color: #292d33;
font-weight: 500;
margin-bottom: toRpx(24);
width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
max-width: 100%;
}
.card-item-text {
position: relative;
display: flex;
align-items: center;
font-size: toRpx(24);
margin-bottom: toRpx(14);
&:last-child {
margin-bottom: 0;
}
.card-item-label {
width: toRpx(96);
color: #999ea8;
margin-right: toRpx(24);
}
.card-item-value {
color: #666666;
display: inline-flex;
align-items: center;
justify-content: center;
.dot-value {
width: toRpx(12);
height: toRpx(12);
border-radius: 50%;
background: #2cca74;
margin-right: toRpx(8);
}
.gray {
color: #666666;
}
}
.blueValue {
color: #4673ff;
}
}
.card-item-progress {
width: toRpx(366);
height: toRpx(16);
background: linear-gradient(128.8deg, rgba(117, 188, 255, 0.35) 0%, rgba(44, 102, 247, 0.35) 100%);
border-radius: toRpx(8);
.card-item-progress-text {
color: #3b73ff;
font-size: toRpx(24);
position: absolute;
top: 50%;
right: 0;
transform: translateY(-50%);
}
.card-item-progress-bar {
height: 100%;
background: linear-gradient(128.8deg, #75bcff 0%, #2c66f7 100%);
border-radius: toRpx(8);
}
}
}
</style>
<!--针对弹窗穿透滚动,统一封装的popup-->
<template>
<page-meta :page-style="'overflow:' + (show ? 'hidden' : 'visible')"></page-meta>
<uni-popup :class="['customPopup', popupClass, noTitle ? 'noTitle' : '', size]" ref="publishPopup" :type="type" @change="change" :safe-area="safeArea" :is-mask-click="isMaskClick" :showClose="showClose">
<!-- 顶部标题栏插槽 -->
<slot name="header">
<view class="popup-top-box flex align-center" v-if="showTitle">
<view class="popup-top-box-title flex-1">{{ title }}</view>
<view style="font-size: 0">{{ otherText }}</view>
<view @click.stop="closePopup">
<view class="sprite-icon icon-evaluationClose"></view>
</view>
</view>
</slot>
<!-- 主要内容插槽 -->
<view class="content">
<slot name="content"></slot>
</view>
<!-- 底部插槽 插槽有内容就优先自定义内容-->
<slot name="footer">
<view class="footer-box flex justify-center" v-if="isShowFooter">
<view class="cancle-btn btn" v-if="isShowCancel" @click.stop="closePopup">{{ cancelText }}</view>
<view class="sure-btn btn" :class="{ 'single-btn': isShowCancel }" @click.stop="confirm">{{ confirmText }}</view>
</view>
</slot>
</uni-popup>
</template>
<script>
import { size } from 'lodash'
export default {
name: 'GeneralPopup',
props: {
type: {
type: String,
default: 'bottom'
},
size: {
type: String,
default: 'small'
},
isMaskClick: {
type: Boolean,
default: false
},
safeArea: {
type: Boolean,
default: true
},
popupClass: {
type: String,
default: ''
},
showClose: {
type: Boolean,
default: true
},
title: {
type: String,
default: ''
},
showTitle: {
type: Boolean,
default: true
},
isShowFooter: {
type: Boolean,
default: true
},
cancelText: {
type: String,
default: '取消'
},
confirmText: {
type: String,
default: '确定'
},
isShowCancel: {
type: Boolean,
default: true
},
autoClose: {
type: Boolean,
default: true
},
noTitle: {
type: Boolean,
default: false
},
otherText: {
type: String,
default: ''
}
},
data() {
return {
show: false
}
},
methods: {
open() {
this.$refs.publishPopup.open()
},
change(e) {
this.show = e.show
},
closePopup() {
this.$refs.publishPopup.close()
this.$emit('close')
},
confirm() {
if (this.autoClose) {
this.$refs.publishPopup.close()
}
this.$emit('confirm')
}
}
}
</script>
<style scoped lang="scss">
.justify-between {
-webkit-box-pack: justify;
-ms-flex-pack: justify;
-webkit-justify-content: space-between;
justify-content: space-between;
}
.align-center {
align-items: center;
}
.uniui-closeempty {
color: #1a1a1a;
font-size: toRpx(24);
font-weight: 600;
}
.single-btn {
width: 100%;
}
.popup-top-box {
padding: 0 toRpx(48);
height: toRpx(112);
width: 100%;
background-color: transparent;
color: #333333;
font-size: toRpx(36);
.popup-top-box-title {
text-align: center;
}
.icon-close {
text-align: end;
}
}
.btn {
width: toRpx(720);
height: toRpx(76);
border-radius: toRpx(48);
opacity: 1;
line-height: toRpx(80);
text-align: center;
color: rgba(26, 26, 26, 0.6);
font-size: toRpx(32);
font-weight: 500;
}
.cancle-btn {
background: #f0f1f5;
margin-right: toRpx(38);
}
.sure-btn {
color: #fff;
background: linear-gradient(0deg, #2c66f7 0%, #48a6ff 100%);
}
::v-deep .customPopup.center.small {
// width: toRpx(690);
}
::v-deep .customPopup.center.medium .uni-popup__wrapper {
width: 60vw;
max-height: 80vh;
min-height: 68vh;
border-radius: toRpx(32);
background: linear-gradient(180deg, #e6f0ff 0%, #ffffff 100%);
overflow: hidden;
}
::v-deep .customPopup.center.large {
// width: toRpx(990);
}
</style>
<template> <template>
<view class="left-side"> <view class="left-side">
<view class="user-box"> <view class="user-box">
<view <view class="user-info flex" @click="jumpPersonCenter">
class="user-info flex"
@click="jumpPersonCenter"
>
<view :class="['user-avatar', 'sprite-icon', 'icon-avatar', tabIndex == 99 ? 'user-active' : '']"></view> <view :class="['user-avatar', 'sprite-icon', 'icon-avatar', tabIndex == 99 ? 'user-active' : '']"></view>
<view class="user-name"> <view class="user-name">
<view class="user-name-text">{{ userInfo.name }}</view> <view class="user-name-text">{{ userInfo.name }}</view>
<view <view v-if="hasPerson" class="sprite-icon icon-arrow-next"></view>
v-if="hasPerson"
class="sprite-icon icon-arrow-next"
></view>
</view> </view>
</view> </view>
</view> </view>
<view :class="['left-tabs', { three: tabs.length == 3 }]"> <view :class="['left-tabs', { three: tabs.length == 3 }]">
<template v-for="(i, index) in tabs"> <template v-for="(i, index) in tabs">
<view <view :class="['tab-item', { tabActive: tabIndex == index }]" :key="index" @click="changeIndex(index, i)" v-if="!i.hidden">
:class="['tab-item', { tabActive: tabIndex == index }]"
:key="index"
@click="changeIndex(index, i)"
v-if="!i.hidden"
>
<view class="icon-box"> <view class="icon-box">
<view :class="['sprite-icon', `icon-${i.icon}${tabIndex == index ? '-active' : ''}`]"></view> <view :class="['sprite-icon', `icon-${i.icon}${tabIndex == index ? '-active' : ''}`]"></view>
</view> </view>
{{ i.label }} {{ i.label }}
<view <view class="dot" v-if="i.icon == 'record' && perRecordNumber"></view>
class="dot" <view class="tip-box" v-if="i.icon == 'study' && readCount">待办事项:{{ readCount }}</view>
v-if="i.icon == 'record' && perRecordNumber"
></view>
<view
class="tip-box"
v-if="i.icon == 'study' && readCount"
>待办事项:{{ readCount }}</view>
</view> </view>
</template> </template>
</view> </view>
...@@ -49,40 +32,19 @@ ...@@ -49,40 +32,19 @@
v-if="messageTotal > 0" v-if="messageTotal > 0"
></view> ></view>
</view> --> </view> -->
<view <view class="btn" @click="openScenePopup">
class="btn"
@click="openScenePopup"
>
<view class="sprite-icon icon-scene-change"></view> <view class="sprite-icon icon-scene-change"></view>
</view> </view>
<view <view class="btn" @click="handleSetting">
class="btn"
@click="handleSetting"
>
<view class="sprite-icon icon-setting"></view> <view class="sprite-icon icon-setting"></view>
</view> </view>
</view> </view>
<!-- 客服弹框 --> <!-- 客服弹框 -->
<!-- <kf-box ref="kfRef" /> --> <!-- <kf-box ref="kfRef" /> -->
<message-pop <message-pop ref="kfRef" :type="messageType" :messageData="messageData"></message-pop>
ref="kfRef"
:type="messageType"
:messageData="messageData"
></message-pop>
<!-- 设置弹框 --> <!-- 设置弹框 -->
<setting-box <setting-box ref="settingRef" @stopAudio="$emit('stopAudio')" />
ref="settingRef" <center-popup :list="sceneTypeList" ref="sceneTypeRef" @choose="chooseSceneType" title="选择场景" tag="当前场景" :id="userInfo.sceneType" isLine />
@stopAudio="$emit('stopAudio')"
/>
<center-popup
:list="sceneTypeList"
ref="sceneTypeRef"
@choose="chooseSceneType"
title="选择场景"
tag="当前场景"
:id="userInfo.sceneType"
isLine
/>
</view> </view>
</template> </template>
...@@ -114,10 +76,12 @@ export default { ...@@ -114,10 +76,12 @@ export default {
hasPerson: false, hasPerson: false,
messageType: 'study', messageType: 'study',
sopCount: 0, sopCount: 0,
activityTabVisible: true
} }
}, },
watch: { watch: {
userInfo (n) { userInfo (n) {
console.log('userInfo', n)
if (n.shopMerchantId) this.haveCustomerAccess(n) if (n.shopMerchantId) this.haveCustomerAccess(n)
}, },
...@@ -191,26 +155,43 @@ export default { ...@@ -191,26 +155,43 @@ export default {
label: "场景集市", label: "场景集市",
icon: "scene", icon: "scene",
name: 'SceneMarket', name: 'SceneMarket',
eventCode: 'app_scene_market', eventCode: 'app_scene_market'
hidden: false },
{
label: "活动中心",
icon: "activity",
isTrack: true,
name: 'ActivityCenter',
eventCode: 'app_activeity_center',
hidden: !this.activityTabVisible
} }
] ]
let { sceneType } = uni.$storage.get("userInfo") let { sceneType } = uni.$storage.get("userInfo")
if(sceneType == 7) tabs[1].hidden = true if(sceneType == 7) tabs[1].hidden = true
console.log('tabs', tabs)
return tabs return tabs
} }
}, },
created () { created () {
// 监听自定义事件 // 监听自定义事件
uni.$on('pageBack', () => { uni.$on('pageBack', () => {
console.log('pageBack') console.log('pageBack')
this.getMessageInfo(); this.getMessageInfo();
}); });
uni.$on('studyCenter', () => { uni.$on('ActivityCenter', this.handleActivityCenter);
let { tabs } = this, // uni.$on('ActivityCenter', () => {
index = tabs.findIndex(e => e.name == 'StudyCenter') // console.log('ActivityCenter')
this.changeIndex(index, this.tabs[index]) // let { tabs } = this,
}); // index = tabs.findIndex(e => e.name == 'ActivityCenter')
// this.changeIndex(index, this.tabs[index])
// })
// uni.$on('studyCenter', () => {
// let { tabs } = this,
// index = tabs.findIndex(e => e.name == 'StudyCenter')
// this.changeIndex(index, this.tabs[index])
// });
console.log('this.tabIndex', this.tabIndex)
this.getUnreadCount() this.getUnreadCount()
this.getStudyCenterPermission() this.getStudyCenterPermission()
this.getMessageInfo() this.getMessageInfo()
...@@ -272,6 +253,14 @@ export default { ...@@ -272,6 +253,14 @@ export default {
}) })
}) })
}, },
handleActivityCenter() {
console.log('ActivityCenter triggered'); // 添加日志查看触发次数
let { tabs } = this;
let index = tabs.findIndex(e => e.name == 'ActivityCenter');
if (index !== -1) {
this.changeIndex(index, this.tabs[index]);
}
},
async changeIndex (index, item) { async changeIndex (index, item) {
if (item.eventCode) uni.$track.add({ if (item.eventCode) uni.$track.add({
eventCode: item.eventCode eventCode: item.eventCode
...@@ -313,7 +302,7 @@ export default { ...@@ -313,7 +302,7 @@ export default {
// const res = await uni.$api.customerApi.haveCustomerAccess({ // const res = await uni.$api.customerApi.haveCustomerAccess({
// merchantId: shopMerchantId // merchantId: shopMerchantId
// }) // })
// if (res) // if (res)
// this.tabs.push({ // this.tabs.push({
// label: "客户档案", // label: "客户档案",
// icon: "customer-file", // icon: "customer-file",
...@@ -327,12 +316,10 @@ export default { ...@@ -327,12 +316,10 @@ export default {
// uni.$storage.set('isSaleOpen', result) // uni.$storage.set('isSaleOpen', result)
if (result) { if (result) {
this.hasPerson = true this.hasPerson = true
this.activityTabVisible = scene !== 7
}else {
this.activityTabVisible = false
} }
// const channelType = 1
// // 非直营且非鸿蒙智行, 隐藏学习中心tab
// if (result || channelType == 1) {
// this.tabs[2].hidden = false
// }
}) })
}, },
// 获取话术未读列表 // 获取话术未读列表
...@@ -465,6 +452,7 @@ export default { ...@@ -465,6 +452,7 @@ export default {
// this.trackInterval = null // this.trackInterval = null
}, },
beforeDestroy () { beforeDestroy () {
uni.$off('ActivityCenter', this.handleActivityCenter);
// clearInterval(this.trackInterval) // clearInterval(this.trackInterval)
// this.trackInterval = null // this.trackInterval = null
}, },
......
<template> <template>
<view> <view>
<ServiceList :messageList="messageList" :topListProp="topList" @handleClick="handleClick" /> <ServiceList type="out" :messageList="messageList" :topListProp="topList" @handleClick="handleClick" />
</view> </view>
</template> </template>
<script> <script>
......
...@@ -356,7 +356,8 @@ export default { ...@@ -356,7 +356,8 @@ export default {
gap: toRpx(40) toRpx(46); gap: toRpx(40) toRpx(46);
padding: toRpx(2) toRpx(44) 0; padding: toRpx(2) toRpx(44) 0;
.item { .item {
width: toRpx(610); // width: toRpx(610);
width: calc(50% - #{toRpx(23)});
background: #ffffff; background: #ffffff;
box-sizing: border-box; box-sizing: border-box;
padding: toRpx(24) toRpx(32); padding: toRpx(24) toRpx(32);
......
...@@ -270,8 +270,16 @@ export default { ...@@ -270,8 +270,16 @@ export default {
this.$refs[popkey].close() this.$refs[popkey].close()
if (popkey == 'carBrandVisible') { if (popkey == 'carBrandVisible') {
this.$refs.carBrandVisible.close() this.$refs.carBrandVisible.close()
this.customerInfo.brandModel = item.name // this.customerInfo.brandModel = item.name
this.customerInfo.carBrand = item.carChildsBrandName // this.customerInfo.carBrand = item.carChildsBrandName
Object.assign(this.customerInfo, {
brandModel: item.name,
carModelId: item.id,
carBrand: item.carChildsBrandName,
carBrandId: item.carChildsBrandId,
oneCarBrand: item.carBrand,
oneCarBrandId: item.carBrandId
})
} else if (popkey == 'customerTagstVisible') { } else if (popkey == 'customerTagstVisible') {
let names = [], let names = [],
ids = [] ids = []
...@@ -308,6 +316,13 @@ export default { ...@@ -308,6 +316,13 @@ export default {
params[e.key] = customerInfo[e.key] params[e.key] = customerInfo[e.key]
}) })
if (customerInfo.id) params.id = customerInfo.id if (customerInfo.id) params.id = customerInfo.id
Object.assign(params, {
carModelId: customerInfo.carModelId,
carBrand: customerInfo.carBrand,
carBrandId: customerInfo.carBrandId,
oneCarBrand: customerInfo.oneCarBrand,
oneCarBrandId: customerInfo.oneCarBrandId
})
params.customerTagName = params.customerTagName.replace(/|/g, ',') params.customerTagName = params.customerTagName.replace(/|/g, ',')
uni.showLoading({ uni.showLoading({
mask: true mask: true
...@@ -377,6 +392,7 @@ export default { ...@@ -377,6 +392,7 @@ export default {
animation: left-in 0.25s forwards; animation: left-in 0.25s forwards;
.nav-bar { .nav-bar {
width: 100%; width: 100%;
top: 0;
height: toRpx(96); height: toRpx(96);
z-index: 9; z-index: 9;
text-align: center; text-align: center;
......
...@@ -459,7 +459,8 @@ export default { ...@@ -459,7 +459,8 @@ export default {
gap: toRpx(40) toRpx(46); gap: toRpx(40) toRpx(46);
padding: toRpx(2) toRpx(44) 0; padding: toRpx(2) toRpx(44) 0;
.item { .item {
width: toRpx(610); // width: toRpx(610);
width: calc(50% - #{toRpx(23)});
background: #ffffff; background: #ffffff;
box-sizing: border-box; box-sizing: border-box;
padding: toRpx(24) toRpx(32); padding: toRpx(24) toRpx(32);
......
...@@ -400,7 +400,7 @@ export default { ...@@ -400,7 +400,7 @@ export default {
} }
} }
.right { .right {
width: toRpx(1358); width: calc(100% - #{toRpx(752)});
border: toRpx(2) solid #fff; border: toRpx(2) solid #fff;
box-sizing: border-box; box-sizing: border-box;
&.only-right { &.only-right {
......
...@@ -669,7 +669,16 @@ export default { ...@@ -669,7 +669,16 @@ export default {
font-weight: 500; font-weight: 500;
font-size: toRpx(34); font-size: toRpx(34);
color: #292D33; color: #292D33;
.sprite-icon {
&.active {
position: absolute;
top: 0;
z-index: -1;
font-weight: 500;
font-size: toRpx(32);
color: #3B73FF;
}
}
.first { .first {
left: 0; left: 0;
} }
...@@ -700,26 +709,25 @@ export default { ...@@ -700,26 +709,25 @@ export default {
border-radius: 50%; border-radius: 50%;
right: toRpx(86); right: toRpx(86);
} }
} &.active {
.active {
position: absolute;
top: 0;
z-index: -1;
font-weight: 500;
font-size: toRpx(32);
color: #3B73FF;
&::after {
content: '';
position: absolute; position: absolute;
bottom: 0; top: 0;
left: 50%; z-index: -1;
transform: translateX(-50%); font-weight: 500;
width: toRpx(48); font-size: toRpx(32);
height: toRpx(8); color: #3B73FF;
background-color: #3B73FF;
border-radius: toRpx(16); &::after {
content: '';
position: absolute;
bottom: 0;
left: 50%;
transform: translateX(-50%);
width: toRpx(48);
height: toRpx(8);
background-color: #3B73FF;
border-radius: toRpx(16);
}
} }
} }
} }
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
:imgKey="bannerKey" :imgKey="bannerKey"
:loadComplete="loadComplete" :loadComplete="loadComplete"
:noDataObject="swiperNoDataObject" :noDataObject="swiperNoDataObject"
> >
</swiper-component> </swiper-component>
</template> </template>
</view> </view>
...@@ -238,8 +238,9 @@ import Promotion from './components/Income/Promotion.vue' ...@@ -238,8 +238,9 @@ import Promotion from './components/Income/Promotion.vue'
import History from './components/Income/History.vue' import History from './components/Income/History.vue'
import merge from '@/mixin/record/merge.js' import merge from '@/mixin/record/merge.js'
import MessageDetail from './components/Message/MessageDetail.vue' import MessageDetail from './components/Message/MessageDetail.vue'
import StudyCenter from './components/StudyCenter.vue'
import SwiperComponent from '../SwiperComponent.vue' import SwiperComponent from '../SwiperComponent.vue'
import StudyCenter from './components/StudyCenter.vue'
import ActivityCenter from './components/ActivityCenter.vue'
import MessageIndex from './components/Message/index.vue' import MessageIndex from './components/Message/index.vue'
import permision from '@/js_sdk/wa-permission/permission.js' import permision from '@/js_sdk/wa-permission/permission.js'
import Entrance from '@/components/Entrance.vue' import Entrance from '@/components/Entrance.vue'
...@@ -250,8 +251,13 @@ import StudyPopupContent from '@/components/StudyPopupContent.vue' ...@@ -250,8 +251,13 @@ import StudyPopupContent from '@/components/StudyPopupContent.vue'
import ExamSubmitPopup from '@/components/ExamSubmitPopup.vue' import ExamSubmitPopup from '@/components/ExamSubmitPopup.vue'
import StudyCenterPermissionPopup from '@/components/StudyCenterPermissionPopup.vue' import StudyCenterPermissionPopup from '@/components/StudyCenterPermissionPopup.vue'
export default { export default {
<<<<<<< HEAD
mixins: [recorder, uploader, timeout, versionCheck, merge, interceptionMixin], mixins: [recorder, uploader, timeout, versionCheck, merge, interceptionMixin],
components: { ReceptionCenter, StudyCenter, SceneMarket, LeftSide, Point, dayPoint, rulePoint, Course, Ranking, LevelPoint, Calendar, Promotion, History, LevelMedal, MessageDetail, SwiperComponent, MessageIndex, Entrance, StudyPopup, StudyPopupContent, ExamSubmitPopup, StudyCenterPermissionPopup }, components: { ReceptionCenter, StudyCenter, SceneMarket, LeftSide, Point, dayPoint, rulePoint, Course, Ranking, LevelPoint, Calendar, Promotion, History, LevelMedal, MessageDetail, SwiperComponent, MessageIndex, Entrance, StudyPopup, StudyPopupContent, ExamSubmitPopup, StudyCenterPermissionPopup },
=======
mixins: [recorder, uploader, timeout, versionCheck, interceptionMixin, merge],
components: { ReceptionCenter, StudyCenter, ActivityCenter, SceneMarket, LeftSide, Point, dayPoint, rulePoint, Course, Ranking, LevelPoint, Calendar, Promotion, History, LevelMedal, MessageDetail, SwiperComponent, MessageIndex, Entrance },
>>>>>>> f10973ab20e45cf1c16d4bc356b8872846032300
props: { props: {
id: [String, Number], id: [String, Number],
finishDoneText: String, finishDoneText: String,
...@@ -612,20 +618,14 @@ export default { ...@@ -612,20 +618,14 @@ export default {
async entranceClick (item) { async entranceClick (item) {
// 清除评估单的图片视频资源缓存 // 清除评估单的图片视频资源缓存
const noInterceptPage = ['DailyReport'], const noInterceptPage = ['DailyReport', 'DeliveryManagement'],
{ sceneType } = this { sceneType } = this
if (!noInterceptPage.includes(item.name) && ((await this.checkDailyReport(sceneType != 7)))) return if (!noInterceptPage.includes(item.name)) {
if (sceneType != 7 && await this.inspectionOfProhibitionBill()) return if (sceneType != 7) {
if (await this.inspectionOfProhibitionBill()) return
// 新建工单时检查学习中心权限
if (item.name === 'CreateOrder') {
const hasPermission = await this.checkStudyCenterPermission()
if (!hasPermission) {
this.showStudyPermissionPopup = true
return
} }
if (await this.checkDailyReport(sceneType != 7)) return
} }
if (item.name === 'EvaluationFormList') { if (item.name === 'EvaluationFormList') {
mediaResourceManager.cleanupExpired() mediaResourceManager.cleanupExpired()
uni.navigateTo({ uni.navigateTo({
...@@ -633,7 +633,11 @@ export default { ...@@ -633,7 +633,11 @@ export default {
}) })
return return
} }
if (item.page) return uni.navigateTo({
url: item.page
})
let pageName = { let pageName = {
0: 'equity',
1: 'boutique', 1: 'boutique',
7: 'usedCar' 7: 'usedCar'
}[this.sceneType] }[this.sceneType]
...@@ -784,6 +788,7 @@ export default { ...@@ -784,6 +788,7 @@ export default {
} }
} }
.right-content-box { .right-content-box {
width: 100%;
height: calc(100% - #{toRpx(232)}); height: calc(100% - #{toRpx(232)});
gap: toRpx(48); gap: toRpx(48);
box-sizing: border-box; box-sizing: border-box;
...@@ -806,6 +811,7 @@ export default { ...@@ -806,6 +811,7 @@ export default {
.content-left, .content-left,
.content-right { .content-right {
height: 100%; height: 100%;
flex-shrink: 0;
} }
.content-left { .content-left {
width: toRpx(1210); width: toRpx(1210);
...@@ -822,10 +828,12 @@ export default { ...@@ -822,10 +828,12 @@ export default {
} }
} }
.content-right { .content-right {
width: toRpx(800); width: calc(100% - #{toRpx(1322)});
// width: toRpx(800);
} }
} }
.app-content-box { .app-content-box {
width: 100%;
position: absolute; position: absolute;
left: 0; left: 0;
top: 0; top: 0;
......
...@@ -28,6 +28,8 @@ ...@@ -28,6 +28,8 @@
</uni-popup> </uni-popup>
</template> </template>
<script> <script>
import utils from '@/utils/utils'
export default { export default {
props: { props: {
// 弹窗类型:success, error, warning, info // 弹窗类型:success, error, warning, info
...@@ -84,9 +86,10 @@ export default { ...@@ -84,9 +86,10 @@ export default {
watch: { watch: {
buttons: { buttons: {
immediate: true, immediate: true,
deep: true,
handler(newVal) { handler(newVal) {
if (newVal) { if (newVal) {
this.buttonsList = JSON.parse(JSON.stringify(newVal)) this.buttonsList = utils.deepClone(newVal)
} }
} }
} }
...@@ -94,7 +97,7 @@ export default { ...@@ -94,7 +97,7 @@ export default {
created() { created() {
// 初始化时将buttons赋值给buttonsList // 初始化时将buttons赋值给buttonsList
this.buttonsList = JSON.parse(JSON.stringify(this.buttons)) this.buttonsList = utils.deepClone(this.buttons)
} }
} }
</script> </script>
...@@ -104,7 +107,7 @@ export default { ...@@ -104,7 +107,7 @@ export default {
background-color: #fff; background-color: #fff;
border-radius: toRpx(38); border-radius: toRpx(38);
width: toRpx(848); width: toRpx(848);
height: toRpx(660); min-height: toRpx(660);
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
...@@ -124,10 +127,10 @@ export default { ...@@ -124,10 +127,10 @@ export default {
} }
.popup-title { .popup-title {
font-size: toRpx(40); font-size: toRpx(48);
font-weight: 500; font-weight: 500;
color: #333; color: #333;
margin-bottom: toRpx(16); margin-bottom: toRpx(24);
text-align: center; text-align: center;
} }
...@@ -135,7 +138,7 @@ export default { ...@@ -135,7 +138,7 @@ export default {
font-size: 28rpx; font-size: 28rpx;
color: #666; color: #666;
text-align: center; text-align: center;
margin-bottom: 32rpx; margin:0 64rpx 32rpx;
line-height: 1.5; line-height: 1.5;
} }
......
...@@ -48,6 +48,8 @@ ...@@ -48,6 +48,8 @@
:endDate="endDate" :endDate="endDate"
@confirm="confirmCalendar" @confirm="confirmCalendar"
:rangeValue="rangeValue" :rangeValue="rangeValue"
hideMask
showBottomBtn
/> />
</view> </view>
</template> </template>
......
<template>
<view class="page-box" :style="pageStyle">
<view
class="nav-bar"
:style="{ 'z-index': backProp.zindex || 9 }"
>
<template v-if="backProp.show">
<view
class="back"
@click="backProp.click"
>
<uni-icons
:type="backProp.iconType || 'left'"
:size="backProp.size || 20"
:color="backProp.color || '#000'"
></uni-icons>
</view>
</template>
{{ title }}
</view>
<slot></slot>
</view>
</template>
<script type='text/ecmascript-6'>
export default {
props: {
pageStyle:{
type: String,
default: ''
},
backProp: {
type: Object,
default: () => {
return {
show: true,
click: () => {
uni.navigateBack({
delta: 1,
animationType: 'pop-out',
animationDuration: 100
})
}
}
}
},
title: {
type: String,
default: ''
}
},
name: '',
data () {
return {
}
},
mounted () {
},
methods: {
}
}
</script>
<style scoped lang='scss'>
.page-box {
position: relative;
width: 100vw;
height: 100vh;
background-image: url('@/assets/images/common/page-bg.webp');
background-size: 100%;
.nav-bar {
position: fixed;
width: 100%;
height: toRpx(96);
left: 0;
top: toRpx(48);
text-align: center;
font-weight: 700;
font-size: toRpx(32);
color: #1a1a1a;
line-height: toRpx(96);
.back {
position: absolute;
left: 0;
top: 0;
height: 100%;
aspect-ratio: 1/1;
display: flex;
align-items: center;
justify-content: center;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template> <template>
<view class="select-box"> <view :class="['select-box',{styleV2:styleV2},{'disabled':disabled}]">
<view <view
class="select" class="select"
@click.stop="isSelect = !isSelect" @click.stop="showPop"
> >
{{selectList[selectIndex].label}} {{selectValue}}
<view class="sprite-icon icon-arrow-bottom"></view> <template v-if="!disabled">
<view class="sprite-icon icon-arrow-bottom"></view>
</template>
</view> </view>
<view <view
class="pop-box" class="pop-box"
...@@ -29,6 +31,35 @@ export default { ...@@ -29,6 +31,35 @@ export default {
labelKey: { labelKey: {
type: String, type: String,
default: 'label' default: 'label'
},
styleV2: {
type: Boolean,
default: false
},
disabled: {
type: Boolean,
default: false
},
defaultValue: [String, Number],
valueKey: {
type: String,
default: 'value'
}
},
computed: {
selectValue () {
let { selectList, selectIndex, labelKey } = this
return selectList[selectIndex][labelKey]
}
},
watch: {
defaultValue: {
immediate: true,
deep: true,
handler (n) {
let { selectList , valueKey} = this
this.selectIndex = selectList.findIndex(e => e[valueKey] == n)
}
} }
}, },
name: '', name: '',
...@@ -49,6 +80,10 @@ export default { ...@@ -49,6 +80,10 @@ export default {
this.isSelect = false this.isSelect = false
this.$emit('chooseType', { item, index }) this.$emit('chooseType', { item, index })
}, },
showPop () {
if (this.disabled) return
this.isSelect = !this.isSelect
}
} }
} }
</script> </script>
...@@ -96,4 +131,24 @@ export default { ...@@ -96,4 +131,24 @@ export default {
} }
} }
} }
.styleV2 {
.select {
height: toRpx(80);
background: #3b73ff1a;
color: #333333;
font-size: toRpx(28);
transition: all 0.15s;
}
.pop-box {
font-size: toRpx(28);
.type-item {
height: toRpx(80);
}
}
}
.disabled {
.select {
padding: 0 toRpx(40);
}
}
</style> </style>
\ No newline at end of file \ No newline at end of file
<template> <template>
<view class="type-tab"> <view class="type-tab">
<view class="type-box"> <template v-if="!styleV2">
<view <view class="type-box">
class="tab-item"
v-for="(i, index) in typeList"
:key="index"
@click="tabClick(index)"
>
<view <view
:class="['sprite-icon',tabClass(index)]" class="tab-item"
:style="{ v-for="(i, index) in typeList"
:key="index"
@click="tabClick(index)"
>
<view
:class="['sprite-icon',tabClass(index)]"
:style="{
left:blockLeft left:blockLeft
}" }"
></view> ></view>
<view
class="text"
:class="[tabIndex == index ? `active` : '']"
>
{{ i[nameKey] }}
</view>
</view>
</view>
<view class="mask-box"></view>
</template>
<template v-else>
<view class="type-box-v2">
<view <view
class="text" :class="['tab-item',{active:tabIndex == index}]"
:class="[tabIndex == index ? `active` : '']" v-for="(i, index) in typeList"
:key="index"
@click="tabClick(index)"
> >
{{ i[nameKey] }} <template v-if="index == 0">
<view class="sprite-icon icon-first-right"></view>
</template>
<template v-else>
<view class="sprite-icon icon-second-left"></view>
<view class="sprite-icon icon-second-right"></view>
</template>
<view class="text">
{{ i[nameKey] }}
</view>
</view> </view>
</view> </view>
</view> </template>
<view class="mask-box"></view>
</view> </view>
</template> </template>
...@@ -36,6 +59,10 @@ export default { ...@@ -36,6 +59,10 @@ export default {
nameKey: { nameKey: {
type: String, type: String,
default: 'tabName' default: 'tabName'
},
styleV2: {
type: Boolean,
default: true
} }
}, },
name: '', name: '',
...@@ -63,8 +90,9 @@ export default { ...@@ -63,8 +90,9 @@ export default {
return className return className
}, },
tabClick (index) { tabClick (index) {
if(this.tabIndex == index) return
this.$emit('update:tabIndex', index) this.$emit('update:tabIndex', index)
this.$emit('tabClick',index) this.$emit('tabClick', index)
} }
} }
} }
...@@ -128,5 +156,73 @@ export default { ...@@ -128,5 +156,73 @@ export default {
border-radius: toRpx(48); border-radius: toRpx(48);
overflow: hidden; overflow: hidden;
} }
.type-box-v2 {
position: relative;
display: flex;
width: 100%;
background-color: #eef4fe;
height: toRpx(96);
line-height: toRpx(96);
border-radius: toRpx(48) toRpx(48) 0 0;
z-index: 0;
flex-wrap: nowrap;
overflow-x: auto;
gap: 0 toRpx(80);
.tab-item {
padding: 0 toRpx(40);
flex-shrink: 0;
position: relative;
&:first-of-type{
padding-left: toRpx(80);
}
.text {
color: #292d33;
font-size: toRpx(32);
position: relative;
z-index: 2;
}
.sprite-icon {
position: absolute;
display: none;
}
}
.active {
background: #fff;
&:last-of-type {
.icon-second-right {
// display: none;
}
}
.text {
color: #3b73ff;
font-weight: 500;
transition: all 0.15s;
position: relative;
&::after {
width: toRpx(40);
height: toRpx(6);
border-radius: toRpx(4);
background: #3b73ff;
position: absolute;
content: '';
left: 50%;
transform: translateX(-50%);
bottom: toRpx(12);
}
}
.sprite-icon {
display: block;
}
.icon-first-right {
right: toMinusRpx(100);
}
.icon-second-left {
left: toMinusRpx(100);
}
.icon-second-right {
right: toMinusRpx(100);
}
}
}
} }
</style> </style>
\ No newline at end of file \ No newline at end of file
...@@ -62,7 +62,7 @@ const evaluationDomain = { ...@@ -62,7 +62,7 @@ const evaluationDomain = {
ip: 'http://192.168.1.221:5003', ip: 'http://192.168.1.221:5003',
// ip: 'http://192.168.2.80:8558', // ip: 'http://192.168.2.80:8558',
dev: 'http://gsc.dev.glsx.com.cn', dev: 'http://gsc.dev.glsx.com.cn',
beta: 'https://dj.beta.glsx.com.cn', //预发布 appid: wx9f91c1ec493eb425 beta: 'https://gsc.beta.glsx.com.cn', //预发布 appid: wx9f91c1ec493eb425
uat: 'http://gsc.test.glsx.com.cn', //测试 appid: wxe10067a63c1856ac uat: 'http://gsc.test.glsx.com.cn', //测试 appid: wxe10067a63c1856ac
prod: 'https://gsc.glsx.com.cn', prod: 'https://gsc.glsx.com.cn',
pet: 'https://cdptest.glsx.com.cn' //压测 appid: wx7ce755e425603084 pet: 'https://cdptest.glsx.com.cn' //压测 appid: wx7ce755e425603084
......
...@@ -16,12 +16,14 @@ import wnCanvas from './components/Canvas/wn-canvas' ...@@ -16,12 +16,14 @@ import wnCanvas from './components/Canvas/wn-canvas'
import UpdateBox from './components/UpdateBox' import UpdateBox from './components/UpdateBox'
import webView from './components/WebView' import webView from './components/WebView'
import uView from 'uview-ui' import uView from 'uview-ui'
import PageComponent from './components/PageComponent'
Vue.use(uView) Vue.use(uView)
Vue.use(webView) Vue.use(webView)
Vue.component('GlsxImage', GlsxImage) Vue.component('GlsxImage', GlsxImage)
Vue.component('MessageBox', MessageBox) Vue.component('MessageBox', MessageBox)
Vue.component('wnCanvas', wnCanvas) Vue.component('wnCanvas', wnCanvas)
Vue.component('UpdateBox', UpdateBox) Vue.component('UpdateBox', UpdateBox)
Vue.component('PageComponent', PageComponent)
Vue.config.productionTip = false Vue.config.productionTip = false
App.mpType = 'app' App.mpType = 'app'
// Vue.prototype.$ossDomain = config.OSS_DOMAIN // Vue.prototype.$ossDomain = config.OSS_DOMAIN
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
"name" : "展业助手", "name" : "展业助手",
"appid" : "__UNI__D3BD3DF", "appid" : "__UNI__D3BD3DF",
"description" : "", "description" : "",
"versionName" : "2.16.0", "versionName" : "2.17.1",
"versionCode" : "2160", "versionCode" : "2171",
"transformPx" : false, "transformPx" : false,
"sassImplementationName" : "node-sass", "sassImplementationName" : "node-sass",
/* 5+App特有相关 */ /* 5+App特有相关 */
......
...@@ -179,7 +179,48 @@ export default { ...@@ -179,7 +179,48 @@ export default {
}) })
}, },
/**延保日报 */ /**延保日报 */
equityStaffDailyReport () { }, equityStaffDailyReport () {
let { userInfo } = this
return new Promise((resolve, reject) => {
uni.$api.interceptionApi
.staffDailyReportMerchantValid({
merchantId: userInfo.shopMerchantId,
yqMerchantId: userInfo.merchantId,
staffUuid: userInfo.uuid,
sceneType: 0
})
.then(data => {
if (data) {
// 获取当前日期
let currentDate = new Date()
// 获取上一天的日期
let previousDate = new Date(currentDate)
previousDate.setDate(currentDate.getDate() - 1)
// toISOString 方法会丢失时区 导致与北京时间差八小时
let hour = previousDate.getHours() + 8
previousDate.setHours(hour)
// 格式化日期为"yyyy-mm-dd"
let formattedDate = previousDate.toISOString().split('T')[0]
// if (wx.__HAS_NOTLOGIN_MODAL) return false; //
this.addModalToQueue('日报提醒', '您有未填写的日报,请点击前往。', '前往填写', false, 2, res => {
if (res.confirm) {
const pages = getCurrentPages(),
currentPage = pages[pages.length - 1]
if (currentPage.route == 'pages/equity/tool/index') uni.$emit('jumpToDailyReport', formattedDate)
else uni.navigateTo({
url: `/pages/equity/tool/index?componentName=DailyReport&currentDate=${formattedDate}`
})
}
})
resolve(true)
} else {
resolve(false)
}
}).catch(err => {
resolve()
})
})
},
addModalToQueue (title, content, confirmText, showCancel, priority, eventCallback) { addModalToQueue (title, content, confirmText, showCancel, priority, eventCallback) {
if (modalQueue.findIndex(val => val.content == content) < 0) if (modalQueue.findIndex(val => val.content == content) < 0)
modalQueue.push({ modalQueue.push({
......
...@@ -268,6 +268,24 @@ ...@@ -268,6 +268,24 @@
"style": { "style": {
"navigationStyle": "custom" "navigationStyle": "custom"
} }
},
{
"path": "pages/usedCar/deliveryManagement/index",
"style": {
"navigationStyle": "custom"
}
},
{
"path": "pages/usedCar/deliveryManagement/detail",
"style": {
"navigationStyle": "custom"
}
},
{
"path": "pages/equity/tool/index",
"style": {
"navigationStyle": "custom"
}
} }
], ],
"globalStyle": { "globalStyle": {
...@@ -283,4 +301,4 @@ ...@@ -283,4 +301,4 @@
"rpxCalcBaseDeviceWidth": 375, "rpxCalcBaseDeviceWidth": 375,
"rpxCalcIncludeWidth": 750 "rpxCalcIncludeWidth": 750
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -266,8 +266,14 @@ export default { ...@@ -266,8 +266,14 @@ export default {
this.$store.dispatch("setReceptionTrack", { key, value }) this.$store.dispatch("setReceptionTrack", { key, value })
}, },
handleSelect (item) { handleSelect (item) {
this.customerInfo.carModel = item.name this.customerInfo.carModel = item.name || ''
this.customerInfo.carModelId = item.id this.customerInfo.carModelId = item.id || ''
Object.assign(this.customerInfo, {
carBrand: item.carChildsBrandName || '',
carBrandId: item.carChildsBrandId || '',
oneCarBrand: item.carBrand || '',
oneCarBrandId: item.carBrandId || ''
})
this.$store.dispatch('setCustomerInfo', this.customerInfo) this.$store.dispatch('setCustomerInfo', this.customerInfo)
this.carInfo = item this.carInfo = item
uni.hideLoading() uni.hideLoading()
...@@ -414,7 +420,7 @@ export default { ...@@ -414,7 +420,7 @@ export default {
} }
.content-box { .content-box {
height: 100%; height: 100%;
padding: toRpx(144) 0 toRpx(64) toRpx(64); padding: toRpx(144) 0 toRpx(64) toRpx(64);
animation: show-view-opacity 0.15s forwards; animation: show-view-opacity 0.15s forwards;
.left-content { .left-content {
width: toRpx(1328); width: toRpx(1328);
......
...@@ -6,9 +6,7 @@ ...@@ -6,9 +6,7 @@
* @LastEditTime: 2024-05-31 16:07:23 * @LastEditTime: 2024-05-31 16:07:23
--> -->
<template> <template>
<view <view class="detail-box">
class="detail-box"
>
<view class="nav-bar"> <view class="nav-bar">
<view <view
class="back" class="back"
...@@ -204,13 +202,17 @@ export default { ...@@ -204,13 +202,17 @@ export default {
// } // }
let customer = { let customer = {
customerName: item.customerName, customerName: item.customerName,
carModel: item.carSeriesName, carModel: item.carSeriesName || '',
phoneNumber: item.customerPhone, phoneNumber: item.customerPhone,
salesUuid: item.userId, salesUuid: item.userId,
staffName: item.employeeName, staffName: item.employeeName,
receiveCouponDate: item.receiveCouponDate, receiveCouponDate: item.receiveCouponDate,
customerCouponId: item.customerCouponId, customerCouponId: item.customerCouponId,
carSeriesId: item.carSeriesId carSeriesId: item.carSeriesId || '',
carBrand: item.carChildsBrandName || '',
carBrandId: item.carChildsBrandId || '',
oneCarBrand: item.carBrand || '',
oneCarBrandId: item.carBrandId || ''
} }
let [reception] = this.$refs.media1 let [reception] = this.$refs.media1
reception?.clearCustomerReceivedTimer() reception?.clearCustomerReceivedTimer()
......
...@@ -134,7 +134,7 @@ export default { ...@@ -134,7 +134,7 @@ export default {
customerName: customer.customerName customerName: customer.customerName
} }
this.orderObj.carBrand = `${customer.carBrand}-${customer.carChildsBrandName}-${customer.carSeriesName}` this.orderObj.carBrand = customer.carBrandId ? `${customer.carBrand}-${customer.carChildsBrandName}-${customer.carSeriesName}` : ''
// 更新表单状态 // 更新表单状态
const updateFormCell = (formIndex, fieldName, value) => { const updateFormCell = (formIndex, fieldName, value) => {
...@@ -283,7 +283,7 @@ export default { ...@@ -283,7 +283,7 @@ export default {
const cell = this.formList[2].find(item => item.value == 'payeeType') const cell = this.formList[2].find(item => item.value == 'payeeType')
if (cell) { if (cell) {
cell.current = 1 cell.current = 1
cell.radioList[1].disabled = false cell.radioList[1].disabled = false
} }
this.getConfig() this.getConfig()
} }
...@@ -323,7 +323,7 @@ export default { ...@@ -323,7 +323,7 @@ export default {
}, },
// 弹窗确认回调 // 弹窗确认回调
onConfirm(val, flag) { onConfirm(val, flag) {
console.log(val,flag, 'onConfirm') console.log(val, flag, 'onConfirm')
this.externalData = [] this.externalData = []
// const { chooseContent } = val // const { chooseContent } = val
const chooseContent = utils.deepClone(val.chooseContent) const chooseContent = utils.deepClone(val.chooseContent)
...@@ -356,9 +356,7 @@ export default { ...@@ -356,9 +356,7 @@ export default {
} else { } else {
// 过滤出已选的goodFlag为2的对象 // 过滤出已选的goodFlag为2的对象
const selectedGoods = this.orderObj[_typeValue.key].filter(item => item.goodsFlag === 2) const selectedGoods = this.orderObj[_typeValue.key].filter(item => item.goodsFlag === 2)
const singleGoods = flag ? const singleGoods = flag ? this.orderObj[_typeValue.key].filter(item => item.goodsFlag === 1) : chooseContent.filter(item => item.goodsFlag === 1)
this.orderObj[_typeValue.key].filter(item => item.goodsFlag === 1) :
chooseContent.filter(item => item.goodsFlag === 1)
const moreGoods = chooseContent const moreGoods = chooseContent
.filter(item => item.goodsFlag === 2) .filter(item => item.goodsFlag === 2)
.filter(item => { .filter(item => {
...@@ -771,7 +769,7 @@ export default { ...@@ -771,7 +769,7 @@ export default {
const cell = this.formList[2].find(item => item.value === key) const cell = this.formList[2].find(item => item.value === key)
if (cell) cell.hidden = arrMap[key].length === 0 if (cell) cell.hidden = arrMap[key].length === 0
}) })
console.log('this.formList', this.formList)
const subOrderList = this.subOrderList || [] const subOrderList = this.subOrderList || []
console.log('subOrderList', subOrderList) console.log('subOrderList', subOrderList)
let chooseList = [] let chooseList = []
......
...@@ -389,16 +389,16 @@ export default { ...@@ -389,16 +389,16 @@ export default {
this.warrantyCardList.push(warrantyItem) this.warrantyCardList.push(warrantyItem)
} }
// 膜类商品 并且服务商开通了使用膜卷号配置 不走签名流程 // 膜类商品 并且服务商开通了使用膜卷号配置 不走签名流程
if (this.baseConfigData?.membraneTypeList?.includes(e?.upgradeGoodsType) && this.isUseFilmRoll && !this.signatureSwitch) { // if (this.baseConfigData?.membraneTypeList?.includes(e?.upgradeGoodsType) && this.isUseFilmRoll && !this.signatureSwitch) {
let result = await api.getfilmRollNoByGoods({ // let result = await api.getfilmRollNoByGoods({
upgradeGoodsId: e.upgradeGoodsId, // upgradeGoodsId: e.upgradeGoodsId,
yqMerchantId: data?.sellerMerchantId, // yqMerchantId: data?.sellerMerchantId,
merchantId: data?.merchantId // merchantId: data?.merchantId
}) // })
e.filmNumberData = result?.data || [] // e.filmNumberData = result?.data || []
// 仅配置一个膜卷号 自动选中 // // 仅配置一个膜卷号 自动选中
if (!e.filmRollNo && e.filmNumberData?.length == 1) e.filmRollNo = e.filmNumberData[0] // if (!e.filmRollNo && e.filmNumberData?.length == 1) e.filmRollNo = e.filmNumberData[0]
} // }
} }
if (data.packageGoodsList) { if (data.packageGoodsList) {
......
...@@ -4,44 +4,30 @@ ...@@ -4,44 +4,30 @@
<view class="shop-item" v-for="(item, index) in list" :key="index"> <view class="shop-item" v-for="(item, index) in list" :key="index">
<view class="sprite-icon icon-blue-delete" @click="deleteGoods(index)"></view> <view class="sprite-icon icon-blue-delete" @click="deleteGoods(index)"></view>
<view class="right"> <view class="right">
<view class="shop-name">商品名称:{{ item.multipleSpecificationsGoods ? <view class="shop-name">商品名称:{{ item.multipleSpecificationsGoods ? item.multipleSpecificationsGoods.baseGoodsName : item.goods.goodsAlias || item.goods.upgradeGoodsName || item.goods.goodsInfo.goodsName }}</view>
item.multipleSpecificationsGoods.baseGoodsName : item.goods.goodsAlias || item.goods.upgradeGoodsName || <view class="alias" v-if="item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods.goodsAlias">商品别名:{{ item.multipleSpecificationsGoods.goods.goodsAlias }}</view>
item.goods.goodsInfo.goodsName }}</view>
<view class="alias"
v-if="item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods.goodsAlias">商品别名:{{
item.multipleSpecificationsGoods.goods.goodsAlias }}</view>
<view class="front-gear-box"> <view class="front-gear-box">
<view class="front-gear-input-box"> <view class="front-gear-input-box">
<template <template v-if="item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods.specificationStr">
v-if="item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods.specificationStr">
<view class="front-gear-label"> <view class="front-gear-label">
{{item.multipleSpecificationsGoods.goods.specificationStr}} {{ item.multipleSpecificationsGoods.goods.specificationStr }}
</view> </view>
</template> </template>
<template v-if="item.goods"> <template v-if="item.goods">
<template <template v-if="(item.goods.merchantGoodsPosition || item.goods.upgradeGoodsPosition) && (item.goods.goodsInfo.goodsType == 1 || item.goods.upgradeGoodsType == 1 || item.goods.goodsInfo.goodsType == baseConfigData.selfBuildFilmType || item.goods.upgradeGoodsType == baseConfigData.selfBuildFilmType)">
v-if="(item.goods.merchantGoodsPosition || item.goods.upgradeGoodsPosition) && (item.goods.goodsInfo.goodsType == 1 || item.goods.upgradeGoodsType == 1 || item.goods.goodsInfo.goodsType == baseConfigData.selfBuildFilmType || item.goods.upgradeGoodsType == baseConfigData.selfBuildFilmType)">
<view class="front-gear-label"> <view class="front-gear-label">
{{ formatPosition((item.goods.merchantGoodsPosition || item.goods.upgradeGoodsPosition), {{ formatPosition(item.goods.merchantGoodsPosition || item.goods.upgradeGoodsPosition, positionTypeList) }}
positionTypeList)}}
</view> </view>
</template> </template>
<template <template v-if="(item.goods.goodsInfo.goodsType == 1 || item.goods.upgradeGoodsType == 1) && !item.goods.merchantGoodsPosition && !item.goods.upgradeGoodsPosition">无部位属性</template>
v-if="(item.goods.goodsInfo.goodsType == 1 || item.goods.upgradeGoodsType == 1) && !item.goods.merchantGoodsPosition && !item.goods.upgradeGoodsPosition">无部位属性</template>
</template> </template>
<view class="front-gear-input"> <view class="front-gear-input">
<view class="unit">¥</view> <view class="unit">¥</view>
<template v-if="item.multipleSpecificationsGoods"> <template v-if="item.multipleSpecificationsGoods">
<input class="uni-input" type="digit" maxlength="9" placeholder="请输入价格" <input class="uni-input" type="digit" maxlength="9" :disabled="isDisabled" placeholder="请输入价格" placeholder-style="font-size: 14px" v-model="item.multipleSpecificationsGoods.goods.sellPrice" @blur="validatePrice($event, item, index)" />
placeholder-style="font-size: 14px"
v-model="item.multipleSpecificationsGoods.goods.sellPrice"
@blur="validatePrice($event, item, index)" />
</template> </template>
<template v-else> <template v-else>
<input class="uni-input" type="digit" maxlength="9" placeholder="请输入价格" <input class="uni-input" type="digit" :disabled="isDisabled" maxlength="9" placeholder="请输入价格" placeholder-style="font-size: 14px" v-model="item.goods.sellPrice" @blur="validatePrice($event, item, index)" />
placeholder-style="font-size: 14px"
v-model="item.goods.sellPrice"
@blur="validatePrice($event, item, index)" />
</template> </template>
<!-- <input class="uni-input" type="digit" maxlength="9" placeholder="请输入价格" <!-- <input class="uni-input" type="digit" maxlength="9" placeholder="请输入价格"
placeholder-style="font-size: 14px" placeholder-style="font-size: 14px"
...@@ -52,14 +38,10 @@ ...@@ -52,14 +38,10 @@
<view class="control"> <view class="control">
<view class="minus" @click="decreaseNumber(item)">-</view> <view class="minus" @click="decreaseNumber(item)">-</view>
<template v-if="item.multipleSpecificationsGoods"> <template v-if="item.multipleSpecificationsGoods">
<input class="uni-input control-input" type="number" maxlength="3" <input class="uni-input control-input" type="number" maxlength="3" v-model="item.multipleSpecificationsGoods.number" @blur="validateNumber($event, item)" />
v-model="item.multipleSpecificationsGoods.number"
@blur="validateNumber($event, item)" />
</template> </template>
<template v-else> <template v-else>
<input class="uni-input control-input" type="number" maxlength="3" <input class="uni-input control-input" type="number" maxlength="3" v-model="item.goods.number" @blur="validateNumber($event, item)" />
v-model="item.goods.number"
@blur="validateNumber($event, item)" />
</template> </template>
<!-- <input class="uni-input control-input" type="number" maxlength="3" <!-- <input class="uni-input control-input" type="number" maxlength="3"
:value="item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods ? item.multipleSpecificationsGoods.goods.number : item.goods.number" :value="item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods ? item.multipleSpecificationsGoods.goods.number : item.goods.number"
...@@ -88,6 +70,10 @@ export default { ...@@ -88,6 +70,10 @@ export default {
baseConfigData: { baseConfigData: {
type: Object, type: Object,
default: {} default: {}
},
isDisabled: {
type: Boolean,
default: false
} }
}, },
created() { created() {
...@@ -172,9 +158,7 @@ export default { ...@@ -172,9 +158,7 @@ export default {
} }
} else if (item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods) { } else if (item.multipleSpecificationsGoods && item.multipleSpecificationsGoods.goods) {
// 多规格商品的最小价格检查 // 多规格商品的最小价格检查
if (item.multipleSpecificationsGoods.goods.validMinSellPrice === 'Y' && if (item.multipleSpecificationsGoods.goods.validMinSellPrice === 'Y' && item.multipleSpecificationsGoods.goods.minSellPrice && parseFloat(value) < parseFloat(item.multipleSpecificationsGoods.goods.minSellPrice)) {
item.multipleSpecificationsGoods.goods.minSellPrice &&
parseFloat(value) < parseFloat(item.multipleSpecificationsGoods.goods.minSellPrice)) {
console.log('最小值', item.multipleSpecificationsGoods.goods.minSellPrice) console.log('最小值', item.multipleSpecificationsGoods.goods.minSellPrice)
uni.showToast({ uni.showToast({
title: '单价不可低于商品最低价', title: '单价不可低于商品最低价',
...@@ -380,4 +364,4 @@ export default { ...@@ -380,4 +364,4 @@ export default {
} }
} }
} }
</style>
\ No newline at end of file \ No newline at end of file
</style>
...@@ -181,8 +181,8 @@ export default { ...@@ -181,8 +181,8 @@ export default {
width: toRpx(36); width: toRpx(36);
height: toRpx(36); height: toRpx(36);
position: absolute; position: absolute;
top: - toRpx(12); top: toMinusRpx(12);
right: - toRpx(12); right: toMinusRpx(12);
background: rgba(0, 0, 0, 0.6); background: rgba(0, 0, 0, 0.6);
border-radius: 50%; border-radius: 50%;
text-align: center; text-align: center;
......
...@@ -447,8 +447,7 @@ const DEFEAT_FORM_LIST = [ ...@@ -447,8 +447,7 @@ const DEFEAT_FORM_LIST = [
value: 'skuGoods', value: 'skuGoods',
type: 'select', type: 'select',
key: 'name', key: 'name',
addHtml: 'skuGoods', addHtml: 'skuGoods'
hidden: true
}, },
{ {
label: '收款方式', label: '收款方式',
......
...@@ -192,7 +192,8 @@ export default { ...@@ -192,7 +192,8 @@ export default {
} }
} }
.detail-right { .detail-right {
width: toRpx(1368); // width: toRpx(1368);
width: calc(100% - #{toRpx(832)});
height: 100%; height: 100%;
border-radius: toRpx(48); border-radius: toRpx(48);
background: #ffffff59; background: #ffffff59;
......
...@@ -31,15 +31,35 @@ ...@@ -31,15 +31,35 @@
<view class="brand flex">{{pageData.carModel}}</view> <view class="brand flex">{{pageData.carModel}}</view>
</view> </view>
<view class="tips flex"> <view class="tips flex">
<view :class="['tips-text',{deal:pageData.orderFinishFlag}]"> <template v-if="sceneType == 1">
{{pageData.orderFinishFlag? '成交': '未成交'}} <view :class="['tips-text',{deal:pageData.orderFinishFlag}]">
</view> {{pageData.orderFinishFlag? '成交': '战败'}}
<view </view>
class="score-box" <view
v-if="pageData.score != null" class="score-box"
> v-if="pageData.score != null"
{{pageData.score}}<view class="unit">分</view> >
</view> {{pageData.score}}<view class="unit">分</view>
</view>
</template>
<template v-else>
<template v-if="pageData.indeterminate">
<view class="tips-text indeterminate">
待定
</view>
</template>
<template v-else>
<view :class="['tips-text',{deal:pageData.orderFinishFlag}]">
{{pageData.orderFinishFlag? '成交': '战败'}}
</view>
<view
class="score-box"
v-if="pageData.score != null"
>
{{formatReceptionScore(pageData)}}
</view>
</template>
</template>
</view> </view>
</view> </view>
...@@ -174,9 +194,9 @@ export default { ...@@ -174,9 +194,9 @@ export default {
onLoad () { onLoad () {
let _this = this let _this = this
this.getOpenerEventChannel().on('getData', function (data) { this.getOpenerEventChannel().on('getData', function (data) {
console.log(data)
data.totalDuration = (data.receptionEndTime - data.receptionStartTime) / 1000 data.totalDuration = (data.receptionEndTime - data.receptionStartTime) / 1000
_this.pageData = data || {} _this.pageData = data || {}
if (!data.orderFinishFlag && dayjs(data.receptionEndTime).isSame(dayjs(), 'day')) data.indeterminate = true
if (data.batchId) _this.findCheckResultByBatchId(data.batchId) if (data.batchId) _this.findCheckResultByBatchId(data.batchId)
_this.setAudio(data.recordingUrl) _this.setAudio(data.recordingUrl)
}) })
...@@ -193,6 +213,10 @@ export default { ...@@ -193,6 +213,10 @@ export default {
// }, // },
qualityRef () { qualityRef () {
return this.$refs.qualityRef return this.$refs.qualityRef
},
sceneType () {
const { sceneType } = uni.$storage.get('userInfo')
return sceneType
} }
}, },
onBackPress (options) { onBackPress (options) {
...@@ -454,6 +478,19 @@ export default { ...@@ -454,6 +478,19 @@ export default {
if (data.isResponding || data.isRecording) { if (data.isResponding || data.isRecording) {
this.disabledText = data.isResponding ? '请等待内容生成后再切换其他质检点' : '请等待录音结束后再切换其他质检点' this.disabledText = data.isResponding ? '请等待内容生成后再切换其他质检点' : '请等待录音结束后再切换其他质检点'
} }
},
formatReceptionScore (pageData) {
const { orderFinishFlag, score } = pageData;
if (score >= 85 && orderFinishFlag) return 'A+';
if (score >= 60 && score < 85 && orderFinishFlag) return 'A';
if (score < 60 && orderFinishFlag) return 'B';
if (score >= 85 && !orderFinishFlag) return 'B+';
if (score >= 60 && score < 85 && !orderFinishFlag) return 'B';
if (score < 60 && !orderFinishFlag) return 'C';
return '-';
},
orderFinishText ({ orderFinishFlag, receptionEndTime }) {
return orderFinishFlag ? '成交' : '战败'
} }
} }
} }
...@@ -542,10 +579,15 @@ export default { ...@@ -542,10 +579,15 @@ export default {
line-height: toRpx(40); line-height: toRpx(40);
.tips-text { .tips-text {
color: #f24724; color: #f24724;
font-size: toRpx(32);
} }
.deal { .deal {
color: #2cca74; color: #2cca74;
} }
.indeterminate {
color: #999ea8;
}
&-box { &-box {
opacity: 0.85; opacity: 0.85;
color: #2cca74; color: #2cca74;
......
<template> <template>
<scroll-view scroll-y class="service-list"> <scroll-view scroll-y class="service-list">
<view class="message-index-box"> <view :class="['message-index-box', type == 'out' ? 'message-out' : '']">
<view class="message-list" v-if="getTopList.length > 0"> <view class="message-list" v-if="getTopList.length > 0">
<view :class="['message-item', moduleType == i.moduleType ? 'active' : '']" v-for="(i, ind) in getTopList" <view :class="['message-item', moduleType == i.moduleType ? 'active' : '']" v-for="(i, ind) in getTopList"
:key="ind" @click.stop="handleClick(i)"> :key="ind" @click.stop="handleClick(i)">
...@@ -67,7 +67,11 @@ export default { ...@@ -67,7 +67,11 @@ export default {
messageList: { messageList: {
type: Array, type: Array,
default: () => [] default: () => []
} },
type: {
type: String,
default: ''
},
}, },
data() { data() {
return { return {
...@@ -193,6 +197,10 @@ export default { ...@@ -193,6 +197,10 @@ export default {
.message-index-box { .message-index-box {
margin: 0 toRpx(32); margin: 0 toRpx(32);
height: 100%; height: 100%;
&.message-out {
padding-bottom: toRpx(40);
box-sizing: content-box;
}
.message-group { .message-group {
.message-date { .message-date {
......
...@@ -3,7 +3,8 @@ const moduleTypeEnum = { ...@@ -3,7 +3,8 @@ const moduleTypeEnum = {
1: '优秀话术', 1: '优秀话术',
2: '违规话术', 2: '违规话术',
3: '短课程学习', 3: '短课程学习',
4: '长课程学习' 4: '长课程学习',
5: '活动中心'
} }
const moduleIconEnum = { const moduleIconEnum = {
...@@ -11,7 +12,8 @@ const moduleIconEnum = { ...@@ -11,7 +12,8 @@ const moduleIconEnum = {
1: 'notice-script', 1: 'notice-script',
2: 'notice-violate', 2: 'notice-violate',
3: 'notice-study', 3: 'notice-study',
4: 'notice-study' 4: 'notice-study',
5: 'active-msg'
} }
const moduleContentEnum = { const moduleContentEnum = {
......
module.exports = {
data: {
orderObj: [
{
label: '工单编号',
key: 'orderCode',
copy: true
},
{
label: '工单时间',
key: 'time',
dateChange: true
},
{
label: '工单状态',
key: 'status',
color: '#14CC68',
status: true
},
{
label: '支付方式',
key: 'payType',
payType: true
}
],
customerObj: [
{
label: '客户姓名',
key: 'customerName'
},
{
label: '性别',
key: 'customerSex',
enum: {
1: '男',
2: '女'
}
},
{
label: '手机号',
key: 'customerPhone',
color: '#347BFF',
callBack: 'makePhoneCall',
copy: true
},
{
label: '车型',
key: 'carType'
},
{
label: '车架号',
key: 'standNo'
},
{
label: '车牌号',
key: 'plateNumber'
},
{
label: '是否体验',
key: 'experienceFlag',
enum: {
Y: '是',
N: '否'
}
},
{
label: '销售顾问',
arr: ['merchantName', 'employeeName']
},
{
label: '转化专员',
arr: ['sellerMerchantName', 'sellerName']
},
{
label: '备注',
key: 'remark'
}
],
payType: {
0: '战败',
1: '微信支付',
2: '门店收款',
3: 'pos机支付',
4: '支付宝支付',
5: '嘀加收款',
6: '对公转账',
7: '其它收款'
},
orderType: [
{
name: '全部',
active: true,
value: []
},
{
name: '升级下单',
value: [1, 2, 3, 4, 6]
},
{
name: '核销抵扣',
value: [5]
}
],
status: {
12: {
text: '已退款',
color: '#F7A431',
background: '#FFF5E6'
},
11: {
text: '已失效',
color: '#8F959E',
background: ' #F3F4F5'
},
10: {
text: '已关闭',
color: '#8F959E'
},
9: {
text: '已撤销',
color: '#8F959E',
background: '#F0F0F0'
},
1: {
text: '待跟进',
color: '#FF9D0A',
background: '#FFF5E6'
},
2: {
text: '战败',
color: '#F24724',
background: '#FDECE9'
},
3: {
text: '待支付',
color: '#FF9D0A',
background: '#FFF5E6'
},
4: {
text: '已支付',
color: '#35C376',
background: '#EAF9F1'
},
6: {
text: '已评价',
color: '#347BFF',
background: '#EAF1FF'
}
},
// 订单状态 1 待跟进, 2 不升级, 3 待支付,4 已支付,6 已评价 , 9 已撤销
statusList: [
{
name: '待跟进',
value: [1]
},
{
name: '已支付',
value: [4]
},
{
name: '待支付',
value: [3]
},
{
name: '已撤销',
value: [9]
},
{
name: '战败',
value: [2]
},
{
name: '已评价',
value: [6]
},
{
name: '已关闭',
value: [10]
},
{
name: '已失效',
value: [11]
}
],
grassInfo: {},
orderCode: '',
userInfo: {}
}
}
<template>
<view>
<view :class="[list.length > 0 ? 'package-list' : '']">
<view class="package-item" v-for="(item, index) in list" :key="index">
<view class="header">
<view class="header-left">
<view class="sprite-icon icon-blue-delete" @click="deleteGoods(index)"></view>
<view class="name">{{ item.packageGoods.packageAlias || item.packageGoods.packageName }}</view>
<view class="control">
<view class="minus" @click="decreaseNumber(item)">-</view>
<input class="uni-input control-input" type="number" maxlength="3" v-model="item.packageGoods.number" @blur="validateNumber($event, item)" />
<view class="add" @click="increaseNumber(item)">+</view>
</view>
</view>
<view class="price">¥{{ changeTotal(item) }}</view>
</view>
<view class="goods-item" v-for="(goods, ind) in item.packageGoods.goodsList" :key="ind">
<view class="goods-name">{{ goods.goodsAlias || goods.upgradeGoodsName }}</view>
<!-- <view class="alias-name">商品别名:阿尔法 T5极狐非三电整车延保(新车2年6万公里)</view> -->
<view class="front-gear-box">
<view class="front-gear-input-box">
<!-- <view class="front-gear-label" v-if="goods.merchantGoodsPosition || goods.goodsInfo.goodsTypeName">{{goods.goodsInfo.goodsType===1?formatPosition(goods.merchantGoodsPosition, positionTypeList):goods.goodsInfo.goodsTypeName}}</view> -->
<view class="front-gear-input">
<view class="unit">¥</view>
<input class="uni-input" type="digit" maxlength="9" placeholder="请输入价格" placeholder-style="font-size: 14px" v-model="goods.sellPrice" @blur="validatePrice($event, goods, ind, index)" />
</view>
</view>
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
name: 'Package',
props: {
list: {
type: Array,
default: () => []
},
positionTypeList: {
type: Array,
default: []
}
},
created() {
// 初始化商品数量
this.initProductNumbers()
console.log(this.list, 'Package-list')
},
mounted() {
// 确保每次使用组件时都检查并设置number属性
this.initProductNumbers()
},
updated() {
// 当组件数据更新时也检查number属性
this.initProductNumbers()
console.log(this.list, 'Package-list2')
},
methods: {
// 初始化商品数量方法
initProductNumbers() {
if (this.list && this.list.length > 0) {
this.list.forEach(item => {
if (!item.packageGoods.number) {
this.$set(item.packageGoods, 'number', '1')
}
// 存储旧值
item.packageGoods.goodsList.forEach(goods => {
if (!goods.price) {
goods.oldPrice = goods.sellPrice
}
})
})
}
},
// // 格式化位置信息
// formatPosition(item, positionTypeList) {
// const filterData = positionTypeList.filter(v => v.positionValue == item)
// return (filterData.length && filterData[0] && filterData[0].positionName) || ''
// },
// 验证数量输入
validateNumber(event, item) {
let value = event.detail.value
// 限制只能输入整数
value = value.replace(/[^\d]/g, '')
// 如果为空或0,设置为1
if (!value || value.trim() === '' || parseInt(value) === 0) {
value = '1'
}
// 更新值
this.$set(item.packageGoods, 'number', value)
this.$emit('changeTotalPrice')
},
// 增加数量
increaseNumber(item) {
if (!item.packageGoods.number) {
this.$set(item.packageGoods, 'number', '1')
} else {
const currentValue = parseInt(item.packageGoods.number)
// 限制最大数量为999
const newValue = currentValue >= 999 ? 999 : currentValue + 1
this.$set(item.packageGoods, 'number', newValue.toString())
}
this.$emit('changeTotalPrice')
},
// 减少数量
decreaseNumber(item) {
// 如果商品数量不存在或小于等于1,设置为1
if (!item.packageGoods.number || parseInt(item.packageGoods.number) <= 1) {
this.$set(item.packageGoods, 'number', '1')
return
}
const currentValue = parseInt(item.packageGoods.number)
// 确保减少后的值不小于1
const newValue = Math.max(1, currentValue - 1)
this.$set(item.packageGoods, 'number', newValue.toString())
this.$emit('changeTotalPrice')
},
validatePrice(event, goods, ind, index) {
let value = event.detail.value
// 如果为空则设置为0
if (!value || value.trim() === '') {
value = '0'
}
// 限制只能输入数字和小数点
value = value.replace(/[^\d.]/g, '')
// 限制只能有一个小数点
if (value.split('.').length > 2) {
value = value.slice(0, value.lastIndexOf('.')) + value.slice(value.lastIndexOf('.') + 1)
}
// 限制最多两位小数
if (value.includes('.')) {
const parts = value.split('.')
if (parts[1].length > 2) {
parts[1] = parts[1].substring(0, 2)
value = parts.join('.')
}
}
// 限制最大值为100000
if (parseFloat(value) > 100000) {
value = '100000'
}
// 限制最小值为0
if (parseFloat(value) < 0 || parseFloat(value) == 0) {
value = '0'
}
// 如果validMinSellPrice为Y,则强制修改值为最小值
if (goods.validMinSellPrice === 'Y' && goods.minSellPrice && parseFloat(value) < parseFloat(goods.minSellPrice)) {
console.log('最小值', goods.minSellPrice)
uni.showToast({
title: '单价不可低于商品最低价',
icon: 'none'
})
value = goods.minSellPrice.toString()
}
// 更新值
this.$set(this.list[index].packageGoods.goodsList[ind], 'sellPrice', value)
this.$emit('changeTotalPrice')
},
// 删除商品
deleteGoods(index) {
this.list.splice(index, 1)
this.$emit('changeTotalPrice')
},
// 计算套餐的总价
changeTotal(item) {
let total = 0
item.packageGoods.goodsList.forEach(i => {
// total += parseFloat(i.sellPrice) * parseInt(item.packageGoods.number)
total += parseFloat(i.sellPrice)
})
item.packageGoods.upgradePrice = total
return total.toFixed(2)
}
}
}
</script>
<style scoped lang="scss">
.front-gear-box {
display: flex;
justify-content: space-between;
margin-top: toRpx(24);
.front-gear-input-box {
display: flex;
align-items: center;
.front-gear-label {
font-size: toRpx(24);
margin-right: toRpx(24);
color: #999999;
}
.front-gear-input {
position: relative;
display: flex;
border: toRpx(2) solid #eff0f2;
background-color: #fff;
font-size: toRpx(28);
height: toRpx(72);
width: toRpx(250);
line-height: toRpx(70);
text-align: right;
border-radius: toRpx(12);
.uni-input {
padding: 0 toRpx(32);
height: 100%;
}
.unit {
position: absolute;
top: 50%;
left: toRpx(32);
transform: translateY(-50%);
}
}
}
}
.package-list {
padding: toRpx(12) toRpx(32) toRpx(12) 0;
.package-item {
background-color: #f5f7fa;
border-radius: toRpx(16);
margin-bottom: toRpx(16);
.control {
margin-left: toRpx(32);
display: flex;
align-items: center;
.control-input {
width: toRpx(94);
height: toRpx(74);
background-color: #fff;
border: toRpx(2) solid #eff0f2;
padding: 0 toRpx(10);
text-align: center;
}
.minus,
.add {
width: toRpx(80);
height: toRpx(74);
line-height: toRpx(70);
text-align: center;
background-color: #fff;
border-top: toRpx(2) solid #eff0f2;
border-bottom: toRpx(2) solid #eff0f2;
}
.minus {
border-radius: toRpx(12) 0 0 toRpx(12);
border-left: toRpx(2) solid #eff0f2;
}
.add {
border-radius: 0 toRpx(12) toRpx(12) 0;
border-right: toRpx(2) solid #eff0f2;
}
}
.header {
display: flex;
justify-content: space-between;
align-items: center;
border-bottom: toRpx(1.6) solid #dce1e6;
padding: toRpx(24);
&-left {
display: flex;
align-items: center;
font-size: toRpx(28);
.name {
margin-left: toRpx(26);
color: #333;
}
.price {
color: #666;
}
}
}
.goods-item {
padding: toRpx(24);
border-bottom: toRpx(1.6) solid #dce1e6;
&:last-child {
border-bottom: none;
}
.goods-name {
color: #ff781f;
font-size: toRpx(28);
}
.alias-name {
margin-top: toRpx(12);
font-size: toRpx(24);
color: #666;
}
}
}
}
</style>
<template>
<view>
<view :class="[list.length ? 'shop-list':'']">
<view class="shop-item" v-for="(item, index) in list" :key="item.goods.goodsId">
<view class="sprite-icon icon-blue-delete" @click="deleteGoods(index)"></view>
<view class="right">
<view class="shop-name">商品名称:{{ item.goods.goodsAlias || item.goods.upgradeGoodsName || item.goods.goodsInfo.goodsName }}</view>
<!-- <view class="alias">商品别名:{{ item.goods.goodsAlias }}</view> -->
<view class="front-gear-box">
<view class="front-gear-input-box">
<view class="front-gear-label" v-if="(item.goods.merchantGoodsPosition || item.goods.upgradeGoodsPosition) && (item.goods.goodsInfo.goodsType == 1 || item.goods.upgradeGoodsType == 1 || item.goods.goodsInfo.goodsType == baseConfigData.selfBuildFilmType || item.goods.upgradeGoodsType == baseConfigData.selfBuildFilmType)">
{{ formatPosition(item.goods.merchantGoodsPosition || item.goods.upgradeGoodsPosition, positionTypeList) }}
</view>
<view class="front-gear-input">
<view class="unit">¥</view>
<input class="uni-input" :disabled="isDisabled" type="digit" maxlength="9" placeholder="请输入价格" placeholder-style="font-size: 14px" v-model="item.goods.sellPrice" @blur="validatePrice($event, item, index)" />
</view>
</view>
<view class="control">
<view class="minus" @click="decreaseNumber(item)">-</view>
<input class="uni-input control-input" type="number" maxlength="3" v-model="item.goods.number" @blur="validateNumber($event, item)" />
<view class="add" @click="increaseNumber(item)">+</view>
</view>
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
name: 'Product',
props: {
list: {
type: Array,
default: []
},
positionTypeList: {
type: Array,
default: []
},
baseConfigData: {
type: Object,
default: {}
},
isDisabled: {
type: Boolean,
default: false
}
},
created() {
// 初始化商品数量
this.initProductNumbers()
},
mounted() {
// 确保每次使用组件时都检查并设置number属性
this.initProductNumbers()
},
updated() {
// 当组件数据更新时也检查number属性
this.initProductNumbers()
},
methods: {
// 初始化商品数量方法
initProductNumbers() {
if (this.list && this.list.length > 0) {
this.list.forEach(item => {
if (!item.goods.number) {
this.$set(item.goods, 'number', '1')
}
})
}
},
circulation(data, str) {
let arr = str.split('.'),
result
if (arr.length) {
result = arr.reduce((pre, key) => {
return pre[key]
}, data)
}
return result
},
// 格式化位置信息
formatPosition(item, positionTypeList) {
const filterData = positionTypeList.filter(v => v.positionValue == item)
return (filterData.length && filterData[0] && filterData[0].positionName) || ''
},
// 验证价格输入
validatePrice(event, item, index) {
let value = event.detail.value
// 如果为空则设置为0
if (!value || value.trim() === '') {
value = '0'
}
// 限制只能输入数字和小数点
value = value.replace(/[^\d.]/g, '')
// 限制只能有一个小数点
if (value.split('.').length > 2) {
value = value.slice(0, value.lastIndexOf('.')) + value.slice(value.lastIndexOf('.') + 1)
}
// 限制最多两位小数
if (value.includes('.')) {
const parts = value.split('.')
if (parts[1].length > 2) {
parts[1] = parts[1].substring(0, 2)
value = parts.join('.')
}
}
// 限制最 大值为100000
if (parseFloat(value) > 100000) {
value = '100000'
}
// 限制最小值为0
if (parseFloat(value) < 0 || parseFloat(value) == 0) {
value = '0'
}
if (item.goods.validMinSellPrice === 'Y' && item.goods.minSellPrice && parseFloat(value) < parseFloat(item.goods.minSellPrice)) {
console.log('最小值', item.goods.minSellPrice)
uni.showToast({
title: '单价不可低于商品最低价',
icon: 'none'
})
value = item.goods.minSellPrice.toString()
}
// 更新值
// this.$set(item.goods, 'sellPrice', value)
this.$set(this.list[index].goods, 'sellPrice', value)
this.$emit('changeTotalPrice')
},
// 验证数量输入
validateNumber(event, item) {
let value = event.detail.value
// 限制只能输入整数
value = value.replace(/[^\d]/g, '')
// 如果为空或0,设置为1
if (!value || value.trim() === '' || parseInt(value) === 0) {
value = '1'
}
// 更新值
this.$set(item.goods, 'number', value)
this.$emit('changeTotalPrice')
},
// 增加数量
increaseNumber(item) {
if (!item.goods.number) {
this.$set(item.goods, 'number', '1')
} else {
const currentValue = parseInt(item.goods.number)
// 限制最大数量为999
const newValue = currentValue >= 999 ? 999 : currentValue + 1
this.$set(item.goods, 'number', newValue.toString())
}
this.$emit('changeTotalPrice')
},
// 减少数量
decreaseNumber(item) {
// 如果商品数量不存在或小于等于1,设置为1
if (!item.goods.number || parseInt(item.goods.number) <= 1) {
this.$set(item.goods, 'number', '1')
return
}
const currentValue = parseInt(item.goods.number)
// 确保减少后的值不小于1
const newValue = Math.max(1, currentValue - 1)
this.$set(item.goods, 'number', newValue.toString())
this.$emit('changeTotalPrice')
},
// 删除商品
deleteGoods(index) {
this.list.splice(index, 1)
this.$emit('changeTotalPrice')
}
}
}
</script>
<style scoped lang="scss">
.shop-list {
padding: toRpx(12) toRpx(32) toRpx(12) 0;
.shop-item {
display: flex;
align-items: center;
background-color: #f5f7fa;
border-radius: toRpx(16);
margin-bottom: toRpx(16);
padding: toRpx(24);
.right {
flex: 1;
font-size: toRpx(28);
margin-left: toRpx(24);
.shop-name {
color: #ff781f;
}
.alias {
margin-top: toRpx(12);
font-size: toRpx(24);
color: #666;
}
}
}
}
.front-gear-box {
display: flex;
justify-content: space-between;
margin-top: toRpx(24);
.front-gear-input-box {
display: flex;
align-items: center;
.front-gear-label {
font-size: toRpx(24);
margin-right: toRpx(24);
color: #999999;
}
.front-gear-input {
position: relative;
display: flex;
border: toRpx(2) solid #eff0f2;
background-color: #fff;
font-size: toRpx(28);
height: toRpx(72);
width: toRpx(250);
line-height: toRpx(70);
text-align: right;
border-radius: toRpx(12);
.uni-input {
padding: 0 toRpx(32);
height: 100%;
}
.unit {
position: absolute;
top: 50%;
left: toRpx(32);
transform: translateY(-50%);
}
}
}
.control {
display: flex;
align-items: center;
.control-input {
width: toRpx(94);
height: toRpx(74);
background-color: #fff;
border: toRpx(2) solid #eff0f2;
padding: 0 toRpx(10);
text-align: center;
}
.minus,
.add {
width: toRpx(80);
height: toRpx(74);
line-height: toRpx(70);
text-align: center;
background-color: #fff;
border-top: toRpx(2) solid #eff0f2;
border-bottom: toRpx(2) solid #eff0f2;
}
.minus {
border-radius: toRpx(12) 0 0 toRpx(12);
border-left: toRpx(2) solid #eff0f2;
}
.add {
border-radius: 0 toRpx(12) toRpx(12) 0;
border-right: toRpx(2) solid #eff0f2;
}
}
}
</style>
<template>
<view class="upload-proof-of-payment">
<view class="common-title">上传付款凭证</view>
<view class="px-48">
<view class="box-shell">
<view class="flex align-center justify-between box-flow">
<view class="box-label">
交易流水号
<text class="required">*</text>
</view>
<input v-model="outTradeNo" type="text" @input="outTradeNoInput" class="uni-input" maxlength="150" placeholder="请输入" />
</view>
<view class="payment">
<view class="payment-label">
付款凭证
<text class="required">*</text>
</view>
<view class="upload-box flex flex-wrap">
<view class="upload-item" @click.stop="selectImg"></view>
<view v-for="(item, index) in payVoucherList" :key="index" class="previewImageList">
<image :src="item"></image>
<view class="close-box" @click="deleteImg(index)">
<uni-icons class="icon-close" type="closeempty" color="#ffffff"></uni-icons>
</view>
</view>
</view>
</view>
</view>
</view>
<view class="uploadBtn" @click.stop="confirm">确定提交</view>
</view>
</template>
<script>
import { uploadFile } from '@/utils/ossUploadFile/uploadFile.js'
import { debounce } from 'lodash'
export default {
name: 'UploadProofOfPayment',
props: {
transmissionOfData: {
type: Object,
default: () => null
}
},
data() {
return {
payVoucherList: [],
outTradeNo: ''
}
},
mounted() {
console.log(this.transmissionOfData, 'console.log(this.transmissionOfData)')
},
methods: {
selectImg() {
let _this = this
uni.chooseImage({
count: 1, //默认9
sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
sourceType: ['album'], //从相册选择
success: function (res) {
console.log(res)
_this.upLoad(res)
}
})
},
outTradeNoInput(e) {
const filteredValue = e.detail.value.replace(/[\u4E00-\u9FA5]/g, '')
this.$nextTick(() => {
this.$set(this, 'outTradeNo', filteredValue)
})
console.log(this.outTradeNo)
},
// 上传付款凭证
async upLoad(event) {
console.log(event)
let _this = this
const { tempFilePaths } = event
let url = await uploadFile(tempFilePaths[0])
this.payVoucherList.push(url)
},
confirm: debounce(function (e) {
console.log(this.transmissionOfData)
let { outTradeNo, payVoucherList } = this
if (payVoucherList.length && outTradeNo) {
this.createPayOrder()
} else {
uni.showToast({ title: '交易流水号或付款凭证不能为空!', icon: 'none' })
}
}, 300),
deleteImg(index) {
this.payVoucherList.splice(index, 1)
},
createPayOrder() {
const { orderCode, payType, payeeType, successDate } = this.transmissionOfData
let obj = {
orderCode,
payType: payType,
payeeType: payeeType,
successDate
}
if (this.payVoucherList?.length && this.outTradeNo) {
obj.payVoucherList = this.payVoucherList
obj.outTradeNo = this.outTradeNo
}
uni.showLoading({
title: '提交中...',
mask: true
})
uni.$api.boutiqueApi.createPayOrder(obj).then(data => {
uni.hideLoading()
uni.showToast({ title: '提交成功', icon: 'success' })
this.$emit('jump', 'OrderDetail', data)
})
}
}
}
</script>
<style scoped lang="scss">
.px-48 {
padding: 0 toRpx(48);
}
.upload-proof-of-payment {
width: 100%;
height: 100%;
position: relative;
.box-shell {
width: 100%;
border-radius: toRpx(16);
background: #ffffff;
padding: toRpx(24) toRpx(32);
// margin-top: toRpx(16);
.box-flow {
border-bottom: toRpx(2) solid #f7f7f6;
padding-bottom: toRpx(28);
.box-label {
font-weight: 400;
font-size: toRpx(28);
color: #333333;
}
.required {
color: #f00;
margin-left: toRpx(8);
}
.uni-input {
text-align: right;
.uni-input-placeholder {
font-size: toRpx(28);
font-weight: 400;
}
}
}
.payment {
.payment-label {
font-weight: 400;
font-size: toRpx(28);
color: #333333;
margin-top: toRpx(32);
margin-bottom: toRpx(24);
.required {
color: #f00;
margin-left: toRpx(8);
}
}
.upload-box {
gap: toRpx(20);
.upload-item {
width: toRpx(320) !important;
height: toRpx(240) !important;
border-radius: toRpx(12);
background: url('@/assets/images/boutique/uploadImage.png') no-repeat;
background-size: 100% 100%;
}
.previewImageList {
position: relative;
image {
width: toRpx(320) !important;
height: toRpx(240) !important;
border-radius: toRpx(12);
}
.close-box {
width: toRpx(36);
height: toRpx(36);
position: absolute;
top: - toRpx(12);
right: - toRpx(12);
background: rgba(0, 0, 0, 0.6);
border-radius: 50%;
text-align: center;
line-height: toRpx(40);
}
.icon-close {
font-size: toRpx(12);
}
}
}
}
}
.uploadBtn {
width: 80%;
height: toRpx(80);
border-radius: toRpx(48);
background: linear-gradient(0deg, #2c66f7 0%, #48a6ff 100%);
color: #ffffff;
font-size: toRpx(28);
font-weight: 500;
position: absolute;
bottom: toRpx(20);
margin: 0 auto;
left: 0;
right: 0;
text-align: center;
line-height: toRpx(80);
}
}
</style>
<template>
<view class="detail-box">
<view class="nav-bar">
<view
class="back"
@click="backPage"
>
<uni-icons
type="left"
:size="20"
color="#000"
></uni-icons>
</view>
<view class="title">展业工具</view>
</view>
<view class="detail-content">
<view class="detail-left">
<view class="common-title">展业</view>
<view class="content">
<image
class="banner"
src="../../../assets/images/common/tool_banner.png"
mode="scaleToFill"
/>
<template v-if="toolComponentName !== 'DailyReport'">
<Entrance @entranceClick="entranceClick"></Entrance>
</template>
<template v-else>
<uni-calendar
ref="calendar"
:clearDate="false"
:endDate="endDate"
:showMonth="false"
@monthSwitch="currentMonth = `${$event.year}-${$event.month}`"
@change="currentDate = $event.fulldate"
backgroundColor="transparent"
:selected="selectedDays"
:date="currentDate"
/>
</template>
</view>
</view>
<view class="detail-right">
<component
:is="toolComponentName"
@jump="jump"
:transmission-of-data="transmissionOfData"
:currentDate="currentDate"
:currentMonth="currentMonth"
@setCalendarSelected="selectedDays = $event"
/>
</view>
</view>
<NoticePopup
ref="notice"
title="重要提示"
text="当前页面暂未保存,是否确认退出"
type="warning"
></NoticePopup>
</view>
</template>
<script>
import Entrance from '@/components/Entrance.vue'
import CreateOrder from './components/CreateOrder.vue'
import DailyReport from './components/DailyReport.vue'
import DefeatOrder from './components/DefeatOrder.vue'
import OrderManagement from './components/OrderManagement.vue'
import ConfirmOrder from './components/ConfirmOrder.vue'
import OrderDetail from './components/OrderDetail.vue'
import UploadProofOfPayment from './components/UploadProofOfPayment.vue'
import NoticePopup from '@/components/NoticePopup.vue'
import dayjs from 'dayjs'
import { interceptionMixin } from '@/mixin/index'
export default {
mixins: [interceptionMixin],
components: {
Entrance,
CreateOrder,
DailyReport,
DefeatOrder,
OrderManagement,
ConfirmOrder,
NoticePopup,
UploadProofOfPayment,
OrderDetail
},
data () {
return {
toolComponentName: '',
transmissionOfData: null,
endDate: dayjs().format('YYYY-MM-DD'),
currentDate: dayjs().format('YYYY-MM-DD'),
currentMonth: dayjs().format('YYYY-MM'),
selectedDays: []
}
},
onLoad (options) {
if (options.componentName) this.toolComponentName = options.componentName
if (options.currentDate) this.setCurrentDate(options.currentDate)
uni.$on('jumpToDailyReport', currentDate => {
this.toolComponentName = 'DailyReport'
if (currentDate) this.setCurrentDate(currentDate)
})
},
methods: {
setCurrentDate (currentDate) {
this.currentDate = currentDate
this.currentMonth = dayjs(currentDate).format('YYYY-MM')
},
async entranceClick (item) {
const noInterceptPage = ['DailyReport']
if (!noInterceptPage.includes(item.name) && ((await this.checkDailyReport()) || (await this.inspectionOfProhibitionBill()))) return
// 保存当前选择的组件信息,但不立即切换
const selectedItem = item
if (this.toolComponentName === selectedItem.name && (!this.transmissionOfData || this.transmissionOfData.type !== 'supplementOrder')) return
// 如果当前组件是OrderManagement,直接切换组件,不显示弹窗
// 只有从CreateOrder、DefeatOrder切换其他组件时需要二次确认
if (this.toolComponentName !== 'CreateOrder' && this.toolComponentName !== 'DefeatOrder') {
this.toolComponentName = selectedItem.name
this.transmissionOfData = null
return
}
// 配置弹窗按钮
this.$refs.notice.buttonsList = [
{
text: '确认退出',
type: 'default',
callback: () => {
// 点击确认后才切换组件
this.toolComponentName = selectedItem.name
// if (selectedItem.name !== 'CreateOrder') {
// this.transmissionOfData = null
// }else {
// console.log(111)
// this.transmissionOfData = null
// }
this.transmissionOfData = null
this.$refs.notice.close()
}
},
{
text: '继续编辑',
type: 'primary',
callback: () => {
this.$refs.notice.close()
}
}
]
// 打开弹窗
this.$refs.notice.open()
},
backPage () {
uni.navigateBack()
},
// name:跳转组件名,val:跳转参数
jump (name, val) {
this.toolComponentName = name
console.log(this.toolComponentName, val)
if (val) {
this.transmissionOfData = val
}
}
}
}
</script>
<style scoped lang="scss">
.detail-content {
display: flex;
height: calc(100vh - #{toRpx(212)});
.detail-left {
width: toRpx(800);
height: 100%;
border-radius: toRpx(48);
background: #ffffff59;
box-shadow: inset 0 0 toRpx(16) 0 #ffffff;
margin-right: toRpx(32);
z-index: 1;
overflow: hidden;
.content {
padding: 0 toRpx(48);
.banner {
width: toRpx(704);
height: toRpx(296);
margin-top: toRpx(10);
margin-bottom: toRpx(64);
}
}
}
.detail-right {
width: toRpx(1368);
height: 100%;
border-radius: toRpx(48);
background: #ffffff59;
box-shadow: inset 0 0 toRpx(16) 0 #ffffff;
z-index: 1;
overflow: hidden;
}
.common-title {
display: flex;
align-items: center;
justify-content: space-between;
font-size: toRpx(34);
}
}
</style>
...@@ -108,7 +108,7 @@ ...@@ -108,7 +108,7 @@
/> />
<GeneralPopup ref="calendarGeneralPopup" popupClass="calendarGeneralPopup" :showClose="false" :showTitle="false" @confirm="confirmCalendar"> <GeneralPopup ref="calendarGeneralPopup" popupClass="calendarGeneralPopup" :showClose="false" :showTitle="false" @confirm="confirmCalendar">
<template #content> <template #content>
<uni-calendar class="calendar" :showMonth="false" :date="defaultDate" :startDate="startDate" @change="calendarChange" /> <uni-calendar class="calendar" :showMonth="false" :date="defaultDate" :startDate="startDate" :endDate="endDate" @change="calendarChange" />
</template> </template>
</GeneralPopup> </GeneralPopup>
<GeneralPopup ref="tipsPopup" popupClass="tipsPopup" type="center" :showClose="true" :showTitle="false" :noTitle="true"> <GeneralPopup ref="tipsPopup" popupClass="tipsPopup" type="center" :showClose="true" :showTitle="false" :noTitle="true">
...@@ -1004,7 +1004,7 @@ export default { ...@@ -1004,7 +1004,7 @@ export default {
if (field.endDate) { if (field.endDate) {
this.endDate = dayjs().format('YYYY-MM-DD') this.endDate = dayjs().format('YYYY-MM-DD')
} else { } else {
this.endDate = '' this.endDate = '2039-5-20'
} }
this.$refs.calendarGeneralPopup this.$refs.calendarGeneralPopup
.open() .open()
......
...@@ -81,13 +81,14 @@ export default { ...@@ -81,13 +81,14 @@ export default {
text-align: center; text-align: center;
font-weight: 400; font-weight: 400;
font-size: toRpx(28); font-size: toRpx(28);
color: #1f2133; color: #292D33;
position: relative; position: relative;
.text { .text {
position: relative; position: relative;
text-align: center; text-align: center;
height: toRpx(96); height: toRpx(96);
padding: 0 toRpx(64); padding: 0 toRpx(64);
transition: all .15s;
.count { .count {
font-size: toRpx(24); font-size: toRpx(24);
} }
...@@ -110,18 +111,18 @@ export default { ...@@ -110,18 +111,18 @@ export default {
} }
.active { .active {
position: relative; position: relative;
font-weight: 700; font-weight: 500;
font-size: toRpx(32); font-size: toRpx(32);
color: #2c66f7; color: #3B73FF;
&::after { &::after {
content: ''; content: '';
position: absolute; position: absolute;
bottom: toRpx(16); bottom: toRpx(16);
left: 50%; left: 50%;
transform: translateX(-50%); transform: translateX(-50%);
width: toRpx(48); width: toRpx(40);
height: toRpx(8); height: toRpx(6);
background-color: #2c66f7; background-color: #3B73FF;
border-radius: toRpx(16); border-radius: toRpx(16);
} }
} }
...@@ -133,15 +134,15 @@ export default { ...@@ -133,15 +134,15 @@ export default {
position: absolute; position: absolute;
} }
.tab-first-right { .tab-first-right {
right: - toRpx(64); right: toMinusRpx(64);
position: absolute; position: absolute;
} }
.tab-second-right { .tab-second-right {
right: - toRpx(64); right: toMinusRpx(64);
position: absolute; position: absolute;
} }
.tab-second-left { .tab-second-left {
left: - toRpx(64); left: toMinusRpx(64);
position: absolute; position: absolute;
} }
} }
......
<template>
<view class="step-1">
<view class="item flex">
<view class="sprite-icon icon-delivery-step-1"></view>
<view class="info">
客户到店确认
<view class="des">等待客户到店后操作</view>
</view>
<view
class="btn flex"
@click="confirmArrive"
>确认到店</view>
</view>
<view class="tips">
<view class="title flex">
<view class="icon">
<uni-icons
type="info"
:size="16"
color="#F59619"
></uni-icons>
</view>交付要点
</view>
<view class="text">核实车款: 引导客户现场完成尾款支付,并确认款项到账。</view>
<view class="text">核验人车: 核对客户身份信息,并与客户共同确认车辆信息及实际车况。</view>
<view class="text">交接资料: 清点并交付车辆登记证、行驶证、车钥匙等重要物品。</view>
<view class="text">签署确认: 引导客户签署《车辆交付确认书》,完成交付流程。 </view>
</view>
</view>
</template>
<script type='text/ecmascript-6'>
export default {
props: {
step: [String, Number],
detail: {
type: Object,
default: () => {
return {}
}
}
},
name: '',
data () {
return {
}
},
mounted () {
},
methods: {
async confirmArrive () {
try {
uni.$track.add({
eventCode: 'app_delivery_arrive_shop'
})
uni.showLoading({ title: '确定中...', mask: true })
const { step, detail } = this,
{ deliveryOrderId } = detail,
{ data: { code, msg } } = await uni.$api.usedCarApi.confirmArrive({
deliveryOrderId
})
uni.hideLoading()
if (code == 0) {
this.$emit('comfirm', step)
this.$emit('refreshLog')
}
else throw msg
} catch (error) {
uni.hideLoading()
if (error) this.$emit('openError', error)
}
}
}
}
</script>
<style scoped lang='scss'>
.step-1 {
margin: 0 toRpx(48);
.item {
height: toRpx(144);
border-radius: toRpx(16);
background: #ffffff;
margin-bottom: toRpx(24);
box-sizing: border-box;
padding: 0 toRpx(32);
.sprite-icon {
zoom: 2;
}
.info {
margin-left: toRpx(24);
color: #333333;
font-size: toRpx(28);
font-weight: 500;
line-height: toRpx(40);
.des {
color: #666666;
font-size: toRpx(26);
font-weight: 400;
line-height: toRpx(36);
margin-top: toRpx(4);
}
}
.btn {
margin-left: auto;
width: toRpx(192);
height: toRpx(64);
border-radius: toRpx(48);
background: linear-gradient(0deg, #2c66f7 0%, #48a6ff 100%);
color: #ffffff;
font-size: toRpx(28);
font-weight: 500;
justify-content: center;
}
}
.tips {
height: toRpx(272);
border-radius: toRpx(16);
background: #fef4e8;
box-sizing: border-box;
padding: toRpx(24) toRpx(32) toRpx(24) toRpx(72);
color: #f59619;
font-size: toRpx(26);
line-height: toRpx(44);
.title {
font-weight: 500;
line-height: toRpx(36);
margin-bottom: toRpx(12);
position: relative;
}
.icon {
position: absolute;
right: calc(100% + #{toRpx(8)});
top: 50%;
transform: translateY(-50%) rotate(180deg);
width: toRpx(32);
height: toRpx(32);
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<view class="step-2">
<view class="upload-box box">
<view class="title">
交付照片
<view class="required">*</view>
</view>
<view class="tips">完成交付图片上传,拍摄需包含车辆图片(铭牌、45%角)、提车人照片,及提车人身份证照片。</view>
<view class="img-list flex">
<template v-if="imgList.length < 10">
<view class="img-item upload flex" @click="chooseImage">
<uni-icons type="plusempty" :size="22" color="#347BFF" class="icon"></uni-icons>
{{ imgList.length }}/10
</view>
</template>
<template v-for="(i, index) in imgList">
<view class="img-item" :key="index">
<image :src="i" class="img" mode="aspectFill" @click="previewMedia(i, 1)" />
<view class="del flex">
<uni-icons type="closeempty" :size="10" color="#fff" @click="delImage(index)"></uni-icons>
</view>
</view>
</template>
</view>
<view class="img-tips">单个文件不超过10M,最多可上传10张。</view>
</view>
<view class="remark-box box">
<view class="title">交付备注</view>
<view class="remark">
<textarea placeholder="请描述交付过程备注信息" placeholder-class="placeholder" :value="remark" @input="remark = $event.detail.value" :maxlength="200" class="textarea"></textarea>
<view class="limit">{{ remark.length }}/200</view>
</view>
</view>
<view class="btn-box box flex">
<view class="sprite-icon icon-delivery-step-2"></view>
<view class="info">
客户提车确认
<view class="des">请让客户在拍卖小程序完成交割单签署,签署完成后才可点击确认提车。</view>
</view>
<view :class="['btn flex', { disabled: !imgList.length }]" @click="comfirm">确认提车</view>
</view>
<view class="block"></view>
</view>
</template>
<script type="text/ecmascript-6">
import { uploadFile } from '@/utils/ossUpload.js'
import permision from '@/js_sdk/wa-permission/permission.js'
const MAX_IMAGE_SIZE = 10 * 1024 * 1024, // 图片最大10MB
MAX_IMG_COUNT = 10 // 最大图片数量
export default {
name: '',
props: {
step: [String, Number],
detail: {
type: Object,
default: () => {
return {}
}
}
},
data() {
return {
imgList: [],
remark: ''
}
},
mounted() {
},
methods: {
delImage(index) {
this.imgList.splice(index, 1)
},
async chooseImage() {
const { imgList } = this,
_this = this
try {
// #ifdef APP-PLUS
const photoLibrary = await permision.requestAndroidPermission('android.permission.READ_EXTERNAL_STORAGE')
const camera = await permision.requestAndroidPermission('android.permission.CAMERA')
const isOnline = await uni.$isNetWork()
if (photoLibrary != 1) throw '您的设备不支持相册功能或未授权访问,请前往设置中开启相册权限'
if (camera != 1) throw '您的设备不支持摄像头功能或未授权访问,请前往设置中开启摄像头权限'
if (!isOnline) throw '当前无网络连接,请连接网络后重试'
// #endif
uni.chooseImage({
count: MAX_IMG_COUNT - imgList.length,
async success(res) {
for (const file of res.tempFiles) {
if (file.size > MAX_IMAGE_SIZE) {
return uni.showToast({
title: '图片上传最大10MB',
icon: 'none'
})
}
}
uni.showLoading({ title: '上传中...', mask: true })
for (let i = 0; i < res.tempFilePaths.length; i++) {
const url = await uploadFile(res.tempFiles[i], res.tempFilePaths[i])
_this.imgList.push(url)
}
if (_this.imgList.length >= res.tempFilePaths.length) uni.hideLoading()
},
fail(err) {
console.log(err)
uni.hideLoading()
if (err.errMsg.indexOf('cancel') === -1) {
return uni.showToast({
title: '图片上传失败',
icon: 'none'
})
}
},
})
} catch (error) {
console.log(error)
uni.hideLoading()
return uni.showToast({
title: error,
icon: 'none'
})
}
},
async comfirm() {
try {
let { imgList, step, remark, detail } = this,
{ deliveryOrderId } = detail,
confirmImages = ''
if (!imgList.length) return
confirmImages = imgList.join(',')
uni.showLoading({ title: '提交中...', mask: true })
uni.$track.add({
eventCode: 'app_delivery_submit_detail'
})
const { data: { code, msg } } = await uni.$api.usedCarApi.confirmDelivery({
deliveryOrderId,
confirmImages,
remark
})
uni.hideLoading()
if (code == 0) {
this.$emit('comfirm', step)
this.$emit('refreshLog')
}
else throw msg
} catch (error) {
console.log(error)
uni.hideLoading()
if (error) this.$emit('openError', error)
}
},
previewMedia(media, type) {
const url = `/pages/boutique/preview?tabName=预览&sourceType=${type}&detailUrl=${media}`
uni.navigateTo({
url: `${url}`
})
}
}
}
</script>
<style scoped lang="scss">
.step-2 {
position: relative;
z-index: 2;
margin: 0 toRpx(48);
.box {
border-radius: toRpx(16);
background: #ffffff;
margin-bottom: toRpx(24);
padding: 0 toRpx(32);
.title {
color: #333333;
font-size: toRpx(28);
font-weight: 500;
display: flex;
line-height: toRpx(40);
padding-top: toRpx(28);
.required {
color: #f24724;
font-size: toRpx(28);
margin-left: toRpx(8);
}
}
}
.upload-box {
.tips {
margin: toRpx(4) 0 toRpx(28);
color: #999999;
font-size: toRpx(26);
line-height: toRpx(36);
}
.img-list {
flex-wrap: wrap;
gap: toRpx(24);
.upload {
background: #f5f8ff;
flex-direction: column;
justify-content: center;
color: #999999;
font-size: toRpx(26);
.icon {
font-weight: 700;
margin-bottom: toRpx(22);
}
}
.img-item {
width: toRpx(224);
height: toRpx(224);
border-radius: toRpx(12);
position: relative;
overflow: hidden;
.img {
width: 100%;
height: 100%;
}
.del {
position: absolute;
width: toRpx(32);
height: toRpx(32);
background: #00000080;
border-radius: 100%;
top: toRpx(8);
right: toRpx(4);
justify-content: center;
}
}
}
.img-tips {
color: #999999;
font-size: toRpx(24);
padding: toRpx(16) 0 toRpx(28);
line-height: toRpx(36);
}
}
.remark-box {
padding-bottom: toRpx(28);
.title {
padding-bottom: toRpx(24);
}
.remark {
height: toRpx(200);
border-radius: toRpx(16);
background: #fafafa;
box-sizing: border-box;
padding: toRpx(24) 0 toRpx(24) toRpx(24);
position: relative;
.textarea {
height: toRpx(132);
width: 100%;
color: #333333;
font-size: toRpx(28);
}
.limit {
position: absolute;
bottom: toRpx(8);
right: toRpx(8);
color: #999999;
font-size: toRpx(28);
line-height: toRpx(44);
}
}
.placeholder {
color: #999999;
font-size: toRpx(28);
}
}
.btn-box {
box-sizing: border-box;
height: toRpx(144);
.info {
margin-left: toRpx(24);
color: #333333;
font-size: toRpx(28);
font-weight: 500;
line-height: toRpx(40);
.des {
color: #666666;
font-size: toRpx(26);
font-weight: 400;
line-height: toRpx(36);
margin-top: toRpx(4);
}
}
.btn {
margin-left: auto;
width: toRpx(192);
height: toRpx(64);
border-radius: toRpx(48);
background: linear-gradient(0deg, #2c66f7 0%, #48a6ff 100%);
color: #ffffff;
font-size: toRpx(28);
font-weight: 500;
justify-content: center;
}
.disabled {
opacity: 0.5;
}
}
.block {
width: 100%;
height: toRpx(24);
}
}
</style>
<template>
<view class="step-3">
<view class="upload-box box">
<view class="title">
交付照片
</view>
<view class="img-list flex">
<template v-for="(i, index) in detail.imgList">
<view
class="img-item"
:key="index"
>
<image
:src="i"
class="img"
mode="aspectFill"
@click="previewMedia(i, 1)"
/>
</view>
</template>
</view>
</view>
<view class="remark-box box">
<view class="title">交付备注</view>
<view class="remark">
<rich-text :nodes="detail.remark || '-'"></rich-text>
</view>
</view>
<view class="btn-box box flex">
<view class="sprite-icon icon-delivery-step-2"></view>
<view class="info">
客户提车确认
<view class="des">提车时间:{{detail.pickUpTime}}</view>
</view>
<view class="btn flex">已提车</view>
</view>
</view>
</template>
<script type="text/ecmascript-6">
export default {
name: '',
props: {
step: [String, Number],
detail: {
type: Object,
default: () => {
return {}
}
}
},
data () {
return {
}
},
mounted () {
},
methods: {
previewMedia (media, type) {
const url = `/pages/boutique/preview?tabName=预览&sourceType=${type}&detailUrl=${media}`
uni.navigateTo({
url: `${url}`
})
}
}
}
</script>
<style scoped lang="scss">
.step-3 {
margin: 0 toRpx(48);
.box {
border-radius: toRpx(16);
background: #ffffff;
margin-bottom: toRpx(24);
padding: 0 toRpx(32);
.title {
color: #333333;
font-size: toRpx(28);
font-weight: 500;
display: flex;
line-height: toRpx(40);
padding-top: toRpx(28);
}
}
.upload-box {
padding-bottom: toRpx(28);
.title {
margin-bottom: toRpx(28);
}
.img-list {
flex-wrap: wrap;
gap: toRpx(24);
.img-item {
width: toRpx(224);
height: toRpx(224);
border-radius: toRpx(12);
position: relative;
overflow: hidden;
.img {
width: 100%;
height: 100%;
}
.del {
position: absolute;
width: toRpx(32);
height: toRpx(32);
background: #00000080;
border-radius: 100%;
top: toRpx(8);
right: toRpx(4);
justify-content: center;
}
}
}
.img-tips {
color: #999999;
font-size: toRpx(24);
padding: toRpx(16) 0 toRpx(28);
line-height: toRpx(36);
}
}
.remark-box {
padding-bottom: toRpx(28);
.remark {
margin-top: toRpx(24);
max-height: toRpx(220);
box-sizing: border-box;
color: #333333;
font-size: toRpx(28);
overflow-y: auto;
line-height: toRpx(44);
word-break: break-all;
}
.placeholder {
color: #999999;
font-size: toRpx(28);
}
}
.btn-box {
box-sizing: border-box;
height: toRpx(144);
margin-bottom: 0;
.info {
margin-left: toRpx(24);
color: #333333;
font-size: toRpx(28);
font-weight: 500;
line-height: toRpx(40);
.des {
color: #666666;
font-size: toRpx(26);
font-weight: 400;
line-height: toRpx(36);
margin-top: toRpx(4);
}
}
.btn {
margin-left: auto;
width: toRpx(192);
height: toRpx(64);
border-radius: toRpx(48);
color: #999ea8;
background: #f0f1f5;
font-size: toRpx(28);
font-weight: 500;
justify-content: center;
}
.disabled {
opacity: 0.5;
}
}
}
</style>
<template>
<view class="steps-box flex common-title">
<template v-for="(item, index) in list">
<view
:class="['step-item flex',{
'active-item': index <= stepNum
}]"
:key="index"
>
<template v-if="index != 0">
<view class="line"></view>
</template>
<view class="serial-num flex">
<view class="num flex">
<template v-if="index >= stepNum">
{{index + 1}}
</template>
<template v-if="index < stepNum">
<uni-icons
type="checkmarkempty"
:size="12"
color="#fff"
></uni-icons>
</template>
</view>
</view>
{{item}}
</view>
</template>
</view>
</template>
<script type='text/ecmascript-6'>
export default {
props: {
step: [String, Number],
list: Array
},
name: '',
data () {
return {
}
},
computed: {
stepNum () {
return this.step - 1
}
},
mounted () {
},
methods: {
}
}
</script>
<style scoped lang='scss'>
.steps-box {
padding: toRpx(40) 0 toRpx(24) toRpx(54);
margin-bottom: toRpx(8);
.step-item {
color: #999;
font-size: toRpx(32);
font-weight: 500;
height: toRpx(56);
.serial-num {
width: toRpx(46);
height: toRpx(46);
border-radius: 100%;
box-sizing: border-box;
margin-right: toRpx(12);
position: relative;
border: toRpx(3) solid #b1b1b1;
justify-content: center;
.num {
width: 100%;
height: 100%;
border: toRpx(3) solid #fff;
background: #b1b1b1;
color: #fff;
border-radius: 100%;
justify-content: center;
font-size: toRpx(28);
font-weight: 700;
}
}
.line {
width: toRpx(64);
border-top: toRpx(2) dashed #d6d6d6;
border-bottom: toRpx(2) dashed #d6d6d6;
margin: 0 toRpx(32);
}
}
.active-item {
color: #4673ff;
.serial-num {
border-color: #4673ff;
box-shadow: toRpx(3) toRpx(3) toRpx(4) #d7e3ff;
.num {
background: #4673ff;
}
}
.line {
border-color: #4673ff;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<view class="delivery-steps-box">
<template v-if="detail.id">
<steps
:step="step"
:list="stepList"
/>
</template>
<view class="step-component">
<template v-for="(i,index) in stepList">
<view
:class="['step-view',
{'animation-view': viewClass(index) && !viewComplete[index + 1]},
{'show-view':index + 1 == step}]"
:key="index"
>
<component
:is="'Step' + (index + 1)"
:step="step"
@comfirm="comfirm"
@openError="$emit('openError',$event)"
:detail="detail"
@refreshLog="$emit('refreshLog')"
></component>
</view>
</template>
</view>
</view>
</template>
<script type='text/ecmascript-6'>
import Steps from './Steps.vue'
import Step1 from './Step1'
import Step2 from './Step2'
import Step3 from './Step3'
export default {
components: {
Steps,
Step1,
Step2,
Step3
},
props: {
detail: {
type: Object,
default: () => {
return {}
}
},
},
watch: {
detail: {
handler (val) {
this.step = Number(val.orderStatus) + 1
},
deep: true
}
},
name: '',
data () {
return {
step: -1,
stepList: [
'待交付',
'交付中',
'交付完成'
],
viewComplete: {
1: false,
2: false,
3: false
}
}
},
mounted () {
},
methods: {
comfirm (step) {
const { id } = this.detail
this.step = step + 1
if (this.step == 3) this.$emit('refresh', id)
},
viewClass (index) {
setTimeout(() => {
this.viewComplete[this.step] = true
}, 1e3)
return index + 1 == this.step
}
}
}
</script>
<style scoped lang='scss'>
.delivery-steps-box {
height: 100%;
.step-component {
height: calc(100% - #{toRpx(128)});
overflow-y: auto;
position: relative;
.step-view {
position: absolute; //验证
width: 100%;
height: 100%;
z-index: -1;
top: 0;
left: 0;
visibility: hidden;
}
.animation-view {
position: absolute;
z-index: 1;
visibility: visible;
animation: to-right 0.15s forwards;
}
.show-view {
z-index: 1;
visibility: visible;
}
@keyframes to-right {
0% {
left: 100%;
}
100% {
left: 0;
}
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<view class="detail-info-box">
<template v-if="detail.id">
<view class="pay-info box">
<view class="title">财务信息</view>
<view class="item">
<view class="label">付款状态</view>
<view :class="['value await',{'success':detail.paymentStatus == 1}]">{{PAYMENT_STATUS[detail.paymentStatus]}}</view>
</view>
<template v-if="detail.paymentStatus != 1">
<view class="tips">
<view class="icon">
<uni-icons
type="info"
:size="16"
color="#F59619"
></uni-icons>
</view>
中拍人现场看车后支付,请门店人员确认客户完成车款支付。
</view>
</template>
</view>
<view class="car-info box">
<view class="title">车辆与客户信息</view>
<template v-for="(i,index) in carInfo">
<view
class="item-box"
:key="index"
>
<view class="item">
<view class="label">{{i.label}}</view>
<view class="value">{{detail[i.key] || '-'}}</view>
</view>
<template v-if="i.hasLine">
<view class="line"></view>
</template>
</view>
</template>
<template v-if="detail.paymentStatus != 1">
<view class="tips">
<view class="icon">
<uni-icons
type="info"
:size="16"
color="#F59619"
></uni-icons>
</view>
交付专员需确认交付车辆信息,与买家信息无误后才可交付。
</view>
</template>
</view>
<view class="log-info box">
<view class="title">操作日志</view>
<view class="log-box">
<template v-for="(i,index) in logList">
<view
class="log-item"
:key="index"
>
<view class="log-title">{{OP_TYPE[i.opType]}}</view>
<view class="item">
<view class="label">操作人</view>
<view class="value">{{i.opUserName}}</view>
</view>
<view class="item">
<view class="label">时间</view>
<view class="value">{{i.createdDate}}</view>
</view>
<view class="item-mark">
<view :class="['circle',{first:index == 0}]"></view>
<template v-if="index != logList.length - 1">
<view class="mark-line"></view>
</template>
</view>
</view>
</template>
</view>
</view>
</template>
</view>
</template>
<script type='text/ecmascript-6'>
import { PAYMENT_STATUS, OP_TYPE } from '../contant'
export default {
name: '',
props: {
detail: {
type: Object,
default: () => {
return {}
}
}
},
data () {
return {
OP_TYPE,
PAYMENT_STATUS,
logList: [],
carInfo: Object.freeze([
{
label: '车型名称',
key: 'vehicleTitle'
},
{
label: '车牌号',
key: 'licensePlate'
},
{
label: '车架号',
key: 'vin'
},
{
label: '当前位置',
key: 'currentLocation',
hasLine: true
},
{
label: '客户姓名',
key: 'buyerName'
},
{
label: '联系方式',
key: 'buyerContact'
},
{
label: '提车地址',
key: 'pickupAddress'
},
{
label: '成交时间',
key: 'transactionTime',
hasLine: true
},
{
label: '保管人姓名',
key: 'custodianName'
},
{
label: '车辆保管人电话',
key: 'custodianPhone'
},
{
label: '交付专员',
key: 'handlerName'
},
{
label: '交付专员电话',
key: 'handlerPhone',
},
])
}
},
watch: {
detail: {
handler (val) {
if (val.deliveryOrderId) this.getDeliveryOrderOpLog()
},
deep: true
}
},
mounted () {
},
methods: {
async getDeliveryOrderOpLog () {
const { deliveryOrderId } = this.detail,
data = await uni.$api.usedCarApi.getDeliveryOrderOpLog({
deliveryOrderId
})
this.logList = data
console.log(data)
},
}
}
</script>
<style scoped lang='scss'>
.detail-info-box {
padding: toRpx(48);
.box {
border-radius: toRpx(16);
background: #ffffff;
margin-bottom: toRpx(24);
box-sizing: border-box;
padding: 0 toRpx(24) toRpx(24);
.tips {
margin-top: toRpx(28);
border-radius: toRpx(16);
background: #fef4e8;
box-sizing: border-box;
padding: toRpx(16) toRpx(16) toRpx(16) toRpx(56);
color: #f59619;
font-size: toRpx(26);
line-height: toRpx(36);
position: relative;
.icon {
position: absolute;
top: toRpx(16);
left: toRpx(16);
transform: rotate(180deg);
width: toRpx(32);
height: toRpx(32);
display: flex;
align-items: center;
justify-content: center;
}
}
.item {
margin-top: toRpx(28);
line-height: toRpx(40);
display: flex;
font-size: toRpx(28);
.label {
color: #999999;
width: toRpx(208);
}
.value {
width: calc(100% - #{toRpx(208)});
color: #333333;
}
.await {
color: #f59619;
}
.success {
color: #2cca74;
}
}
.line {
margin-top: toRpx(28);
width: 100%;
height: toRpx(2);
background: #f7f7f6;
}
.title {
padding-top: toRpx(24);
color: #333333;
font-size: toRpx(32);
font-weight: 500;
line-height: toRpx(48);
}
}
.log-info {
margin-bottom: 0;
.log-box {
padding-top: toRpx(32);
.log-item {
min-height: toRpx(188);
position: relative;
padding-left: toRpx(60);
.item {
margin-top: toRpx(16);
.label {
width: toRpx(168);
}
.value {
width: calc(100% - #{toRpx(168)});
word-break: break-all;
}
}
.item-mark {
position: absolute;
top: 0;
left: 0;
width: toRpx(32);
.mark-line {
height: toRpx(180);
width: toRpx(2);
background: #d6e4ff;
position: absolute;
top: toRpx(8);
left: 50%;
transform: translateX(-50%);
}
.circle {
position: relative;
width: toRpx(20);
height: toRpx(20);
background: #8eb2fb;
border-radius: 100%;
margin: toRpx(8) auto 0;
z-index: 2;
}
.first {
width: toRpx(32);
height: toRpx(32);
background: #d6e4ff;
position: relative;
&::before,
&::after {
content: '';
position: absolute;
border-radius: 100%;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
&::before {
width: toRpx(20);
height: toRpx(20);
background: #2c66f7;
}
&::after {
width: toRpx(10);
height: toRpx(10);
background: #fff;
}
}
}
}
.log-title {
color: #333333;
font-size: toRpx(32);
font-weight: 500;
line-height: toRpx(44);
}
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<view class="type-tab">
<view class="type-box">
<view
class="tab-item"
v-for="(i, index) in typeList"
:key="index"
@click="tabClick(index)"
>
<view
:class="['sprite-icon',tabClass(index)]"
:style="{
left:blockLeft
}"
></view>
<view
class="text flex"
:class="[tabIndex == index ? `active` : '']"
>
{{ i[nameKey] }}
<template v-if="hasNum">
<view class="num"> {{formatNum(i[numKey] || 0)}}</view>
</template>
</view>
</view>
</view>
<view
class="mask-box"
:style="[{height:maskHeight}]"
></view>
</view>
</template>
<script type='text/ecmascript-6'>
export default {
props: {
typeList: Array,
tabIndex: {
type: Number,
default: 0
},
nameKey: {
type: String,
default: 'tabName'
},
maskHeight: {
type: String,
default: '100vh'
},
hasNum: {
type: Boolean,
default: false
},
numKey: {
type: String,
default: 'tabNum'
}
},
name: '',
data () {
return {
firstClass: Object.freeze(['first-nav', 'second-nav']),
}
},
computed: {
blockLeft () {
let { tabIndex } = this
return `${(tabIndex * 248) - (tabIndex == 0 ? 0 : 36)}rpx`
}
},
mounted () {
},
methods: {
tabClass (index) {
let className = ''
if (this.tabIndex == index) {
className = 'active icon-'
if (index == 0) className += 'first-nav'
else className += 'second-nav'
}
return className
},
tabClick (index) {
this.$emit('update:tabIndex', index)
this.$emit('tabClick', index)
},
formatNum(num){
if(num > 99) return '99+'
else return num
}
}
}
</script>
<style scoped lang='scss'>
.type-tab {
position: relative;
height: 96rpx;
overflow: hidden;
.type-box {
position: relative;
display: flex;
width: 100%;
background-color: #eef4fe;
height: toRpx(120);
line-height: toRpx(96);
border-radius: toRpx(48) toRpx(48) 0 0;
overflow: hidden;
z-index: 0;
.tab-item {
width: toRpx(248);
text-align: center;
font-weight: 500;
font-size: toRpx(32);
color: #1f2133;
.text {
position: relative;
justify-content: center;
width: toRpx(248);
.num {
font-size: 24rpx;
margin-left: 8rpx;
}
}
.active {
position: absolute;
top: 0;
z-index: -1;
font-weight: 700;
font-size: toRpx(32);
color: #2c66f7;
&::after {
content: '';
position: absolute;
bottom: 0;
left: 50%;
transform: translateX(-50%);
width: toRpx(48);
height: toRpx(8);
background-color: #2c66f7;
border-radius: toRpx(16);
}
}
.sprite-icon {
transform: scale(.65, .73);
transform-origin: 0 0;
transition: left 0.15s;
}
}
}
.mask-box {
position: absolute;
width: 100%;
background: #fff;
left: 0;
top: toRpx(96);
border-radius: toRpx(48);
overflow: hidden;
}
}
</style>
\ No newline at end of file \ No newline at end of file
const ORDER_STATUS = {
0: '待交付',
1: '交付中',
2: '交付完成'
}
const PAYMENT_STATUS = {
0: '待支付',
1: '已结清'
}
const OP_TYPE = {
1: '创建交付工单',
2: '确认客户到店',
3: '确认客户提车'
}
module.exports = {
ORDER_STATUS,
PAYMENT_STATUS,
OP_TYPE
}
\ No newline at end of file \ No newline at end of file
<template>
<page-component
title="交付详情"
:backProp="{
show: true,
click: this.backPage
}"
>
<view class="content flex">
<view class="left">
<detail-info :detail="detail" ref="infoRef"></detail-info>
</view>
<view class="right">
<delivery-steps
:detail="detail"
@openError="openError"
@refresh="refresh"
@refreshLog="$refs.infoRef.getDeliveryOrderOpLog()"
></delivery-steps>
</view>
<NoticePopup
ref="errNotice"
title="提示"
:text="errorMessage"
type="warning"
:buttons="errButtons"
></NoticePopup>
<NoticePopup
ref="backNotice"
title="提示"
text="当前交付未完成,退出将不保留当前信息。"
type="warning"
:buttons="backButtons"
></NoticePopup>
</view>
</page-component>
</template>
<script type='text/ecmascript-6'>
import DetailInfo from './components/DetailInfo.vue'
import deliverySteps from './components/DeliverySteps/index.vue'
import NoticePopup from '@/components/NoticePopup.vue'
export default {
components: {
DetailInfo,
deliverySteps,
NoticePopup
},
name: '',
data () {
return {
detail: {},
errorMessage: '',
errButtons: Object.freeze([
{
text: '知道了',
type: 'primary'
}
]),
backButtons: Object.freeze([
{
text: '关闭',
type: 'default'
},
{
text: '确定退出',
type: 'primary',
callback: _ => {
uni.navigateBack()
}
}
])
}
},
onLoad (options) {
this.getDeliveryOrderDetail(options.id)
uni.$track.add({
eventCode: 'app_delivery_detail'
})
},
onBackPress (options) {
if (options.from === 'backbutton') {
// 物理返回按钮触发
// 阻止默认行为,即不执行页面返回
this.backPage()
return true
}
// 其他情况允许正常返回
return false
},
methods: {
async getDeliveryOrderDetail (id) {
try {
uni.showLoading({
title: '加载中',
mask: true
})
const data = await uni.$api.usedCarApi.getDeliveryOrderDetail({
id: Number(id)
})
uni.hideLoading()
if (data.orderStatus == 2) {
if (data.remark) data.remark = data.remark.replace(/<\/?br\s*\/?>|\n/g, '<br>')
if (data.confirmImages) data.imgList = data.confirmImages.split(',')
}
this.detail = data
} catch (error) {
uni.hideLoading()
this.openError(error || '请求失败')
}
},
openError (message) {
this.errorMessage = message
this.$refs.errNotice.open()
},
backPage () {
if (this.detail.orderStatus != 2) this.$refs.backNotice.open()
else uni.navigateBack()
},
refresh(id){
this.getDeliveryOrderDetail(id)
}
}
}
</script>
<style scoped lang='scss'>
.content {
width: 100vw;
height: 100vh;
box-sizing: border-box;
padding: toRpx(160) toRpx(64) toRpx(64);
box-sizing: border-box;
.left,
.right {
height: 100%;
background: #ffffff59;
backdrop-filter: blur(toRpx(16));
box-shadow: inset 0 0 toRpx(16) 0 #ffffff;
border-radius: toRpx(48);
overflow-y: auto;
}
.left {
width: 34.1vw;
}
.right {
width: 59.08vw;
margin-left: auto;
}
}
</style>
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!