17 lines
751 B
JavaScript
17 lines
751 B
JavaScript
|
function update_cates_and_tags()
|
||
|
{
|
||
|
$('.select_option,.select_all').removeAttr('disabled');
|
||
|
$(".select_all:checked").each(function( obj ) {
|
||
|
$(this).parent().siblings('label').find('.select_option').attr('disabled',true);
|
||
|
$(this).parent().siblings('label').find('.select_option').removeAttr('checked');
|
||
|
});
|
||
|
$(".select_option:checked").each(function( obj ) {
|
||
|
$(this).parent().siblings('label').find('.select_all').attr('disabled',true);
|
||
|
$(this).parent().siblings('label').find('.select_all').removeAttr('checked');
|
||
|
});
|
||
|
}
|
||
|
|
||
|
$(document).ready(function(){
|
||
|
update_cates_and_tags();
|
||
|
$("#widget_data_source_category,#widget_data_source_tag,#app_page_category,#app_page_tag").find('input').change(function(){update_cates_and_tags()});
|
||
|
});
|