bb2643e8 by ex

未完成订单

1 parent 3a19c2d9
......@@ -69,24 +69,27 @@ angular.module('myApp')
localStorage.removeItem('ls.user')
return
}
if(data.data.unfinishedOrder.status == 200) {
if(data.data.unfinishedOrder.id) {
$rootScope.isRendBike = true;
$scope.unfinishOrder = data.data.unfinishedOrder;
if(date.meta.code === 200) {
if(data.data.unfinishedOrder.status == 200) {
if(data.data.unfinishedOrder.id) {
$rootScope.isRendBike = true;
$scope.unfinishOrder = data.data.unfinishedOrder;
}
layer.open({
content: '您有未支付的订单,是否前往支付?',
btn: ['确认', '取消'],
shadeClose: false,
yes: function(index){
layer.close(index);
$state.go('tripDetail' , { orderId : $scope.unfinishOrder.id});
return;
},no: function(index){
layer.close(index);
}
});
}
layer.open({
content: '您有未支付的订单,是否前往支付?',
btn: ['确认', '取消'],
shadeClose: false,
yes: function(index){
layer.close(index);
$state.go('tripDetail' , { orderId : $scope.unfinishOrder.id});
return;
},no: function(index){
layer.close(index);
}
});
}
}).error(function(data , status) {
console.log(JSON.stringify(data))
})
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!