So using your tip, I've done this:
class Foo1Bar(FooBar):
>
> objects = TypeAwareManager('foo__type',1)
>
> class Meta:
> proxy= True
>
> def change_fb(cls):
> old_foo = cls.foo
>
> @property
> def new_foo(self):
> return
Thanks, I saw that .model thing too, but was also unsure about it... I
might just test it.
Em sábado, 21 de abril de 2012 19h04min30s UTC-3, akaariai escreveu:
>
> On Apr 21, 8:35 pm, Arruda wrote:
> > Should I create this many-to-many table as a normal model(no
On Apr 21, 8:35 pm, Arruda wrote:
> Should I create this many-to-many table as a normal model(no proxy) and set
> the foo foreingkey to Foo1 instead of Foo?
> Or should I use only FooBar as many-to-many and create some specific
> queries that would convert ALL the
I know already that are some limitations when using Many-to-Many and proxy
models, I just want to know what is the best practices when doing something
in this case:
obs: the Choices is from model_utils (Django model utils)
I have this first class:
class Foo(models.Model):
> "The single
I'm working on a rewrite of an app that has three categories of users
and I'm wondering about the best way to link them to the
authentication system:
In-House Staff.
Contractors
Customers who interact via the app.
The in-house staff model doesn't store any address info. Contractor
and Customer
Hi everyone,
I am still having issues with my data models. I can't tell if the
underlying problem is my model definitions or my inability to do the
queries to manipulate my models to get the output that I want.
Could someone please tell me if this is the right way to do it in my
models.py?
On Mar 28, 2:28 am, Daniel wrote:
> Hi all,
>
> I'd appreciate it if you could help me out with something.
>
> I am trying to build a way to use faceted browsing through a database
> of biological samples.
>
> what I want to model is this:
>
> Sample 1
> race = white
>
Hi
For what i understand of your problem, you are calling tag the fields
of a Model called Sample. From, what you say, it is not possible to
say a lot of things, but it appear that you will have others models,
such as Diseases, Country,
You will need to relate the models with
Hi all,
I'd appreciate it if you could help me out with something.
I am trying to build a way to use faceted browsing through a database
of biological samples.
what I want to model is this:
Sample 1
race = white
age = adult
gene = XCFR2
disease = cancer
Sample 2
race =
m, ALJ <astley.lejas...@gmail.com> wrote:
>
> > > > Hi Preston,
>
> > > > Sorry, I don't get it.
>
> > > > The certainly do have the same fields, but sometimes the fields are
> > > > derived from a linked table, or are a foreign key o
stand how having the interface adapt to what the
> > > current type is would work.
>
> > > ALJ
>
> > > On Mar 16, 3:04 pm, Preston Holmes <pres...@ptone.com> wrote:
>
> > > > On Mar 16, 3:21 am, ALJ <astley.lejas...@gmail.co
e
> > current type is would work.
>
> > ALJ
>
> > On Mar 16, 3:04 pm, Preston Holmes <pres...@ptone.com> wrote:
>
> > > On Mar 16, 3:21 am, ALJ <astley.lejas...@gmail.com> wrote:
>
> > > > This is a bit of a modeling question that I
>
> ALJ
>
> On Mar 16, 3:04 pm, Preston Holmes <pres...@ptone.com> wrote:
>
> > On Mar 16, 3:21 am, ALJ <astley.lejas...@gmail.com> wrote:
>
> > > This is a bit of a modeling question that I am struggling to get my
> > > head around. How
, Preston Holmes <pres...@ptone.com> wrote:
> On Mar 16, 3:21 am, ALJ <astley.lejas...@gmail.com> wrote:
>
>
>
> > This is a bit of a modeling question that I am struggling to get my
> > head around. How would you model this scenario?
>
> > I have to record ex
On Mar 16, 3:21 am, ALJ <astley.lejas...@gmail.com> wrote:
> This is a bit of a modeling question that I am struggling to get my
> head around. How would you model this scenario?
>
> I have to record expenses that are of 3 different types.
>
> 1. Fixed - The name of the
... I suppose this would be the approach for extending a base model.
My question is ... does it really matter which approach to take? Does
one approach have advanteages or pitfalls?
>>.
class BaseCost(models.Model):
markettingevent = models.ForeignKey(Event)
This is a bit of a modeling question that I am struggling to get my
head around. How would you model this scenario?
I have to record expenses that are of 3 different types.
1. Fixed - The name of the expense and unit amount are fixed. For
example, "inconvenience allowance" of £30
Hello Jeff,
Not sure of your implementation but you should be able to adapt:
http://projects.django-development.com/trac/dd_devel/wiki/recursive_groups_of_groups
to work. You could replace department with navigation-collection and
employee with menu item I believe. If nothing else the tests
Hello Jeff,
Not sure of your implementation but you should be able to adapt:
http://projects.django-development.com/trac/dd_devel/wiki/recursive_groups_of_groups
to work. You could replace department with navigation-collection and
employee with menu item I believe. If nothing else the tests
Hi Guys,
I have a website (go figure!) where there is a main navigation, there
is going to need to be sub pages for each main nav item, but this sub
page can belong to more than 1 main nav, typically in the past I used
a self referencing FK to handle this, but this time it's a m2m, any
tips on
If you want to add a profile for each user, check out
http://scottbarnham.com/blog/2008/08/21/extending-the-django-user-model-with-inheritance/
the key in django is reusing existing "applications"
maybe this might help
http://code.google.com/p/django-messages/
On Thu, Jan 21, 2010 at 6:16 AM,
This is my first Django experience and I'm having trouble figuring out
the right answer to the right relationship to have. (brain fart
maybe.. )
I have a site that users have profiles and can message each other. So
my model looks like:
class User(models.Model):
username =
I've got a csv file filled with directory paths, users and their
permissions...
I have a database for paths and users
I need to go to every path and find which user has what permissions for
that path.
do I need to make a
class Web_Permission(models.Model):
path = models.ForeignKey(Web_Path)
23 matches
Mail list logo