Re: Model design

2009-10-29 Thread Caisys
Dear Vinicius, What is the difference between: -- def __unicode__(self): return unicode(self.place)+' - '+self.nome -- and -- def __unicode__(self): return self.place+' - '+self.nome -- because the both seem to work and display the same inf

Re: Model design

2009-10-25 Thread Caisys
familiar with the forms. I just need to know how to call the a related field in __unicode__ (self) On Oct 25, 2:30 pm, "Vinicius Mendes | meiocodigo.com" wrote: > On Oct 25, 4:53 am, Caisys wrote: > > > > Just override the form in the inlne admin. All you have to do is set a &

Re: Model design

2009-10-25 Thread Caisys
e a view to retrieve the subplaces based in the selected > place. I am not so sure how to do that yet. However, i would like to know how i could not return the related object name in __unicode__ . Where did I go wrong? Thanks On Oct 24, 1:38 pm, "Vinicius Mendes | meiocodigo.com&qu

Re: Model design

2009-10-24 Thread Caisys
more logically. > > On 23 Okt., 15:41, chefsmart wrote: > > > I would go with your second solution. > > > On Oct 23, 5:17 pm, Caisys wrote: > > > > Hi, > > > I have classes for Event, Place and Subplace. Some of the Places are > > > divided

Re: More than one stackedinline in admin

2009-10-23 Thread Caisys
(admin.ModelAdmin): inlines = [child2Inline] admin.site.register(model1, child1Admin, child2Admin) On Oct 21, 3:45 pm, Daniel Roseman wrote: > On Oct 21, 2:42 pm, Caisys wrote: > > > > > > > Hi, > > Suppose i have 3 model classes: > &g

Model design

2009-10-23 Thread Caisys
Hi, I have classes for Event, Place and Subplace. Some of the Places are divided into different Halls (Subplace) and some have only one. I would like to know how design the relations between the classes. 1) Should I put two columns in the Event one FK to Place and another FK to Hall? 2) Should I

More than one stackedinline in admin

2009-10-21 Thread Caisys
Hi, Suppose i have 3 model classes: class model1(model.Models): fields . class child1(models.Model): model1 = models.ForeignKey(model1) class child2(models.Model): model1 = models.ForeignKey(model1) -- Is it possible to have child1 and child2

Re: Redirect home page

2009-10-11 Thread Caisys
Thanks On Oct 11, 8:15 am, jeffschenck wrote: > The simplest option is probably to use the redirect generic view > (http://docs.djangoproject.com/en/dev/ref/generic-views/#django-views- > generic-simple-redirect-to). You could add something like this to your > urlconf: > > (r'^$', 'django.views.

Redirect home page

2009-10-10 Thread Caisys
Hi, I would like visitors to my site homepage www.example.com to be redirected to www.example.com/en/ in order to allow for translations in the future. What is the most efficient way? 1- Use apache mod-rewrite? 2- I know i could use the HttpResponseRedirect function in django but i felt it might

Django for workflow

2009-08-13 Thread Caisys
Hi Everyone, I would like to develop a small internal tool in my company for telesales agents to fill in orders of different products then finance can approve them and send them to the shipping department. I was going to use php and dreamweaver but I have some python and django knowledge. My impre

Re: Flatpage App vs. Static Template

2008-11-21 Thread Caisys
Thank you all, it's my first django project and its nice to be reassured ;) --~--~-~--~~~---~--~~ 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 u

Flatpage App vs. Static Template

2008-11-21 Thread Caisys
Hi, I would like to publish some statics files on my website and I have a some questions: 1- The flatpage app examples like http://www.lawrence.com/about/staph/ contain elaborate html, is this edited as a text field in the admin interface, wouldn't it be tedious to maintain? 2- Can i do something

Re: Using Django

2008-11-05 Thread Caisys
This looks like you are missing the link between your web server and the django code. I do not know how dreamhost works but for django to work you need to tell your web server: "hey server when you get a request for www.mysite.com don't just try to serve index.html from a root directory, i want yo

Re: Using Django

2008-11-05 Thread Caisys
This looks like you are missing the link between your web server and the django code. I do not know how dreamhost works but for django to work you need to tell your web server: "hey server when you get a request for www.mysite.com don't just try to serve index.html from a root directory, i want yo

Cascading List List Boxes

2008-11-01 Thread Caisys
Hi, Is it possible to populate a list depending on another list choice? I am working on an event guide, when creating the event the user will need to select a place from a drop down list, some places have different rooms, so I want another drop down list containing the rooms that relate to the pl

Re: Designing the model of a website

2008-09-29 Thread Caisys
Thanks a lot guys. That was helpful. I will try it like this and definitely come back later for more advice. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Designing the model of a website

2008-09-28 Thread Caisys
Hi, I am new to django and mvc. I have php and asp experience. I followed the tutorial and would like to create a site that will act as as a sort of city guide. to Simplify things I will assume the site will have 5 types of information: 1-Hotels 2- Monuments 3-Venues 4-Peformers 5-Concerts (have

Re: View error in tutorial 3 (URLCONF)

2008-09-23 Thread Caisys
Thanks a lot !! On Sep 22, 6:19 pm, "Karen Tracey" <[EMAIL PROTECTED]> wrote: > On Mon, Sep 22, 2008 at 11:52 AM, Caisys <[EMAIL PROTECTED]> wrote: > > > Hi, > > I am following the tutorials on django website. My problem is that > > when i create u

View error in tutorial 3 (URLCONF)

2008-09-22 Thread Caisys
Hi, I am following the tutorials on django website. My problem is that when i create url conf for views that do not exist, the admin site ceases to work. Mysite\urls.py includes: (r'^admin/(.*)', admin.site.root), (r'^polls/', include('mysite.polls.urls')), Mysite\Polls\urls.py includes: urlpatter