[Radiant] Comments behaviors released (Sean Cribbs)
Nicholas Mulder [Mulder Consulting]
nick at mulderconsulting.ca
Fri Sep 1 22:45:47 CDT 2006
Sean,
Behavior looks good! I quickly put it into a plugin since i dont have
an expanded radiant install going at the moment. It seems to be having
a problem with
comments.parts.create! :name => "config", :content =>
(@page.part("config").content || "")
line 29 commentable_behavior.rb nil.content call.
Seems like if you dont define a config part it errors out. try :content
=> (@page.part("config") ? @page.part("config").content : "") instead.
or something similar. getting the part once might be a better idea.
also with that little fix in place getting a "Status must be a number"
|comments_util.rb:23:in `create_comment_in'
Might want to call .to_i on line 25 same file -- :status_id => page_config["status"].to_i || Status[:draft].to_i
that seemed to do the trick for me. Wicked job so easy so slick.
Are these comments going to end up in their own table? or stay in the page/page_parts tables?
|
Nicholas Mulder
Mulder Consulting
905 658 5641
nick at mulderconsulting.ca <mailto:nick at mulderconsulting.ca>
More information about the Radiant
mailing list