Commit 4f0bc783 by 胡悦

Merge branch 'V4.56.0' of http://192.168.3.233:8090/glsx/gl_tape into V4.56.0

2 parents a32cf930 fc6890a0
......@@ -325,5 +325,17 @@ module.exports = {
/** 战败订单批量补录 */
notUpgradeOrder(data) {
return http.post({ method: 'dj.api.smartcarlife.order.notUpgrade.batchInsert', projectName: 'boutique', ...data })
},
/**改变支付订单状态 */
createPayOrder(data) {
return http.post({ method: 'dj.api.smartcarlife.payOrder.create', projectName: 'boutique', ...data })
},
/** 质保价格编辑接口 */
modifyWarrantyPrice(data) {
return http.post({
method: 'dj.api.smartcarlife.customer.warrantyCard.modifyWarrantyPrice',
projectName: 'boutique',
...data
})
}
}

2.61 MB | W: | H:

2.61 MB | W: | H:

assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -58,22 +58,15 @@
</template>
<script type='text/ecmascript-6'>
import popupmixin from './popupmixin'
export default {
mixins: [popupmixin],
name: 'CarModelList',
inject: ['userInfo'],
data () {
return {
list: [],
currentId: '',
searchList: [],
letter: 'A',
searchStatus: false,
}
},
props: {
params: Object,
data: Object,
},
mounted () {
},
methods: {
......@@ -82,7 +75,7 @@ export default {
{ cacheData } = params
this.currentId = ''
if (cacheData && cacheData.length) {
this.initCarList(cacheData)
this.initData(cacheData)
if (searchValue) this.handleSearch(searchValue)
return
}
......@@ -90,13 +83,9 @@ export default {
data = await uni.$api.popupApi.getMerchantCarBrandList({
merchantId: shopMerchantId
})
if (data && data.length) {
this.initCarList(data)
params.cacheData = data
this.$emit('update:params', params)
}
if (data && data.length) this.updateParams(params, data)
},
initCarList (carData) {
initData (carData) {
let { params: { idKey }, data: { customer } } = this,
letterList = Array.from(new Set([...carData.map((e) => e.letter)])),
carModelList = letterList.map(e => {
......
......@@ -48,22 +48,15 @@
</template>
<script type='text/ecmascript-6'>
import popupmixin from './popupmixin'
export default {
mixins: [popupmixin],
name: 'CouponList',
inject: ['userInfo'],
data () {
return {
list: [],
currentId: '',
searchList: [],
searchStatus: false,
customerCouponList: []
}
},
props: {
params: Object,
data: Object,
},
watch: {
'data.customer.customerPhone': {
handler (val) {
......@@ -81,7 +74,7 @@ export default {
{ cacheData } = params
this.currentId = ''
if (cacheData && cacheData.length) {
this.initCouponList(cacheData)
this.initData(cacheData)
if (searchValue) this.handleSearch(searchValue)
return
}
......@@ -91,13 +84,9 @@ export default {
yqMerchantId: merchantId,
orderByType: 9
})
if (data && data.length) {
this.initCouponList(data)
params.cacheData = data
this.$emit('update:params', params)
}
if (data && data.length) this.updateParams(params, data)
},
initCouponList (data) {
initData (data) {
let couponTypeList = Array.from(new Set([...data.map((e) => e.couponInfo.couponType)])),
couponList = couponTypeList.map((e, index) => {
let list = [];
......@@ -232,7 +221,8 @@ export default {
}
}
.disabled {
opacity: 0.5;
border: 2rpx solid #dce0e666;
color: #3333331a;
}
.active {
border-color: #2c66f7;
......
......@@ -14,19 +14,14 @@
</template>
<script type='text/ecmascript-6'>
import popupmixin from './popupmixin'
export default {
mixins: [popupmixin],
name: 'DiversionMerchant',
inject: ['userInfo'],
data () {
return {
list: [],
currentId: ''
}
},
props: {
params: Object,
data: Object,
},
mounted () {
},
methods: {
......@@ -35,19 +30,17 @@ export default {
{ cacheData } = params
this.currentId = ''
if (cacheData && cacheData.length) {
this.$emit('onComplete')
this.list = cacheData
this.initData(cacheData)
return
}
const data = await uni.$api.popupApi.getDiversionMerchantRef({
merchantId: shopMerchantId
})
if (data && data.length) {
this.$emit('onComplete')
this.list = data
params.cacheData = data
this.$emit('update:params', params)
}
if (data && data.length) this.updateParams(params, data)
},
initData (data) {
this.list = data
this.$emit('onComplete')
},
choose (i) {
this.currentId = i.subMerchantId
......
......@@ -14,19 +14,15 @@
</template>
<script type='text/ecmascript-6'>
import popupmixin from './popupmixin'
export default {
mixins: [popupmixin],
name: 'EmployeeList',
inject: ['userInfo'],
data () {
return {
list: [],
currentId: ''
}
},
props: {
params: Object,
data: Object
},
mounted () {
},
methods: {
......@@ -35,8 +31,7 @@ export default {
{ cacheData } = params
this.currentId = ''
if (!search && cacheData && cacheData.length) {
this.$emit('onComplete')
this.list = cacheData
this.initData(cacheData)
return
}
const { shopMerchantId, sceneType, merchantId } = userInfo,
......@@ -45,12 +40,11 @@ export default {
sceneList: params.idKey == 'sellerUserId' ? '' : [sceneType],
name: searchValue
})
if (data && data.length) {
this.$emit('onComplete')
this.list = data
params.cacheData = data
this.$emit('update:params', params)
}
if (data && data.length) this.updateParams(params, data)
},
initData(data){
this.list = data
this.$emit('onComplete')
},
handleSearch (searchValue) {
this.list = []
......
......@@ -22,23 +22,14 @@
</template>
<script type='text/ecmascript-6'>
import popupmixin from './popupmixin'
export default {
mixins: [popupmixin],
name: 'GoodsList',
inject: ['userInfo', 'baseConfigData'],
data () {
return {
list: [],
currentIds: [],
chooseList: [],
searchStatus: false,
searchList: [],
}
},
props: {
params: Object,
data: [Object, Array],
dataKey: String
},
mounted () {
},
methods: {
......@@ -48,20 +39,16 @@ export default {
this.currentIds = []
this.chooseList = []
if (cacheData && cacheData.length) {
this.list = this.initGoodsList(cacheData)
this.initData(cacheData)
if (searchValue) this.handleSearch(searchValue)
return
}
const { shopMerchantId, sceneType } = userInfo,
response = await uni.$api.popupApi.getGoodsList({
data = await uni.$api.popupApi.getGoodsList({
merchantId: shopMerchantId,
sceneType
})
if (response && response.length) {
this.list = this.initGoodsList(response)
params.cacheData = response
this.$emit('update:params', params)
}
if (data && data.length) this.updateParams(params, data)
},
handleSearch (searchValue) {
if (!searchValue) this.searchStatus = false
......@@ -80,9 +67,9 @@ export default {
this.searchStatus = true
}
},
initGoodsList (goodsData) {
initData (goodsData) {
let { goodsType } = this.params,
{ data ,dataKey } = this,
{ data, dataKey } = this,
arr = []
goodsData.map(val => {
if (val.goodsFlag == 1) {
......@@ -100,7 +87,7 @@ export default {
this.chooseList.push(e)
})
this.$emit('onComplete')
return arr
this.list = arr
},
choose (i) {
let { goodsId } = i.goods,
......
<template>
<view class="goods-list">
<!-- <template v-if="list.length"> -->
<template v-for="(item, index) in (searchStatus ? searchList : list)">
<view
:key="index"
@click="choose(item)"
:class="['item',{active: checkActive(item)}]"
>
<view class="title flex">
<view class="icon">
<uni-icons
type="circle"
:size="16"
color="#8C8C8C"
class="uni-icons"
></uni-icons>
<view class="sprite-icon icon-notice-success"></view>
</view>
{{item.packageGoods.packageAlias||item.packageGoods.packageName}}
<text class="price">¥{{item.packageGoods.upgradePrice}}</text>
</view>
<view class="package-list">
<template v-for="(i,ind) in item.packageGoods.goodsList">
<view
class="package-item flex"
:key="ind"
>
<view class="name">{{i.goodsAlias||i.upgradeGoodsAlias||i.upgradeGoodsName}}</view>
<view class="price">¥{{i.sellPrice}}</view>
<template v-if="params.loadComplete">
<template v-if="listData.length">
<template v-for="(item, index) in listData">
<view
:key="index"
@click="choose(item)"
:class="['item',{active: checkActive(item)}]"
>
<view class="title flex">
<view class="icon">
<uni-icons
type="circle"
:size="16"
color="#8C8C8C"
class="uni-icons"
></uni-icons>
<view class="sprite-icon icon-notice-success"></view>
</view>
{{item.packageGoods.packageAlias||item.packageGoods.packageName}}
<text class="price">¥{{item.packageGoods.upgradePrice}}</text>
</view>
<view class="package-list">
<template v-for="(i,ind) in item.packageGoods.goodsList">
<view
class="package-item flex"
:key="ind"
>
<view class="name">{{i.goodsAlias||i.upgradeGoodsAlias||i.upgradeGoodsName}}</view>
<view class="price">¥{{i.sellPrice}}</view>
</view>
</template>
</view>
</template>
</view>
</view>
</view>
</template>
</template>
</template>
<!-- </template> -->
</view>
</template>
<script type='text/ecmascript-6'>
import NP from 'number-precision'
import popupmixin from './popupmixin'
export default {
mixins: [popupmixin],
name: 'PackageList',
inject: ['userInfo', 'baseConfigData'],
data () {
return {
list: [],
currentIds: [],
chooseList: [],
searchStatus: false,
searchList: [],
}
},
props: {
params: Object,
data: [Object, Array],
dataKey: String
},
mounted () {
},
methods: {
......@@ -65,20 +58,16 @@ export default {
this.currentIds = []
this.chooseList = []
if (cacheData && cacheData.length) {
this.list = this.initGoodsList(cacheData)
this.initData(cacheData)
if (searchValue) this.handleSearch(searchValue)
return
}
const { shopMerchantId, sceneType } = userInfo,
response = await uni.$api.popupApi.getGoodsList({
data = await uni.$api.popupApi.getGoodsList({
merchantId: shopMerchantId,
sceneType
})
if (response && response.length) {
this.list = this.initGoodsList(response)
params.cacheData = response
this.$emit('update:params', params)
}
if (data && data.length) this.updateParams(params, data)
},
handleSearch (searchValue) {
if (!searchValue) this.searchStatus = false
......@@ -97,7 +86,7 @@ export default {
this.searchStatus = true
}
},
initGoodsList (goodsData) {
initData (goodsData) {
let { data, dataKey } = this,
arr = []
goodsData.map(val => {
......@@ -115,7 +104,7 @@ export default {
this.chooseList.push(e)
})
this.$emit('onComplete')
return arr
this.list = arr
},
choose (i) {
let { packageCode } = i.packageGoods,
......
<template>
<view class="goods-list">
<template v-for="(i, index) in (searchStatus ? searchList : list)">
<view
:key="index"
@click.stop="choose(i ,index)"
:class="['item',{active: checkActive(i) || i.active},{single:i.goodsFlag == 1}]"
>
<template v-if="i.goodsFlag == 1">
<view class="flex">
<view class="icon">
<uni-icons
type="circle"
:size="16"
color="#8C8C8C"
class="uni-icons"
></uni-icons>
<view class="sprite-icon icon-notice-success"></view>
</view>
<text class="goods-name text-hide">
{{replaceItemText(i.goods,'goodsAlias') ||replaceItemText(i.goods,'upgradeGoodsName') || replaceItemText(i.goodsInfo,'goodsName')}}
</text>
<template v-if="i.goods.merchantGoodsPosition && (i.goods.goodsInfo.goodsType == 1 || i.goods.goodsInfo.goodsType == baseConfigData.selfBuildFilmType)">
<text>「{{ i.goods.positionStr}}」</text>
<template v-if="params.loadComplete">
<template v-if="listData.length">
<template v-for="(i, index) in listData">
<view
:key="index"
@click.stop="choose(i ,index)"
:class="['item',{active: checkActive(i) || i.active},{single:i.goodsFlag == 1}]"
>
<template v-if="i.goodsFlag == 1">
<view class="flex">
<view class="icon">
<uni-icons
type="circle"
:size="16"
color="#8C8C8C"
class="uni-icons"
></uni-icons>
<view class="sprite-icon icon-notice-success"></view>
</view>
<text class="goods-name text-hide">
{{replaceItemText(i.goods,'goodsAlias') ||replaceItemText(i.goods,'upgradeGoodsName') || replaceItemText(i.goodsInfo,'goodsName')}}
</text>
<template v-if="i.goods.merchantGoodsPosition && (i.goods.goodsInfo.goodsType == 1 || i.goods.goodsInfo.goodsType == baseConfigData.selfBuildFilmType)">
<text>「{{ i.goods.positionStr}}」</text>
</template>
<text class="price">¥{{i.goods.price}}</text>
</view>
</template>
<text class="price">¥{{i.goods.price}}</text>
</view>
</template>
<template v-if="i.goodsFlag == 2">
<view class="title flex">
<view class="icon">
<uni-icons
type="circle"
:size="16"
color="#8C8C8C"
class="uni-icons"
></uni-icons>
<view class="sprite-icon icon-notice-success"></view>
</view>
{{i.multipleSpecificationsGoods.baseGoodsName}}
<template v-if="i.multipleSpecificationsGoods.goods && i.multipleSpecificationsGoods.goods.sellPrice">
<text class="price">¥{{i.multipleSpecificationsGoods.goods.sellPrice}}</text>
</template>
</view>
<template v-if="i.multipleSpecificationsGoods.specificationList && i.multipleSpecificationsGoods.specificationList.length">
<view
class="package-list"
:key="i.key"
>
<template v-for="(specific, specificIndex) in i.multipleSpecificationsGoods.specificationList">
<template v-if="i.goodsFlag == 2">
<view class="title flex">
<view class="icon">
<uni-icons
type="circle"
:size="16"
color="#8C8C8C"
class="uni-icons"
></uni-icons>
<view class="sprite-icon icon-notice-success"></view>
</view>
{{i.multipleSpecificationsGoods.baseGoodsName}}
<template v-if="i.multipleSpecificationsGoods.goods && i.multipleSpecificationsGoods.goods.sellPrice">
<text class="price">¥{{i.multipleSpecificationsGoods.goods.sellPrice}}</text>
</template>
</view>
<template v-if="i.multipleSpecificationsGoods.specificationList && i.multipleSpecificationsGoods.specificationList.length">
<view
class="package-list"
:key="i.key"
>
<template v-for="(specific, specificIndex) in i.multipleSpecificationsGoods.specificationList">
<picker
@click.stop
@change="handlePickerChange($event, {
<picker
@click.stop
@change="handlePickerChange($event, {
item:specific,
list:specific.specificationSelectValueList,
parent: i,
index
} )"
:range="specific.specificationSelectValueList"
:key="`key_${index}_${specificIndex}`"
>
<view class="package-item flex">
<view class="label">
{{specific.specificationName}}
</view>
<view class="value">
<template v-if="specific.value">
{{specific.value}}
</template>
<text
class="placeholder"
v-else
>请选择</text>
</view>
</view>
</picker>
:range="specific.specificationSelectValueList"
:key="`key_${index}_${specificIndex}`"
>
<view class="package-item flex">
<view class="label">
{{specific.specificationName}}
</view>
<view class="value flex">
<template v-if="specific.value">
{{specific.value}}
</template>
<text
class="placeholder flex"
v-else
>
请选择
</text>
<uni-icons
type="right"
size="14"
class="arrow"
/>
</view>
</view>
</picker>
</template>
</view>
</template>
</view>
</template>
</template>
</view>
</template>
</view>
</template>
</template>
</view>
</template>
<script type='text/ecmascript-6'>
import popupmixin from './popupmixin'
export default {
mixins: [popupmixin],
name: 'SkuGoodsList',
inject: ['userInfo', 'baseConfigData'],
data () {
return {
list: [],
currentIds: [],
chooseList: [],
searchStatus: false,
searchList: [],
}
},
props: {
params: Object,
data: [Object, Array],
dataKey: String
},
mounted () {
},
methods: {
......@@ -112,20 +114,16 @@ export default {
this.currentIds = []
this.chooseList = []
if (cacheData && cacheData.length) {
this.list = this.initGoodsList(cacheData)
this.initData(cacheData)
if (searchValue) this.handleSearch(searchValue)
return
}
const { shopMerchantId, sceneType } = userInfo,
response = await uni.$api.popupApi.getGoodsList({
data = await uni.$api.popupApi.getGoodsList({
merchantId: shopMerchantId,
sceneType
})
if (response && response.length) {
this.list = this.initGoodsList(response)
params.cacheData = response
this.$emit('update:params', params)
}
if (data && data.length) this.updateParams(params, data)
},
handleSearch (searchValue) {
if (!searchValue) this.searchStatus = false
......@@ -135,7 +133,12 @@ export default {
arr = []
goodsList.map(c => {
let name = ''
if (c.goodsFlag == 3 && c.packageGoods) name = c.packageGoods.packageName || c.packageGoods.packageAlias
if (c.goodsFlag == 1 && c.goods) {
name = c.goods.goodsAlias || c.goods.upgradeGoodsName || c.goods.goodsName || ''
}
if (c.goodsFlag == 2 && c.multipleSpecificationsGoods) {
name = c.multipleSpecificationsGoods.baseGoodsName
}
if (name.indexOf(searchValue) != -1) {
arr.push(c)
}
......@@ -144,7 +147,7 @@ export default {
this.searchStatus = true
}
},
initGoodsList (goodsData) {
initData (goodsData) {
let { data, dataKey } = this,
arr = []
goodsData.map((val) => {
......@@ -183,8 +186,8 @@ export default {
this.chooseList.push(e)
}
})
this.list = arr
this.$emit('onComplete')
return arr
},
async choose (i, index) {
if (i.goodsFlag == 2) {
......@@ -462,6 +465,9 @@ export default {
margin-left: auto;
max-width: 50%;
flex-shrink: 0;
.arrow {
margin-left: 4rpx;
}
}
&:last-of-type {
border: none;
......
export default {
inject: ['userInfo', 'baseConfigData'],
data () {
return {
list: [],
searchStatus: false,
searchList: [],
chooseList: [],
currentId: '',
currentIds: [],
}
},
props: {
params: Object,
data: [Object, Array],
dataKey: String
},
computed: {
listData () {
return this.searchStatus ? this.searchList : this.list
},
noData () {
return !this.listData.length
}
},
watch: {
noData: {
handler (val) {
let { params } = this
params.noData = val
this.updateParams(params)
},
deep: true
}
},
methods: {
updateParams (params, data) {
if (data) {
this.initData && this.initData(data)
params.cacheData = data
}
this.$emit('update:params', params)
}
}
}
\ No newline at end of file
......@@ -21,39 +21,61 @@ const componentConfig = {
name: 'EmployeeList',
title: '销售顾问/录单员',
placeholder: '请输入姓名',
idKey: 'userId'
idKey: 'userId',
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
1: {
name: 'EmployeeList',
title: '交付专员',
placeholder: '请输入姓名',
nullTips: '请选择交付专员',
idKey: 'deliveryUserId'
idKey: 'deliveryUserId',
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
2: {
name: 'DiversionMerchant',
title: '二级流量方',
hideSearch: true,
idKey: 'subShopMerchantId'
idKey: 'subShopMerchantId',
cacheData: [],
loadComplete: false
},
3: {
name: 'EmployeeList',
title: '转化人员',
placeholder: '请输入姓名',
idKey: 'sellerUserId',
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
4: {
name: 'CarModelList',
title: '选择车型',
placeholder: '查找',
idKey: 'carSeriesId'
idKey: 'carSeriesId',
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
5: {
name: 'CouponList',
title: '选择礼券',
placeholder: '查找',
idKey: 'customerCouponCode',
nullTips: '优惠券不能为空'
nullTips: '优惠券不能为空',
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
6: {
name: 'GoodsList',
......@@ -61,7 +83,11 @@ const componentConfig = {
placeholder: '请输入名称',
idKey: 'goodsId',
nullTips: '请勾选商品',
goodsType: [1]//前档
goodsType: [1],//前档
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
7: {
name: 'GoodsList',
......@@ -69,7 +95,11 @@ const componentConfig = {
placeholder: '请输入名称',
idKey: 'goodsId',
nullTips: '请勾选商品',
goodsType: [2] // 前侧窗玻璃
goodsType: [2], // 前侧窗玻璃
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
8: {
name: 'GoodsList',
......@@ -77,7 +107,11 @@ const componentConfig = {
placeholder: '请输入名称',
idKey: 'goodsId',
nullTips: '请勾选商品',
goodsType: [3] // 后侧窗玻璃
goodsType: [3], // 后侧窗玻璃
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
9: {
name: 'GoodsList',
......@@ -85,7 +119,11 @@ const componentConfig = {
placeholder: '请输入名称',
idKey: 'goodsId',
nullTips: '请勾选商品',
goodsType: [4] // 后档
goodsType: [4],// 后档
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
10: {
name: 'GoodsList',
......@@ -93,26 +131,38 @@ const componentConfig = {
placeholder: '请输入名称',
idKey: 'goodsId',
nullTips: '请勾选商品',
goodsType: [5, 6, 7] // 天窗
goodsType: [5, 6, 7],// 天窗
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
11: {
name: 'PackageList',
title: '选择套餐',
placeholder: '查找',
nullTips: '请勾选套餐',
idKey: 'packageCode'
idKey: 'packageCode',
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
12: {
name: 'SkuGoodsList',
title: '选择商品',
nullTips: '请勾选商品',
placeholder: '查找',
cacheData: [],
loadComplete: false,
searchValue: '',
noData: false
},
13: {
name: 'DateTime',
title: '选择时间',
hideSearch: true,
loadComplete: false
}
}
export default { componentConfig }
\ No newline at end of file
......@@ -19,14 +19,14 @@
></uni-icons>
</view>
</view>
<template v-if="!componentObject.hideSearch">
<template v-if="!componentObject[popupType].hideSearch">
<view class="popup-search">
<input
class="input"
type="text"
:placeholder="componentObject.placeholder || '请输入'"
:placeholder="componentObject[popupType].placeholder || '请输入'"
placeholder-class="placeholder"
v-model="componentObject.searchValue"
v-model="componentObject[popupType].searchValue"
confirm-type="search"
@confirm="handleSearch"
>
......@@ -37,29 +37,33 @@
<uni-icons
type="closeempty"
size="16"
v-if="componentObject.searchValue"
v-if="componentObject[popupType].searchValue"
></uni-icons>
</view>
</view>
</template>
<view :class="['popup-body',{ 'hide-search' :componentObject.hideSearch}]">
<view :class="['popup-body',{ 'hide-search' :componentObject[popupType].hideSearch}]">
<scroll-view
scroll-y
:class="['popup-scroll-view',{show:loadComplete}]"
:class="['popup-scroll-view',{show:componentObject[popupType].loadComplete}]"
>
<component
:is="componentObject.name"
:params.sync="componentObject"
:is="componentObject[popupType].name"
:params.sync="componentObject[popupType]"
:data="data"
:dataKey="dataKey"
ref="componentRef"
@choose="chooseContent = $event"
@openSkuPopup="openSkuPopup"
@onComplete="loadComplete = true"
@onComplete="componentObject[popupType].loadComplete = true"
@updateCacheData="updateCacheData"
></component>
<template v-if="componentObject[popupType].noData">
<view class="nothing flex">暂无数据</view>
</template>
</scroll-view>
<image
v-if="!loadComplete"
v-if="!componentObject[popupType].loadComplete"
class="loading"
src="../../assets/images/common/loadding.gif"
/>
......@@ -127,14 +131,12 @@ export default {
return {
position: 'bottom',
chooseContent: null,
componentObject: null,
loadComplete: false
componentObject: config.componentConfig,
}
},
watch: {
popupType: {
handler (val) {
this.componentObject = config.componentConfig[this.popupType]
if (val == 11 || val == 12) this.position = 'right'
else this.position = 'bottom'
},
......@@ -143,9 +145,15 @@ export default {
},
externalData: {
handler (val) {
if (val && this.componentObject) this.componentObject.cacheData = val
if (val) {
}
if (val && val.length && this.componentObject[this.popupType]) {
this.componentObject[this.popupType].cacheData = val
}
},
deep: true,
immediate: true
}
},
computed: {
......@@ -170,6 +178,7 @@ export default {
this.initPopupData()
},
cancel () {
console.log()
this.$refs.popup.close()
this.$emit('cancel')
},
......@@ -180,7 +189,7 @@ export default {
initPopupData () {
let componentRef = this.componentRef()
if (!componentRef) setTimeout(this.initPopupData, .1e3)
else componentRef.getList && componentRef.getList(this.componentObject.searchValue)
else componentRef.getList && componentRef.getList(this.componentObject[this.popupType].searchValue)
},
handleSearch () {
let componentRef = this.componentRef()
......@@ -188,7 +197,7 @@ export default {
title: '请稍后再试',
icon: 'none'
})
else componentRef.handleSearch(this.componentObject.searchValue)
else componentRef.handleSearch(this.componentObject[this.popupType].searchValue)
},
confirm () {
try {
......@@ -197,14 +206,14 @@ export default {
chooseContent = this.componentRef().getResult()
}
if (chooseContent) {
if(Array.isArray(chooseContent) && !chooseContent.length && componentObject.nullTips) throw componentObject.nullTips
if (Array.isArray(chooseContent) && !chooseContent.length && componentObject[popupType].nullTips) throw componentObject.nullTips
this.$emit('onConfirm', {
chooseContent,
popupType
})
this.$refs.popup.close()
} else {
if (componentObject.nullTips) throw componentObject.nullTips
if (componentObject[popupType].nullTips) throw componentObject[popupType].nullTips
}
} catch (error) {
uni.showToast({
......@@ -224,9 +233,9 @@ export default {
})
},
clear () {
this.componentObject.searchValue = ''
this.componentObject[this.popupType].searchValue = ''
this.handleSearch()
}
},
}
}
</script>
......@@ -335,6 +344,15 @@ export default {
background: linear-gradient(0deg, #2c66f7 0%, #48a6ff 100%);
}
}
.nothing{
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
z-index: 2;
justify-content: center;
}
}
.right-box {
width: 46vw;
......
......@@ -72,17 +72,33 @@ export default {
}
},
methods: {
open(callback) {
this.$refs.publishPopup.open()
open() {
this.$nextTick(() => {
console.log(this.$refs)
if (this.$refs.publishPopup) {
this.$refs.publishPopup.open()
}
})
return new Promise((resolve, reject) => {
this.resolve = resolve
this.reject = reject
})
},
change(e) {
this.show = e.show
},
closePopup() {
this.$refs.publishPopup.close()
if (this.reject) {
this.reject()
}
this.$emit('close')
},
confirm() {
if (this.resolve) {
this.$refs.publishPopup.close()
this.resolve()
}
this.$emit('confirm')
}
}
......
......@@ -84,9 +84,9 @@
</view>
</view>
<!-- 施工技师 -->
<view class="construction-staff flex" v-if="orderCardDetail.constructionFlag == 'Y'">
<view class="construction-staff flex" v-if="orderCardDetail && orderCardDetail.constructionFlag == 'Y'">
<view class="staff-label">施工技师</view>
<view class="staff-value">111</view>
<view class="staff-value">{{ orderCardDetail.technicianName }}</view>
</view>
<PublishPopup ref="recordOrderPopup" popupClass="recordOrderPopup" type="center" :showClose="true" title="请选择录单入口">
<template #content>
......@@ -103,7 +103,7 @@
<view class="sprite-icon icon-expiration"></view>
失效客户
</view>
<view class="modalbox cancle" :class="selectType == 4 ? 'act' : ''" @click.stop="changeType(4)">
<view class="modalbox cancle" v-if="orderCardDetail.constructionFlag !== 'Y' && orderCardDetail.selectPayType !== 1 && orderCardDetail.selectPayType !== 3 && orderCardDetail.selectPayType !== 4 && orderCardDetail.status !== 9" :class="selectType == 4 ? 'act' : ''" @click.stop="changeType(4)">
<view class="sprite-icon icon-revoke"></view>
撤销工单
</view>
......@@ -136,9 +136,16 @@ export default {
components: {
PublishPopup
},
computed: {
payType() {
return order_mixins.data.payType || {}
},
status() {
return order_mixins.data.status || {}
}
},
data() {
return {
...order_mixins.data,
IMG_URL: 'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/',
isSettingExpiredTraffic: false, // 是否启用流量失效
selectType: 1,
......@@ -181,9 +188,13 @@ export default {
label: '工单时间',
key: 'orderTime'
}
]
],
localUserInfo: null
}
},
mounted() {
this.localUserInfo = uni.$storage.get('userInfo')
},
methods: {
// 查看全部商品
showAllGoodsList(e) {
......@@ -198,18 +209,18 @@ export default {
// failureFlag 订单失效状态(Y:已失效,N:未失效)
// console.log(e.currentTarget.dataset)
// return
const userInfo = uni.$storage.get('userInfo')
if (userInfo.merchantAccountList && userInfo.merchantAccountList.length) {
if (this.localUserInfo.merchantAccountList && this.localUserInfo.merchantAccountList.length) {
try {
userInfo.merchantAccountList.map(e => {
this.localUserInfo.merchantAccountList.map(e => {
if (e == 6 || e == 8) throw true
})
} catch (error) {
userInfo.merchantType = error
this.localUserInfo.merchantType = error
}
}
userInfo.isMake = !(userInfo?.isSuper || userInfo?.loginRole == 3 || userInfo?.loginRole == 5 || userInfo?.loginRole == 6 || userInfo?.loginRole == 7)
let { userType, isSuper, merchantType, isMake } = userInfo
this.localUserInfo.isMake = !(this.localUserInfo?.isSuper || this.localUserInfo?.loginRole == 3 || this.localUserInfo?.loginRole == 5 || this.localUserInfo?.loginRole == 6 || this.localUserInfo?.loginRole == 7)
let { userType, isSuper, merchantType, isMake } = this.localUserInfo
console.log(item)
if (name == 'CreateOrder' || name == 'PremiumUpgrade') {
if (merchantType && !isSuper && isMake) {
......@@ -246,16 +257,20 @@ export default {
if ((!this.isSettingExpiredTraffic || scan) && this.selectType == 3) {
this.selectType = 1
}
this.$refs.recordOrderPopup.open()
this.$nextTick(() => {
if (this.$refs.recordOrderPopup) {
this.$refs.recordOrderPopup.open()
} else {
console.error('recordOrderPopup ref is not available')
}
})
},
// 获取轻改录单配置是否启用流量失效
getCreateOrderSetting() {
let userInfo = uni.$storage.get('userInfo')
let merchantType = userInfo?.merchantAccountList.includes('6') || userInfo?.merchantAccountList.includes('8')
if (merchantType && !userInfo?.isSuper && userInfo?.loginRole != 3 && userInfo?.userType == 2 && userInfo?.shopMerchantId) {
uni.$api.boutiqueApi.getServiceBaseInfo({ merchantId: userInfo?.shopMerchantId }).then(res => {
let merchantType = this.localUserInfo?.merchantAccountList.includes('6') || this.localUserInfo?.merchantAccountList.includes('8')
if (merchantType && !this.localUserInfo?.isSuper && this.localUserInfo?.loginRole != 3 && this.localUserInfo?.userType == 2 && this.localUserInfo?.shopMerchantId) {
uni.$api.boutiqueApi.getServiceBaseInfo({ merchantId: this.localUserInfo?.shopMerchantId }).then(res => {
this.isSettingExpiredTraffic = res?.data?.trafficExpireFlag == 'Y'
})
}
......@@ -270,8 +285,21 @@ export default {
console.log(await this.inspectionOfProhibitionBill())
if (await this.inspectionOfProhibitionBill()) return
this.$emit('jump', 'CreateOrder', { paramsData: this.orderCardDetail, type: 'createWithPay' })
} else {
} else if (this.selectType == 2) {
this.$emit('jump', 'DefeatOrder', { paramsData: this.orderCardDetail, type: 'createWithPay' })
} else if (this.selectType == 4) {
let _this = this
uni.$api.boutiqueApi
.revokeOrder({
orderCode: this.orderCardDetail.orderCode
})
.then(data => {
uni.showToast({
title: '操作成功',
icon: 'success'
})
this.$emit('refresh')
})
}
},
cancelSelection() {
......
......@@ -64,11 +64,11 @@
</view>
</view>
</view>
<view class="flex align-center py-8">
<view class="flex align-center py-8" v-if="orderInfo">
<view class="sprite-icon icon-coupon fs-14"></view>
<text class="fs-14 coupon-name">{{ orderInfo.couponName || '' }}{{ orderInfo.customerCoupon.customerCouponCode || '' }}({{ orderInfo.customerCoupon.employeeName || '' }})</text>
</view>
<view class="flex justify-end align-center">
<view class="flex justify-end align-center" v-if="orderInfo">
<text class="good-total-lable">商品总金额:</text>
<text class="good-total-value">
<text class="unit">¥</text>
......@@ -183,7 +183,7 @@
<uni-calendar class="calendar" :showMonth="false" @change="calendarChange" />
</template>
</PublishPopup>
<!-- <OrderPopup :orderType="orderInfo.selectPayType" v-if="showPopup" :show="showPopup" :qrCode="orderInfo.payOrder.outTradeNo || ''" :price="orderInfo.total_price" :orderCode="orderInfo.orderCode" /> -->
<order-popup ref="openDate" popupType="13" @onConfirm="confirmDate" />
<PublishPopup ref="payPopup" popupClass="payPopup" type="center" :isShowFooter="false">
<template #header>
<view class="popup-top">
......@@ -194,7 +194,7 @@
</view>
</template>
<template #content>
<view class="pos-popup">
<view class="pos-popup" v-if="orderInfo">
<view class="price">¥{{ orderInfo.total_price }}</view>
<image class="qrcode" :src="orderInfo.selectPayType == 1 ? wxqrcode : posQrCode"></image>
<view class="level-1-tips">{{ orderInfo.selectPayType == 1 ? '请让客户打开微信扫描上方付款码进行支付' : '请使用POS机扫描此码,再向客户收款' }}</view>
......@@ -223,6 +223,21 @@ export default {
PublishPopup,
OrderPopup
},
watch: {
transmissionOfData: {
handler(newVal) {
if (newVal) {
console.log('接收到的交易数据:', newVal)
console.log(this.transmissionOfData, 'this.transmissionOfData')
this.getPositionList()
// "this.transmissionOfData.orderCode"
this.getDetail(this.transmissionOfData.orderCode)
this.successDate = dayjs().format('YYYY-MM-DD HH:mm:ss')
}
},
immediate: true
}
},
data() {
return {
...order_mixins.data,
......@@ -237,10 +252,10 @@ export default {
}
},
mounted() {
this.getPositionList()
// 250819144103724
this.getDetail(this.transmissionOfData.orderCode)
this.successDate = dayjs().format('YYYY-MM-DD HH:mm:ss')
// this.getPositionList()
// // "this.transmissionOfData.orderCode"
// this.getDetail('250826172036851')
// this.successDate = dayjs().format('YYYY-MM-DD HH:mm:ss')
},
methods: {
replaceItemText(item) {
......@@ -248,7 +263,7 @@ export default {
return item ? item.replace(reg, ' ') : ''
},
async getDetail(orderCode) {
// console.log(orderCode)
console.log(orderCode)
let _this = this
uni.$api.boutiqueApi
.getPackageGoodsDetail({
......@@ -257,9 +272,7 @@ export default {
.then(data => {
if (data.payOrder && data.payOrder.payStatus == 2) {
if (this.time) clearInterval(this.time)
// wx.$router.redirectTo('orderDetail', {
// orderCode
// })
this.$emit('jump', 'OrderDetail', data)
return
}
let couponName = data.customerCoupon ? data.customerCoupon.couponName : ''
......@@ -310,6 +323,7 @@ export default {
data.carType = `${data.customer.carBrand || ''}-${data.customer.carChildsBrandName || ''}-${data.customer.carSeriesName || ''}`
}
_this.orderInfo = data
console.log('data', _this.orderInfo)
_this.flag = true
_this.warrantyCardList = warrantyCardList
// 校验是否显示二级流量方
......@@ -485,7 +499,7 @@ export default {
this.createPayOrder()
},
openDate() {
this.$refs.test.open()
this.$refs.openDate.open()
},
customizeDate() {
console.log(this.$refs.calendarPopup, 'this.$refs.calendarPopup')
......@@ -521,6 +535,7 @@ export default {
uni.$api.boutiqueApi.createPayOrder(obj).then(data => {
if (data) {
console.log(`类型为:${selectPayType}`)
console.log(this.orderInfo)
if (selectPayType == 3 || selectPayType == 1) {
this.orderInfo.payOrder.outTradeNo = data.outTradeNo
let size = 0
......@@ -654,6 +669,7 @@ export default {
height: 100%;
.scroll-y {
border-radius: toRpx(16);
height: calc(100% - #{toRpx(296)});
overflow-y: scroll;
&::-webkit-scrollbar {
......
......@@ -237,7 +237,7 @@ export default {
const cell = this.formList[2].find(item => item.value == 'payeeType')
if (cell) {
cell.current = 0
cell.radioList[1].disabled = true // 禁用4s店收款
cell.radioList[1].disabled = true // 禁用4s店收款
}
this.djPayList = [
{
......@@ -464,7 +464,7 @@ export default {
baseGoodsId: e.multipleSpecificationsGoods.goods.baseGoodsId,
totalPrice: Number(e.multipleSpecificationsGoods.goods.sellPrice),
number: e.multipleSpecificationsGoods.number,
merchantGoodsId: e.multipleSpecificationsGoods.goods.id || e.multipleSpecificationsGoods.goods.merchantGoodsId,
merchantGoodsId: e.multipleSpecificationsGoods.goods.id || e.multipleSpecificationsGoods.goods.merchantGoodsId
})
}
})
......@@ -486,7 +486,7 @@ export default {
title: '保存成功',
icon: 'success'
})
this.$emit('jump', 'ConfirmOrder', res.data)
this.$emit('jump', orderCreateType == 'supplementOrder' ? 'OrderDetail' : 'ConfirmOrder', res)
}
},
// 计算所有产品的总价
......
......@@ -47,7 +47,7 @@
:value="orderObj[i.value]"
:range="i.range"
:range-key="i.rangeKey"
@change="orderObj[i.value] = $event.detail.value"
@change="changePicker($event,i)"
:disabled="filterDisabled(isEditReport)"
>
{{i.range[orderObj[i.value]][i.rangeKey] || ''}}
......@@ -211,7 +211,8 @@ export default {
range: [
{ id: 'N', name: '否' },
{ id: 'Y', name: '是' }
]
],
submitValue: 'onBreak'
},
{
label: '个人成交总金额',
......@@ -496,14 +497,36 @@ export default {
handleBlur (e, i) {
let { value } = e.detail
if (value) {
let { orderObj, userInfo } = this
let key = i.value,
numbers = value.match(/\d+/g)
numbers = numbers ? numbers.join('') : ''
if (numbers.length > 1) numbers = numbers.replace(/^0+/, '')
this.orderObj[key] = Math.min(Math.max(Number(numbers), 0), 100).toString()
this.dateKey = Date.now()
if (
this.isNotEmpty(orderObj.recordStaffCount) &&
this.isNotEmpty(value) &&
orderObj.recordStaffCount != value &&
orderObj.lastStaffUuid &&
userInfo.uuid != orderObj.lastStaffUuid
) uni.showModal({
title: '预警提示',
content: `今日驻店人数与 ${orderObj.lastStaffName} 提交不一致,再次确认!不一致提交日报时,今日驻店人数将被清空。`,
showCancel: false,
confirmText: '知道了',
confirmColor: '#347BFF'
})
}
},
isNotEmpty (value) {
return (
value !== null &&
value !== undefined &&
value !== '' &&
!(Array.isArray(value) && value.length === 0)
)
},
handleCarInputBlur (e, i, item) {
let { value } = e.detail
if (value) {
......@@ -516,37 +539,44 @@ export default {
}
},
async submit () {
uni.showLoading({
title: '提交中',
mask: true
})
try {
let { orderObj, carBandList } = this
let { orderObj, carBandList, hwOhterObjArray } = this
orderObj.isAdmin = false
orderObj.oprBy = orderObj.staffUuid
orderObj.sceneType = 1
orderObj.brandDataList = carBandList
if (orderObj.onBreak == 'Y') {
orderObj.brandDataList.forEach(item => {
item.notDeliveryCount = item.notDeliveryCount || 0
item.equityToShopCount = item.equityToShopCount || 0
})
}
if (orderObj.pickerValue == 0) {
if (orderObj.staffCount == null) throw {
message: '今日驻店人数(按店)',
refId: 'staffCount'
}
orderObj.brandDataList.map((e, index) => {
if (e.deliveryCount == null) throw { message: '店端实际交车数', refId: `deliveryCount_${index}` }
if (!e.notDeliveryCount == null) throw { message: '店端总未触客数', refId: `notDeliveryCount_${index}` }
if (!e.equityToShopCount == null) throw { message: '实际售前触客数', refId: `equityToShopCount_${index}` }
carBandList.map((item, index) => {
hwOhterObjArray.map(el => {
if (el.required && ['', null].includes(item[el.key])) throw {
message: el.label,
refId: `${el.refId}_${index}`
}
})
})
}
if (orderObj.onBreak == 'Y') {
orderObj.brandDataList.forEach(item => {
item.notDeliveryCount = item.notDeliveryCount || 0
item.equityToShopCount = item.equityToShopCount || 0
})
}
const data = await uni.$api.boutiqueApi.saveStaffDailyReport(orderObj)
uni.hideLoading()
if (data) {
this.isEditReport = false
this.$refs.reportNotice.open()
}
} catch (errorObj) {
console.log(errorObj)
uni.hideLoading()
if (errorObj.message) {
uni.showToast({
title: `${errorObj.message}不能为空`,
......@@ -563,6 +593,11 @@ export default {
filterDisabled (disabledStatus) {
let { weeklyList, currentDate, orderObj: { isDateWithin7Days } } = this
return weeklyList.includes(currentDate) && !disabledStatus || !isDateWithin7Days
},
changePicker (e, i) {
let { value } = e.detail
this.orderObj[i.value] = value
this.orderObj[i.submitValue] = value == 1 ? 'Y' : 'N'
}
}
}
......
......@@ -26,7 +26,7 @@
</view>
<z-paging ref="paging" :fixed="false" paging-class="paging-class px-48" :loading-full-fixed="false" :auto-show-system-loading="true" :show-scrollbar="false" v-model="dataList" @query="queryList" :default-page-size="10">
<OrderCard v-for="(item, index) in dataList" :key="index" :orderCardDetail="item" @toggle-goods-list="handleToggleGoodsList" @jump="jump"></OrderCard>
<OrderCard v-for="(item, index) in dataList" :key="index" :orderCardDetail="item" @toggle-goods-list="handleToggleGoodsList" @jump="jump" @refresh="search()"></OrderCard>
</z-paging>
<PublishPopup ref="WaitinputorderPopup" popupClass="waitinputorderPopup" :showClose="true" title="选择交易参考号">
......@@ -108,7 +108,7 @@
</template>
</PublishPopup>
<PublishPopup ref="abnormalTipsPopup" popupClass="abnormalTipsPopup" :showClose="true" title="超分账期">
<PublishPopup ref="abnormalTipsPopup" popupClass="abnormalTipsPopup" :showClose="true" title="超分账期" @confirm="confirmTips">
<template #content>
<scroll-view scroll-y class="ul px-48">
<view class="title">字段定义</view>
......@@ -147,6 +147,17 @@ export default {
PublishPopup,
OrderScreen
},
computed: {
orderObj() {
return order_mixins.data.orderObj || []
},
payType() {
return order_mixins.data.payType || {}
},
status() {
return order_mixins.data.status || {}
}
},
data() {
return {
itemFormObj: [
......@@ -199,13 +210,12 @@ export default {
normalCurrentPage: 1,
abnormalPages: 1,
normalPages: 1,
userInfo: null,
checkListObj: {},
...order_mixins.data
localUserInfo: null
}
},
mounted() {
this.userInfo = uni.$storage.get('userInfo') || {}
this.localUserInfo = uni.$storage.get('userInfo') || {}
this.search()
this.startWaitOrderPolling()
},
......@@ -214,10 +224,10 @@ export default {
},
methods: {
search() {
// 判断是不是超管 && !this.userInfo.isSuper
// 判断是不是超管 && !this.localUserInfo.isSuper
// ,不是只能筛选当前4s店的
if (!this.searchObj.merchantId) {
this.searchObj.merchantId = this.userInfo?.shopMerchantId
this.searchObj.merchantId = this.localUserInfo?.shopMerchantId
}
this.$refs.paging.reload()
this.getStatByStatus()
......@@ -326,7 +336,7 @@ export default {
.then(result => {
const { list, total } = result
// 这个是用来判断哪些用户可以撤销的
let userType = (!this.userInfo.isSuper && this.userInfo.merchantType) || (this.userInfo.loginRole !== 3 && this.userInfo?.loginRole !== 6)
let userType = (!this.localUserInfo.isSuper && this.localUserInfo.merchantType) || (this.localUserInfo.loginRole !== 3 && this.localUserInfo?.loginRole !== 6)
// let userType = true
list.map(e => {
......@@ -339,8 +349,8 @@ export default {
// 开票按钮
e.invoiceName = e.invoiceStatus == 2 ? '查看发票' : '申请开票'
// && e.status != 1 待跟进现在也能撤销
let orderType = (this.userInfo.userType == 1 || this.userInfo.userType == 2) && e.status != 9 && ![1, 3, 4].includes(e.selectPayType)
// let orderType = this.userInfo.userType !== 1 && e.status != 9 && e.status != 1 && e.selectPayType != 3 && e.selectPayType != 1
let orderType = (this.localUserInfo.userType == 1 || this.localUserInfo.userType == 2) && e.status != 9 && ![1, 3, 4].includes(e.selectPayType)
// let orderType = this.localUserInfo.userType !== 1 && e.status != 9 && e.status != 1 && e.selectPayType != 3 && e.selectPayType != 1
// console.log(userType);
// console.log(orderType);
e.repeal = userType && orderType
......@@ -437,6 +447,9 @@ export default {
showQuestionPopup() {
this.$refs.abnormalTipsPopup.open()
},
confirmTips() {
this.$refs.abnormalTipsPopup.closePopup()
},
activeClick(item) {
if (this.checkListObj[item.tradeNo]) {
this.$delete(this.checkListObj, item.tradeNo)
......
<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 class="back" @click="backPage">
<uni-icons type="left" :size="20" color="#000"></uni-icons>
</view>
<view class="title">展业工具</view>
</view>
......@@ -17,45 +10,20 @@
<view class="detail-left">
<view class="common-title">展业</view>
<view class="content">
<image
class="banner"
src="../../../assets/images/common/tool_banner.png"
mode="scaleToFill"
/>
<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"
/>
<uni-calendar ref="calendar" :clearDate="false" :endDate="endDate" :showMonth="false" @monthSwitch="currentMonth = `${$event.year}-${$event.month}`" @change="currentDate = $event.fulldate" backgroundColor="transparent" :selected="selectedDays" />
</template>
</view>
</view>
<view class="detail-right">
<component
:is="toolComponentName"
@jump="jump"
:transmission-of-data="transmissionOfData"
:currentDate="currentDate"
:currentMonth="currentMonth"
@setCalendarSelected="selectedDays = $event"
/>
<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>
<NoticePopup ref="notice" title="重要提示" text="当前页面暂未保存,是否确认退出" type="warning"></NoticePopup>
</view>
</template>
......@@ -85,7 +53,7 @@ export default {
UploadProofOfPayment,
OrderDetail
},
data () {
data() {
return {
toolComponentName: '',
transmissionOfData: null,
......@@ -95,16 +63,16 @@ export default {
selectedDays: []
}
},
onLoad (options) {
onLoad(options) {
if (options.componentName) this.toolComponentName = options.componentName
uni.$on('jumpToDailyReport', _ => {
this.toolComponentName = 'DailyReport'
})
},
methods: {
async entranceClick (item) {
async entranceClick(item) {
console.log(item)
if (item.name != 'DailyReport' && (await this.checkDailyReport() || await this.inspectionOfProhibitionBill())) return
if (item.name != 'DailyReport' && ((await this.checkDailyReport()) || (await this.inspectionOfProhibitionBill()))) return
// 保存当前选择的组件信息,但不立即切换
const selectedItem = item
if (this.toolComponentName == selectedItem.name) return
......@@ -129,24 +97,26 @@ export default {
}
this.$refs.notice.close()
}
}, {
},
{
text: '继续编辑',
type: 'primary',
callback: () => {
this.$refs.notice.close()
}
}]
}
]
// 打开弹窗
this.$refs.notice.open()
},
backPage () {
backPage() {
uni.navigateBack()
},
// name:跳转组件名,val:跳转参数
jump (name, val) {
jump(name, val) {
this.toolComponentName = name
console.log(this.toolComponentName)
console.log(this.toolComponentName, val)
if (val) {
this.transmissionOfData = val
}
......
......@@ -190,20 +190,24 @@ $uni-primary: #4673ff !default;
.uni-calendar-item--checked {
background-color: $uni-primary;
color: #fff;
opacity: 0.8;
// opacity: 0.8;
}
.uni-calendar-item--multiple {
background-color: $uni-primary;
background-color: rgba($color: $uni-primary, $alpha: 0.8);
color: #fff;
opacity: 0.8;
.uni-calendar-item--multiple{
background: none;
}
// opacity: 0.8;
}
.uni-calendar-item--before-checked {
background-color: #ff5a5f;
background-color: #4673FF;
color: #fff;
}
.uni-calendar-item--after-checked {
background-color: #ff5a5f;
background-color: #4673FF;
color: #fff;
border-radius: inherit;
}
</style>
......@@ -22,6 +22,7 @@
>
<text class="uni-calendar__header-text uni-calendar--fixed-width">{{cancelText}}</text>
</view>
<viw class="uni-calendar__header-title">{{title}}</viw>
<view
class="uni-calendar__header-btn-box"
@click="confirm"
......@@ -184,9 +185,13 @@ export default {
type: Object,
default: () => { { } }
},
backgroundColor:{
backgroundColor: {
type: String,
default: '#fff'
},
title:{
type: String,
default: '选择日期'
}
},
data () {
......@@ -308,7 +313,7 @@ export default {
}
this.choiceDate(before)
setTimeout(() => {
uni.hideLoading()
uni.hideLoading()
this.choiceDate(after)
}, 100)
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!