On Fri, Mar 26, 2010 at 2:33 PM, Michael Peck <[email protected]> wrote: > prefer to have a list of valid statuses, and a more normalized database. > What if, in the database, we have a table of statuses, such as: > > id | status > 1 | registered > 2 | active > 3 | loggedin > ... > > ...and we store the status id in our user model...how would I handle the > authenticate method call?
I'm personally not sure I'd consider that normalized since a user could be all 3. I'd have a boolean and 3 columns, and I think it'd be more normalized. then you can just check the bool. although I'm not sure why you want to check any of those at authentication. One of the only other fields I check is a boolean 'enabled' because I want to be able to disable user accounts, and a disabled account can't authenticate. also if a users's status is 'logged in' why are we logging them in again? I post apologize because I don't actually know how to do what you are trying to do... but I suppose I commented because I even less understand why. -- Caleb Cushing http://xenoterracide.blogspot.com _______________________________________________ List: [email protected] Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[email protected]/ Dev site: http://dev.catalyst.perl.org/
