On 1 Oct 2006, at 17:02, Nicolas Steinmetz wrote:
> to have 3 app (a blog app, a tutorial app and a category app) ? In  
> the second case, the questions are :

I would suggest this is the way to go, if you added another app, say  
a photo gallery or something, you can add photos to categories.

> 1. Is it possible to set "bridge" between apps in django ?

Yep, you import the models...

from myproject.apps.categories.models import Category

then you can do something along the lines of:

class BlogPost(models.Model):
     categories = models.ManyToManyField(Category)

It may be worth having a look at the generic relationships [1] stuff  
and the Tag application used as an example. While the GR stuff in the  
Django admin is truly horrible, you can easily write a couple of  
views and maybe a custom manipulator to tidy things up.

Hope that helps, John.


[1] <http://www.djangoproject.com/documentation/models/ 
generic_relations/>

--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to