Class: App::Views::UsersShow

Inherits:
Layout
  • Object
show all
Includes:
App::ViewHelpers
Defined in:
app/views/users_show.rb

Instance Method Summary collapse

Methods included from App::ViewHelpers

#add_book_button, #admin, #admin?, #app_name, #base_url, #book_permitted, #count_instances, #external_link_glyph, #flag_modal_button, #flags, #get_instances_per_page, #instance_permitted, #instances_by_names, #javascripts, #json_file, #logged_in, #map_height, #metadata, #not_empty, #place_permitted, #places, #rendered_flash, #stylesheets, #user_name

Methods inherited from Layout

#page_title, #selected_item

Instance Method Details

#usersObject


7
8
9
10
11
12
13
14
15
16
# File 'app/views/users_show.rb', line 7

def users
  @users.map{ |u| {
    username: u.username,
    name: u.name,
    email: u.email,
    admin: u.admin,
    instances: u.instances.count,
    books: u.books.count
  } }
end