uest logs when you're running the
> development server (runserver). When you're running in fastcgi mode (and
> its been a while since I have), you'll only get entries in outlog and
> errlog if you actually send stuff to stdout and stderr yourself. And THAT
> will
Hello,
I'm running a django app on lighttpd with fastcgi.
For debugging matters I would need the output logs that usually are
displayed on the console.
Because I run my application in a daemonize mode I tried to use the outlog
and errlog options but it did not work.
Here is the command I run:
I'm having some trouble making my website compatible with accented
characters (french website).
I have a form where some field values can be with accented chars: "Coupé"
for instance.
My URL looks like this:
http://localhost:8080/recherches/s?marque=Audi&modeles=A5+Coup%C3%A9
In my django v
You may be right but like I said, I will do differently:
for s in MyBaseModel.__subclasses__():
if s.__name__ == "ClassA":
MyClass = ClassA
elif s.__name__ == "ClassB":
MyClass = ClassB
it was so simple!!!
Thank you anyway.
--
You received this message because you are
Nevermind,
I will do differently...
--
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.
Fo
Hi Micky,
sorry for my late answer but I havn't been working this week-end.
I just tried your trick but it doesn't work. I don't think it's a
probleme of manager, because if I want to query a subclass directly by
its name, it works:
ClassA.objects.all() works normally.
On 8 juil, 19:48, Micky Hul
#x27;t understand why it raises this error, what am I missing?
Thank you very much for your help.
Cheers,
Gontran
--
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 un
> Do you mean, "in a ModelAdmin subclass instance, how do I get the
> model class that instance is associated with?"? If so, self.model.
Yes I do.
Thank you Tom.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send emai
)
admin.site.register(ClassB, CommonModelAdmin)
I defined a custom admin view in which I would like to get the class
that is currently administered.
Is it possible to do it?
Thank you very much for your help
Regards,
Gontran
--
You received this message because you are subscribed to the Google
Thank you very much Francesco,
Works like a charm...
On 20 juin, 15:33, francescortiz wrote:
> Try doing this in your models.py:
>
> def get_profile(self):
> ...your code to get the profile for a the user...
>
> User.get_profile = get_profile
>
> On Jun 2
elp.
Regards,
Gontran
--
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 o
Hi Everyone,
I've been searching again and again but I can't figure out how to
display the list of all users in a group admin page. I'd like to
select members of a group directly from this group admin page.
Does anyone knows if it's possible?
Thank you for your help.
Regard
mpty forms I defined with extra keyword.
My question is: how to display the name of the previously uploded
files instead of having an empty input?
Thank you by advance,
Gontran
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post
rmSet = inlineformset_factory(Publication, Document)
So I know have two forms and I just want one form.
Is it possible to simply add the inline formset to PublicationForm ?
Thank you in advance,
regards,
Gontran
--
You received this message because you are subscribed to the Google Groups
"Django users&
()).distinct()
I hope that it will be useful to somebody.
Regards,
Gontran
On 29 mar, 10:34, Kenneth Gonsalves wrote:
> On Tue, 2011-03-29 at 01:17 -0700, bruno desthuilliers wrote:
> > On 29 mar, 09:33, Kenneth Gonsalves wrote:
> > > Product is not linked to them - they are
ofile().company.product_licences.all()).distinct()
On 29 mar, 10:24, bruno desthuilliers
wrote:
> On 29 mar, 09:11, gontran wrote:
>
> > Hi everybody,
>
> > considering the folowing models:
>
> > UserProfile(models.Model):
> > user = models.OneToOneField(User)
&g
Ok. I 'll try again
Thank you very much for your consideration.
Regards,
Gontran
On 29 mar, 09:33, Kenneth Gonsalves wrote:
> Product is not linked to them - they are linked to Product. I do not
> think you can do it in one query because there are ManyToMany fields
> which have t
Yes: ProductLicence and News
On 29 mar, 09:19, Kenneth Gonsalves wrote:
> On Tue, 2011-03-29 at 00:11 -0700, gontran wrote:
> > UserProfile(models.Model):
> > user = models.OneToOneField(User)
> > company = models.ForeignKey(Company)
>
> > Company(models.Mo
given user, that are related to products, for
which the company of the user owns licences.
Is it possible to do it with a single query?
Thank you for your time,
regards,
Gontran
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To po
Still no answers.
Is it because it's impossible?
By the way, I know that inside the code of my tag I can get the
context and then the language used by the user, by I want to access to
this value inside my template, without having to pass explicitely the
value.
On 25 mar, 16:39, gontran
g something or is it impossible to use LANGUAGE_CODE in
this case?
Thank you for your answers.
Regards,
Gontran
--
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 uns
Hi,
back from my WE and still no answers.
Should I presume that what I want to do is impossible?
On 11 mar, 17:40, gontran wrote:
> Hi,
>
> I'm wondering if it's possible to chain StackedInlined object in a
> django admin page.
> Let me explain it:
> I have a class
I didn't try it, but werefr0g may be right. It seems that
Model.clean() is the method do you need. And you can still add a
javascript control for more convenience without the risk that if a
user deactivate javascript, the error will be saved.
Let us know greenie if it's ok with this method.
On
edit: you don't need to raise an error if the restaurant already has 3
Cuisine's objects associated, you just need to return a string with
the explanation of the error.
On 11 mar, 20:11, gontran wrote:
> Hi greenie,
>
> you just need to override the save method from yo
Hi greenie,
you just need to override the save method from your model Restaurant.
Before saving each instance, you check if the restaurant already has
3 Cuisine's objects associated. If yes, you don't save the instance
and raise an error for exemple, if no, just call the standard method
of the su
Hi,
I'm wondering if it's possible to chain StackedInlined object in a
django admin page.
Let me explain it:
I have a class UserProfile which is linked by a OneToOneField to the
django auth module class User. By this way (which is recommended) I
store additionnal informations about my users. In th
I will answer to myself (after having been trying for over an hour, I
found the answer a couple of minutes after posting my question)
products =
Product.objects.filter(productlicence__client=client).distinct()
--
You received this message because you are subscribed to the Google Groups
"Django
Sorry for the question,
but I've been trying for over an hour and just when I post this
message, I find the answer!!
Here is it:
products =
Product.objects.filter(productlicence__client=client).distinct()
Hope that it will be useful
--
You received this message because you are subscribed to the
oducts.
I'm trying to get in one query all products for which a given client
owns a licence.
Is it possible to do it or should I make 2 queries?
Thanks in advance
regards,
Gontran
--
You received this message because you are subscribed to the Google Groups
"Django users" gro
that's right!
thank you!
I don't know how I missed that information in the doc...
On 29 sep, 23:51, Javier Guerra wrote:
> sorry, the right syntax is
>
> {% for key, element in toto.items %}
> Name: {{ element.name }} - Desc: {{ element.desc }}
> {% endfor %}
>
> (as documented
> inhttp:/
It doesn't change anything
On 29 sep, 21:39, Javier Guerra wrote:
> On Tue, Sep 29, 2009 at 2:35 PM, gontran wrote:
> > In my template, I want to access to the name and to the desc of each
> > key of toto:
> > {% for element in toto %}
> > Name: {{ element
Hello,
here is my problem:
I have a dictionary which keys are unknown and which values are
dictionaries.
(I don't know the keys because they are dynamically created by a loop)
For example:
toto = {}
toto['123'] = {}
toto['123']['name'] = 'name of 123'
toto['123']['desc'] = 'desc of 123'
toto['45
Thank you for your answer.
--~--~-~--~~~---~--~~
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
Hello,
I would like to know if it's possible to automatically perform a db
operation at the end of a session.
For example: a client book an item in a store but don't ckeck out his
cart and close his browser. The item booked (which was unavailable
during the session) is now available for other cl
ld(max_length=30)
>
> def __unicode__(self):
> return self.name
>
> 2009/4/24 gontran
>
>
>
>
>
> > Hello,
>
> > I have a problem with a select in a ModelForm.
>
> > My model:
> > class Person(models.Model):
> >
Hello,
I have a problem with a select in a ModelForm.
My model:
class Person(models.Model):
first_name = models.CharField(max_length=30)
last_name = models.CharField(max_length=30)
id_town = foreignyKey(Town)
class Town(models.Model):
id_town = models.AutoField(primary_key=True)
Ok, thank you all for your help
On 12 nov, 15:19, Steve Holden <[EMAIL PROTECTED]> wrote:
> By all means use your custom tag. Inside the code for the tag, use a
> template to generate the HTML. That's all!
>
> regards
> Steve
>
> gontran wrote:
> > Could
Ok, thank you all for your help
On 12 nov, 15:19, Steve Holden <[EMAIL PROTECTED]> wrote:
> By all means use your custom tag. Inside the code for the tag, use a
> template to generate the HTML. That's all!
>
> regards
> Steve
>
> gontran wrote:
> > Could
Ok, thank you all for your help
On 12 nov, 15:19, Steve Holden <[EMAIL PROTECTED]> wrote:
> By all means use your custom tag. Inside the code for the tag, use a
> template to generate the HTML. That's all!
>
> regards
> Steve
>
> gontran wrote:
> > Could
Ok, thank you all for your help
On 12 nov, 15:19, Steve Holden <[EMAIL PROTECTED]> wrote:
> By all means use your custom tag. Inside the code for the tag, use a
> template to generate the HTML. That's all!
>
> regards
> Steve
>
> gontran wrote:
> > Could
Could you be more explicite because I don't understand everything and
why not using my custom tag? (which works fine)
On 12 nov, 14:43, bruno desthuilliers <[EMAIL PROTECTED]>
wrote:
> On 12 nov, 14:25, gontran <[EMAIL PROTECTED]> wrote:> On 12 nov, 13:22, Steve
>
Hello Steve,
Maybe I'm wrong but I want to display this menu in all pages of my
site, so by using a custom tag, I can display my menu without having
to import my model in my different views.
On 12 nov, 13:22, Steve Holden <[EMAIL PROTECTED]> wrote:
> gontran wrote:
> > Me
no desthuilliers <[EMAIL PROTECTED]>
wrote:
> On 12 nov, 09:22, gontran <[EMAIL PROTECTED]> wrote:
>
>
>
> > Hello,
>
> > I've got a problem with a recursive function:
> > in my model, I have a class named myClass: each object in my class has
> > an
id):
displayString += '' + element.id + ''
displayListObject(element.id, displayString)
else:
displayString += '' + element.id + ''
displayString += ''
return displayString
On 12 nov, 09:22, gontran <
Hello,
I've got a problem with a recursive function:
in my model, I have a class named myClass: each object in my class has
an id, a parentId, and a name.
I want to make a list of all my objects that looks like this:
object1
object2
object3
object4
ob
Sorry but I was working with an old documentation!
I fixed it with th e filter 'safe'
thank you for the quick answer
On 6 nov, 17:48, "Ramiro Morales" <[EMAIL PROTECTED]> wrote:
> On Thu, Nov 6, 2008 at 2:16 PM, gontran <[EMAIL PROTECTED]> wrote:
>
&g
hello,
I just started to learn django, so my question may be stupid:
In my template, I would like to display a html string (stored in my
database). My problem is that it displays the string but it
automatically escapes the html tags.
for example, if my string is: my text
instade of showing: my
47 matches
Mail list logo