I need year to date and month to date creation date filters on table-
plus. I followed the agility tutorial except that I created the
options array as follows:
periods = [[:YTD, Date.civil(Date.today.year,1,1)-1] ,
[:MTD, Date.civil(Date.today.year,Date.today.month,
1)-1]]
I subtract a day from the dates so i can use the created_after scope.
Using <filter-menu param-name="start_date" options='&periods'/>
prependend to the table-plus header works, and my controller applies
the scope created_after((params[:start_date]). Everything does what
I expect it to except that the filter always goes back to All. As I
looked through the posts, I saw that a much earlier release of Hobo
had this problem, but it was fixed a while ago. The only difference
I can see between what I am doing and the tutorial is that I am
manually creating my options. Is the easiest way to fix this to
create a model for a period table?
--
You received this message because you are subscribed to the Google Groups "Hobo
Users" 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/hobousers?hl=en.