Some cleanup
authorSteve Sutton <steve@gaslightmedia.com>
Mon, 2 Oct 2017 20:02:12 +0000 (16:02 -0400)
committerSteve Sutton <steve@gaslightmedia.com>
Mon, 2 Oct 2017 20:02:12 +0000 (16:02 -0400)
Removing uneeded methods.

js/frontRegApp.js
js/views/front/newRegistrant.js

index 4023207..ed6d4f2 100644 (file)
@@ -685,33 +685,12 @@ app.Views.Front.NewRegistrant = Backbone.View.extend({
     template: _.template( jQuery('#eventReg-registrant-add').html() ),
 
     events: {
-        //'click .add-new-registrant': 'addNew',
     },
 
     initialize: function(){
         return this;
     },
 
-    addNew: function(){
-        console.log( 'called addNew in newReg view' );
-        var fname = this.$('.reg_fname').val().trim();
-        var lname = this.$('.reg_lname').val().trim();
-        var email = this.$('.reg_email').val().trim();
-        console.log( 'email: ' + email + ' fname: ' + fname + ' lname: ' + lname );
-
-        // Create a account
-        // this.model.set({
-        //     fname: this.$('.reg_fname').val().trim(),
-        //     lname: this.$('.reg_lname').val().trim(),
-        //     email: this.$('.reg_email').val().trim(),
-        // });
-
-
-        // Destroy the model and view
-        this.model.destroy();
-        this.remove();
-    },
-
     render: function(){
         this.$el.html( this.template( this.model.toJSON() ) );
         return this;
index e79d6fd..17420a8 100644 (file)
@@ -6,33 +6,12 @@ app.Views.Front.NewRegistrant = Backbone.View.extend({
     template: _.template( jQuery('#eventReg-registrant-add').html() ),
 
     events: {
-        //'click .add-new-registrant': 'addNew',
     },
 
     initialize: function(){
         return this;
     },
 
-    addNew: function(){
-        console.log( 'called addNew in newReg view' );
-        var fname = this.$('.reg_fname').val().trim();
-        var lname = this.$('.reg_lname').val().trim();
-        var email = this.$('.reg_email').val().trim();
-        console.log( 'email: ' + email + ' fname: ' + fname + ' lname: ' + lname );
-
-        // Create a account
-        // this.model.set({
-        //     fname: this.$('.reg_fname').val().trim(),
-        //     lname: this.$('.reg_lname').val().trim(),
-        //     email: this.$('.reg_email').val().trim(),
-        // });
-
-
-        // Destroy the model and view
-        this.model.destroy();
-        this.remove();
-    },
-
     render: function(){
         this.$el.html( this.template( this.model.toJSON() ) );
         return this;