Siryuanshao 6 years ago
commit dfce41f267

@ -36,4 +36,5 @@ Page({
duration: 2000
});
},
})

@ -103,4 +103,4 @@ text {
display: block;
font-size: 25rpx;
margin: 10rpx;
}
}

@ -5,6 +5,7 @@ Page({
* 页面的初始数据
*/
data: {
'iscart':false,
'goodList': [
{
'cover': '/pages/index/image/suanfa.jpg',
@ -178,6 +179,7 @@ Page({
this.calculateTotal();
},
/**
* 生命周期函数--监听页面加载
*/
@ -233,6 +235,18 @@ Page({
onShareAppMessage: function () {
},
newAddress: function () {
if (this.data.totalCount >0)
{wx.navigateTo({
url: '/pages/order/order'
})}
else
{
wx.showToast({
title: '没有选择商品',
icon: 'success',
duration: 2000
})
}
}
})

@ -61,9 +61,9 @@
<text>¥{{totalPrice}}</text>
</view>
</view>
<navigator url='../checkout/index'>
<view class='btn {{totalCount > 0 ? "btn-primary" : "btn-default"}}'>去结算</view>
</navigator>
<view class='btn {{totalCount > 0 ? "btn-primary" : "btn-default"}}' bindtap="newAddress">去结算</view>
</view>

@ -11,7 +11,7 @@ Page({
'totalPrice': 0,
'address':'湖南师范大学理学院',
'consignee': "杨盼成",
'phone': '12345678912',
'phone': '123456789',
'unpaidList': [//待付款
{
'cover': '../index/image/suanfa.jpg',

@ -15,6 +15,12 @@ Page({
url: '/pages/userInfo/userInfo'
})
},
towode: function () {
wx.switchTab
({
url: "/pages/wode/wode"
})
},
bindDateChange: function (e) {
this.setData({
date: e.detail.value
@ -25,10 +31,5 @@ Page({
this.setData({
tapCurrent: current
})
},
newAddress: function () {
wx.navigateTo({
url: "/pages/wode/wode"
})
},
}
})

@ -3,14 +3,14 @@
<view class="address_item flexRowBetween">
<view class="address_left">
<view class="text1">
李雷
杨盼成
</view>
<view class="text1 text_other">
科技路高新大都荟
湖南师范大学
</view>
</view>
<view class="address_right">
18888888888
123456789
</view>
</view>
<view class="address_set flexRowBetween">
@ -27,10 +27,7 @@
<text>删除</text>
</view>
</view>
<view class="submit_info" bindtap="newAddress">
保存
<view class="submit_info" bindtap="towode">保存
</view>
</view>

@ -46,7 +46,7 @@
align-items:center;}
.de_color{color:#7d7d7d}
.submit_info{
margin-top:0rpx;
margin-top:0rpx;
position:absolute;
bottom:120rpx;
}

@ -40,23 +40,7 @@ Page({
})
},
onLoad: function() {
console.log('onLoad')
var that = this
//调用应用实例的方法获取全局数据
app.getUserInfo(function(userInfo) {
//更新数据
that.setData({
userInfo: userInfo
})
})
},
getUserInfo: function(e) {
console.log(e)
app.globalData.userInfo = e.detail.userInfo
this.setData({
userInfo: e.detail.userInfo,
hasUserInfo: true
})
},
address: function() {
wx.navigateTo({

@ -13,8 +13,8 @@
},
"compileType": "miniprogram",
"libVersion": "2.4.4",
"appid": "wxd037e598f9fc428d",
"projectname": "%E5%B0%8F%E7%A8%8B%E5%BA%8F%E5%BC%80%E5%8F%91%E6%B5%8B%E8%AF%95111",
"appid": "wx18f06ad86d422b11",
"projectname": "%E5%B0%8F%E7%A8%8B%E5%BA%8F",
"debugOptions": {
"hidedInDevtools": []
},

Loading…
Cancel
Save