DESKTOP-2IO5MST\huting 1 year ago
parent
commit
bca1dc6bfb

+ 1
- 1
pages.json View File

{ {
"path": "interestsList", "path": "interestsList",
"style": { "style": {
"navigationBarTitleText": "加购权益产品"
"navigationBarTitleText": "权益简介" //加购权益产品
} }
}, },
{ {

+ 7
- 7
pages/index/index.vue View File

<view class="item item-5"> <view class="item item-5">
<image :src="fileURL + 'image/index/item-5.png'" mode="aspectFill" /> <image :src="fileURL + 'image/index/item-5.png'" mode="aspectFill" />
</view> </view>
<view class="text">挂失解挂</view>
<view class="text">设备注销</view>
</view> </view>
<view class="item-box" @click="cardRecharge(2)"> <view class="item-box" @click="cardRecharge(2)">
<view class="item item-6"> <view class="item item-6">
<image :src="fileURL + 'image/index/item-6.png'" mode="aspectFill" /> <image :src="fileURL + 'image/index/item-6.png'" mode="aspectFill" />
</view> </view>
<view class="text">解除车牌占用</view>
<view class="text">通行费补缴</view>
</view> </view>
<!-- <view class="item-box" <!-- <view class="item-box"
@click="$util.navTo(`/subpackage/personal-center/setting/personal-information/corrections`,true)"> @click="$util.navTo(`/subpackage/personal-center/setting/personal-information/corrections`,true)">


<!--快速办理通道 --> <!--快速办理通道 -->
<view class="express-lane"> <view class="express-lane">
<view class="title">快速办理通道</view>
<view class="title">快速办理</view>
<view class="lane"> <view class="lane">
<view class="lane-item lane-1" :style="{ '--background': bgOrange }" @click="showMask(1)"> <view class="lane-item lane-1" :style="{ '--background': bgOrange }" @click="showMask(1)">
<image :src="fileURL + 'image/index/icon-car.png'" mode="aspectFill"></image> <image :src="fileURL + 'image/index/icon-car.png'" mode="aspectFill"></image>
<view class="text"> <view class="text">
<text class="head">客车通道</text>
<text class="decribe">业务内容简介</text>
<text class="head">客车用户</text>
<!-- <text class="decribe">业务内容简介</text> -->
</view> </view>
</view> </view>
<view class="lane-item lane-2" :style="{ '--background': bgBlue }" @click="showMask(2)"> <view class="lane-item lane-2" :style="{ '--background': bgBlue }" @click="showMask(2)">
<image :src="fileURL + 'image/index/icon-truck.png'" mode="aspectFill"></image> <image :src="fileURL + 'image/index/icon-truck.png'" mode="aspectFill"></image>
<view class="text"> <view class="text">
<text class="head">货车通道</text>
<text class="decribe">业务内容简介</text>
<text class="head">货车用户</text>
<!-- <text class="decribe">业务内容简介</text> -->
</view> </view>
</view> </view>
</view> </view>

+ 41
- 14
subpackage/orders/choice-product.vue View File

<navBar title="选择产品" :scrollTop="scrollTop"></navBar> <navBar title="选择产品" :scrollTop="scrollTop"></navBar>
<navBgCar></navBgCar> <navBgCar></navBgCar>
<view class="content-value"> <view class="content-value">
<view @click="savaHandle(item)" class="ul-item" v-for="(item, index) in state.dataArray" :key="index">
<image style="width: 100%; height: 170rpx; border-radius: 20rpx"
:src="`${$imgUrl}applyCard/product-bg.png`"></image>
<view class="item-value">
<image class="icon-tip"
:src="state.sysType === 'WECHAT'?`${$imgUrl}applyCard/wechat.png` : `${$imgUrl}applyCard/alibaba.png`">
</image>
<view class="content">
<view class="title">
<view v-for="(item, index) in state.dataArray" :key="index">
<!-- #F4F6FA -->
<view :style="`background-color:${bgc}`" style="border-radius: 16rpx;padding: 20rpx;margin-top: 20rpx;">
<view class="title" style="display: flex;flex-direction: row;justify-content: flex-start;">
<view style="font-weight: bold;margin-right: 10rpx;font-size: 18px;">
{{ item.promoteName }} {{ item.promoteName }}
</view> </view>
<view style="margin-top: 15rpx" class="tip">
<view>
{{ item['releaseProductStandards']['productStandards']['cardTypeArr'] }} {{ item['releaseProductStandards']['productStandards']['cardTypeArr'] }}
</view> </view>
</view> </view>
<view class="money">
¥:{{ item.fee * 0.01 }}
<view v-for="(str, index) in item.releaseProductStandards.equityList" :key="index" class="ul-item"
style="padding: 0rpx;margin-top: 20rpx;" @click="savaHandle(item,index)">
<image style="width: 100%; height: 170rpx; border-radius: 20rpx"
:src="`${$imgUrl}applyCard/product-bg.png`"></image>
<view class="item-value">
<image class="icon-tip"
:src="state.sysType === 'WECHAT'?`${$imgUrl}applyCard/wechat.png` : `${$imgUrl}applyCard/alibaba.png`">
</image>
<view class="content">
<view class="title">
{{ str.equityName }}
</view>
<view style="margin-top: 15rpx" class="tip">
{{ str.sellingPoint }}
</view>
</view>
<view class="money">
¥:{{ str.discountPrice * 0.01 }}
</view>
</view>
</view> </view>
</view> </view>

</view> </view>
<view class="bottomTip"> 到底啦!敬请期待其他产品! </view> <view class="bottomTip"> 到底啦!敬请期待其他产品! </view>
</view> </view>
import { msg } from "@/utils/utils"; import { msg } from "@/utils/utils";
import { agentId } from "@/utils/network/difference"; import { agentId } from "@/utils/network/difference";
const imgURL = `${fileURL}image/`; const imgURL = `${fileURL}image/`;
let bgc = ""
// #ifdef MP-ALIPAY
bgc = "#FFFFFF"
// #endif
// #ifdef MP-WEIXIN
bgc = "#F4F6FA" //52010106004
// #endif


const scrollTop = ref(0); //滚动距离 const scrollTop = ref(0); //滚动距离
// 单选默认数据 // 单选默认数据
url: `/subpackage/orders/interestsList?promoteId=${getItem("promoteId")}&userType=${state.userType}&type=${state.type}&isValueCard=${state.isValueCard}&fee=${Number(state.fee)}`, url: `/subpackage/orders/interestsList?promoteId=${getItem("promoteId")}&userType=${state.userType}&type=${state.type}&isValueCard=${state.isValueCard}&fee=${Number(state.fee)}`,
}); });
} }
const savaHandle = (val) => {
const savaHandle = (val,idx) => {
console.log("vAL", val) console.log("vAL", val)
setItem("clientFee", val.clientFee); setItem("clientFee", val.clientFee);
setItem("promoteId", val.promoteId); setItem("promoteId", val.promoteId);
console.log("state.isValueCard", state.isValueCard) console.log("state.isValueCard", state.isValueCard)
setItem("isValueCard", state.isValueCard); setItem("isValueCard", state.isValueCard);
uni.navigateTo({ uni.navigateTo({
url: `/subpackage/orders/interestsList?promoteId=${val['promoteId']}&userType=${state.userType}&type=${state.type}&isValueCard=${state.isValueCard}&fee=${Number(val.fee)}`,
url: `/subpackage/orders/interestsList?equityId=${val.releaseProductStandards.equityList[idx].equityId}&promoteId=${val['promoteId']}&userType=${state.userType}&type=${state.type}&isValueCard=${state.isValueCard}&fee=${Number(val.fee)}`,
}); });
} else { } else {
state.radiolist1 = []; state.radiolist1 = [];
</script> </script>


<style lang="scss" scoped> <style lang="scss" scoped>
// page {
// background-color: #FFFFFF;
// }
::v-deep .u-radio { ::v-deep .u-radio {
display: flex !important; display: flex !important;
align-items: center !important; align-items: center !important;

+ 47
- 7
subpackage/orders/interestsList.vue View File

<template> <template>
<view class="content" style="padding-top: 12rpx;overflow: hidden;">
<view @click="addInterestsList(item)" class="ul-item" v-for="(item, index) in state.list" :key="index">
<view class="content" style="padding: 20rpx;overflow: hidden;">
<rich-text :nodes="richText">

</rich-text>
<!-- <view @click="addInterestsList(item)" class="ul-item" v-for="(item, index) in state.list" :key="index">
<image style="width: 100%; height: 170rpx; border-radius: 20rpx" <image style="width: 100%; height: 170rpx; border-radius: 20rpx"
:src="`${$imgUrl}applyCard/product-bg.png`"></image> :src="`${$imgUrl}applyCard/product-bg.png`"></image>
<view class="item-value"> <view class="item-value">
¥:{{ item.discountPrice * 0.01 }} ¥:{{ item.discountPrice * 0.01 }}
</view> </view>
</view> </view>
</view>
</view> -->
</view>
<view style="align-items: center;text-align: center;padding 20rpx;position: absolute;bottom: 40rpx;width: 90%;left: 5%;" >
<button type="default" class="button" @click="addInterestsList(item)" v-for="(item, index) in state.list" :key="index">
下一步
</button>
</view> </view>
</template> </template>


<script setup lang="ts"> <script setup lang="ts">
import { onLoad, onShow } from "@dcloudio/uni-app"; import { onLoad, onShow } from "@dcloudio/uni-app";
import { reactive } from "vue";
import { equityProductsApi } from "@/utils/network/api.js";
import { reactive, ref } from "vue";
import { equityProductsApi, equityProductsInfo } from "@/utils/network/api.js";
import { stringToJson } from "@/utils/network/encryption"; import { stringToJson } from "@/utils/network/encryption";
import { request } from "@/utils/network/request"; import { request } from "@/utils/network/request";
import { fileURL } from "@/datas/fileURL.js"; import { fileURL } from "@/datas/fileURL.js";


const state = reactive({ const state = reactive({
openid: "", openid: "",
equityId: "",
id: "", id: "",
clientFee: "", clientFee: "",
list: [], //权益数据 list: [], //权益数据
sysType: "" sysType: ""
}) })


let richText = ref('')
onLoad((option : any) => { onLoad((option : any) => {
// #ifdef MP-ALIPAY // #ifdef MP-ALIPAY
state.sysType = 'ALI'; state.sysType = 'ALI';
// #endif // #endif
console.log("promoteId", option) console.log("promoteId", option)
state.clientFee = option.clientFee; state.clientFee = option.clientFee;
state.equityId = option.equityId;
state.userType = option.userType; state.userType = option.userType;
state.type = option.type; state.type = option.type;
state.isValueCard = option.isValueCard; state.isValueCard = option.isValueCard;
state.changeCardType = option.changeCardType; state.changeCardType = option.changeCardType;
state.applyId = option.applyId; state.applyId = option.applyId;
state.orderId = option.orderId; state.orderId = option.orderId;
getInfo();
getList(); getList();
getOpenID(); getOpenID();
//equityProductsInfo
console.log("option", option) console.log("option", option)
}) })
const addInterestsList = (item) => { const addInterestsList = (item) => {
} }
} }


const getInfo = () => {
const options = {
type: 2,
data: {
"singleEquityId": state.equityId,
},
method: 'POST',
showLoading: true,
}
request(equityProductsInfo, options).then((res) => {
const data = stringToJson(res.bizContent);
console.log("333333", data.productIntro)
richText.value = data.productIntro
})
}


const getList = () => { const getList = () => {
const options = { const options = {
</script> </script>


<style scoped lang="scss"> <style scoped lang="scss">
.imageDefault { .imageDefault {
height: 40rpx; height: 40rpx;
width: 40rpx; width: 40rpx;
font-size: 32rpx; font-size: 32rpx;


} }
.button {
height: 80rpx;
background: linear-gradient(-90deg, #43a1e0 0%, #13e7c1 100%);
border-radius: 40rpx;
font-size: 32rpx;
font-weight: 400;
color: #ffffff;
line-height: 80rpx;
}


.item>.title { .item>.title {
width: 100%; width: 100%;
} }


.ul-item { .ul-item {
padding: 5px 20rpx;
// padding: 5px 20rpx;
padding-top: 20rpx;
display: flex; display: flex;
align-items: center; align-items: center;



+ 80
- 32
subpackage/service/equity/equity.vue View File

我的权益</view> 我的权益</view>
<!-- <view v-if="exchangeCodes.length > 0" style="text-align: center;">暂无权益内容</view> @scrolltolower="loadMore" --> <!-- <view v-if="exchangeCodes.length > 0" style="text-align: center;">暂无权益内容</view> @scrolltolower="loadMore" -->
<scroll-view scroll-y="true"> <scroll-view scroll-y="true">

<view v-for="(item, index) in exchangeCodes" :key="index" class="item" @click.stop="click(item)"> <view v-for="(item, index) in exchangeCodes" :key="index" class="item" @click.stop="click(item)">
<view style="display: flex;flex-direction: row;flex: 1;">
<view style="display: flex;flex-direction: column;margin: 10px;">
<text>权益名称:{{item.equityInfoItems[0].productName}}</text>
<view style="display: flex;flex-direction: column;flex: 1;margin: 10px;">
<view style="display: flex;flex-direction: column;">
<text style="margin-top: 10rpx;">车牌号:{{item.vehiclePlate}}</text> <text style="margin-top: 10rpx;">车牌号:{{item.vehiclePlate}}</text>

<text v-if="item.drawTime" style="margin-top: 10rpx;">领取时间:{{item.drawTime}}</text> <text v-if="item.drawTime" style="margin-top: 10rpx;">领取时间:{{item.drawTime}}</text>
<text style="margin-top: 10rpx;">领取时间:{{item.getStatus}}</text> <text style="margin-top: 10rpx;">领取时间:{{item.getStatus}}</text>
<text style="margin-top: 10rpx;">有效期:{{ item.periodOfValidity }}</text> <text style="margin-top: 10rpx;">有效期:{{ item.periodOfValidity }}</text>
<text v-if="item.redeemCodeStr" class="code">券码:{{ item.redeemCodeStr}}</text> <text v-if="item.redeemCodeStr" class="code">券码:{{ item.redeemCodeStr}}</text>
</view> </view>
</view> </view>
<view
style="margin: 10px;border-radius: 0 8px 8px 0 ;justify-content: center;text-align: center; display: flex;flex-direction: column;background: white;flex: 1;">
<text v-if="item.equityInfoItems[0] && item.equityInfoItems[0].equityType !='ZFB'"
class="text-w"
:style="item.status == 'WAIT_ACTIVATED' ? 'color: #023F8F;' : item.status == 'WAIT_USE' ? 'color: orange;' : item.status == 'USED' ? 'color: green;' : 'color: gray;'">{{item.status == 'WAIT_ACTIVATED' ? '待激活' : item.status == 'WAIT_USE' ? '待领取' :
item.status == 'USED' ? '已领取' : '已失效'}}</text>
<button
v-if="item.status != 'EXPIRED' && item.equityInfoItems[0] && item.equityInfoItems[0].equityType !='ZFB'"
:style="item.status == 'WAIT_ACTIVATED' ? 'background-color: #023F8F;' : item.status == 'WAIT_USE' ? 'background-color: orange;' : item.status == 'USED' ? 'background-color: green;' : 'background-color: gray;'"
class="copy-btn" data-code="{{item}}" @click.stop="copyCode(item)">
{{item.status == 'WAIT_ACTIVATED' ? '去激活' : item.status == 'WAIT_USE' ? '立即领取' :
item.status == 'USED' ? '复制' : ''}}</button>
<view v-for="(list, index) in item.equityInfoItems">
<view v-if="list.equityType == 'COUPONS'">
<div class="horizontal-line"></div>
<view style="display: flex;flex-direction: column;">
<text style="width: 100%;">权益名称:{{list.productName}}</text>
<view
style="display: flex;flex-direction: row;min-height: 60rpx;justify-content: space-between;text-align: baseline;">
<text class="text-w"
style="flex: 1;margin-top: 5rpx;"
:style="item.status == 'WAIT_ACTIVATED' ? 'color: #023F8F;' : item.status == 'WAIT_USE' ? 'color: orange;' : item.status == 'USED' ? 'color: green;' : 'color: gray;'">卡卷状态:{{item.status == 'WAIT_ACTIVATED' ? '待激活' : item.status == 'WAIT_USE' ? '待领取' : item.status == 'USED' ? '已领取' : '已失效'}}</text>
<button v-if="item.status != 'EXPIRED' && list && list.equityType !='ZFB'"
:style="item.status == 'WAIT_ACTIVATED' ? 'background-color: #023F8F;' : item.status == 'WAIT_USE' ? 'background-color: orange;' : item.status == 'USED' ? 'background-color: green;' : 'background-color: gray;'"
class="copy-btn" data-code="{{item}}" @click.stop="copyCode(list)">
{{item.status == 'WAIT_ACTIVATED' ? '去激活' : item.status == 'WAIT_USE' ? '立即领取' :
item.status == 'USED' ? '复制' : '已失效'}}</button>
</view>
</view>
</view>
<view v-if="list.equityType == 'ZFB'">
<div class="horizontal-line"></div>
<view style="display: flex;flex-direction: column;">
<text style="width: 100%;">权益名称:{{list.productName}}</text>
<view
style="display: flex;flex-direction: row;min-height: 60rpx;justify-content: space-between;text-align: baseline;">
<text class="text-w" style="flex: 1;margin-top: 5rpx;color: #4caf50;">
卡卷状态:正常
</text>
<button style="background-color: #4caf50;" class="copy-btn"
data-code="{{item}}" @click.stop="copyCode(list)">
去使用
</button>
</view>
</view>
</view>
</view> </view>
</view> </view>
</view> </view>
</scroll-view> </scroll-view>

</view> </view>
</view> </view>

<!-- <view style="width: 100%; text-align: center;margin-top: 20rpx; ">暂无更多数据内容!</view> --> <!-- <view style="width: 100%; text-align: center;margin-top: 20rpx; ">暂无更多数据内容!</view> -->
</view> </view>
</template> </template>
} }


function click(item) { function click(item) {
console.log("item.equityInfoItems[0].equityType", item.equityInfoItems[0].equityType)
if (item.equityInfoItems[0].equityType == 'ZFB') {
console.log("1")
uni.navigateTo({
url: `/subpackage/service/zfbqy/zfbqy`
})
} else {
console.log("2")
uni.navigateTo({
url: '/subpackage/service/equityInfo/equityInfo?singleEquityId=' + singleEquityId.value +
"&couponAgencyType=" + couponAgencyType.value + "&couponId=" + couponId.value,
})
}
// console.log("item.equityInfoItems[0].equityType", item.equityInfoItems[0].equityType)
// if (item.equityInfoItems[0].equityType == 'ZFB') {
// console.log("1")
// uni.navigateTo({
// url: `/subpackage/service/zfbqy/zfbqy`
// })
// } else {
// console.log("2")
// uni.navigateTo({
// url: '/subpackage/service/equityInfo/equityInfo?singleEquityId=' + singleEquityId.value +
// "&couponAgencyType=" + couponAgencyType.value + "&couponId=" + couponId.value,
// })
// }

uni.navigateTo({
url: '/subpackage/service/equityInfo/equityInfo?singleEquityId=' + singleEquityId.value +
"&couponAgencyType=" + couponAgencyType.value + "&couponId=" + couponId.value,
})
} }


function copyCode(e) { function copyCode(e) {
let item = e; let item = e;
// // 复制兑换码到剪贴板 // // 复制兑换码到剪贴板
let code = e.redeemCode; let code = e.redeemCode;
console.log("e", e);
console.log("===e===", e.equityType);
if (item.equityType == 'ZFB') {
uni.navigateTo({
url: `/subpackage/service/zfbqy/zfbqy`
})
return
}

if (item.status == 'WAIT_ACTIVATED') { //待激活 if (item.status == 'WAIT_ACTIVATED') { //待激活
uni.showModal({ uni.showModal({
title: '温馨提示', title: '温馨提示',
color: #fff; color: #fff;
border: none; border: none;
min-width: 120rpx; min-width: 120rpx;
margin-top: 20px;
border-radius: 10rpx; border-radius: 10rpx;
font-size: 24rpx; font-size: 24rpx;
height: 60rpx;
box-shadow: 0 2rpx 4rpx rgba(0, 0, 0, 0.2); box-shadow: 0 2rpx 4rpx rgba(0, 0, 0, 0.2);
text-align: center;
display: inline-block;
line-height: 60rpx;
} }


.copy-btn:hover { .copy-btn:hover {
.text-w { .text-w {
font-weight: bold; font-weight: bold;
} }

.horizontal-line {
width: 100%;
/* 设置横线的宽度 */
height: 1px;
/* 设置横线的高度 */
background-color: #9ACDFA;
/* 设置横线的颜色 */
margin: 10px 0;
/* 可以根据需要调整横线与周围内容的间距 */
}
</style> </style>

+ 1
- 0
utils/network/api.js View File

export const transferRecordApi = "323bc6e1f3304c83921155fc220e9e37" //过户记录查询 export const transferRecordApi = "323bc6e1f3304c83921155fc220e9e37" //过户记录查询
export const agreementConfirmApi = "96fa039a85f54655af06d980c8ddc057" //协议确认接口 export const agreementConfirmApi = "96fa039a85f54655af06d980c8ddc057" //协议确认接口
export const equityProductsApi = "56db1aa8b9854f2f8c2428f3393e5045" //查询加购权益产品 export const equityProductsApi = "56db1aa8b9854f2f8c2428f3393e5045" //查询加购权益产品
export const equityProductsInfo = "35c5db593cea426d87fb48525873ecc9" //查询加购权益产品详情
export const gotoAgainUseOrderApi = "f92bfe60dbdf492eb37e2aad96ae1fd2" //再次使用订单接口 export const gotoAgainUseOrderApi = "f92bfe60dbdf492eb37e2aad96ae1fd2" //再次使用订单接口
export const finishUseOrderApi = "6eb10e968aac40f8bf4549cd05c8f5eb" //结束订单 export const finishUseOrderApi = "6eb10e968aac40f8bf4549cd05c8f5eb" //结束订单
export const ETCProductStatusListQueryApi = "448e81a599fe49b5b7f90f4af3ecae06" //ETC产品状态名单查询 export const ETCProductStatusListQueryApi = "448e81a599fe49b5b7f90f4af3ecae06" //ETC产品状态名单查询

+ 3
- 3
utils/network/difference.js View File

export const source = "ALI" export const source = "ALI"
// #endif // #endif
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
export const source = "WECHAT"
export const source = "ALI" //WECHAT
// #endif // #endif


// 微信小程序渠道编号:52010106004 支付宝小程序52010106998 // 微信小程序渠道编号:52010106004 支付宝小程序52010106998
export const agentId = "52010188937" export const agentId = "52010188937"
// #endif // #endif
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
export const agentId = "52010106004"
export const agentId = "52010106004" //
// #endif // #endif


// 网点编号 // 网点编号
export const channelId = "5201010600401140003" export const channelId = "5201010600401140003"
// #endif // #endif
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
export const channelId = "5201010200601130001"
export const channelId = "5201010200601130001" //
// #endif // #endif

Loading…
Cancel
Save