Thanks, Rick, for a great plugin. But one thgn leads to another, sort
of like pulling at the thread in the willy jumper ....
Three questions about acts_as_versioned; the second leads to other
issues.
1. use of :sequence_name
is this the "order_by"? How is this going to be different from
using the ':version_column' to order the
revisions.
This is some postgres thing, you can probably ignore it on other databases.
2. Derived from (1).
If I have a ':version_column' set and I want optimistic locking
as well, how do I do that?
I think you just set the version column to lock_version. I've never
used optimistic locking, so it may need some patches to get working
correctly. Feel free to contribute if you do this.
3. I'm very unclear about using ':extend' or the "acts_as_versioned
do ... end" construct.
It's similar to the :extend or block syntax of ActiveRecord
associations, only it defines the methods on both the current class
and the version class. For instance in Lighthouse (my Rails based
ticket tracker app), Ticket comments are really just versions of the
same ticket. But, I want the Ticket::Version model to quack like a
Ticket, so I add a lot of methods and associations inside the
acts_as_versioned block.
Obviously I want to be able to reference any revision of the Page and
any field or method: