Mike Orr wrote: > I'm not happy with the "model." prefix throughout the Data Queries > section. Some people will use this code in the model; others in the > controller. I think it's less jarring to have it without the prefix > and people can add it, rather than the other way around. Do others > think differently?
Well, I guess this was the default place back when pylons had a database helper. Just from my POV, I feel it convenient to have all my SA stuff under "model". I have like over 20 models (tables) and half more controllers. Instead of playing around with import statments filling up my namespance and adapt the changes to every new controller I create, it's just handy to have them all available under model as it's already there for you. That prefix doesn't bother me much when I'm just about to write a model.Client.query.options(...).join(['...','...','...']).filter(foo.c.bar==baz).filter(or_(*OR)).all() long line. :) "model" is like my pillow, my SA models are kept under it. AFAIR, this is how the pylonshq is done. Back when I started learning Pylons, I remember myself browing the source code. So from my POV, it's also kind of historical. :) Either way is not incorrect and the tutorial reader can just adapt to his needs. Alex --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pylons-discuss" 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/pylons-discuss?hl=en -~----------~----~----~----~------~----~------~--~---
