| @@ -19,7 +19,7 @@ | |||||
| background: #fff; | background: #fff; | ||||
| font-size: 28rpx; | font-size: 28rpx; | ||||
| font-weight: 400; | font-weight: 400; | ||||
| color: rgba(2, 192, 255, 1); | |||||
| color: #fc5b24; | |||||
| border-bottom-left-radius: 50rpx; | border-bottom-left-radius: 50rpx; | ||||
| border-top-left-radius: 50rpx; | border-top-left-radius: 50rpx; | ||||
| } | } | ||||
| @@ -1,7 +1,6 @@ | |||||
| var config = require("../../config/config.js"); | var config = require("../../config/config.js"); | ||||
| const Http = require("../../utils/HttpBasics"); | const Http = require("../../utils/HttpBasics"); | ||||
| const imgurl = require("../../utils/imgurl"); | const imgurl = require("../../utils/imgurl"); | ||||
| const { spellStatus, spellStatus02 } = require("../../utils/spell"); | |||||
| Page({ | Page({ | ||||
| /** | /** | ||||
| * 页面的初始数据 | * 页面的初始数据 | ||||
| @@ -26,7 +25,12 @@ Page({ | |||||
| }, | }, | ||||
| onLoad: function (options) { | onLoad: function (options) { | ||||
| let that = this; | let that = this; | ||||
| that.getBannerlist(); | |||||
| console.log(options) | |||||
| if (options &&options.credit){ | |||||
| that.setData({ | |||||
| credit: options.credit | |||||
| }) | |||||
| } | |||||
| var todayDate = new Date().getTime(); | var todayDate = new Date().getTime(); | ||||
| that.setData({ | that.setData({ | ||||
| optionsData: options, | optionsData: options, | ||||
| @@ -59,23 +63,6 @@ Page({ | |||||
| url: '/pages/integralmall/integraHistory/index', | url: '/pages/integralmall/integraHistory/index', | ||||
| }) | }) | ||||
| }, | }, | ||||
| /** | |||||
| * banner | |||||
| */ | |||||
| getBannerlist: function () { | |||||
| let that = this; | |||||
| Http.get({ | |||||
| url: config.api.bannerlist, | |||||
| data: { | |||||
| pageNum: 1, | |||||
| pageSize: 7 | |||||
| } | |||||
| }).then(res => { | |||||
| that.setData({ | |||||
| list: res.data.list | |||||
| }); | |||||
| }); | |||||
| }, | |||||
| getList(pageNum) { | getList(pageNum) { | ||||
| var that = this; | var that = this; | ||||
| console.log(pageNum) | console.log(pageNum) | ||||
| @@ -180,7 +167,6 @@ Page({ | |||||
| */ | */ | ||||
| onPullDownRefresh: function (e) { | onPullDownRefresh: function (e) { | ||||
| let that = this; | let that = this; | ||||
| that.getBannerlist(); | |||||
| that.getList(1); | that.getList(1); | ||||
| } | } | ||||
| }) | }) | ||||
| @@ -2,7 +2,7 @@ | |||||
| <view class='topbg'> | <view class='topbg'> | ||||
| <image bindtap='gotojifen' src='{{wangmeimeicredit}}' mode='widthFix'></image> | <image bindtap='gotojifen' src='{{wangmeimeicredit}}' mode='widthFix'></image> | ||||
| <text class='my'>我的积分</text> | <text class='my'>我的积分</text> | ||||
| <text class='score'>200</text> | |||||
| <text class='score'>{{credit}}</text> | |||||
| </view> | </view> | ||||
| <view class='no-data01' wx:if='{{lists.length==0}}'> | <view class='no-data01' wx:if='{{lists.length==0}}'> | ||||
| <image src='{{nodata}}'></image> | <image src='{{nodata}}'></image> | ||||
| @@ -36,7 +36,6 @@ Page({ | |||||
| */ | */ | ||||
| onShow: function () { | onShow: function () { | ||||
| let that = this; | let that = this; | ||||
| that.getScore(); | |||||
| that.record(1, 15); | that.record(1, 15); | ||||
| }, | }, | ||||
| record(pageNum) { | record(pageNum) { | ||||
| @@ -67,7 +66,6 @@ Page({ | |||||
| }); | }); | ||||
| } | } | ||||
| that.data.list = that.data.list.concat(res.data.list); | that.data.list = that.data.list.concat(res.data.list); | ||||
| console.log(that.data.list,22222222222) | |||||
| that.setData({ | that.setData({ | ||||
| list: that.data.list, | list: that.data.list, | ||||
| creditAmount: that.data.list[0].creditAmount | creditAmount: that.data.list[0].creditAmount | ||||
| @@ -84,20 +82,6 @@ Page({ | |||||
| }) | }) | ||||
| } | } | ||||
| }, | }, | ||||
| getScore: function () { | |||||
| let that = this; | |||||
| Http.get({ | |||||
| url: config.api.getScore, | |||||
| data: {} | |||||
| }) | |||||
| .then(res => { | |||||
| console.log(res) | |||||
| that.setData({ | |||||
| score: res.data.score, | |||||
| levelName: res.data.levelName, | |||||
| }) | |||||
| }) | |||||
| }, | |||||
| /** | /** | ||||
| * 刷新 | * 刷新 | ||||
| */ | */ | ||||
| @@ -110,8 +110,9 @@ Page({ | |||||
| }, | }, | ||||
| //跳往积分商城 | //跳往积分商城 | ||||
| gotouser:function(){ | gotouser:function(){ | ||||
| let credit = this.data.credit; | |||||
| wx.navigateTo({ | wx.navigateTo({ | ||||
| url: '/pages/integralmall/index', | |||||
| url: `/pages/integralmall/index?credit=${credit}` | |||||
| }) | }) | ||||
| }, | }, | ||||
| //跳往砍价专场 | //跳往砍价专场 | ||||