summaryrefslogtreecommitdiff
path: root/StoneIsland/www/js
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2015-11-19 22:39:56 -0500
committerJules Laplace <jules@okfoc.us>2015-11-19 22:39:56 -0500
commit9c4846681b13923046d0e2da837c6580a419e950 (patch)
treeddb96638a71b6d9a03ae4f66f94ae9924634834f /StoneIsland/www/js
parente458c052238c5f5bebd33affc7e5750671beeb23 (diff)
fix divs and things
Diffstat (limited to 'StoneIsland/www/js')
-rw-r--r--StoneIsland/www/js/lib/account/ProfileView.js1
-rw-r--r--StoneIsland/www/js/lib/auth/SignupView.js1
-rw-r--r--StoneIsland/www/js/lib/blogs/BlogView.js5
-rw-r--r--StoneIsland/www/js/lib/cart/CartConfirm.js2
-rw-r--r--StoneIsland/www/js/lib/cart/CartPayment.js2
-rw-r--r--StoneIsland/www/js/lib/cart/CartShipping.js2
-rw-r--r--StoneIsland/www/js/lib/products/ClosedStoreView.js1
7 files changed, 9 insertions, 5 deletions
diff --git a/StoneIsland/www/js/lib/account/ProfileView.js b/StoneIsland/www/js/lib/account/ProfileView.js
index 6d9a44a3..f03572dc 100644
--- a/StoneIsland/www/js/lib/account/ProfileView.js
+++ b/StoneIsland/www/js/lib/account/ProfileView.js
@@ -24,6 +24,7 @@ var ProfileView = FormView.extend({
validate_fields: function(errors){
if (data.Password && ! data.Password2) { errors.push("Password2", "Please enter your new password.") }
+ if (data.Password && data.Password.length < 7) { errors.push("Password", "Password must be 7 characters or more.") }
},
success: function(data){
diff --git a/StoneIsland/www/js/lib/auth/SignupView.js b/StoneIsland/www/js/lib/auth/SignupView.js
index 24eb0d09..28d828c3 100644
--- a/StoneIsland/www/js/lib/auth/SignupView.js
+++ b/StoneIsland/www/js/lib/auth/SignupView.js
@@ -32,6 +32,7 @@ var SignupView = FormView.extend({
},
validate_fields: function(errors){
+ if (data.Password.length < 7) { errors.push("Password", "Password must be 7 characters or more.") }
if (data.Password !== data.Password2) { errors.push("Password2", "Passwords don't match.") }
if (data.Email !== data.ConfirmEmail) { errors.push("ConfirmEmail", "Email addresses don't match.") }
if (! data.YooxLetter) { data.YooxLetter = "false" }
diff --git a/StoneIsland/www/js/lib/blogs/BlogView.js b/StoneIsland/www/js/lib/blogs/BlogView.js
index fb9c2157..9cb2afbe 100644
--- a/StoneIsland/www/js/lib/blogs/BlogView.js
+++ b/StoneIsland/www/js/lib/blogs/BlogView.js
@@ -17,6 +17,7 @@ var BlogView = View.extend({
},
success: function(data){
+ if (this.loaded) return
this.loaded = true
this.data = data
this.loader.preloadImage(data.archive[0].images[0].uri, function(img){
@@ -32,8 +33,10 @@ var BlogView = View.extend({
app[page.tag].populate(page)
})
app.collection.setCollectionName( data.store[0].collection )
+
+ app.closed.populate(data.store[0].ClosedStoreImages)
if (data.store[0].StoreIsOpen !== "true") {
- app.closed.populate(data.store[0].ClosedStoreImages)
+ app.closed.storeIsClosed = true
}
},
diff --git a/StoneIsland/www/js/lib/cart/CartConfirm.js b/StoneIsland/www/js/lib/cart/CartConfirm.js
index 659d36e6..7d8c6568 100644
--- a/StoneIsland/www/js/lib/cart/CartConfirm.js
+++ b/StoneIsland/www/js/lib/cart/CartConfirm.js
@@ -1,4 +1,4 @@
-var CartConfirm = View.extend({
+var CartConfirm = FormView.extend({
el: "#cart_confirm",
diff --git a/StoneIsland/www/js/lib/cart/CartPayment.js b/StoneIsland/www/js/lib/cart/CartPayment.js
index 50fbef9c..bcca1915 100644
--- a/StoneIsland/www/js/lib/cart/CartPayment.js
+++ b/StoneIsland/www/js/lib/cart/CartPayment.js
@@ -1,4 +1,4 @@
-var CartPayment = View.extend({
+var CartPayment = FormView.extend({
el: "#cart_payment",
diff --git a/StoneIsland/www/js/lib/cart/CartShipping.js b/StoneIsland/www/js/lib/cart/CartShipping.js
index 2c7bae4a..65e2cb65 100644
--- a/StoneIsland/www/js/lib/cart/CartShipping.js
+++ b/StoneIsland/www/js/lib/cart/CartShipping.js
@@ -1,4 +1,4 @@
-var CartShipping = View.extend({
+var CartShipping = FormView.extend({
el: "#cart_shipping",
diff --git a/StoneIsland/www/js/lib/products/ClosedStoreView.js b/StoneIsland/www/js/lib/products/ClosedStoreView.js
index 3949f11f..77dc15b1 100644
--- a/StoneIsland/www/js/lib/products/ClosedStoreView.js
+++ b/StoneIsland/www/js/lib/products/ClosedStoreView.js
@@ -37,7 +37,6 @@ var ClosedStoreView = View.extend({
},
populate: function(data){
- this.storeIsClosed = true
this.images = data.map(function(img){ return img.uri })
},