summaryrefslogtreecommitdiff
path: root/StoneIsland/www/js/lib/cart/CartView.js
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2015-11-25 04:08:39 -0500
committerJules Laplace <jules@okfoc.us>2015-11-25 04:08:39 -0500
commitf0c551933c5e725b980014b559d757bee99d0536 (patch)
treeba8f090c42934f3ef601eb8d0e42b4398242fc68 /StoneIsland/www/js/lib/cart/CartView.js
parente024c35a2584f5d975b3b4f8fe942bb8e35b6e47 (diff)
fix auth bugs pt 1
Diffstat (limited to 'StoneIsland/www/js/lib/cart/CartView.js')
-rw-r--r--StoneIsland/www/js/lib/cart/CartView.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/StoneIsland/www/js/lib/cart/CartView.js b/StoneIsland/www/js/lib/cart/CartView.js
index 8bea43dc..b57caadd 100644
--- a/StoneIsland/www/js/lib/cart/CartView.js
+++ b/StoneIsland/www/js/lib/cart/CartView.js
@@ -15,6 +15,8 @@ var CartView = View.extend({
this.confirm = new CartConfirm ({ parent: this })
this.thanks = new CartThanks ({ parent: this })
+ this.$full_msg = this.$(".full_msg")
+ this.$empty_msg = this.$(".empty_msg")
this.$itemcount = this.$(".itemcount")
},
@@ -47,4 +49,16 @@ var CartView = View.extend({
this.payment.show()
},
+ setHeaderCount: function(n){
+ if (n) {
+ this.$itemcount.html(pluralize(n, "ITEM", "S"))
+ this.$full_msg.show()
+ this.$empty_msg.hide()
+ }
+ else {
+ this.$full_msg.hide()
+ this.$empty_msg.show()
+ }
+ },
+
}) \ No newline at end of file