1 class UsersController < ApplicationController
2 skip_before_filter :find_object_by_uuid, :only => :welcome
3 skip_around_filter :thread_with_mandatory_api_token, :only => :welcome
7 params[:action] = 'home'
13 @showallalerts = false
14 @my_ssh_keys = AuthorizedKey.where(authorized_user_uuid: current_user.uuid)
15 # @my_vm_perms = Link.where(tail_uuid: current_user.uuid, head_kind: 'arvados#virtual_machine', link_class: 'permission', name: 'can_login')
16 # @my_repo_perms = Link.where(tail_uuid: current_user.uuid, head_kind: 'arvados#repository', link_class: 'permission', name: 'can_write')
22 order('created_at desc').
23 where(created_by: current_user.uuid)
25 @my_collections = Collection.
27 order('created_at desc').
28 where(created_by: current_user.uuid)
30 Link.limit(1000).where(head_uuid: @my_collections.collect(&:uuid),
31 link_class: 'tag').each do |link|
32 (@my_tag_links[link.head_uuid] ||= []) << link
35 @my_pipelines = PipelineInstance.
37 order('created_at desc').
38 where(created_by: current_user.uuid)
41 # A Tutorial is a Link which has link_class "resources" and name
42 # "wants", and is owned by the Tutorials Group (i.e., named
43 # "Arvados Tutorials" and owned by the system user).
44 @tutorial_group = Group.where(owner_uuid: User.system.uuid,
45 name: 'Arvados Tutorials').first
47 @tutorial_links = Link.where(tail_uuid: @tutorial_group.uuid,
48 link_class: 'resources',
53 @tutorial_complete = {
54 'Run a job' => @my_last_job
57 f.js { render template: 'users/home.js' }
58 f.html { render template: 'users/home' }