Class: Pageflow::Admin::GroupedFolderList

Inherits:
ViewComponent
  • Object
show all
Defined in:
app/views/components/pageflow/admin/grouped_folder_list.rb

Overview

Since:

  • 12.2

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#foldersObject (readonly)

Since:

  • 12.2



6
7
8
# File 'app/views/components/pageflow/admin/grouped_folder_list.rb', line 6

def folders
  @folders
end

Instance Method Details

#build(folders, options = {}) ⇒ Object

Since:

  • 12.2



8
9
10
11
12
13
14
15
16
17
18
19
20
21
# File 'app/views/components/pageflow/admin/grouped_folder_list.rb', line 8

def build(folders, options = {})
  super(options.slice(:class))

  @folders = folders
  @active_id = options[:active_id]

  build_all_link

  if options[:grouped_by_accounts]
    build_folder_list_grouped_by_accounts
  else
    build_folder_list(folders)
  end
end