|
@@ -17,7 +17,9 @@ Page({
|
|
|
currentX: 0,
|
|
currentX: 0,
|
|
|
perpage:10,
|
|
perpage:10,
|
|
|
nowpage:1,
|
|
nowpage:1,
|
|
|
- cartMore:true
|
|
|
|
|
|
|
+ cartMore:true,
|
|
|
|
|
+ cent:0,
|
|
|
|
|
+ centlist: []
|
|
|
},
|
|
},
|
|
|
handleMovableChange: function(e) {
|
|
handleMovableChange: function(e) {
|
|
|
// this.data.currentX = e.detail.x;
|
|
// this.data.currentX = e.detail.x;
|
|
@@ -48,12 +50,42 @@ Page({
|
|
|
onShow: function () {
|
|
onShow: function () {
|
|
|
this.setData({cartList:[]})
|
|
this.setData({cartList:[]})
|
|
|
this.getCartList();
|
|
this.getCartList();
|
|
|
|
|
+ this.getBalanceInfo();
|
|
|
|
|
+ this.getCentAct();
|
|
|
this.setData({
|
|
this.setData({
|
|
|
submitlock: false,
|
|
submitlock: false,
|
|
|
selectedall: false
|
|
selectedall: false
|
|
|
});
|
|
});
|
|
|
// this.getCartListAndSelected();
|
|
// this.getCartListAndSelected();
|
|
|
},
|
|
},
|
|
|
|
|
+ getCentAct(){
|
|
|
|
|
+ var that = this
|
|
|
|
|
+ var url = 'v1/task_sign/daily/check'
|
|
|
|
|
+ var params = {
|
|
|
|
|
+ }
|
|
|
|
|
+ var success = function (res) {
|
|
|
|
|
+ var result = res.data
|
|
|
|
|
+ that.setData({
|
|
|
|
|
+ centlist: result
|
|
|
|
|
+ })
|
|
|
|
|
+ console.log('getCentAct',result)
|
|
|
|
|
+ }
|
|
|
|
|
+ _request.$get(url, params, success)
|
|
|
|
|
+ },
|
|
|
|
|
+ getBalanceInfo () {
|
|
|
|
|
+ var that = this
|
|
|
|
|
+ var url = 'v1/user/cent/info'
|
|
|
|
|
+ var params = {
|
|
|
|
|
+ }
|
|
|
|
|
+ var success = function (res) {
|
|
|
|
|
+ var result = res.data.total
|
|
|
|
|
+ that.setData({
|
|
|
|
|
+ cent: result
|
|
|
|
|
+ })
|
|
|
|
|
+ console.log('getBalanceInfo',result)
|
|
|
|
|
+ }
|
|
|
|
|
+ _request.$get(url, params, success)
|
|
|
|
|
+ },
|
|
|
getCartList:function(){
|
|
getCartList:function(){
|
|
|
console.log('getCartList')
|
|
console.log('getCartList')
|
|
|
var that = this
|
|
var that = this
|