Commit 8c2cb0e5 by zhangmengjie

23.3.7

parent ebb2e627
...@@ -78,7 +78,7 @@ export default { ...@@ -78,7 +78,7 @@ export default {
url: path.url url: path.url
}); });
} }
this.$emit('tabBarChange', path.url, path.type); // this.$emit('tabBarChange', path.url, path.type);
} }
} }
}; };
......
...@@ -28,12 +28,12 @@ ...@@ -28,12 +28,12 @@
</view> </view>
</view> </view>
</view> </view>
<view class="content-discounts"> <view class="content-discounts" @click="jump(1)">
<view class=""> <view class="">
选择优惠券 选择优惠券
</view> </view>
<view class=""> <view class="">
-99 {{times}}
<image src="@/static/icon/jt.png" mode=""></image> <image src="@/static/icon/jt.png" mode=""></image>
</view> </view>
</view> </view>
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
<view class=""> <view class="">
截止1小时内支付完成 <text>00:59:42</text> 截止1小时内支付完成 <text>00:59:42</text>
</view> </view>
<button @click="jump">立即支付 300.00元</button> <button @click="jump(2)">立即支付 300.00元</button>
</view> </view>
</view> </view>
</template> </template>
...@@ -53,15 +53,22 @@ ...@@ -53,15 +53,22 @@
return { return {
imgBgUrl: apiBaseConfig.imgBgUrl, imgBgUrl: apiBaseConfig.imgBgUrl,
globalData: getApp().globalData, globalData: getApp().globalData,
scrollTopHeader: 0 scrollTopHeader: 0,
times:'0'
}; };
}, },
onLoad() {}, onLoad() {},
methods: { methods: {
jump() { jump(val) {
this.$uniGo.navigateTo({ if(val == 1){
url: `/demand/confirm/index` this.$uniGo.navigateTo({
}); url: `/my/coupon/index?type=pay`
});
}else{
this.$uniGo.navigateTo({
url: `/demand/confirm/index`
});
}
} }
} }
} }
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<text></text> <text></text>
<view>可用优惠券(2)</view> <view>可用优惠券(2)</view>
</view> </view>
<view class="index-content-item-qu"> <view class="index-content-item-qu" @click="optionData.type === 'pay'?jump():null">
<image class="index-content-item-qu-bg" src="@/static/icon/xy01.png" mode=""></image> <image class="index-content-item-qu-bg" src="@/static/icon/xy01.png" mode=""></image>
<view class="index-content-item-qu-bl"> <view class="index-content-item-qu-bl">
<text class="index-content-item-qu-bl-tl">满减优惠券</text> <text class="index-content-item-qu-bl-tl">满减优惠券</text>
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</view> </view>
<view class="index-content-item-qu-bl-lk-b">有效期:2022.3.1-2022.12.31</view> <view class="index-content-item-qu-bl-lk-b">有效期:2022.3.1-2022.12.31</view>
</view> </view>
<template v-if="optionData.type === 'coupon'"> <template v-if="optionData.type === 'pay'">
<view class="index-content-item-qu-bl-rk"> <view class="index-content-item-qu-bl-rk">
<view class="index-content-item-qu-bl-rk-a">订单金额满</view> <view class="index-content-item-qu-bl-rk-a">订单金额满</view>
<view class="index-content-item-qu-bl-rk-b">9999元</view> <view class="index-content-item-qu-bl-rk-b">9999元</view>
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
<view class="index-content-item-qu-bl-rk-d">当前可使用</view> <view class="index-content-item-qu-bl-rk-d">当前可使用</view>
</view> </view>
</template> </template>
<template v-if="optionData.type === 'pay'"> <template v-if="optionData.type === 'coupon'">
<view class="index-content-item-qu-bl-rk"> <view class="index-content-item-qu-bl-rk">
<view class="index-content-item-qu-bl-rk-a index-content-item-qu-bl-rk-axl">订单金额满</view> <view class="index-content-item-qu-bl-rk-a index-content-item-qu-bl-rk-axl">订单金额满</view>
<view class="index-content-item-qu-bl-rk-b index-content-item-qu-bl-rk-bxl">9999元</view> <view class="index-content-item-qu-bl-rk-b index-content-item-qu-bl-rk-bxl">9999元</view>
...@@ -53,7 +53,8 @@ ...@@ -53,7 +53,8 @@
<text>200</text> <text>200</text>
优惠券 优惠券
</view> </view>
<view class="index-content-item-qu-bl-lk-b index-content-item-qu-bl-lk-bx">有效期:2022.3.1-2022.12.31</view> <view class="index-content-item-qu-bl-lk-b index-content-item-qu-bl-lk-bx">
有效期:2022.3.1-2022.12.31</view>
</view> </view>
<view class="index-content-item-qu-bl-rk"> <view class="index-content-item-qu-bl-rk">
<view class="index-content-item-qu-bl-rk-a index-content-item-qu-bl-rk-ax">订单金额满</view> <view class="index-content-item-qu-bl-rk-a index-content-item-qu-bl-rk-ax">订单金额满</view>
...@@ -69,235 +70,290 @@ ...@@ -69,235 +70,290 @@
</template> </template>
<script> <script>
import apiBaseConfig from '@/config/index.js'; import apiBaseConfig from '@/config/index.js';
export default { export default {
data() { data() {
return { return {
imgBgUrl: apiBaseConfig.imgBgUrl, imgBgUrl: apiBaseConfig.imgBgUrl,
globalData: getApp().globalData, globalData: getApp().globalData,
scrollTopHeader: 0, scrollTopHeader: 0,
optionData: {}, optionData: {},
title: '' title: ''
}; };
}, },
onLoad(option) { onLoad(option) {
let self = this;
self.optionData = option;
self.initial();
},
methods: {
initial() {
let self = this; let self = this;
switch (self.optionData.type) { self.optionData = option;
case 'coupon': //优惠券 console.log(option)
self.title = '优惠券'; self.initial();
break; },
case 'pay': //支付 methods: {
self.title = '确认支付'; initial() {
break; let self = this;
switch (self.optionData.type) {
case 'coupon': //优惠券
self.title = '优惠券';
break;
case 'pay': //支付
self.title = '确认支付';
break;
}
},
jump() {
console.log('22222')
// 获取所有页面栈实例列表
let pages = getCurrentPages();
// 上一页页面实例
let prevPage = pages[pages.length - 2];
// 修改上一页data里面的times参数值为100
prevPage.$vm.times = 100;
//uni.navigateTo跳转的返回,默认1为返回上一级
uni.navigateBack({
delta: 1
});
console.log('1111111')
} }
} }
} };
};
</script> </script>
<style> <style>
page { page {
background-color: #f7f8f9; background-color: #f7f8f9;
} }
</style> </style>
<style lang="scss" scoped> <style lang="scss" scoped>
.index { .index {
&-content { &-content {
margin: 24rpx 20rpx; margin: 24rpx 20rpx;
width: calc(100% - 20rpx * 2); width: calc(100% - 20rpx * 2);
&-item {
margin-bottom: 30rpx; &-item {
&-nav { margin-bottom: 30rpx;
margin-bottom: 20rpx;
> text { &-nav {
display: inline-block; margin-bottom: 20rpx;
width: 6rpx;
height: 36rpx; >text {
background: #2c66ff; display: inline-block;
border-radius: 3rpx; width: 6rpx;
margin-right: 10rpx; height: 36rpx;
} background: #2c66ff;
> view { border-radius: 3rpx;
font-size: 28rpx; margin-right: 10rpx;
font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi; }
font-weight: 500;
color: #333333; >view {
> text { font-size: 28rpx;
color: #2c66ff; font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi;
font-weight: 500;
color: #333333;
>text {
color: #2c66ff;
}
} }
} }
}
&-nav:last-child { &-nav:last-child {
margin-bottom: 0rpx; margin-bottom: 0rpx;
}
&-navx {
> text {
background: #666666;
} }
}
&-qu { &-navx {
width: 710rpx; >text {
height: 200rpx; background: #666666;
background: #ffffff; }
box-shadow: 1rpx 1rpx 6rpx 0rpx rgba(0, 0, 0, 0.05); }
border-radius: 16rpx;
overflow: hidden; &-qu {
margin-bottom: 20rpx;
position: relative;
&-bg,
&-bl {
width: 710rpx; width: 710rpx;
height: 200rpx; height: 200rpx;
} background: #ffffff;
&-bg { box-shadow: 1rpx 1rpx 6rpx 0rpx rgba(0, 0, 0, 0.05);
position: absolute; border-radius: 16rpx;
left: 0rpx; overflow: hidden;
top: 0rpx; margin-bottom: 20rpx;
}
&-bl {
position: relative; position: relative;
> text,
> view { &-bg,
position: absolute; &-bl {
} width: 710rpx;
&-tl { height: 200rpx;
font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400;
color: #4384ff;
top: 4rpx;
left: 62rpx;
} }
&-tlx {
color: #666666; &-bg {
position: absolute;
left: 0rpx;
top: 0rpx;
} }
&-lk {
bottom: 20rpx; &-bl {
left: 20rpx; position: relative;
&-t {
font-size: 30rpx; >text,
>view {
position: absolute;
}
&-tl {
font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi; font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400; font-weight: 400;
color: #333333; color: #4384ff;
> text:nth-child(1) { top: 4rpx;
font-size: 40rpx; left: 62rpx;
}
&-tlx {
color: #666666;
}
&-lk {
bottom: 20rpx;
left: 20rpx;
&-t {
font-size: 30rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400;
color: #333333;
>text:nth-child(1) {
font-size: 40rpx;
font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi;
font-weight: 500;
color: #2c66ff;
}
>text:nth-child(2) {
font-size: 72rpx;
font-family: AlibabaPuHuiTi-Bold, AlibabaPuHuiTi;
font-weight: bold;
color: #2c66ff;
margin-right: 20rpx;
}
}
&-tx {
color: #999999;
>text:nth-child(1) {
color: #999999;
}
>text:nth-child(2) {
color: #999999;
}
}
&-b {
font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400;
color: #333333;
}
&-bx {
color: #999999;
}
}
&-rk {
width: 170rpx;
height: 200rpx;
right: 0rpx;
top: 0rpx;
>view {
text-align: center;
}
&-a {
font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400;
color: #ffffff;
margin-top: 26rpx;
}
&-ax {
color: #999999;
margin-top: 21rpx;
}
&-axl {
margin-top: 21rpx;
}
&-b {
font-size: 30rpx;
font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi; font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi;
font-weight: 500; font-weight: 500;
color: #2c66ff; color: #ffffff;
margin-top: 10rpx;
} }
> text:nth-child(2) {
font-size: 72rpx; &-bx {
font-family: AlibabaPuHuiTi-Bold, AlibabaPuHuiTi; color: #666666;
font-weight: bold; margin-top: 5rpx;
color: #2c66ff;
margin-right: 20rpx;
} }
}
&-tx { &-bxl {
color: #999999; margin-top: 5rpx;
> text:nth-child(1) { }
&-c,
&-d {
font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400;
color: #ffffff;
margin-top: 10rpx;
}
&-cx {
color: #999999; color: #999999;
margin-top: 5rpx;
}
&-cxl {
margin-top: 5rpx;
}
&-d {
font-weight: 500;
margin-top: 21rpx;
} }
> text:nth-child(2) {
&-dx {
width: 120rpx;
border: 1rpx solid #999999;
margin: 0 calc((100% - 120rpx - 2rpx) / 2);
height: 44rpx;
line-height: 44rpx;
border-radius: 10rpx;
color: #999999; color: #999999;
margin-top: 17rpx;
}
&-dxl {
width: 120rpx;
height: 44rpx;
line-height: 44rpx;
margin: 0 calc((100% - 120rpx) / 2);
background: #ffffff;
border-radius: 10rpx;
color: #4486ff;
background-color: #ffffff;
margin-top: 17rpx;
} }
}
&-b {
font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400;
color: #333333;
}
&-bx {
color: #999999;
}
}
&-rk {
width: 170rpx;
height: 200rpx;
right: 0rpx;
top: 0rpx;
> view {
text-align: center;
}
&-a {
font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400;
color: #ffffff;
margin-top: 26rpx;
}
&-ax {
color: #999999;
margin-top: 21rpx;
}
&-axl {
margin-top: 21rpx;
}
&-b {
font-size: 30rpx;
font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi;
font-weight: 500;
color: #ffffff;
margin-top: 10rpx;
}
&-bx {
color: #666666;
margin-top: 5rpx;
}
&-bxl {
margin-top: 5rpx;
}
&-c,
&-d {
font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400;
color: #ffffff;
margin-top: 10rpx;
}
&-cx {
color: #999999;
margin-top: 5rpx;
}
&-cxl {
margin-top: 5rpx;
}
&-d {
font-weight: 500;
margin-top: 21rpx;
}
&-dx {
width: 120rpx;
border: 1rpx solid #999999;
margin: 0 calc((100% - 120rpx - 2rpx) / 2);
height: 44rpx;
line-height: 44rpx;
border-radius: 10rpx;
color: #999999;
margin-top: 17rpx;
}
&-dxl {
width: 120rpx;
height: 44rpx;
line-height: 44rpx;
margin: 0 calc((100% - 120rpx) / 2);
background: #ffffff;
border-radius: 10rpx;
color: #4486ff;
background-color: #ffffff;
margin-top: 17rpx;
} }
} }
} }
} }
} }
} }
}
</style> </style>
...@@ -8,16 +8,16 @@ ...@@ -8,16 +8,16 @@
<view v-show="subscript == index" class="content-tabs-text-area"></view> <view v-show="subscript == index" class="content-tabs-text-area"></view>
</view> </view>
</view> </view>
<template v-if="arr && arr.length"> <!-- <template v-if="arr && arr.length"> -->
<comindex class="content-mindex" :subscript='subscript'></comindex> <comindex class="content-mindex" :subscript='subscript'></comindex>
</template> <!-- </template> -->
<view v-else class="diagram"> <!-- <view v-else class="diagram">
<image src="@/static/icon/qst.png" mode=""></image> <image src="@/static/icon/qst.png" mode=""></image>
<view class=""> <view class="">
暂无数据 暂无数据
</view> </view>
</view> </view> -->
<com-tabbar @tabBarChange='tabBarChange' :list=" [{ <com-tabbar :list=" [{
name: '首页', name: '首页',
icon: '/static/tabbar/tb1.png', icon: '/static/tabbar/tb1.png',
selectIcon:'/static/tabbar/td1.png', selectIcon:'/static/tabbar/td1.png',
...@@ -84,13 +84,6 @@ ...@@ -84,13 +84,6 @@
} }
}, },
methods: { methods: {
tabBarChange(url, type) {
if (type == 'type') {
uniGo.reLaunch({
url: url
});
}
},
jump(ind) { jump(ind) {
this.subscript = ind this.subscript = ind
} }
......
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
</view> </view>
<com-navbar :leftIcon="false" :homeShow="false" bgColor="transparent" title="首页" <com-navbar :leftIcon="false" :homeShow="false" bgColor="transparent" title="首页"
:titleStyle="{ color: '#FFFFFF', fontSize: '32rpx',scrollTopHeader: scrollTopHeader }" /> :titleStyle="{ color: '#FFFFFF', fontSize: '32rpx',scrollTopHeader: scrollTopHeader }" />
<com-tabbar @tabBarChange='tabBarChange' :list="tabBarList"></com-tabbar> <com-tabbar :list="tabBarList"></com-tabbar>
</view> </view>
</template> </template>
...@@ -100,13 +100,6 @@ ...@@ -100,13 +100,6 @@
url: `/home/index/index` url: `/home/index/index`
}); });
}, },
tabBarChange(url, type) {
if (type == 'type') {
this.$uniGo.reLaunch({
url: url
});
}
}
} }
} }
</script> </script>
...@@ -119,7 +112,6 @@ ...@@ -119,7 +112,6 @@
.content { .content {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
// align-items: center;
justify-content: center; justify-content: center;
&-swiper { &-swiper {
...@@ -149,7 +141,6 @@ ...@@ -149,7 +141,6 @@
>view:nth-child(2) { >view:nth-child(2) {
font-size: 28rpx; font-size: 28rpx;
font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi;
font-weight: 500; font-weight: 500;
color: #333333; color: #333333;
} }
...@@ -173,7 +164,6 @@ ...@@ -173,7 +164,6 @@
>view:nth-child(1) { >view:nth-child(1) {
font-size: 28rpx; font-size: 28rpx;
font-family: AlibabaPuHuiTi-Medium, AlibabaPuHuiTi;
font-weight: 700; font-weight: 700;
color: #333333; color: #333333;
margin-top: 8rpx; margin-top: 8rpx;
...@@ -182,7 +172,6 @@ ...@@ -182,7 +172,6 @@
>view:nth-child(2) { >view:nth-child(2) {
margin-top: 6rpx; margin-top: 6rpx;
font-size: 24rpx; font-size: 24rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400; font-weight: 400;
color: #444444; color: #444444;
} }
...@@ -190,7 +179,6 @@ ...@@ -190,7 +179,6 @@
>view:nth-child(3) { >view:nth-child(3) {
margin-top: 9rpx; margin-top: 9rpx;
font-size: 20rpx; font-size: 20rpx;
font-family: AlibabaPuHuiTi-Regular, AlibabaPuHuiTi;
font-weight: 400; font-weight: 400;
color: #5281FF; color: #5281FF;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment