Bad rendering of forms with tabular inlines

2009-01-13 Thread mathieu
"fields" setting of the inline admin class. Please help! -Mathieu --~--~-~--~~~---~--~~ 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@googlegro

Is there a way to store Django tables in another schema

2008-08-28 Thread mathieu
Hi, I'm trying to use Django with an existing Oracle database, but I'd rather not clutter the existing DB with Django tables, so I was wondering if I can force them to some other schema that the main schema I'm using. Thanks -Mathieu --~--~-~--~~~-

Re: Is there a way to store Django tables in another schema

2008-08-28 Thread mathieu
Thanks. --~--~-~--~~~---~--~~ 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 mor

In unitTest, GET Formset returns 302 instead of 200

2011-09-07 Thread MATHIEU
Hi, I want to test the GET method for an inline formset. The view in which the inline formset is created is as follows: @login_required def patron_edit_phone(request, *args, **kwargs): patron = request.user PhoneNumberFormSet = inlineformset_

Filtering parents by child attributes

2009-01-02 Thread Mathieu Steele
Here is an example of the data model for the type of filter I would like to do: class Student name class Absence foreign key Student date Is there a way to filter Students with no absences? something like Student.objects.filter(absence_set__count=0) --~--~-~--~--

Base Class and Multiple SubClasses

2009-01-06 Thread Mathieu Steele
I'm trying to find the right way to make an instance of a subclass of a model also an instance of a different subclass in the model, like so: class Person(models.Model): ... class Customer(Person): ... class Employee(Person): ... If I have an instance of Employee that I want to hav

Send emails using sendmail or postfix

2008-09-01 Thread Mathieu Leplatre
Hi all, According to the documentation, email sending is done through smtp. Is there a way to use sendmail or postfix instead ? Thank you. Mathieu. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django

Re: Send emails using sendmail or postfix

2008-09-01 Thread Mathieu Leplatre
On Sep 1, 4:02 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Mon, 2008-09-01 at 11:39 -0700, Mathieu Leplatre wrote: > > Hi all, > > > According to the documentation, email sending is done through smtp. > > Is there a way to use sendmail or postfix instead ?

How to syncdb programatically (django standalone script) ?

2008-09-15 Thread Mathieu Leplatre
Hi all, I found many post about specific errors regarding django as a standalone tool. With a little bit of researching, I ended up with this script below. Unfortunately, it fails on database initialization. ... ... File "/home/mathieu/Code/uhm/svn/uhm/django/db/backends/sqlite3/ ba

Re: How to syncdb programatically (django standalone script) ?

2008-09-16 Thread Mathieu Leplatre
Thanks for the tip. Indeed it loooks to be the way, however I am having app_label errors... It complains Error: No module named p (for polls) If I put my script in a module or remove Meta : File "[...]/django/db/models/base.py", line 51, in __new__ kwargs = {"app_label": model_module.__name

Re: How to syncdb programatically (django standalone script) ?

2008-09-16 Thread Mathieu Leplatre
Should I post a new thread ? I cannot find anything about this way of using Django... On Sep 16, 9:12 am, Mathieu Leplatre <[EMAIL PROTECTED]> wrote: > Thanks for the tip. > > Indeed it loooks to be the way, however I am having app_label > errors... > It complains >

Re: How to syncdb programatically (django standalone script) ?

2008-09-17 Thread Mathieu Leplatre
bout that in the Django documentation web site. > I hope it was helpfull > > []s > Ronaldo. > > On Tue, Sep 16, 2008 at 7:53 PM, Mathieu Leplatre <[EMAIL PROTECTED]> wrote: > > > Should I post a new thread ? > > I cannot find anything about this way of

Error: No module named X (django standalone script)

2008-09-17 Thread Mathieu Leplatre
Hi all, I am starting a new thread, the first one became off-topic (http:// groups.google.com/group/django-users/browse_thread/thread/ 34b501d2d1f88496/f8a5d5ef5aeab62a) I want to do a simple external script that just relies on django's ORM. So I did a single file testdjango.py : -- import

Re: Error: No module named X (django standalone script)

2008-09-18 Thread Mathieu Leplatre
On Sep 17, 10:41 pm, Eric Abrahamsen <[EMAIL PROTECTED]> wrote: > On Sep 17, 2008, at 11:45 PM, Mathieu Leplatre wrote: > > > > > > > Hi all, > > > I am starting a new thread, the first one became off-topic (http:// > > groups.googl

How to model a OneToMany relation to an abstract class ?

2009-07-01 Thread Mathieu Leplatre
Hi all, I am trying to design the following model : - a checklist is a collection of checkpoints - a checkpoint can be an action, or a group of actions. - the same action can be in several groups I read the Generic relations documentation : http://www.djangoproject.com/documentation/models

Re: Making a ManyToManyField to its own model?

2009-07-01 Thread Mathieu Leplatre
On 1 juil, 10:45, littlejim84 wrote: > I'm new to Django, and I'm developing an project where I have an app > called 'people' and a model inside called 'person'. The project itself > is based around the idea of people connecting with each other... So, I > as a person can connect to 3 other person

Re: How to filter out posts from friends?

2009-07-01 Thread Mathieu Leplatre
On 1 juil, 14:44, coan wrote: > I have a friendship model for users and want to retrieve all the posts > my friends made. > > class Friendship(models.Model): >  from_friend = models.ForeignKey( User, related_name='friend_set' ) >  to_friend = models.ForeignKey( User, related_name='to_friend_set'

Internationalization and Apache

2009-05-28 Thread Damien MATHIEU
Hi, Using the internal web server, I correctly load every language string located in application_path/locale/language/LC_MESSAGES/django.mo But whenever I use Apache, they don't appear to be loaded anymore. However it appear the default ones are loaded. The languages names are appropriately tran

Re: Internationalization and Apache

2009-06-01 Thread Damien MATHIEU
1:51 am, Graham Dumpleton wrote: > On May 28, 11:56 pm, Damien MATHIEU <4...@dmathieu.com> wrote: > > > > > Hi, > > > Using the internal web server, I correctly load every language string > > located in application_path/locale/language/LC_MESSAGES/django.mo

Re: Internationalization and Apache

2009-06-01 Thread Damien MATHIEU
Thank you Karen for being more precise and writing something understandable. On Jun 1, 5:15 pm, Karen Tracey wrote: > On Mon, Jun 1, 2009 at 8:39 AM, Damien MATHIEU <4...@dmathieu.com> wrote: > > > Based on the advices of a friend, I've tried with mod_wsgi instead of >

Re: Internationalization and Apache

2009-06-02 Thread Damien MATHIEU
DJANGO_SETTINGS_MODULE = pyki.settings USER = dmathieu PATH = /usr/local/bin:/usr/bin:/bin:/usr/games MAIL = /var/mail/dmathieu LOGNAME = dmathieu SSH_CONNECTION = 193.251.16.192 2616 213.251.184.40 22 HOME = /home/ _ = /usr/bin/python On Jun 1, 10:58 pm, Damien MATHIEU <4...@dmathieu.com>

Possible bug with django 1.2, postgresql and aggregates?

2010-02-08 Thread Mathieu Pillard
Hi, I have been testing the 1.2 beta1 and think I found a bug, but since the query I'm using is a bit complicated I wanted to run it through the list first. The model I'm using: from django.db import models from django.contrib.auth.models import User class Foo(models.Model): subject = model

Re: Possible bug with django 1.2, postgresql and aggregates?

2010-02-08 Thread Mathieu Pillard
> It may indeed be that the MAX clause is using "mat_foo" instead of the > assigned correlation U0. What happens if you paste the two SQLs into a > query window in PgAdmin 3 and execute them. If the 1.2 query fails > with the same error message, I'd report a bug. > > If it doesn't fail, it's still

Re: Possible bug with django 1.2, postgresql and aggregates?

2010-02-09 Thread Mathieu Pillard
I searched for an existing ticket, couldn't find any. I created http://code.djangoproject.com/ticket/12822 -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from th

Error 500 in admin panel

2008-04-15 Thread Mathieu Goeminne
Hi all, I'm a newbie in Django, and I'have to populate some data using the admin panel. While I'm saving a entity, or sometime while I want to see it, Django raises a 500 error. The default admin entities don't rise any error, only my entity do it. I have changed my user permissions (getting al

Use .html at the end of the url instead of / ?

2007-10-17 Thread Mathieu Poussin
Hello , i have a question, by default , django add a slash at the end of the url , like that : http://my/documents/hello -> http://my/documents/hello/ it's possible to add .html instead of that ? like that : http://my/documents/hello -> http://my/documents/hello.html if yes, how ? thanks , Sorr

Number of objects per page in the admin

2006-04-21 Thread Mathieu Blondel
Hi all, Maybe I'm missing something but I can't find how to specify the number of objects (lines) per page in the admin. The default is 100 which is too much for me. Thanks, Mathieu. --~--~-~--~~~---~--~~ You received this message because you are sub

Django queryset custom manager - refresh caching

2010-12-20 Thread Mathieu Dhondt
ea as to how I could solve my problem? Many thanks in advance, Mathieu -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email t

Re: Django Admin - list_display doesn't follow FK links?

2011-01-29 Thread Mathieu Möller
nkey(othermodel) def get_importantfield(self): return self.FK_othermodel.importantfield In your admin.py call MymodelAdmin(admin.ModelAdmin) list_display=['get_importantfield'] Hope it helps! Mathieu -- You received this message because you are subscribed to the Google Groups "Dj

Re: django user (using django ORM) + SQLAlchemy for other db tables

2015-02-05 Thread Mathieu Rodic
I have been working on a Django project, where complex queries were required... so the Django ORM was out of question. As I didn't want to have both Django and SQLAlchemy models hanging around, I chose to use aldjemy . You can use this simple tutorial

Generate different querysets depending of the website language

2016-03-26 Thread Mathieu Poussin
.META['HTTP_ACCEPT_LANGUAGE'] Any idea of how to make this work ? What is the good way to do this ? Thank you. Mathieu -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving ema

Re: Generate different querysets depending of the website language

2016-03-27 Thread Mathieu Poussin
it always selecting the default language just for the queryset when everything else is translated correctly ? Thanks. Mathieu On Sunday, 27 March 2016 04:49:20 UTC+2, Daniel Chimeno wrote: > > Hello, > > If you are able to change the schema I would suggest you to use > modeltransl

Re: Generate different querysets depending of the website language

2016-03-30 Thread Mathieu Poussin
leMiddleware after your > ForceDefaultLanguage, > so > https://github.com/django/django/blob/master/django/middleware/locale.py#L26 > is setting the default language. > > Hope it helps. > > El sábado, 26 de marzo de 2016, 20:43:09 (UTC+1), Mathieu Poussin escribió: >> >

Re: Use an external REST API in django admin

2018-07-16 Thread mathieu mickael
ok thank you very much 2018-07-17 4:15 GMT+02:00 mottaz hejaze : > even REST API needs a database managments system like postgre or mysql > > so the lowest layer is postgre or mysql or mongodb > > the upper layer on top of any one of them , your backend REST API > > read about DMS and REST API >

Changing a model of place from the admin site

2010-08-16 Thread Mathieu Leduc-Hamel
Hi all, I'm currently developing a e-commerce website using satchmo and django. I would like to simplify the admin pannel from the user perspective. This is why i would like to change the different group of models. Right now, these group are organized by application. But when using some external d

Re: Best OS - VPS environment

2010-08-16 Thread Mathieu Leduc-Hamel
Yeah but it's a little bit simpler with apache and mod_wsgi... If i don't want to run a separate service like gunicorn or something like, how can we do the same thing than apache+mod_wsgi but with nginx. We've tried passenger but it's not very stable and not necessarily always product's ready. O

Re: Changing a model of place from the admin site

2010-08-17 Thread Mathieu Leduc-Hamel
p=='cms': >p='general-content' >elif p=='auth': >p='users' >return HttpResponseRedirect('/admin/#'+p) > > (this basically redirects /admin/auth/ and /admin/cms/ to a named > anchor on the in

Re: How to execute some user defined codes (functions) when Django boot?

2010-08-17 Thread Mathieu Leduc-Hamel
y points system of python and do, like in Pylons, an entry defined by Paster "app_factory" You can see an example there: http://packages.python.org/twod.wsgi/manual/paste-factory.html#using-custom-factories mathieu On Tue, Aug 17, 2010 at 2:45 PM, Emily Rodgers wrote: > On Aug 17,

Proxy models and Meta options

2010-08-17 Thread Mathieu Leduc-Hamel
lause in the Meta class cause the fields are not directly the property of my proxy model !!! How it's possible ? What should I do ? Mathieu Leduc-Hamel -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send e

Re: Chopping Queryset

2010-08-17 Thread Mathieu Leduc-Hamel
If you want the job offer of the current logged user it should be pretty simple using a filter like that: jobsfound.filter(userdetail__user=request.user) But if i was you i would invert the order of these two filter like that: jobsfound = joblist.objects.filter(userdetail__user=request.user) job

Re: How to execute some user defined codes (functions) when Django boot?

2010-08-17 Thread Mathieu Leduc-Hamel
any particular thread or process is going to > live, > and no idea how often this "boot" code would get run. > > But assuming that's OK, one naive strategy would be to just call the > function(s) at top level in some module that gets imported by your > app. > Good e

Re: How to execute some user defined codes (functions) when Django boot?

2010-08-18 Thread Mathieu Leduc-Hamel
Richard, it's not the good way to do this, in the settings.py cause as i said before, the code in the settings.py is executed every time somebody initiate a session for the first time. The point there is a way to have a part of code common to all currently connected user. Tang, I'm not an expert

Re: How to execute some user defined codes (functions) when Django boot?

2010-08-18 Thread Mathieu Leduc-Hamel
7;t really understand what you are trying to do, but it > > sounds like Mathieu does and has offered you some pretty useful > > advice. > > > > If his link below helps you fix what you are trying to do, please let > > us know what you did (this is really useful for othe

Re: django and php

2010-08-19 Thread Mathieu Leduc-Hamel
eload something every minutes and the second would just fetch the data from the database. Look in the documentation to know how to develop correct ajax views... ciao mathieu On Thu, Aug 19, 2010 at 11:01 AM, Imad Elharoussi wrote: > > You said that we must not think in a PHP way while u

Re: connect to database from template

2010-08-19 Thread Mathieu Leduc-Hamel
You have to forget the php when you code something in Python and Django. The process doesn't fallow the same way it does in PHP. It's complete new world (and a more beautiful and peaceful one i think). Your connection will be keep alive, don't worry about that. What do you mean by connection ? T

Re: adding a summary field to a model

2010-08-19 Thread Mathieu Leduc-Hamel
But by the way you field seem to be a sum of some others, maybe it should not be a new field but just a new method returing the resulting calculation depending of the attributes of your instance. No ? On Thu, Aug 19, 2010 at 4:56 PM, bruno desthuilliers < bruno.desthuilli...@gmail.com> wrote: > O

Re: virtualenv and standalone scripts

2010-08-24 Thread Mathieu Leduc-Hamel
And what about using "console_scripts" entry in your setup.py script ? http://www.google.com/search?q=console_scripts On Mon, Aug 23, 2010 at 11:11 PM, Oivvio Polite wrote: > On Mon, Aug 23, 2010 at 10:54:21PM +0200, Oivvio Polite wrote: > > > >

Re: how to turn off CSRF in django 1.2?

2010-08-26 Thread Mathieu Leduc-Hamel
ssage because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-us...@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com. > For more options, visit this group

Re: PIL on 10.6 = PAIN

2010-08-31 Thread Mathieu Leduc-Hamel
oup. >> To post to this group, send email to django-us...@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. >> >&

Re: PIL on 10.6 = PAIN

2010-09-01 Thread Mathieu Leduc-Hamel
fortunately Django/Pinax doesn't seem to see this after reactivating > the ENV and restarting the server: > > BLurghh!!! > > Is it worth trying to remake the virtualenv I am working with? Would > that help or is the problem still up the stream? > > -Ben > > On Aug

Re: GoFlow - anybody out there used it?

2010-09-06 Thread Mathieu Leduc-Hamel
At the time I had to implement a > workflow solution, processmaker and its API did the job for us. > > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-us...@googlegrou

Re: Vim for Python and Django

2010-09-26 Thread Mathieu Leduc-Hamel
l to django-us...@googlegroups.com. >> > To unsubscribe from this group, send email to >> > django-users+unsubscr...@googlegroups.com. >> > For more options, visit this group >> > athttp://groups.google.com/group/django-users?hl=en. > > -- > You received t

Confoo 2011 Call for Speakers

2010-10-06 Thread Mathieu Leduc-Hamel
e the word! -- Mathieu Leduc-Hamel -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.c

Unicode, utf8, mysql

2010-10-11 Thread Mathieu Leduc-Hamel
ally and just wait for the next bug for the next incompatible character with MySQL ! -- Mathieu Leduc-Hamel -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsub

Django cache view

2010-11-12 Thread Mathieu Leduc-Hamel
y configure the middleware and make sure memcached is working properly. What's not working ? -- Mathieu Leduc-Hamel -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegr

Re: Django vs Postgres Connection

2010-12-17 Thread Mathieu Leduc-Hamel
use you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-us...@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com. > For more options, visit this group at >