Check out http://github.com/p8/table_builder/tree/master. It works
similar to form_for. It requires objects with a method that returns a
date.
<% calendar_for(@tasks, :year => @year, :month => @month) do |t| %>
<%= t.head('mon', 'tue', 'wed', 'thu', 'fri', 'sat', 'sun') %>
<% t.day(:day_method => YOUR_DATE_METHOD) do |day, tasks| %>
<%= day.day %><br />
<% tasks.each do |task| %>
<%= h(task.name) %><br />
<% end %>
<% end %>
<% end %>
<% end %>
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---