socialforge/app/views/users/user_resource.js.erb

16 lines
1.3 KiB
Plaintext

$("#search_div").html('<%= escape_javascript( render :partial => 'resource_search_form', :locals => {:user => @user, :type => @type} ) %>');
$("#resources_list").html('<%= escape_javascript( render :partial => 'resources_list' , :locals => { :attachments => @attachments}) %>');
$("#pages").html('<%= pagination_links_full @atta_pages, @atta_count, :per_page_links => false, :remote => @is_remote, :flag => true %>');
$("#res_count").html(0);
$("#checkboxAll").attr('checked',false);
$("#res_all_count").html(<%= @atta_count %>);
$("#public_resource_list").attr('href','<%= user_resource_user_path(@user, :type => '6', :status => @status) %>');
$("#my_resource_list").attr('href','<%= user_resource_user_path(@user, :type => '1', :status => @status) %>');
$("#resource_type_all").attr('href','<%= user_resource_user_path(@user,:type => @type, :status => 1) %>');
$("#resource_type_course").attr('href','<%= user_resource_user_path(@user,:type => @type, :status => 2) %>');
$("#resource_type_project").attr('href','<%= user_resource_user_path(@user,:type => @type, :status => 3) %>');
$("#resource_type_user").attr('href','<%= user_resource_user_path(@user,:type => @type, :status => 5) %>');
$("#resource_type_file").attr('href','<%= user_resource_user_path(@user,:type => @type, :status => 4) %>');