Class: Thredded::AllViewHooks

Inherits:
Object
  • Object
show all
Defined in:
app/view_hooks/thredded/all_view_hooks.rb

Defined Under Namespace

Classes: MessageboardGroupShow, MessageboardsIndex, ModerationUserPage, PostCommon, PostForm, PostsCommon, TopicPage, ViewHook

Class Attribute Summary collapse

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeAllViewHooks

Returns a new instance of AllViewHooks.



32
33
34
35
36
37
38
39
40
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 32

def initialize
  @post_common = PostCommon.new
  @posts_common = PostsCommon.new
  @post_form = PostForm.new
  @moderation_user_page = ModerationUserPage.new
  @messageboards_index = MessageboardsIndex.new
  @messageboard_group_show = MessageboardGroupShow.new
  @topic_page = TopicPage.new
end

Class Attribute Details

.instanceThredded::AllViewHooks (readonly)



23
24
25
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 23

def instance
  @instance
end

Instance Attribute Details

#messageboard_group_showMessageboardGroupShow (readonly)



14
15
16
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 14

def messageboard_group_show
  @messageboard_group_show
end

#messageboards_indexMessageboardsIndex (readonly)

Returns:



12
13
14
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 12

def messageboards_index
  @messageboards_index
end

#moderation_user_pageModerationUserPage (readonly)

Returns:



16
17
18
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 16

def moderation_user_page
  @moderation_user_page
end

#post_commonPostCommon (readonly)

Returns:



6
7
8
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 6

def post_common
  @post_common
end

#post_formPostForm (readonly)

Returns:



10
11
12
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 10

def post_form
  @post_form
end

#posts_commonPostsCommon (readonly)

Returns:



8
9
10
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 8

def posts_common
  @posts_common
end

#topic_pageTopicPage (readonly)

Returns:



18
19
20
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 18

def topic_page
  @topic_page
end

Class Method Details

.reset_instance!Object

Called when the class is reloaded so that server restart is not required when changing view hooks in development.



27
28
29
# File 'app/view_hooks/thredded/all_view_hooks.rb', line 27

def reset_instance!
  @instance = Thredded::AllViewHooks.new
end