mart wrote:
>
> On Sep 30, 2009, at 4:17 PM, Thomas Guettler wrote:
>
>> In OrderDetail you have a ForeignKey to Product. But you need to
>> *copy*
>> the price. Example: if someone orders something at day1 for 1 dollar,
>> and you set the price on day2 to 3 dollar, you need to ship your
>> product cheap for all who odered before day2.
>>
>
> thanks thomas,
>
> i am aware of that, it is more the basic layout principle of such a
> "cart"
> the fixed price (and discount or such) of day1 would go into the
> ordered_products "through" table
> if its gonna be a many-to-many-field in "orders"
I would not use a ManyToManyField. I would use OrderDetail with
a ForeignKey to Order.
You can look at how satchmo did it. It is django application
for a online store:
http://www.satchmoproject.com/
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---