From 2063c6af222c84215a2f6e7b232c34084dc7a8ac Mon Sep 17 00:00:00 2001 From: hurui Date: Tue, 16 Jul 2019 18:36:35 +0800 Subject: [PATCH] =?UTF-8?q?[=E7=A7=AF=E5=88=86=E5=95=86=E5=9F=8E=EF=BC=8C?= =?UTF-8?q?=E7=89=B9=E4=BA=AB=E7=A4=BC=E9=81=87][=E4=BF=AE=E6=94=B9][?= =?UTF-8?q?=E6=A0=B7=E5=BC=8F]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/acSignIn/index.js | 1 + pages/edit/edit.json | 2 +- pages/index/searchbar/index.wxss | 24 +++++--- pages/integralmall/index.js | 35 +++++++++++- pages/integralmall/index.wxml | 53 +++++++++-------- pages/integralmall/index.wxss | 66 ++++++++++++++-------- pages/specialcourtesy/specialcourtesy.json | 2 +- pages/specialcourtesy/specialcourtesy.wxml | 8 +-- pages/specialcourtesy/specialcourtesy.wxss | 29 ++++++---- pages/user/index.wxml | 6 +- 10 files changed, 151 insertions(+), 75 deletions(-) diff --git a/pages/acSignIn/index.js b/pages/acSignIn/index.js index 349f7b2..913545c 100644 --- a/pages/acSignIn/index.js +++ b/pages/acSignIn/index.js @@ -21,6 +21,7 @@ Page({ }) } }, + // pages/index/searchbar/index signIn(id){ let that = this; Http.post({ diff --git a/pages/edit/edit.json b/pages/edit/edit.json index 137be15..bfcbe4c 100644 --- a/pages/edit/edit.json +++ b/pages/edit/edit.json @@ -1,3 +1,3 @@ { - "navigationBarTitleText": "编辑资料" + "navigationBarTitleText": "我的资料" } \ No newline at end of file diff --git a/pages/index/searchbar/index.wxss b/pages/index/searchbar/index.wxss index 4f4244c..0bfe3ea 100644 --- a/pages/index/searchbar/index.wxss +++ b/pages/index/searchbar/index.wxss @@ -15,9 +15,21 @@ height: 100rpx; line-height: 100rpx; text-align: center; - font-size: 34rpx; + font-size: 30rpx; font-family: PingFangSC-Semibold; - color: rgba(51, 51, 51, 1); + color: #3C3C3C; + background: #FFFFFF; + font-weight:500; +} +.text-styleHover{ + position: relative; + width: 139rpx; + height: 100rpx; + line-height: 100rpx; + text-align: center; + font-size: 26rpx; + font-family: PingFangSC-Semibold; + color: #A6A6A6; } .text-style text{ font-size: 26rpx; @@ -25,14 +37,12 @@ .active1 { font-size: 30rpx!important; } - .active { position: absolute; left: 20rpx; bottom: 0rpx; top:0; margin: auto; - width:12rpx; height:24rpx; background:linear-gradient(127deg,rgba(252,177,74,1) 0%,rgba(254,70,20,1) 100%); @@ -78,8 +88,8 @@ top: 0; bottom: 0; margin: auto; - width: 50rpx; - height: 50rpx; + width: 60rpx; + height: 60rpx; } .merchants{ width: 90%; @@ -103,7 +113,6 @@ width: 120rpx; height: 120rpx; border-radius: 16rpx; - border: 1rpx solid #e5e5e5; } .merchants view:nth-child(2) { @@ -112,6 +121,7 @@ .shopVo{ display: flex; padding-left: 0!important; + } .merchants view:nth-child(2) text:nth-child(1) { display: block; diff --git a/pages/integralmall/index.js b/pages/integralmall/index.js index 1da5de4..52cd5a2 100644 --- a/pages/integralmall/index.js +++ b/pages/integralmall/index.js @@ -24,6 +24,7 @@ Page({ content: '数据正在加载中', reloadIf: false, creditAmount: 0, + score: '0', }, goback: function () { wx.switchTab({ @@ -58,7 +59,39 @@ Page({ that.setData({ lists: null }) - } + }; + Http.get({ + url: config.api.getScore, + data: {} + }).then(res => { + if (res.data.address && res.data.name && res.data.sex && res.data.birthdate) { + that.setData({ + showEdit: true + }) + } + that.setData({ + score: res.data.score, + levelName: res.data.levelName, + }) + if (res.data.nickName) { + that.setData({ + ismember: true, + memberId: res.data.id + }) + var size = this.setCanvasSize(); + var initUrl = JSON.stringify({ + flagid: res.data.id + }); + that.createQrCode(initUrl, "mycanvas1", size.w, size.h); + } + }) + .catch(err => { + wx.showModal({ + title: '提示', + content: err.errMsg, + showCancel: false + }) + }) }, // 获得积分,渲染页面 getPoints(){ diff --git a/pages/integralmall/index.wxml b/pages/integralmall/index.wxml index a6ab592..79ef8c2 100644 --- a/pages/integralmall/index.wxml +++ b/pages/integralmall/index.wxml @@ -1,28 +1,37 @@ - - - - - - - {{levelName}} + + + + + + + + + {{levelName}} + + + + + + + 还需{{upgradeScore}}成长值升级 - - - - - 还需1成长值升级 - {{creditAmount}} - - 可用积分> - - - - + + + {{creditAmount}} + + 可用积分> + + + + + + + @@ -47,13 +56,13 @@ 立即换购 - 已兑完 + 立即换购 - 可用于店内套餐消费 - 剩余222张 + {{item.subTitle}} + 剩余{{item.remainInventory}}张 diff --git a/pages/integralmall/index.wxss b/pages/integralmall/index.wxss index 7e34d85..01337fe 100644 --- a/pages/integralmall/index.wxss +++ b/pages/integralmall/index.wxss @@ -2,19 +2,30 @@ .topbg { margin-bottom: 30rpx; - position: relative; width:100%; height:234rpx; background:linear-gradient(180deg,rgba(253,131,45,1) 0%,rgba(254,74,22,1) 100%); } +.topbg-top{ + width:100%; + height: 50%; + display: inline-block +} +.topbg-btom{ + width:100%; + height: 50%; +} .user-avatar { - position: absolute; + width: 20%; + height: 100%; + float: left; +} +.user-box { width: 82rpx; height: 82rpx; border-radius: 50%; overflow: hidden; - top:26rpx; - left:60rpx; + margin: 26rpx 0 0 60rpx; } .user-avatar open-data { display: block; @@ -30,11 +41,12 @@ margin:0 20rpx; } .usre_level{ - width:70rpx; + /* width:70rpx; */ height:32rpx; background:linear-gradient(127deg,rgba(252,177,74,1) 0%,rgba(254,70,20,1) 100%); border-radius:9px 9px 9px 0px; font-family:PingFangSC-Regular; + font-size: 22rpx; font-weight:400; color:rgba(255,255,255,1); line-height:32rpx; @@ -48,36 +60,38 @@ margin-left: 10rpx; } .myName{ - position: absolute; - left: 152rpx; - top:26rpx; + float: left; font-size: 32rpx; - height: 82rpx; + height: 100%; + width:35%; + margin-top:36rpx; } - -.view { - position: absolute; - top: 45rpx; - left: 170rpx; +.view{ + /* margin-top:25rpx; */ + display: block; + margin: 60rpx 0 0 20rpx; } progress{ width:214rpx; height: 6rpx; - display:inline-block; border-radius:60rpx; overflow:hidden; } .msg{ - position: absolute; - top: 68rpx; - left:400rpx; + float: left; font-size:10px!important; font-family:PingFangSC-Regular; font-weight:400; color:rgba(255,255,255,1); - width: 200rpx; + width: 30%; + height: 100%; + margin-top:80rpx; +} +.btoml{ + float: left; + height: 100%; + width: 60%; } - .jifen{ font-size: 20rpx; font-weight: 500; @@ -96,18 +110,17 @@ progress{ left:70rpx; color: #FFFFFF; } + .qrcode{ width: 84rpx; height: 84rpx; - position: absolute; - bottom: 38rpx; - right: 48rpx; + float: right; + margin-right: 48rpx; } .qrcode image { margin: auto; width: 84rpx; } - page { height: auto; overflow: auto; @@ -194,6 +207,9 @@ image{ float: left; margin-left: 20rpx; color: #A6A6A6; + overflow: hidden; + text-overflow:ellipsis; + white-space: nowrap; } .spell-bot .botNum{ width: 40%; @@ -216,7 +232,7 @@ image{ } .content .spell-center{ float: left; - width: 304rpx; + width: 380rpx; height: 170rpx; } .content .tilte{ diff --git a/pages/specialcourtesy/specialcourtesy.json b/pages/specialcourtesy/specialcourtesy.json index 6339287..6f07031 100644 --- a/pages/specialcourtesy/specialcourtesy.json +++ b/pages/specialcourtesy/specialcourtesy.json @@ -1,5 +1,5 @@ { "navigationBarTitleText": "我的特权", - "navigationBarBackgroundColor": "#fc5b24", + "navigationBarBackgroundColor": "#FD832D", "navigationBarTextStyle": "white" } diff --git a/pages/specialcourtesy/specialcourtesy.wxml b/pages/specialcourtesy/specialcourtesy.wxml index 5f3a2f6..d181ab2 100644 --- a/pages/specialcourtesy/specialcourtesy.wxml +++ b/pages/specialcourtesy/specialcourtesy.wxml @@ -4,10 +4,10 @@ - 会员码:{{memberId}} - - - 会员等级为[{{level}}]对应门店的优惠折扣 + 会员码:{{memberId}} + + 会员等级为[{{level}}]对应门店的优惠折扣 + diff --git a/pages/specialcourtesy/specialcourtesy.wxss b/pages/specialcourtesy/specialcourtesy.wxss index 9e99ad1..0b32a8c 100644 --- a/pages/specialcourtesy/specialcourtesy.wxss +++ b/pages/specialcourtesy/specialcourtesy.wxss @@ -1,7 +1,7 @@ @import "../../app.wxss"; Page { - background: #fc5b24; + background:linear-gradient(180deg,#FD832D 0%,#FE4A16 100%); } .none { @@ -27,7 +27,7 @@ Page { .title { padding: 20rpx 40rpx 30rpx; - color: #fff; + color: #3C3C3C; text-align: center; font-size: 26rpx; } @@ -156,20 +156,14 @@ Page { } .code { - width: 684rpx; + width: 714rpx; + height: 794rpx; background: #fff; margin: 0 auto; border-radius: 10rpx; padding: 20rpx 0 40rpx; } -.code text { - color: #666; - display: block; - text-align: center; - font-size: 28rpx; -} - #barcode { width: 600rpx; height: 150rpx; @@ -178,8 +172,21 @@ Page { .code image { display: block; - width: 500rpx; + width: 358rpx; + height: 358rpx; + margin: 142rpx 178rpx 72rpx; +} +.memCode{ + width: 562rpx; + height: 88rpx; + line-height: 88rpx; + border-radius:16rpx; + border:1px solid rgba(225,225,225,1); margin: 0 auto; + color: #666; + display: block; + font-size: 28rpx; + text-align: center; } .building{ display: inline-block; diff --git a/pages/user/index.wxml b/pages/user/index.wxml index ed0e6ae..8d5b670 100644 --- a/pages/user/index.wxml +++ b/pages/user/index.wxml @@ -1,11 +1,11 @@ - + - - + + {{levelName}}