Monday, March 12, 2012

Re: "Dynamyc" modells

Hello,

2012.03.12. 20:48, "Shawn Milochik" <shawn@milochik.com> ezt írta:
>
> On 03/12/2012 03:34 PM, Ervin Hegedüs wrote:
>>
>> The main problem is the PromoList is _dynamyc_ - it means all
>> administrator on admin site should add new PromoList, without me
>> :), so I can't derivate all subclass in code...
>>
>
> You can't dynamically create database tables on the fly.
That's not true. Currently I'm using this way, which I described above, just I can't use Model methods. When admin creates a new record, Django creates a new table trough save hook.

>
> Why not make one model, give it an extra field for the description of what type of promo it is, and just add records to the same model for each "type" of promo code?

Some promotion has few millions of records, different promotions have different format of codes, ... And general: I'm looking for an ultimate solution, and may be the next time every ListRecord will have different columns.

Thanks:
a

--
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+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate