Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
W
wechatapp.shangjiadao.com
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
wangxuelai
wechatapp.shangjiadao.com
Commits
29d38eb4
Commit
29d38eb4
authored
May 21, 2019
by
wangxuelai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
''
parent
34242bb1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
750 additions
and
0 deletions
+750
-0
app.json
app.json
+7
-0
index.js
business/pages/scoremgt/index.js
+169
-0
index.json
business/pages/scoremgt/index.json
+4
-0
index.wxml
business/pages/scoremgt/index.wxml
+326
-0
index.wxss
business/pages/scoremgt/index.wxss
+244
-0
addprize.png
images/2b/scoremgt/addprize.png
+0
-0
exchangeprize.png
images/2b/scoremgt/exchangeprize.png
+0
-0
scan.png
images/2b/scoremgt/scan.png
+0
-0
scoresetting.png
images/2b/scoremgt/scoresetting.png
+0
-0
No files found.
app.json
View file @
29d38eb4
...
...
@@ -547,6 +547,13 @@
"index"
]
},
{
"root"
:
"business/pages/scoremgt"
,
"name"
:
"businessscoremgt"
,
"pages"
:
[
"index"
]
},
{
"root"
:
"business/pages/activityconsumers"
,
"name"
:
"businessactivityconsumers"
,
...
...
business/pages/scoremgt/index.js
0 → 100644
View file @
29d38eb4
// src/pages/activityindex/index.js
import
{
wxChooseImage
,
wxUploadFile
}
from
'../../../utilities/wxApi.js'
;
import
{
cOssAccess
,
}
from
'../../../service/common.js'
;
import
{
getRandomFilename
,
LocalStorage
}
from
'../../../utilities/index.js'
;
import
{
userShow
,
}
from
'../../../service/customer/themeindex.js'
;
var
app
=
getApp
();
Page
({
/**
* 页面的初始数据
*/
data
:
{
imageRoot
:
app
.
globalData
.
imageRoot
,
imageVersion
:
app
.
globalData
.
imageVersion
,
localImageRoot
:
"../../../images/"
,
submiting
:
false
,
sid
:
0
,
userInfo
:
{}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad
:
function
(
options
)
{
const
{
sid
,
}
=
options
;
this
.
setData
({
sid
,
})
wx
.
hideShareMenu
()
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady
:
function
()
{
},
/**
* 生命周期函数--监听页面显示
*/
onShow
:
function
()
{
this
.
userShow
();
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide
:
function
()
{
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload
:
function
()
{
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh
:
function
()
{
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom
:
function
()
{
},
/**
* 用户点击右上角分享
*/
onShareAppMessage
:
function
()
{
},
userShow
()
{
const
visitor
=
LocalStorage
.
getItem
(
'visitor'
);
userShow
({
school_id
:
this
.
data
.
sid
,
consumer_id
:
visitor
&&
visitor
.
id
||
0
}).
then
((
res
)
=>
{
const
{
data
,
code
}
=
res
;
if
(
code
==
30005
)
{
this
.
setData
({
noUserinfo
:
true
})
}
if
(
code
==
200
)
{
if
(
data
)
{
this
.
setData
({
userInfo
:
data
,
noUserinfo
:
false
,
})
}
else
{
this
.
setData
({
noUserinfo
:
true
})
}
}
}).
then
(()
=>
{
})
},
chooseImg
()
{
let
access
=
{};
let
filename
=
''
;
cOssAccess
().
then
((
acc
)
=>
{
access
=
acc
.
data
;
return
wxChooseImage
({})
}).
then
((
res
)
=>
{
const
{
tempFiles
}
=
res
;
filename
=
`
${
access
.
dir
}${
getRandomFilename
(
tempFiles
[
0
].
path
)}
`
;
wx
.
showLoading
({
title
:
'图片上传中'
})
return
wxUploadFile
({
url
:
access
.
host
,
formData
:
{
key
:
filename
,
policy
:
access
.
policy
,
OSSAccessKeyId
:
access
.
accessid
,
signature
:
access
.
signature
,
callback
:
access
.
callback
,
success_action_status
:
'200'
},
filePath
:
tempFiles
[
0
].
path
,
name
:
'file'
,
})
}).
then
((
res
)
=>
{
const
{
data
}
=
res
;
if
(
data
==
'{"status":"ok"}'
)
{
wx
.
showToast
({
title
:
'上传成功'
})
this
.
setData
({
img
:
filename
})
}
else
{
wx
.
hideLoading
();
wx
.
showModal
({
title
:
'提示'
,
content
:
'上传失败'
,
showCancel
:
false
})
}
}).
catch
((
err
)
=>
{
});
}
})
\ No newline at end of file
business/pages/scoremgt/index.json
0 → 100644
View file @
29d38eb4
{
"usingComponents"
:
{},
"navigationBarTitleText"
:
"积分商城"
}
\ No newline at end of file
business/pages/scoremgt/index.wxml
0 → 100644
View file @
29d38eb4
This diff is collapsed.
Click to expand it.
business/pages/scoremgt/index.wxss
0 → 100644
View file @
29d38eb4
.container {
background-color: #fff;
padding-bottom: 50rpx;
}
.header-box {
display: flex;
align-items: center;
justify-content: space-around;
padding: 40rpx 0 36rpx;
}
.btnitem {
width: 120rpx;
/* display: flex; */
text-align: center;
}
.btnitem .iconbox {
margin: 0 auto;
width: 80rpx;
height: 64rpx;
display: flex;
align-items: center;
justify-content: center;
}
.btnitem .iconbox image {
display: block;
}
.btnitem .iconbox .scoresetting {
width: 64rpx;
height: 61rpx;
}
.btnitem .iconbox .addprize {
width: 75rpx;
height: 55rpx;
}
.btnitem .iconbox .exchangeprize {
width: 63rpx;
height: 63rpx;
}
.btnitem .iconbox .scan {
width: 59rpx;
height: 57rpx;
}
.btnitem .btnname {
font-size: 24rpx;
color: #000;
}
.divideline {
height: 20rpx;
background-color: #F7F7F9;
}
.areatitle {
font-size: 30rpx;
color: #000000;
font-weight: 700;
padding-left: 24rpx;
padding-top: 50rpx;
line-height: 1;
margin-bottom: 38rpx;
}
.prizecontent {
display: flex;
/* justify-content: center; */
flex-wrap: wrap;
padding: 0 24rpx;
}
.prizecardbox {
width: 50%;
margin-bottom: 24rpx;
display: flex;
/* flex-direction: column; */
}
.prizecardbox.odd{
justify-content: flex-start;
}
.prizecardbox.even{
justify-content: flex-end;
}
.prizecontent .prizecard {
border-radius: 20rpx;
overflow: hidden;
width: 310rpx;
/* margin: 0 auto; */
height: 364rpx;
box-shadow: 0px 0px 10rpx 0px rgba(0, 0, 0, 0.1);
}
.prizecontent .prizecard .prizeimage{
display: block;
height: 270rpx;
width: 100%;
margin-bottom: 16rpx;
}
.prizecontent .prizecard .prizename {
color: #000;
font-size: 24rpx;
width: 100;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
padding: 0 20rpx;
margin-bottom: 18rpx;
line-height: 1;
}
.prizestatic {
padding: 0 20rpx;
display: flex;
align-items: center;
justify-content: space-between;
}
.prizestatic .scoreneed{
font-size: 22rpx;
color: #FF5E15;
line-height: 1;
}
.prizestatic .prizeleft{
font-size: 22rpx;
color: #878787;
line-height: 1;
}
.couponcontent {
display: flex;
/* justify-content: center; */
flex-wrap: wrap;
padding: 0 24rpx;
}
.couponcardbox {
width: 50%;
display: flex;
}
.couponcardbox.odd {
justify-content: flex-start;
}
.couponcardbox.even {
justify-content: flex-end;
}
.couponcard {
width: 312rpx;
padding-bottom: 30rpx;
}
.couponitem {
width: 100%;
height: 184rpx;
position: relative;
margin-bottom: 25rpx;
display: flex;
}
.couponitem .couponimgbox {
width: 43%;
position: relative;
z-index: 2;
display: flex;
align-items: center;
justify-content: center;
}
.couponitem .couponimgbox .couponimg {
display: block;
width: 98rpx;
height: 98rpx;
border-radius: 50%;
box-shadow: 0px 4rpx 8rpx 0px rgba(255,71,111,0.4);
}
.couponitem .couponinfobox {
width: 57%;
position: relative;
z-index: 2;
display: flex;
align-items: center;
flex-direction: column;
justify-content: center;
color: #fff;
}
.couponitem .couponinfobox .top {
font-size: 30rpx;
font-weight: 700;
line-height: 1;
margin-bottom: 16rpx;
}
.couponitem .couponinfobox .middle {
font-size: 44rpx;
font-weight: 700;
line-height: 1;
margin-bottom: 18rpx;
}
.couponitem .couponinfobox .bottom {
font-size: 24rpx;
line-height: 1;
}
.couponitem .couponbg {
position: absolute;
z-index: 0;
width: 100%;
height: 100%;
left: 0;
top: 0;
}
.couponcard .couponcardname {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
color: #000000;
font-size: 24rpx;
line-height: 1;
}
.empty-content {
padding-top: 152rpx;
}
.empty-content .empty-img-box {
width: 263rpx;
height: 219rpx;
margin: 0 auto;
}
.empty-content .empty-img-box .empty-icon {
width: 263rpx;
height: 219rpx;
}
.empty-content .empty-text {
padding-top: 47rpx;
text-align: center;
font-size: 26rpx;
color: rgba(0, 0, 0, 0.5);
padding-bottom: 217rpx;
}
.prizecardbox .operatebox {
width: 310rpx;
}
.operatebox {
display: flex;
justify-content: space-between;
margin-top: 20rpx;
}
.operatebox .operatebtn{
width: 60px;
height: 26px;
line-height: 26px;
background-color: #F7F7F9;
text-align: center;
font-size: 26rpx;
letter-spacing: 2rpx;
color: #878787;
border-radius: 10rpx;
}
\ No newline at end of file
images/2b/scoremgt/addprize.png
0 → 100644
View file @
29d38eb4
6.89 KB
images/2b/scoremgt/exchangeprize.png
0 → 100644
View file @
29d38eb4
8.9 KB
images/2b/scoremgt/scan.png
0 → 100644
View file @
29d38eb4
9.89 KB
images/2b/scoremgt/scoresetting.png
0 → 100644
View file @
29d38eb4
8.18 KB
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