Commit d8b1aeab by 前端

样式调整

1 parent 002f5112
......@@ -71,9 +71,9 @@ Component({
//报错
showModal(error) {
wx.showModal({
content: error.msg,
showCancel: false,
wx.showToast({
title: error.msg,
icon: 'none',
})
},
......
......@@ -158,9 +158,9 @@ Page({
}
});
if (!selectFlag) {
wx.showModal({
content: "请至少选择一个产品",
showCancel: false,
wx.showToast({
title: "请至少选择一个产品",
icon: 'none',
});
wx.hideLoading();
return;
......@@ -172,7 +172,7 @@ Page({
params.productItems = productItems.join(",");
}
params.cardId = wx.$util.getStorageSync("scene").cardId;
params.merchant = wx.$util.getStorageSync("scene").merchant;
params.merchant = wx.$util.getStorageSync("scene").merchant || wx.$util.getStorageSync("scene").merchantId;
params.openId = wx.$util.getStorageSync("aicard_info").openId;
params.unionId = wx.$util.getStorageSync("aicard_info").unionId;
console.log(params);
......@@ -185,9 +185,9 @@ Page({
wx.$router.go("applySuccess");
} else {
wx.hideLoading();
wx.showModal({
content: message,
showCancel: false,
wx.showToast({
title: message,
icon: 'none',
});
}
});
......
......@@ -2,31 +2,32 @@
<view class="apply-content">
<image class="apply-background" mode="widthFix" webp src="{{IMGURL}}application/application_top.png?v={{img_version}}"></image>
<view class="box-background">
<!-- 产品选择tab -->
<view class="product-tab-box">
<!-- tab栏 -->
<block wx:for="{{productTabList}}">
<view class="product-item {{item.id == selectItemIndex ? 'product-item-active' : ''}}" bindtap="selectProduct" data-item="{{item}}">
<view class="product-item-title {{item.id == selectItemIndex ? 'product-item-title-active' : ''}}">
{{item.title}}
</view>
<view class="product-item-type {{item.id == selectItemIndex ? 'product-item-type-active' : ''}}">
{{item.type}}
</view>
<view wx:if="{{item.id == selectItemIndex}}" class="selected-item">
<view class="selected-item-top"></view>
<view class="selected-item-bottom"></view>
</view>
</view>
</block>
</view>
<!-- 产品展示 -->
<view class="product-box">
<!-- 产品选择tab -->
<view class="product-tab-box">
<!-- tab栏 -->
<block wx:for="{{productTabList}}">
<view class="product-item {{item.id == selectItemIndex ? 'product-item-active' : ''}}" bindtap="selectProduct" data-item="{{item}}">
<view class="product-item-title {{item.id == selectItemIndex ? 'product-item-title-active' : ''}}">
{{item.title}}
</view>
<view class="product-item-type {{item.id == selectItemIndex ? 'product-item-type-active' : ''}}">
{{item.type}}
</view>
<view wx:if="{{item.id == selectItemIndex}}" class="selected-item">
<view class="selected-item-top"></view>
<view class="selected-item-bottom"></view>
</view>
</view>
</block>
</view>
<view class="product-tip">
<image class="tip-icon" mode="widthFix" webp src="{{IMGURL}}application/tip_icon.png?v={{img_version}}"></image>
<image class="tip-icon" wx:if="{{selectItemName == 'scene3'}}" mode="widthFix" webp src="{{IMGURL}}application/tip_icon.png?v={{img_version}}"></image>
<image class="tip-icon" wx:else="" mode="widthFix" webp src="{{IMGURL}}application/tip_icon2.png?v={{img_version}}"></image>
<text class="tip-text">{{sceneTip[selectItemName]}}</text>
</view>
<block wx:for="{{productList[selectItemName]}}">
<block wx:for="{{productList[selectItemName]}}" wx:key="index">
<image wx:if="{{item.name}}" class="product-img" mode="widthFix" webp src="{{IMGURL}}application/{{item.url}}.png?v={{img_version}}" bindtap="goPage" data-item="{{item.name}}"></image>
</block>
</view>
......
......@@ -8,14 +8,12 @@
}
.box-background {
padding-top: 8rpx;
background-image: linear-gradient(179deg, #E3E8FF 0%, #FEFEFE 100%);
}
.product-tab-box {
display: flex;
/* justify-content: space-around; */
padding: 0 26rpx;
margin-bottom: 38rpx;
}
.product-item {
......@@ -92,20 +90,21 @@
}
.product-img {
width: 224rpx;
width: calc((100% - 32rpx)/3);
height: 216rpx;
margin-right: 16rpx;
margin-bottom: 20rpx;
box-shadow: 0 6rpx 24rpx 0 rgba(175, 181, 219, 0.40);
}
.product-img:nth-child(3n) {
.product-img:nth-child(3n+2) {
margin-right: 0;
}
.product-box {
margin: 36rpx 0 56rpx 0;
margin-bottom: 56rpx;
padding: 0 26rpx;
background-image: linear-gradient(179deg, #DBE3FF 0%, #FEFEFE 100%);
}
.product-tip {
......@@ -258,11 +257,13 @@
color: #323436;
letter-spacing: 0;
text-align: center;
line-height: 64rpx;
margin-right: 12rpx;
margin-bottom: 20rpx;
position: relative;
box-sizing: border-box;
display: flex;
align-items: center;
justify-content: center;
}
.item:nth-child(3n) {
......@@ -285,6 +286,6 @@
width: 30rpx;
height: 22rpx;
position: absolute;
top: 0;
right: 0;
top: -1rpx;
right: -1rpx;
}
\ No newline at end of file
......@@ -54,9 +54,9 @@ Page({
//报错
showModal(error) {
wx.showModal({
content: error.msg,
showCancel: false,
wx.showToast({
title: error.msg,
icon: 'none',
})
},
......
......@@ -33,7 +33,7 @@ Page({
// 区分代理商和门店
params.merchantName = applyType == 0 ? params.merchantName + '(新能源-门店)' : params.merchantName + '(新能源-代理商)'
params.cardId = wx.$util.getStorageSync("scene").cardId
params.merchant = wx.$util.getStorageSync("scene").merchant
params.merchant = wx.$util.getStorageSync("scene").merchant || wx.$util.getStorageSync("scene").merchantId
params.openId = wx.$util.getStorageSync('aicard_info').openId
params.unionId = wx.$util.getStorageSync('aicard_info').unionId
console.log(params);
......@@ -50,9 +50,9 @@ Page({
wx.$router.go("applySuccess");
} else {
wx.hideLoading()
wx.showModal({
content: message,
showCancel: false,
wx.showToast({
title: message,
icon: 'none',
})
}
})
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!