Changes for sub_roles
Issues: update doesn't create new i18n_variables, role form has bugs
This commit is contained in:
1 parent
d23cf152da
commit
d27d7a623c
62 files changed
+508
-1142
No files matched your search
@@ -0,0 +1,25 @@
|
||||
$('.attributes_block a.delete').live('click', function(){
|
||||
$(this).parents('.list_item').remove();
|
||||
});
|
||||
|
||||
$('#attributes a.remove_existing_record').live('click', function(){
|
||||
$(this).next('.should_destroy').attr('value', 1);
|
||||
$("#attribute_" + $(this).prev().attr('value')).hide();
|
||||
});
|
||||
|
||||
$('#attributes_block a.switch').live('click', function(){
|
||||
$(this).parent().toggleClass('disable');
|
||||
var $am = $(this).next('.built_in_state')
|
||||
$am.attr('value', ($am.attr('value') == "false") ? "true" : "false");
|
||||
});
|
||||
|
||||
$('.select_type select').live('change', function(){
|
||||
if(this.value == 'select')
|
||||
{
|
||||
$(this).next().show();
|
||||
}
|
||||
else
|
||||
{
|
||||
$(this).next().hide();
|
||||
}
|
||||
});
|
||||
@@ -1,4 +1,7 @@
|
||||
$("div.editable").live("mouseenter mouseleave",
|
||||
function (event) {
|
||||
$(this).children('.edit_link').toggle();
|
||||
});
|
||||
$("div.editable").live("mouseenter mouseleave", function (event) {
|
||||
$(this).children('.edit_link').toggle();
|
||||
});
|
||||
|
||||
$("#page_design_id").live('change', function() {
|
||||
$.getScript($(this).attr('rel') + '/' + $(this).val() + '/reload_themes');
|
||||
});
|
||||
@@ -6,4 +6,5 @@
|
||||
//
|
||||
//= require jquery
|
||||
//= require jquery_ujs
|
||||
//= require page_edit
|
||||
//= require side_bar_history
|
||||
@@ -1,33 +0,0 @@
|
||||
$('#attributes_block a.delete').live('click', function(){
|
||||
$(this).parent().parent().parent().remove();
|
||||
});
|
||||
|
||||
$('#attributes_block a.add').click(function(){
|
||||
$('#attributes').append("<%= escape_javascript(render(:partial => 'admin/user_attribute_models/attribute_model', :object => @user_attribute_model.attribute_models.build)) %>");
|
||||
});
|
||||
|
||||
$('#attributes_block a.remove_existing_record').click(function(){
|
||||
$(this).next('.should_destroy').attr('value', 1);
|
||||
$(this).parent().parent().hide();
|
||||
});
|
||||
|
||||
$('#attributes_block a.change_built_in').click(function(){
|
||||
$(this).parent().toggleClass('disable');
|
||||
var $am = $(this).next('.built_in_state')
|
||||
$am.attr('value', ($am.attr('value') == "false") ? "true" : "false");
|
||||
});
|
||||
|
||||
$('.select_mulitlingual input').live('click', function(){
|
||||
$(this).next().attr('value', this.checked);
|
||||
});
|
||||
|
||||
$('.select_type select').live('change', function(){
|
||||
if(this.value == 'select')
|
||||
{
|
||||
$(this).next().show();
|
||||
}
|
||||
else
|
||||
{
|
||||
$(this).next().hide();
|
||||
}
|
||||
});
|
||||
@@ -1,6 +1,6 @@
|
||||
$(document).ready(function(){
|
||||
$('#user_active_role').change(function(){
|
||||
$('#role_models .roles_block').hide();
|
||||
$('#active_role').change(function(){
|
||||
$('#roles .attributes_block').hide();
|
||||
$('#'+this.value+'_block').toggle();
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user