simple_forum 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (86) hide show
  1. data/README.rdoc +2 -5
  2. data/Rakefile +19 -14
  3. data/app/assets/images/simple_forum/forumNewPosts.gif +0 -0
  4. data/app/assets/images/simple_forum/forumNoNewPosts.gif +0 -0
  5. data/app/assets/javascripts/simple_forum/application.js +15 -0
  6. data/app/assets/javascripts/simple_forum/markitup.js +51 -0
  7. data/app/assets/javascripts/simple_forum/markitup/jquery.markitup.js +574 -0
  8. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/bold.png +0 -0
  9. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/clean.png +0 -0
  10. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/code.png +0 -0
  11. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/fonts.png +0 -0
  12. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/italic.png +0 -0
  13. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/link.png +0 -0
  14. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/list-bullet.png +0 -0
  15. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/list-item.png +0 -0
  16. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/list-numeric.png +0 -0
  17. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/picture.png +0 -0
  18. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/preview.png +0 -0
  19. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/quotes.png +0 -0
  20. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/stroke.png +0 -0
  21. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/images/underline.png +0 -0
  22. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/readme.txt +11 -0
  23. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/set.js +39 -0
  24. data/app/assets/javascripts/simple_forum/markitup/sets/bbcode/style.css.scss +47 -0
  25. data/app/assets/javascripts/simple_forum/markitup/sets/default/images/bold.png +0 -0
  26. data/app/assets/javascripts/simple_forum/markitup/sets/default/images/clean.png +0 -0
  27. data/app/assets/javascripts/simple_forum/markitup/sets/default/images/image.png +0 -0
  28. data/app/assets/javascripts/simple_forum/markitup/sets/default/images/italic.png +0 -0
  29. data/app/assets/javascripts/simple_forum/markitup/sets/default/images/link.png +0 -0
  30. data/app/assets/javascripts/simple_forum/markitup/sets/default/images/picture.png +0 -0
  31. data/app/assets/javascripts/simple_forum/markitup/sets/default/images/preview.png +0 -0
  32. data/app/assets/javascripts/simple_forum/markitup/sets/default/images/stroke.png +0 -0
  33. data/app/assets/javascripts/simple_forum/markitup/sets/default/set.js +27 -0
  34. data/app/assets/javascripts/simple_forum/markitup/sets/default/style.css +27 -0
  35. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-container.png +0 -0
  36. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor-bbcode.png +0 -0
  37. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor-dotclear.png +0 -0
  38. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor-html.png +0 -0
  39. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor-json.png +0 -0
  40. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor-markdown.png +0 -0
  41. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor-textile.png +0 -0
  42. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor-wiki.png +0 -0
  43. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor-xml.png +0 -0
  44. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/bg-editor.png +0 -0
  45. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/handle.png +0 -0
  46. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/menu.png +0 -0
  47. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/images/submenu.png +0 -0
  48. data/app/assets/javascripts/simple_forum/markitup/skins/markitup/style.css.scss +147 -0
  49. data/app/assets/javascripts/simple_forum/markitup/skins/simple/images/handle.png +0 -0
  50. data/app/assets/javascripts/simple_forum/markitup/skins/simple/images/menu.png +0 -0
  51. data/app/assets/javascripts/simple_forum/markitup/skins/simple/images/submenu.png +0 -0
  52. data/app/assets/javascripts/simple_forum/markitup/skins/simple/style.css +118 -0
  53. data/app/assets/javascripts/simple_forum/markitup/templates/preview.css +5 -0
  54. data/app/assets/javascripts/simple_forum/markitup/templates/preview.html +11 -0
  55. data/app/assets/stylesheets/simple_forum/application.css +13 -0
  56. data/app/assets/stylesheets/simple_forum/base.css +124 -0
  57. data/app/assets/stylesheets/simple_forum/markitup.css +5 -0
  58. data/app/controllers/simple_forum/application_controller.rb +1 -0
  59. data/app/controllers/simple_forum/forums_controller.rb +0 -1
  60. data/app/controllers/simple_forum/posts_controller.rb +5 -5
  61. data/app/controllers/simple_forum/topics_controller.rb +2 -2
  62. data/app/models/simple_forum.rb +0 -1
  63. data/app/models/simple_forum/category.rb +0 -3
  64. data/app/models/simple_forum/forum.rb +0 -3
  65. data/app/models/simple_forum/moderatorship.rb +0 -3
  66. data/app/models/simple_forum/post.rb +0 -3
  67. data/app/models/simple_forum/topic.rb +1 -4
  68. data/app/views/layouts/simple_forum.html.erb +4 -5
  69. data/app/views/simple_forum/forums/index.html.erb +4 -4
  70. data/app/views/simple_forum/forums/show.html.erb +5 -5
  71. data/app/views/simple_forum/posts/edit.html.erb +5 -5
  72. data/app/views/simple_forum/topics/_post.html.erb +2 -2
  73. data/app/views/simple_forum/topics/new.html.erb +3 -3
  74. data/app/views/simple_forum/topics/show.html.erb +9 -16
  75. data/config/routes.rb +11 -36
  76. data/db/migrate/20110330123456_create_simple_forum_forums.rb +35 -0
  77. data/db/migrate/20110330123457_create_simple_forum_topics.rb +30 -0
  78. data/db/migrate/20110330123458_create_simple_forum_posts.rb +31 -0
  79. data/db/migrate/20110330123459_create_simple_forum_categories.rb +19 -0
  80. data/db/migrate/20110330123460_create_simple_forum_moderatorships.rb +17 -0
  81. data/lib/simple_forum.rb +6 -4
  82. data/lib/simple_forum/engine.rb +5 -11
  83. data/lib/simple_forum/version.rb +2 -3
  84. metadata +190 -20
  85. data/Gemfile +0 -18
  86. data/lib/simple_forum/tasks/railties.rake +0 -66
@@ -0,0 +1,5 @@
1
+ /* preview style examples */
2
+ body {
3
+ background-color:#EFEFEF;
4
+ font:70% Verdana, Arial, Helvetica, sans-serif;
5
+ }
@@ -0,0 +1,11 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2
+ <html xmlns="http://www.w3.org/1999/xhtml">
3
+ <head>
4
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
+ <title>markItUp! preview template</title>
6
+ <link rel="stylesheet" type="text/css" href="~/templates/preview.css" />
7
+ </head>
8
+ <body>
9
+ <!-- content -->
10
+ </body>
11
+ </html>
@@ -0,0 +1,13 @@
1
+ /*
2
+ * This is a manifest file that'll be compiled into application.css, which will include all the files
3
+ * listed below.
4
+ *
5
+ * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
6
+ * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.
7
+ *
8
+ * You're free to add application-wide styles to this file and they'll appear at the top of the
9
+ * compiled file, but it's generally better to create a new file per style scope.
10
+ *
11
+ *= require_self
12
+ *= require simple_forum/base
13
+ */
@@ -0,0 +1,124 @@
1
+ body {
2
+ background-color: #e1ddd9;
3
+ font-size: 13px;
4
+ font-family: Arial, SunSans-Regular, Sans-Serif;
5
+ color: #564b47;
6
+ padding: 0;
7
+ margin: 0;
8
+ }
9
+
10
+ a {
11
+ color: #ff66cc;
12
+ text-decoration: none;
13
+ }
14
+
15
+ h1 {
16
+ font-size: 16px;
17
+ text-transform: uppercase;
18
+ color: #564b47;
19
+ background-color: #90897a;
20
+ padding: 5px 15px;
21
+ margin: 0px
22
+ }
23
+
24
+ h2 {
25
+ font-size: 16px;
26
+ padding-top: 10px;
27
+ text-transform: uppercase;
28
+ color: #564b47;
29
+ background-color: transparent;
30
+ }
31
+
32
+ .logo {
33
+ margin: 20px 0;
34
+ }
35
+
36
+ p, h2, pre {
37
+ margin: 0;
38
+ padding: 5px 20px;
39
+ }
40
+
41
+ /* positioning-layers statisch und absolut */
42
+
43
+ #left {
44
+ position: absolute;
45
+ left: 0;
46
+ width: 220px;
47
+ }
48
+
49
+ #content {
50
+ margin: 0 220px;
51
+ border: 2px solid #564b47;
52
+ border-top: none;
53
+ background-color: #ffffff;
54
+ }
55
+
56
+ #right {
57
+ position: absolute;
58
+ right: 0;
59
+ width: 220px;
60
+ background-color: #f9c;
61
+ }
62
+
63
+ #breadcrumbs {
64
+ font-size: 14px;
65
+ color: #564b47;
66
+ background-color: transparent;
67
+ }
68
+
69
+ #content .category .body {
70
+ width: 60%;
71
+ margin: 20px;
72
+ }
73
+
74
+ table.forum-table {
75
+ width: 100%;
76
+ }
77
+
78
+ table.forum-table td.icon-cell {
79
+ width: 40px;
80
+ }
81
+
82
+ table.forum-table td.posts-cell {
83
+ width: 80px;
84
+ }
85
+
86
+ table.forum-table td.topics-cell {
87
+ width: 80px;
88
+ }
89
+
90
+ table.forum-table td.last-post-cell {
91
+ width: 140px;
92
+ }
93
+
94
+ table.topic-table {
95
+
96
+ }
97
+
98
+ table.topic-table td.user-cell {
99
+ width: 200px;
100
+ }
101
+
102
+ #flash_messages {
103
+ text-align: center;
104
+ font-size: 24px;
105
+ }
106
+
107
+ #flash_messages .notice {
108
+ color: green;
109
+ }
110
+
111
+ #flash_messages .alert {
112
+ color: red;
113
+ }
114
+
115
+ div.postbody div.post-deleted {
116
+ font-size: 16px;
117
+ color: #6495ed;
118
+ }
119
+
120
+ div.postbody div.post-edited {
121
+ margin-top: 12px;
122
+ font-size: 14px;
123
+ color: #556b2f;
124
+ }
@@ -0,0 +1,5 @@
1
+ /*
2
+ *= require simple_forum/markitup/skins/markitup/style
3
+ *= require simple_forum/markitup/sets/bbcode/style
4
+ *= require_self
5
+ */
@@ -1,5 +1,6 @@
1
1
  module SimpleForum
2
2
  class ApplicationController < ::ApplicationController #::ActionController::Base
3
+ respond_to :html
3
4
  protect_from_forgery
4
5
 
5
6
  layout SimpleForum.layout
@@ -1,6 +1,5 @@
1
1
  module SimpleForum
2
2
  class ForumsController < ApplicationController
3
- respond_to :html
4
3
 
5
4
  before_filter :find_forum, :except => [:index]
6
5
 
@@ -13,7 +13,7 @@ module SimpleForum
13
13
 
14
14
  respond_to do |format|
15
15
  format.html do
16
- redirect_to simple_forum_forum_topic_url(@forum, @topic), :status => :moved_permanently
16
+ redirect_to simple_forum.forum_topic_url(@forum, @topic), :status => :moved_permanently
17
17
  end
18
18
  end
19
19
  end
@@ -21,7 +21,7 @@ module SimpleForum
21
21
  def show
22
22
 
23
23
  respond_to do |format|
24
- format.html { redirect_to simple_forum_forum_topic_url(@forum, @topic, :page => @post.on_page, :anchor => "post-#{@post.id}") }
24
+ format.html { redirect_to simple_forum.forum_topic_url(@forum, @topic, :page => @post.on_page, :anchor => "post-#{@post.id}") }
25
25
  end
26
26
  end
27
27
 
@@ -31,10 +31,10 @@ module SimpleForum
31
31
  respond_to do |format|
32
32
  format.html do
33
33
  if success
34
- redirect_to simple_forum_forum_topic_url(@forum, @topic, :page => @post.on_page, :anchor => "post-#{@post.id}"),
34
+ redirect_to simple_forum.forum_topic_url(@forum, @topic, :page => @post.on_page, :anchor => "post-#{@post.id}"),
35
35
  :notice => t('simple_forum.controllers.posts.post_created')
36
36
  else
37
- redirect_to simple_forum_forum_topic_url(@forum, @topic, :page => @topic.last_page, :anchor => (@topic.recent_post ? "post-#{@topic.recent_post.id}" : nil)),
37
+ redirect_to simple_forum.forum_topic_url(@forum, @topic, :page => @topic.last_page, :anchor => (@topic.recent_post ? "post-#{@topic.recent_post.id}" : nil)),
38
38
  :alert => @post.errors.full_messages.join(', ')
39
39
  end
40
40
  end
@@ -62,7 +62,7 @@ module SimpleForum
62
62
  respond_to do |format|
63
63
  format.html do
64
64
  if success
65
- redirect_to simple_forum_forum_topic_url(@forum, @topic, :page => @post.on_page, :anchor => "post-#{@post.id}"),
65
+ redirect_to simple_forum.forum_topic_url(@forum, @topic, :page => @post.on_page, :anchor => "post-#{@post.id}"),
66
66
  :notice => t('simple_forum.controllers.posts.post_updated')
67
67
  else
68
68
  redirect_to :back, :alert => @post.errors.full_messages.join(', ')
@@ -14,7 +14,7 @@ module SimpleForum
14
14
 
15
15
  respond_to do |format|
16
16
  format.html do
17
- redirect_to simple_forum_forum_url(@forum), :status => :moved_permanently
17
+ redirect_to simple_forum.forum_url(@forum), :status => :moved_permanently
18
18
  end
19
19
  end
20
20
  end
@@ -45,7 +45,7 @@ module SimpleForum
45
45
  format.html do
46
46
  if success
47
47
  flash[:notice] = t('simple_forum.controllers.topics.topic_created')
48
- redirect_to simple_forum_forum_topic_url(@forum, @topic)
48
+ redirect_to simple_forum.forum_topic_url(@forum, @topic)
49
49
  else
50
50
  flash.now[:alert] = @topic.errors.full_messages.join(' ')
51
51
  render :new
@@ -2,5 +2,4 @@ module SimpleForum
2
2
  def self.table_name_prefix
3
3
  'simple_forum_'
4
4
  end
5
-
6
5
  end
@@ -1,8 +1,5 @@
1
1
  module SimpleForum
2
2
  class Category < ::ActiveRecord::Base
3
-
4
- set_table_name 'simple_forum_categories' #should work table_name_prefix in SimpleForum module but it's not!'
5
-
6
3
  has_many :forums,
7
4
  :order => "#{SimpleForum::Forum.quoted_table_name}.position ASC",
8
5
  :dependent => :nullify,
@@ -1,8 +1,5 @@
1
1
  module SimpleForum
2
2
  class Forum < ::ActiveRecord::Base
3
-
4
- set_table_name 'simple_forum_forums' #should work table_name_prefix in SimpleForum module but it's not!'
5
-
6
3
  #acts_as_nested_set
7
4
 
8
5
  has_many :topics,
@@ -1,8 +1,5 @@
1
1
  module SimpleForum
2
2
  class Moderatorship < ::ActiveRecord::Base
3
-
4
- set_table_name 'simple_forum_moderatorships' #should work table_name_prefix in SimpleForum module but it's not!'
5
-
6
3
  belongs_to :forum,
7
4
  :class_name => "SimpleForum::Forum"
8
5
 
@@ -1,8 +1,5 @@
1
1
  module SimpleForum
2
2
  class Post < ::ActiveRecord::Base
3
-
4
- set_table_name 'simple_forum_posts' #should work table_name_prefix in SimpleForum module but it's not!'
5
-
6
3
  belongs_to :user,
7
4
  :class_name => instance_eval(&AbstractAuth.invoke(:user_class)).name
8
5
 
@@ -1,8 +1,5 @@
1
1
  module SimpleForum
2
2
  class Topic < ::ActiveRecord::Base
3
-
4
- set_table_name 'simple_forum_topics' #should work table_name_prefix in SimpleForum module but it's not!'
5
-
6
3
  belongs_to :user, :class_name => instance_eval(&AbstractAuth.invoke(:user_class)).name
7
4
 
8
5
  belongs_to :forum,
@@ -17,7 +14,7 @@ module SimpleForum
17
14
  :class_name => "SimpleForum::Post"
18
15
 
19
16
  has_one :last_post,
20
- :order => "#{SimpleForum::Post.table_name}.created_at DESC",
17
+ :order => "#{SimpleForum::Post.quoted_table_name}.created_at DESC",
21
18
  :class_name => "SimpleForum::Post"
22
19
 
23
20
  has_one :first_post,
@@ -5,18 +5,17 @@
5
5
  <title><%= yield(:title) || '' %></title>
6
6
  <%= favicon_link_tag %>
7
7
 
8
- <%= stylesheet_link_tag('/simple_forum_engine/stylesheets/simple_forum') %>
8
+ <%= stylesheet_link_tag "simple_forum/application" %>
9
9
 
10
10
  <%= yield :stylesheets %>
11
11
 
12
- <%= javascript_include_tag('https://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js') %>
13
- <%= javascript_include_tag('rails') %>
12
+ <%= csrf_meta_tag %>
13
+
14
+ <%= javascript_include_tag "simple_forum/application" %>
14
15
 
15
16
  <%= yield :javascripts %>
16
17
 
17
18
  <%= yield :head %>
18
-
19
- <%= csrf_meta_tag %>
20
19
  </head>
21
20
  <body>
22
21
 
@@ -35,13 +35,13 @@
35
35
  <tr>
36
36
  <td class="icon-cell">
37
37
  <% if f.recent_activity?(authenticated_user) %>
38
- <%= image_tag('/simple_forum_engine/images/forumNewPosts.gif', :alt => t('simple_forum.new_posts_present'), :title => t('simple_forum.new_posts_present')) %>
38
+ <%= image_tag('simple_forum/forumNewPosts.gif', :alt => t('simple_forum.new_posts_present'), :title => t('simple_forum.new_posts_present')) %>
39
39
  <% else %>
40
- <%= image_tag('/simple_forum_engine/images/forumNoNewPosts.gif', :alt => t('simple_forum.new_posts_absent'), :title => t('simple_forum.new_posts_absent')) %>
40
+ <%= image_tag('simple_forum/forumNoNewPosts.gif', :alt => t('simple_forum.new_posts_absent'), :title => t('simple_forum.new_posts_absent')) %>
41
41
  <% end %>
42
42
  </td>
43
43
  <td class="forum-cell">
44
- <span><%= link_to f.name, simple_forum_forum_path(f) %></span><br/>
44
+ <span><%= link_to f.name, simple_forum.forum_path(f) %></span><br/>
45
45
  <span><%= f.body %></span><br/>
46
46
  <span>
47
47
  (
@@ -60,7 +60,7 @@
60
60
  <% if f.recent_post %>
61
61
  <%= content_tag :span, :title => l(f.recent_post.created_at) do %>
62
62
  <%= link_to "#{time_ago_in_words(f.recent_post.created_at)} #{t('simple_forum.ago', :default => 'ago')}",
63
- simple_forum_forum_topic_path(f, f.recent_post.topic, :page => f.recent_post.topic.last_page, :anchor => "post-#{f.recent_post.id}")
63
+ simple_forum.forum_topic_path(f, f.recent_post.topic, :page => f.recent_post.topic.last_page, :anchor => "post-#{f.recent_post.id}")
64
64
  %>
65
65
  <% end %>
66
66
  <br/>
@@ -1,7 +1,7 @@
1
1
  <div id="breadcrumbs">
2
2
  <%= link_to SimpleForum.root_application_name, root_path %>
3
3
  &gt;
4
- <%= link_to 'Forum', simple_forum_root_path %>
4
+ <%= link_to 'Forum', simple_forum.root_path %>
5
5
  &gt;
6
6
  <%= @forum.name %>
7
7
  </div>
@@ -11,7 +11,7 @@
11
11
 
12
12
  <% if @forum.is_topicable? && user_authenticated? %>
13
13
  <li>
14
- <%= link_to t(".new_topic"), new_simple_forum_forum_topic_path(@forum) %>
14
+ <%= link_to t(".new_topic"), simple_forum.new_forum_topic_path(@forum) %>
15
15
  </li>
16
16
  <% end %>
17
17
  </ul>
@@ -42,13 +42,13 @@
42
42
  <% end %>
43
43
  </td>
44
44
  <td class="topic-cell">
45
- <span><%= link_to t.title, simple_forum_forum_topic_path(@forum, t) %></span>
45
+ <span><%= link_to t.title, simple_forum.forum_topic_path(@forum, t) %></span>
46
46
  <% if t.paged? %>
47
47
  <span>
48
48
  <ul>
49
49
  <% t.page_numbers.each do |p| %>
50
50
  <% if p %>
51
- <li><%= link_to p, simple_forum_forum_topic_path(@forum, t, :page => p) %></li>
51
+ <li><%= link_to p, simple_forum.forum_topic_path(@forum, t, :page => p) %></li>
52
52
  <% else %>
53
53
  <li class="gap">&hellip;</li>
54
54
  <% end %>
@@ -75,7 +75,7 @@
75
75
  <% if t.recent_post %>
76
76
  <%= content_tag :span, :title => l(t.recent_post.created_at) do %>
77
77
  <%= link_to "#{time_ago_in_words(t.recent_post.created_at)} #{t('simple_forum.ago', :default => 'ago')}",
78
- simple_forum_forum_topic_path(@forum, t, :page => t.last_page, :anchor => "post-#{t.recent_post.id}")
78
+ simple_forum.forum_topic_path(@forum, t, :page => t.last_page, :anchor => "post-#{t.recent_post.id}")
79
79
  %>
80
80
  <% end %>
81
81
  <br/>
@@ -9,18 +9,18 @@
9
9
  <% end %>
10
10
  <% content_for :head do %>
11
11
  <script type="text/javascript">
12
- var post_preview_path = "<%= preview_simple_forum_forum_topic_posts_path(@forum, @topic) %>";
12
+ var post_preview_path = "<%= simple_forum.preview_forum_topic_posts_path(@forum, @topic) %>";
13
13
  </script>
14
14
  <% end %>
15
15
 
16
16
  <div id="breadcrumbs">
17
17
  <%= link_to SimpleForum.root_application_name, root_path %>
18
18
  &gt;
19
- <%= link_to 'Forum', simple_forum_root_path %>
19
+ <%= link_to 'Forum', simple_forum.root_path %>
20
20
  &gt;
21
- <%= link_to @forum.name, simple_forum_forum_path(@forum) %>
21
+ <%= link_to @forum.name, simple_forum.forum_path(@forum) %>
22
22
  &gt;
23
- <%= link_to @topic.title, simple_forum_forum_topic_path(@forum, @topic) %>
23
+ <%= link_to @topic.title, simple_forum.forum_topic_path(@forum, @topic) %>
24
24
  &gt;
25
25
  <%= t('.post_edit') %>
26
26
  </div>
@@ -29,7 +29,7 @@
29
29
 
30
30
  </table>
31
31
 
32
- <%= form_for @post, :url => simple_forum_forum_topic_post_path(@forum, @topic, @post), :as => :post, :html => {:id => 'new_post_form'} do |f| -%>
32
+ <%= form_for @post, :url => simple_forum.forum_topic_post_path(@forum, @topic, @post), :as => :post, :html => {:id => 'new_post_form'} do |f| -%>
33
33
  <p>
34
34
  <%= f.label :body %>
35
35
  <%= f.text_area :body, :class => 'markitup post-body' %>
@@ -27,10 +27,10 @@
27
27
  <td class="actions">
28
28
  <% if user_authenticated? %>
29
29
  <% if post.editable_by?(authenticated_user, @forum.moderated_by?(authenticated_user)) %>
30
- <%= link_to t('.edit'), edit_simple_forum_forum_topic_post_path(@forum, @topic, post) %>
30
+ <%= link_to t('.edit'), simple_forum.edit_forum_topic_post_path(@forum, @topic, post) %>
31
31
  <% end %>
32
32
  <% if post.deletable_by?(authenticated_user, @forum.moderated_by?(authenticated_user)) %>
33
- <%= link_to t('.delete'), delete_simple_forum_forum_topic_post_path(@forum, @topic, post), :method => :delete, :confirm => t('simple_forum.are_you_sure') %>
33
+ <%= link_to t('.delete'), simple_forum.delete_forum_topic_post_path(@forum, @topic, post), :method => :delete, :confirm => t('simple_forum.are_you_sure') %>
34
34
  <% end %>
35
35
  <% if @topic.is_open? %>
36
36
  <%= link_to t('.cite'), "#", :onclick => "$('#new_post_form textarea').val('[quote=\"#{post.user.name}\"]\\n#{escape_javascript(post.body)}\\n[/quote]'); return false;" %>
@@ -1,14 +1,14 @@
1
1
  <div id="breadcrumbs">
2
2
  <%= link_to SimpleForum.root_application_name, root_path %>
3
3
  &gt;
4
- <%= link_to 'Forum', simple_forum_root_path %>
4
+ <%= link_to 'Forum', simple_forum.root_path %>
5
5
  &gt;
6
- <%= link_to @forum.name, simple_forum_forum_path(@forum) %>
6
+ <%= link_to @forum.name, simple_forum.forum_path(@forum) %>
7
7
  &gt;
8
8
  <%= t('.new_topic') %>
9
9
  </div>
10
10
 
11
- <%= form_for @topic, :as => :topic, :url => simple_forum_forum_topics_path(@forum) do |f| %>
11
+ <%= form_for @topic, :as => :topic, :url => simple_forum.forum_topics_path(@forum) do |f| %>
12
12
  <p>
13
13
  <%= f.label :title %><br/>
14
14
  <%= f.text_field :title %>