Commit 1cf8281a by cen

fix: 跳转参数

1 parent d36bc044

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
...@@ -4,18 +4,10 @@ ...@@ -4,18 +4,10 @@
<view class="box"> <view class="box">
<scroll-view class="scroll-view" scroll-y="true"> <scroll-view class="scroll-view" scroll-y="true">
<view class="box-content"> <view class="box-content">
<GlCell :formList="formList" :formData="orderObj" @radioChange="radioChange" @inputBlur="inputBlur" <GlCell :formList="formList" :formData="orderObj" @radioChange="radioChange" @inputBlur="inputBlur" @handleCell="handleCell">
@handleCell="handleCell">
<!-- 使用v-for循环渲染产品组件,减少重复代码 --> <!-- 使用v-for循环渲染产品组件,减少重复代码 -->
<template v-for="(_, slotName) in productSlots" :slot="slotName" > <template v-for="(_, slotName) in productSlots" :slot="slotName">
<Product <Product :key="slotName" v-if="orderObj[slotName] && orderObj[slotName].length" @changeTotalPrice="changeTotalPrice" :list="orderObj[slotName]" :positionTypeList="positionTypeList" :baseConfigData="baseConfigData"></Product>
:key="slotName"
v-if="orderObj[slotName] && orderObj[slotName].length"
@changeTotalPrice="changeTotalPrice"
:list="orderObj[slotName]"
:positionTypeList="positionTypeList"
:baseConfigData="baseConfigData">
</Product>
</template> </template>
<template slot="package"> <template slot="package">
<Package v-if="orderObj.package" @changeTotalPrice="changeTotalPrice" :list="orderObj.package" :positionTypeList="positionTypeList"></Package> <Package v-if="orderObj.package" @changeTotalPrice="changeTotalPrice" :list="orderObj.package" :positionTypeList="positionTypeList"></Package>
...@@ -24,7 +16,7 @@ ...@@ -24,7 +16,7 @@
<SkuGoods v-if="orderObj.skuGoods" :list="orderObj.skuGoods" @changeTotalPrice="changeTotalPrice" :positionTypeList="positionTypeList" :baseConfigData="baseConfigData"></SkuGoods> <SkuGoods v-if="orderObj.skuGoods" :list="orderObj.skuGoods" @changeTotalPrice="changeTotalPrice" :positionTypeList="positionTypeList" :baseConfigData="baseConfigData"></SkuGoods>
<view class="total" v-if="totalPrice > 0"> <view class="total" v-if="totalPrice > 0">
<view class="total-left">总价</view> <view class="total-left">总价</view>
<view class="total-right">¥{{totalPrice}}</view> <view class="total-right">¥{{ totalPrice }}</view>
</view> </view>
</template> </template>
<template slot="otherPay"> <template slot="otherPay">
...@@ -58,13 +50,13 @@ export default { ...@@ -58,13 +50,13 @@ export default {
SkuGoods SkuGoods
}, },
props: { props: {
selectedTradeData: { transmissionOfData: {
type: Object, type: Object,
default: () => null default: () => null
} }
}, },
watch: { watch: {
selectedTradeData: { transmissionOfData: {
handler(newVal) { handler(newVal) {
if (newVal) { if (newVal) {
console.log('接收到的交易数据:', newVal) console.log('接收到的交易数据:', newVal)
...@@ -78,7 +70,7 @@ export default { ...@@ -78,7 +70,7 @@ export default {
}, },
data() { data() {
return { return {
orderCreateType: "createWithPay", // supplementOrder(补录订单) createWithPay(新增) orderCreateType: 'createWithPay', // supplementOrder(补录订单) createWithPay(新增)
formList: utils.deepClone(FORM_LIST), formList: utils.deepClone(FORM_LIST),
userInfo: {}, userInfo: {},
baseConfigData: {}, baseConfigData: {},
...@@ -116,8 +108,8 @@ export default { ...@@ -116,8 +108,8 @@ export default {
frontWindow: true, frontWindow: true,
rearGear: true, rearGear: true,
rearWindow: true, rearWindow: true,
sunRoof: true, sunRoof: true
}, }
} }
}, },
computed: { computed: {
...@@ -193,7 +185,7 @@ export default { ...@@ -193,7 +185,7 @@ export default {
const _typeValue = this.popupTypeEnum[this.popupType] const _typeValue = this.popupTypeEnum[this.popupType]
console.log(_typeValue) console.log(_typeValue)
// 定义产品相关字段数组 // 定义产品相关字段数组
const productFields = ['frontGear', 'frontWindow', 'rearGear', 'rearWindow', 'sunRoof', 'package', 'skuGoods']; const productFields = ['frontGear', 'frontWindow', 'rearGear', 'rearWindow', 'sunRoof', 'package', 'skuGoods']
if (_typeValue.key == 'carBrand') { if (_typeValue.key == 'carBrand') {
// 车型 // 车型
this.$set(this.orderObj, _typeValue.key, `${chooseContent.carBrand}-${chooseContent.carChildsBrandName}-${chooseContent.carSeriesName}`) this.$set(this.orderObj, _typeValue.key, `${chooseContent.carBrand}-${chooseContent.carChildsBrandName}-${chooseContent.carSeriesName}`)
...@@ -218,7 +210,9 @@ export default { ...@@ -218,7 +210,9 @@ export default {
// 过滤出已选的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 = chooseContent.filter(item => item.goodsFlag === 1) const singleGoods = chooseContent.filter(item => item.goodsFlag === 1)
const moreGoods = chooseContent.filter(item => item.goodsFlag === 2).filter(item => { const moreGoods = chooseContent
.filter(item => item.goodsFlag === 2)
.filter(item => {
return !selectedGoods.some(selectedItem => selectedItem.multipleSpecificationsGoods.id === item.multipleSpecificationsGoods.id) return !selectedGoods.some(selectedItem => selectedItem.multipleSpecificationsGoods.id === item.multipleSpecificationsGoods.id)
}) })
// 合并已选的goodFlag为2的对象 // 合并已选的goodFlag为2的对象
...@@ -313,7 +307,7 @@ export default { ...@@ -313,7 +307,7 @@ export default {
async submit() { async submit() {
console.log(this.orderObj) console.log(this.orderObj)
if (!this.checkRequired()) return if (!this.checkRequired()) return
const {orderCreateType} = this const { orderCreateType } = this
const obj = utils.deepClone(this.orderObj) const obj = utils.deepClone(this.orderObj)
const otherCustomer = ['standNo', 'plateNumber', 'customerSex', 'experienceFlag', 'salesType'] const otherCustomer = ['standNo', 'plateNumber', 'customerSex', 'experienceFlag', 'salesType']
obj.customer = { obj.customer = {
...@@ -332,10 +326,10 @@ export default { ...@@ -332,10 +326,10 @@ export default {
let subGoodsList = [] let subGoodsList = []
labelFields.forEach(field => { labelFields.forEach(field => {
if (Array.isArray(obj[field]) && obj[field].length > 0) { if (Array.isArray(obj[field]) && obj[field].length > 0) {
goodsList = goodsList.concat(obj[field]); goodsList = goodsList.concat(obj[field])
} }
delete obj[field]; delete obj[field]
}); })
if (goodsList.length > 0) { if (goodsList.length > 0) {
goodsList.map(e => { goodsList.map(e => {
if (e.goodsFlag == 1) { if (e.goodsFlag == 1) {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<view class="order-detail"> <view class="order-detail">
<view class="common-title">{{ orderInfo.constructionFlag == 'Y' && orderInfo.status != 10 ? '完成施工' : '工单详情' }}</view> <view class="common-title">{{ orderInfo.constructionFlag == 'Y' && orderInfo.status != 10 ? '完成施工' : '工单详情' }}</view>
<view class="px-48 scroll-y" v-if="orderInfo"> <view class="px-48 scroll-y" v-if="orderInfo">
<view class="top-tips flex align-center" v-if="orderInfo.status != 10 && orderInfo.status != 9"> <view class="top-tips flex align-center" v-if="orderInfo.status != 10 && orderInfo.status != 9 && orderInfo.constructionFlag !== 'Y'">
<uni-icons class="checkbox-filled" type="checkbox-filled" color="#4ac18e"></uni-icons> <uni-icons class="checkbox-filled" type="checkbox-filled" color="#4ac18e"></uni-icons>
<view> <view>
<view class="fs-34 fw-5">客户已付款</view> <view class="fs-34 fw-5">客户已付款</view>
...@@ -19,9 +19,12 @@ ...@@ -19,9 +19,12 @@
<!-- <view class="tips">客户支付超过24小时,系统自动关闭订单</view> --> <!-- <view class="tips">客户支付超过24小时,系统自动关闭订单</view> -->
</view> </view>
<view class="top-tips flex align-center" v-if="orderInfo.constructionFlag == 'Y'"> <view class="top-tips flex align-center" v-if="orderInfo.constructionFlag == 'Y'">
<uni-icons class="checkbox-filled" type="checkbox-filled" color="#4ac18e"></uni-icons>
<view>
<view class="fs-34 fw-5">客户{{ orderInfo.customer.customerName }}</view> <view class="fs-34 fw-5">客户{{ orderInfo.customer.customerName }}</view>
<view class="fs-26">完成施工,如客户有新的需要,可点击再次下单。</view> <view class="fs-26">完成施工,如客户有新的需要,可点击再次下单。</view>
</view> </view>
</view>
<!-- 商品信息 --> <!-- 商品信息 -->
<view class="box-shell"> <view class="box-shell">
<view class="box-shell-title">商品信息</view> <view class="box-shell-title">商品信息</view>
...@@ -138,12 +141,18 @@ ...@@ -138,12 +141,18 @@
<view v-if="warrantyCardList.length || warrantyCardVisible" class="box-shell"> <view v-if="warrantyCardList.length || warrantyCardVisible" class="box-shell">
<view class="box"> <view class="box">
<view class="box-shell-title">{{ orderInfo.selectPayType == 0 ? '客服' : '质保' }}</view> <view class="box-shell-title">{{ orderInfo.selectPayType == 0 ? '客服' : '质保信息' }}</view>
<view class="warranty-list" v-for="(item, index) in warrantyCardList" :key="index"> <view class="warranty-list" v-for="(item, index) in warrantyCardList" :key="index">
<view class="warranty flex align-center pt-8"> <view class="warranty flex align-center justify-between pt-8">
<view class="flex align-center">
<view class="label">质保产品</view> <view class="label">质保产品</view>
<view class="value">{{ replaceItemText(item.goodsName) }}</view> <view class="value">{{ replaceItemText(item.goodsName) }}</view>
</view> </view>
<view class="flex align-center edit-warranty">
<view class="sprite-icon icon-edit mr-8"></view>
质保价格
</view>
</view>
<view class="warranty flex align-center pt-8"> <view class="warranty flex align-center pt-8">
<view class="label">质保期</view> <view class="label">质保期</view>
<view class="value">{{ item.warrantyPeriod }}</view> <view class="value">{{ item.warrantyPeriod }}</view>
...@@ -243,12 +252,12 @@ export default { ...@@ -243,12 +252,12 @@ export default {
if (data.selectPayType != 2 && (data.status == 4 || data.status == 6 || data.status == 12)) { if (data.selectPayType != 2 && (data.status == 4 || data.status == 6 || data.status == 12)) {
// 查询订单可展示按钮 // 查询订单可展示按钮
commonApi.getMoreBtnAPI({ orderCode: data.orderCode }).then(res => { // commonApi.getMoreBtnAPI({ orderCode: data.orderCode }).then(res => {
let { code, data } = res // let { code, data } = res
if (code == 0) { // if (code == 0) {
this.showMoreBtn = data.refundApplyButton == 'Y' || data.refundApplyDetailButton == 'Y' // this.showMoreBtn = data.refundApplyButton == 'Y' || data.refundApplyDetailButton == 'Y'
} // }
}) // })
} }
console.log('3255555666') console.log('3255555666')
// 服务商是否使用膜卷号配置 // 服务商是否使用膜卷号配置
...@@ -562,6 +571,9 @@ export default { ...@@ -562,6 +571,9 @@ export default {
.ml-12 { .ml-12 {
margin-left: toRpx(12); margin-left: toRpx(12);
} }
.mr-8 {
margin-right: toRpx(8);
}
.py-8 { .py-8 {
padding: toRpx(8) 0; padding: toRpx(8) 0;
} }
...@@ -748,6 +760,11 @@ export default { ...@@ -748,6 +760,11 @@ export default {
height: toRpx(158); height: toRpx(158);
} }
} }
.edit-warranty {
color: #347bff;
font-size: toRpx(28);
font-weight: 400;
}
} }
.warranty-tips { .warranty-tips {
margin-bottom: toRpx(12); margin-bottom: toRpx(12);
......
...@@ -463,6 +463,7 @@ export default { ...@@ -463,6 +463,7 @@ export default {
this.$refs.WaitinputorderPopup.closePopup() this.$refs.WaitinputorderPopup.closePopup()
}, },
jump(name, val) { jump(name, val) {
console.log(name, val, 'jump')
this.$emit('jump', name, val) this.$emit('jump', name, val)
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!