Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mini-program-wepy
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ui
mini-program-wepy
Commits
ee2f2d9a
Commit
ee2f2d9a
authored
May 27, 2020
by
ziyu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
improvement: 优化
parent
11ce226e
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
33 additions
and
15 deletions
+33
-15
popup.wpy
src/components/custom/popup.wpy
+18
-2
help.wpy
src/pages/help.wpy
+2
-2
index.wpy
src/pages/index.wpy
+1
-1
raffle.wpy
src/pages/raffle.wpy
+12
-10
No files found.
src/components/custom/popup.wpy
View file @
ee2f2d9a
...
@@ -5,6 +5,11 @@
...
@@ -5,6 +5,11 @@
<image class="image" :src="item.img"></image>
<image class="image" :src="item.img"></image>
<span class="desc">{{item.title}}</span>
<span class="desc">{{item.title}}</span>
</div>
</div>
<div class="popup-item">
<button class="help-button" open-type="contact"></button>
<image class="image" src="/static/images/help@2x.png"></image>
<span class="desc">问题反馈</span>
</div>
</div>
</div>
</div>
</div>
</template>
</template>
...
@@ -22,7 +27,6 @@
...
@@ -22,7 +27,6 @@
menus: [
menus: [
{ img: '/static/images/awards@2x.png', title: '我的抽奖', path: '/pages/myraffles' },
{ img: '/static/images/awards@2x.png', title: '我的抽奖', path: '/pages/myraffles' },
{ img: '/static/images/feedback@2x.png', title: '规则与帮助', path: '/pages/help' },
{ img: '/static/images/feedback@2x.png', title: '规则与帮助', path: '/pages/help' },
{ img: '/static/images/help@2x.png', title: '问题反馈', path: '/pages/help' }
],
],
show: false,
show: false,
popupStyle: ''
popupStyle: ''
...
@@ -98,6 +102,7 @@
...
@@ -98,6 +102,7 @@
display: flex;
display: flex;
flex-direction: column;
flex-direction: column;
align-items: center;
align-items: center;
position: relative;
.image {
.image {
width: 50rpx;
width: 50rpx;
height: 50rpx;
height: 50rpx;
...
@@ -109,7 +114,18 @@
...
@@ -109,7 +114,18 @@
}
}
}
}
}
}
.help-button {
width: 100%;
height:100%;
position: absolute;
background-color: transparent;
border:none;
top:0;
left:0;
}
.help-button::after{
border:none;
}
.popup-wrapper_show{
.popup-wrapper_show{
animation: menuShow .3s linear forwards;
animation: menuShow .3s linear forwards;
}
}
...
...
src/pages/help.wpy
View file @
ee2f2d9a
...
@@ -67,7 +67,7 @@
...
@@ -67,7 +67,7 @@
</view>
</view>
<view class="help-more">
<view class="help-more">
<van-cell title="问题反馈" is-link><button open-type="contact" class="help-button"></button></van-cell>
<van-cell title="问题反馈" is-link><button open-type="contact" class="help-button"></button></van-cell>
<
van-cell title="更多问题" is-link bindtap="tomorehelp"></van-cell
>
<
!--<van-cell title="更多问题" is-link bindtap="tomorehelp"></van-cell>--
>
</view>
</view>
</view>
</view>
</template>
</template>
...
@@ -84,7 +84,7 @@
...
@@ -84,7 +84,7 @@
}
}
},
},
onLoad (
query
) {
onLoad () {
},
},
});
});
...
...
src/pages/index.wpy
View file @
ee2f2d9a
...
@@ -614,7 +614,7 @@
...
@@ -614,7 +614,7 @@
},
},
onShow() {
onShow() {
// 从其他小程序回来可以在当前生命周期检测到,但是这个方法,自己的小程序页面返回也会进入
// 从其他小程序回来可以在当前生命周期检测到,但是这个方法,自己的小程序页面返回也会进入
console.log('页面show!!');
//
console.log('页面show!!');
}
}
});
});
</script>
</script>
...
...
src/pages/raffle.wpy
View file @
ee2f2d9a
...
@@ -111,12 +111,12 @@
...
@@ -111,12 +111,12 @@
<template>
<template>
<view class="raffle-wrapper">
<view class="raffle-wrapper">
<view class="raffle-content">
<view class="raffle-content">
<van-image use-loading-slot src="{{
goodsimg
}}" class="img" width="610rpx" height="610rpx" radius="10rpx">
<van-image use-loading-slot src="{{
photoUrl
}}" class="img" width="610rpx" height="610rpx" radius="10rpx">
<van-loading slot="loading" type="spinner" size="20" vertical />
<van-loading slot="loading" type="spinner" size="20" vertical />
</van-image>
</van-image>
<view class="goodsinfo">
<view class="goodsinfo">
<text class="text">{{
goods
}}</text>
<text class="text">{{
name
}}</text>
<text class="money">{{
corn
}}克币</text>
<text class="money">{{
quantity
}}克币</text>
</view>
</view>
<view class="raffle-chance">中奖概率: {{chance}}</view>
<view class="raffle-chance">中奖概率: {{chance}}</view>
<view class="raffle-progress">中奖进度:
<view class="raffle-progress">中奖进度:
...
@@ -143,10 +143,11 @@
...
@@ -143,10 +143,11 @@
progressStyle: '',
progressStyle: '',
isCheck: false,
isCheck: false,
id: null,
id: null,
corn
: '',
quantity
: '',
goods
: '',
name
: '',
chance: '',
chance: '',
goodsimg: ''
photoUrl: '',
batchId:null,
},
},
methods: {
methods: {
check() {
check() {
...
@@ -164,7 +165,7 @@
...
@@ -164,7 +165,7 @@
},
},
joinin() {
joinin() {
if(!this.isCheck) {
if(!this.isCheck) {
Notify({message: '请先勾选
协议
!', background:'#FF5D15'})
Notify({message: '请先勾选!', background:'#FF5D15'})
}
}
}
}
},
},
...
@@ -187,16 +188,17 @@
...
@@ -187,16 +188,17 @@
}
}
},
},
onLoad (query) {
onLoad (query) {
this.batchId = query.batchId;
let {id, corn, goods, chance, imgsrc, progress} = query;
let {id, corn, goods, chance, imgsrc, progress} = query;
if (progress) {
if (progress) {
this.progress = progress;
this.progress = progress;
this.progressStyle = 'width:' + progress + '%';
this.progressStyle = 'width:' + progress + '%';
}
}
this.id = id;
this.id = id;
this.
corn
= corn;
this.
quantity
= corn;
this.
goods
= goods;
this.
name
= goods;
this.chance = chance;
this.chance = chance;
this.
goodsimg
= imgsrc;
this.
photoUrl
= imgsrc;
}
}
});
});
</script>
</script>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment