Sha256: 5fad5c8d97d4ecaf6d0e303fbfee320b61fbbe35469ef70b78cff95d14def2ba

Contents?: true

Size: 915 Bytes

Versions: 8

Compression:

Stored size: 915 Bytes

Contents

App.Views.NewUser = Backbone.View.extend({
	
	events: {
		"submit form" : "create_user"
	},
	
    initialize: function() {
		this.render();
    },

    create_user: function(e) {
		e.preventDefault();
		this.model.create_user();
	},
    
    render: function() {
        $('#secondary-nav').css('display','block');
		out  = "<div class='page-header well'><h2>New user</h2></div>";
		out += "<div id='newuser-alert' class='alert alert-error' style='display:none'></div>";
		out += "<form>"
	    out += "<input id='new-login' type='text' name='login' placeholder='login' style='margin:0'/>";
		out += "<input id='new-password' type='password' name='password' placeholder='password' style='margin:0 0 0 10px'/>";
		out += "<input type='submit' class='btn btn-primary' value='Add' style='margin:0 0 0 10px'/>"
	    out += "</form>";
	   
        $(this.el).html(out);
        $('#main_content').html(this.el);
    }
});

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
rhoconnect-3.3.1.beta2 lib/rhoconnect/web-console/views/new_user.js
rhoconnect-3.2.1 lib/rhoconnect/web-console/views/new_user.js
rhoconnect-3.2.0 lib/rhoconnect/web-console/views/new_user.js
rhoconnect-3.2.0.beta5 lib/rhoconnect/web-console/views/new_user.js
rhoconnect-3.2.0.beta4 lib/rhoconnect/web-console/views/new_user.js
rhoconnect-3.2.0.beta3 lib/rhoconnect/web-console/views/new_user.js
rhoconnect-3.2.0.beta2 lib/rhoconnect/web-console/views/new_user.js
rhoconnect-3.2.0.beta1 lib/rhoconnect/web-console/views/new_user.js