muck-comments 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION +1 -1
- data/db/migrate/20090613173314_create_comments.rb +1 -1
- data/muck-comments.gemspec +2 -3
- data/rdoc/created.rid +1 -1
- data/rdoc/files/README_rdoc.html +22 -1
- metadata +2 -3
- data/pkg/muck-comments-0.1.1.gem +0 -0
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.2
|
@@ -3,7 +3,7 @@ class CreateComments < ActiveRecord::Migration
|
|
3
3
|
create_table :comments, :force => true do |t|
|
4
4
|
t.integer :commentable_id, :default => 0
|
5
5
|
t.string :commentable_type, :limit => 15, :default => ""
|
6
|
-
t.text :body
|
6
|
+
t.text :body
|
7
7
|
t.integer :user_id, :default => 0, :null => false
|
8
8
|
t.integer :parent_id
|
9
9
|
t.integer :lft
|
data/muck-comments.gemspec
CHANGED
@@ -2,11 +2,11 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{muck-comments}
|
5
|
-
s.version = "0.1.
|
5
|
+
s.version = "0.1.2"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Justin Ball"]
|
9
|
-
s.date = %q{2009-06-
|
9
|
+
s.date = %q{2009-06-18}
|
10
10
|
s.description = %q{The comment engine for the muck system.}
|
11
11
|
s.email = %q{justinball@gmail.com}
|
12
12
|
s.extra_rdoc_files = [
|
@@ -47,7 +47,6 @@ Gem::Specification.new do |s|
|
|
47
47
|
"locales/en.yml",
|
48
48
|
"locales/en.yml",
|
49
49
|
"muck-comments.gemspec",
|
50
|
-
"pkg/muck-comments-0.1.1.gem",
|
51
50
|
"rails/init.rb",
|
52
51
|
"rails/init.rb",
|
53
52
|
"rdoc/classes/ActionController.html",
|
data/rdoc/created.rid
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
Tue, 16 Jun 2009 23:13:25 -0600
|
data/rdoc/files/README_rdoc.html
CHANGED
@@ -56,7 +56,7 @@
|
|
56
56
|
</tr>
|
57
57
|
<tr class="top-aligned-row">
|
58
58
|
<td><strong>Last Update:</strong></td>
|
59
|
-
<td>
|
59
|
+
<td>Tue Jun 16 23:04:54 -0600 2009</td>
|
60
60
|
</tr>
|
61
61
|
</table>
|
62
62
|
</div>
|
@@ -123,6 +123,27 @@ example:
|
|
123
123
|
|
124
124
|
end
|
125
125
|
</pre>
|
126
|
+
<h3>Comment partial</h3>
|
127
|
+
<p>
|
128
|
+
When calling create in the comments controller with :format =>
|
129
|
+
‘json’ the resulting json will include an ‘html’
|
130
|
+
field that contains a rendered version of the comment html. To facilitate
|
131
|
+
this process be sure to create a partial called
|
132
|
+
‘_comment.html.erb’ under a directory with the same name as the
|
133
|
+
parent object. The partial will be passed an object
|
134
|
+
‘comment_owner’ that references the parent object.
|
135
|
+
</p>
|
136
|
+
<p>
|
137
|
+
For example, for an object ‘activity’ that acts_as_commentable
|
138
|
+
create a partial ‘activities/_comment.html.erb’. The contents
|
139
|
+
might look like this:
|
140
|
+
</p>
|
141
|
+
<pre>
|
142
|
+
<div id="<%= comment.dom_id %>">
|
143
|
+
<span class="user"><%= link_to comment_owner.user, comment_owner.user %></span>
|
144
|
+
<p><%= h comment.body %></p>
|
145
|
+
</div>
|
146
|
+
</pre>
|
126
147
|
<p>
|
127
148
|
Copyright (c) 2009 Justin Ball, released under the MIT license
|
128
149
|
</p>
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: muck-comments
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Justin Ball
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-06-
|
12
|
+
date: 2009-06-18 00:00:00 -06:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -61,7 +61,6 @@ files:
|
|
61
61
|
- lib/muck_comments/tasks.rb
|
62
62
|
- locales/en.yml
|
63
63
|
- muck-comments.gemspec
|
64
|
-
- pkg/muck-comments-0.1.1.gem
|
65
64
|
- rails/init.rb
|
66
65
|
- rdoc/classes/ActionController.html
|
67
66
|
- rdoc/classes/ActionController/Routing.html
|
data/pkg/muck-comments-0.1.1.gem
DELETED
Binary file
|