On Feb 9, 2010, at 8:10 PM, steve enzer wrote:

Thanks, Bryan and Owen!

OK, so... here's the update. I decided that I'd start fresh and use
the latest code from github, and was up and running again pretty
quickly. I don't know what I did to cream the nav, but I wanted to
keep moving forward, and that was a pretty good first step.  I hadn't
gone very far, and had some false steps.

It's been a great day so far. All is gently falling into place, like
it should. I'm not sure when I'm going to hit the wall, but I guess
you'll hear about it here...

Well, two minor things I could ask about: first, do I really have to
keep declaring the same 4 permission methods (in my case, because I'm
using an admin subsite, they all return true, all the time) in the
model; can the model classes be subclasses of an abstract domain model
class that has the permissions, or can you think of a different/better
way to accomplish the same thing?


I can't think of a better way off the top of my head - note that in the standard use case, the models are generated with the hobo_model generator that automatically builds that skeleton.

In your case, copy+paste FTW. :)


Also: the project has both customers (who order things and have
accounts on the public site) and Users (who work for the client, and
can log into the backend). I'm trying to figure out how I'm going to
make that work; the client is pretty convinced he wants them to be
separate tables.


Hobo will work with two totally split user tables - I've got an app in production that does just that. It's a little messy, since you basically need two different user_controllers, but it works.

You could try the basic "administrator flag" method that the default generators give you; not sure if that really makes sense in this case, though.

You could also try using STI on the Users table - not sure how easy this would be with your existing infrastructure, but it does simplify things considerably. 99% of the bugs are finally out of the STI stuff, so you shouldn't have any problems.

--Matt Jones

--
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.

Reply via email to