summaryrefslogtreecommitdiff
path: root/StoneIsland/platforms/android/assets/www/js/lib/account/ShippingView.js
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2016-11-08 12:37:03 -0500
committerJules Laplace <jules@okfoc.us>2016-11-08 12:37:03 -0500
commitef4f212fc1482136dba1e690ec589b315b4a377f (patch)
tree0b7e16d72567fafcfd3e08d7c5c591ad07a63458 /StoneIsland/platforms/android/assets/www/js/lib/account/ShippingView.js
parent5fa81da81260d65113f57a293b6256d334fe8e2d (diff)
build 0.7.0
Diffstat (limited to 'StoneIsland/platforms/android/assets/www/js/lib/account/ShippingView.js')
-rwxr-xr-xStoneIsland/platforms/android/assets/www/js/lib/account/ShippingView.js14
1 files changed, 12 insertions, 2 deletions
diff --git a/StoneIsland/platforms/android/assets/www/js/lib/account/ShippingView.js b/StoneIsland/platforms/android/assets/www/js/lib/account/ShippingView.js
index 0bf88025..71cd9eef 100755
--- a/StoneIsland/platforms/android/assets/www/js/lib/account/ShippingView.js
+++ b/StoneIsland/platforms/android/assets/www/js/lib/account/ShippingView.js
@@ -32,6 +32,11 @@ var ShippingView = FormView.extend({
show: function(){
if (! auth.logged_in()) { return app.router.go("intro") }
+ if (! navigator.onLine) {
+ app.closed.showElement()
+ app.closed.setMessage("PLEASE GO ONLINE TO<br>EDIT YOUR SHIPPING INFO.", "")
+ return
+ }
// this.preload( this.data || this.test_data )
app.footer.show("SAVE")
document.body.className = "shipping"
@@ -61,8 +66,13 @@ var ShippingView = FormView.extend({
success: function(data){
app.curtain.show("loading")
- app.account.listAddresses(function(){
- app.curtain.hide("loading")
+ app.account.listAddresses({
+ success: function(){
+ app.curtain.hide("loading")
+ },
+ error: function(){
+ app.curtain.hide("loading")
+ },
})
},