summaryrefslogtreecommitdiff
path: root/StoneIsland/www/js/lib/nav/CreditCardView.js
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2015-11-10 13:27:12 -0500
committerJules Laplace <jules@okfoc.us>2015-11-10 13:27:12 -0500
commite6e86bbccd0e64193805863abd84c23e46136126 (patch)
tree30e9b99db5235e4e43b5108a761039efcdfffc8d /StoneIsland/www/js/lib/nav/CreditCardView.js
parent16e462faf5e661ceee700f6f0053d502121a5f62 (diff)
populate cc/address forms
Diffstat (limited to 'StoneIsland/www/js/lib/nav/CreditCardView.js')
-rw-r--r--StoneIsland/www/js/lib/nav/CreditCardView.js7
1 files changed, 6 insertions, 1 deletions
diff --git a/StoneIsland/www/js/lib/nav/CreditCardView.js b/StoneIsland/www/js/lib/nav/CreditCardView.js
index 6668053d..e54c1805 100644
--- a/StoneIsland/www/js/lib/nav/CreditCardView.js
+++ b/StoneIsland/www/js/lib/nav/CreditCardView.js
@@ -8,9 +8,14 @@ var CreditCardView = View.extend({
initialize: function(opt){
this.parent = opt.parent
+ this.parent.$(".address").html(this.template)
},
- build: function(){
+ populate: function(data){
+ this.parent.$(".address input").val("")
+ Object.keys(data).forEach(function(key){
+ this.parent$(".address [name=" + key + "]").val(data[key])
+ }.bind(this))
},
deserialize: function(){