Sha256: 9457ca59a12e0be709d104b694fe40a1509fbf441e7106afaad519b4b280136b

Contents?: true

Size: 904 Bytes

Versions: 7

Compression:

Stored size: 904 Bytes

Contents

//= require jquery
//= require jquery_ujs
//= require bootstrap

jQuery(document).ready(function() {

	if (current_controller) {
		active_tab = $("#tab-" + current_controller);
		if (active_tab) {
			active_tab.addClass("active");
		}
	}

	if($("#notice")) {
		setTimeout(function() {
			$("#notice").fadeOut(1000);
		}, 10000);
	};

	$("#generate-random-password-checkbox").click(function() {
	  if ($(this).is(':checked')) {
	  	$("#casein_admin_user_password").attr("disabled", true);
	  	$("#casein_admin_user_password_confirmation").attr("disabled", true);
	  }
	  else {
	  	$("#casein_admin_user_password").removeAttr("disabled");
	  	$("#casein_admin_user_password_confirmation").removeAttr("disabled");
	  }
	});

});

toggleDiv = function(div) {
	switch ($("#"+div).css('display')) {
		case "none":
			$("#"+div).fadeIn(300);
		break;

		case "block":
			$("#"+div).fadeOut(300);
		break;
	}	
}

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
casein-5.1.1.5 app/assets/javascripts/casein/casein.js
casein-5.1.1.4 app/assets/javascripts/casein/casein.js
casein-5.1.1.3 app/assets/javascripts/casein/casein.js
casein-5.1.1.2 app/assets/javascripts/casein/casein.js
casein-5.1.1.1 app/assets/javascripts/casein/casein.js
casein-5.1.1.0 app/assets/javascripts/casein/casein.js
casein-5.1.0.0 app/assets/javascripts/casein/casein.js