) inside login():
> def login(request ,template_name):
>
...
> login(request, v)
>
I guess you mean user.login()
HTH,
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Ma
in the permission table
is not done yet.
Any suggestions?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django
delta(minutes=fudge_minutes) to compute the
start and end times of your target time.
http://docs.djangoproject.com/en/dev/ref/models/querysets/#range
On unix you would set up a cron-job which gets called very N minutes.
Does this help you?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
Hi,
> MEDIA_URL = 'D:/workspace/isiscore/media/
That's not a URL. A URL looks like 'http://myserver/' or '/media/'
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You recei
.org/snippets/1026/
Of course it only works for views that you created. It does not change
the breadcrumbs of the admin page.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this m
first.
If you have read and understood the python tutorial, you can ask
yourself (or google)
if you want to try postgres instead of mysql. If this is solved, install
your
favorite database and open your web browser:
http://docs.djangoproject.com/en/dev/
HTH,
Thomas
--
Thomas Guettler, ht
ypeError: expected read buffer, dict found
>
> My conclusion is that my client.py imports StringIO from cStringIO,
> which doesn't accept a dict as content in its __init__ method. But I
> can't be the only person using django to have cStringIO installed,
> right? So someone would have
meppum schrieb:
> Is there an equivalent?
>
>
>
This page explains form and field validation:
http://docs.djangoproject.com/en/dev/ref/forms/validation/
HTH,
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-g
buffer.close()
> response.write(pdf)
> -
> attach = pdf
> mail = EmailMessage(subject, message, sender,[send_to])
> mail.attach(attach.name, attach.read(), attach.content_type)
> mail.send()
>
> this will give me error saying ob
diff orig.sql new.sql
Now you need to now a little SQL to write the correct "ALTER TABLE ..."
statements.
But must of the time it is not that difficult.
HTH,
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli
> except Exception, e:
> raise ValueError, e
> request.user.message_set.create(message="Mail sent successfully.")
> return HttpResponseRedirect('../')
>
> The problem here is if I say attach = response then I am getting error
> 'HttpResponse'
d adds the http://servername/) should be callable within
http context, too.
I can live with the current algorithm. But maybe the documentation
of reverse() could be enhanced.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettle
it. But
it only returns '/myview/'.
Is this a bug in the docs, code or in my brain?
docs for reverse():
http://docs.djangoproject.com/en/dev/topics/http/urls/#reverse
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
T parameter:
http://.../myview?mail_id=1_id=2
In myview:
request.GET.getlist('mail_id') --> ['1', '2', ...]
HTH,
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received thi
ld be too much magic to change django, that range
searches with dates values on datetime columns get automatically expanded.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this
After adding widgets.css it works.
Is this a bug or an undocumented feature?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed
from myclass import MyClass
file myclass.py:
class MyClass(models.Model):
class Meta:
app_label='myapp'
HTH,
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received
t from db cursor? I found
> http://docs.djangoproject.com/en/dev/faq/models/#how-can-i-see-the-raw-sql-queries-django-is-running
> by this doesn't show anything. When they say "just do this", are they
> implying we should run that from a manage.py shell?
>
>
--
.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group,
mark schrieb:
> Hi All,
>
> i'am writing API for a service and i want to use basic http
> authentication for my service users.
>
>
I use this: http://code.djangoproject.com/ticket/689
HTH,
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) th
g
to the subject. I just hit reply without removing it.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"
;
> Now you can edit your views_base.py and see the changes in action,
> without restarting Web Server (except of args of defs(request, args).
>
> >
>
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~-
this view and a small middleware to render "403 forbidden" pages.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Goo
HI,
Maybe your apache starts a new child for every request?
...
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
; does not necessarily mean what it says. The error message is
> also displayed if there is an error in the the method.
>
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You recei
y view files for
> *every* request, which makes the application unusably slow.
>
Please post your wsgi configuration. Do you have something like
maximum-requests=1?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) th
, **kwargs):
return lazy_string(urlresolvers.reverse, *args, **kwargs)
}}}
from lazy import reverse
instead of
from django.core.urlresovlers import reverse
HTH,
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
Hi,
django-tagging looks nice, but I need to have hierarchical tags:
animal / bird / eagle
Any idea: Hack/Update django-tagging, create own, use django-???
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
is the commit_on_success decorator sends COMMIT.
I guess I need to convert all commit_on_success decorators to
a new commit_on_success_unless_inside_transaction decorator.
Any idea how to solve this?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler
progress can be viewed:
> http://timikidemo.io41.com/
>
> Tim ^,^
>
>
>
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
rom being mature or production ready, but is usable and
> I'm actively working on it. (I only started development about 2 or 3
> weeks ago.)
>
> See http://launchpad.net/timiki for getting the code. It's only in a
> bzr repository for now as it's not release worthy yet.
>
>
I will
control is no issue for me. All users can edit everything.
- liberal licence (at best BSD-like)
- of course: Django based.
is there already something like this?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
schrieb:
> On Wed, 2008-06-25 at 09:27 +0200, Thomas Guettler wrote:
>
>> Hi,
>>
>> depending on the values from form.cleaned_data, I want to present different
>> input fields to the user. Example:
>> The user chooses a country, and after submit (no aj
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send em
the uncleaned
request.POST or form.data.
I guess I need to create two forms ..
Any hints?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed
mically fill a ChoiceField by filtering on a value known
> to the URLView? Every "dynamic fill" example I've found assumes the
> form knows it all - I haven't seen anything which shows me how to pass
> that value from the view to the form.
>
>
--
Thomas Guettler,
e.
According to
http://www.djangoproject.com/documentation/db-api/
you need select_params
select={
'rank': "rank_cd(textsearchable, to_tsquery(%s), 32)",
},
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~-
Malcolm Tredinnick schrieb:
> On Fri, 2008-04-25 at 09:37 +0200, Thomas Guettler wrote:
> [...]
>
>
>> I wrote
>> a ticket some time ago. If you care, please leave
>> a comment:
>>
>> http://code.djangoproject.com/ticket/6675
>>
at cleaned_data is sometime available
and sometimes not.
The developer should get a
better error message then 'AttributeError'. I wrote
a ticket some time ago. If you care, please leave
a comment:
http://code.djangoproject.com/ticket/6675
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
Malcolm Tredinnick schrieb:
> On Wed, 2008-04-23 at 15:37 +0200, Thomas Guettler wrote:
>
>> Hi,
>>
>> has some one a script to show the difference between the
>> running database and one which get created by syncdb?
>>
>>
>>
> Thi
ilable for postgres, you
would need something like for other DBs, too.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
&
Hi,
if one unittest fails at the database level, often all following tests
fail with this error:
execute SQL failed: current transaction is aborted, commands ignored
until end of transaction block
Is there a way to stop after the first failing test?
Thomas
--
Thomas Guettler, http
n/
> but shown as
> http://localhost:8000/top-category%3Amaterialien/
> in the browsers address.
>
> any hint? Thanks
>
> >
>
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~
args, **kwargs):
super(TestForm, self).__init__(*args, **kwargs)
self.fields['string'].widget.attrs['size']=64
}}}
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received
news sites, forums ...
>
I guess YouTube is highly concurrent, distributed ...
I think you can create enterprise applications with django and python.
What do you think is possible with Java, that you can't do with python?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mai
two site.
several projects which use one app: Several databases. Completely separated.
my solution: One DB, several tables.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received th
to do this better?
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to
ed a way to convert them to unicode.
HTH,
Thomas Güttler
[1]:
http://www.postgresql.org/docs/current/interactive/datatype-textsearch.html
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You recei
se.
I found this. The solution is post_syncdb signal:
http://www.b-list.org/weblog/2007/nov/21/install-time/
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message
Hi,
what is the best way for application specific settings?
Up to now I do it like this:
{{{
# settings.py
import APPNAME
}}}
APPNAME is a small python file where I store the values. Most of the
time there are only some lines like this: var=value.
Thomas
--
Thomas Guettler, http
Hi,
how can I insert initial data from a script? Static SQL files don't work
for my case.
Background: I need to load some SQL (tsearch2 (postgresql)) if the
database version
is smaller than 8.3 ...
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas
t some which are
under /public/...
Be sure, that you don't do infinite redirects:
if not re.match(r'^/(login|logout|public/.*$', request.path) ... :
...
return django.http.HttpResponseRedirect(login_url)
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: gu
t; Is their a way to get the 'initial' value of the email formfield and
> only perform a check if it has changed?
>
>
I wrote a snippet which checks if a form has changed. Maybe it helps you:
http://www.djangosnippets.org/snippets/621/
Thomas
--
Thomas Guettler, http://www.th
nal server error' in his browser.
But I don't think you need introspection. Since you know the object at
coding time, you don't need to check what kind of objects you are dealing
with.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli
Horst Gutmann schrieb:
> When you do the actual Paginator.page call the Paginator does nothing
> more than you'd have with
> Object.objects.[...].all()[lowerlimit:upperlimit].
>
>
And it does Object.objects.all().count()
Which results in "SELECT COUNT(*) ..."
Th
: http://bugs.python.org/issue170
I post this here, in hope it safes time for other developers.
Unfortunately there is no good fix (except patching python) found yet.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
>
>> And required=False for the ChoiceField (which is the default).
>>
>
> Are you sure? the newforms documentation [1] seems to indicate that
> required=True is the default for all Fields.
>
Sorry, this was a typo. required=True is the default.
--
Thomas Gu
or the ChoiceField (which is the default).
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users&q
snippets.org/snippets/344/
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to t
- drop the old DB or tables, and call syncdb. (Data gets lost)
- Modify the database with "ALTER TABLE"
For the second solution, you can call "./manage.py sqlall old.sql"
before and "./manage.py sqlall new.sql" after the update.
Then compare both files with 'diff
l | ./manage.py dbshell
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this grou
Chirolo schrieb:
> Hi again.
> I tried what Thomas suggested, but I still get the following error:
> NameError: name 'pwdtuple' is not defined
>
>
I am sorry, one line was missing:
import os
import pwd
pwdtuple=pwd.getpwuid(os.getuid())
USER=pwdtuple[0]
HOME=pwdtuple[5]
--
> __init__.py", line 33, in cursor
> cursor = self._cursor(settings)
> File "/usr/lib/python2.5/site-packages/django/db/backends/
> postgresql_psycopg2/base.py", line 69, in _cursor
> self.connection = Database.connect(conn_string, **self.options)
> Operation
re in a
special directory.
path../OBJECT_ID/...
The drawback is, that I can't use the admin interface for uploading images.
But the benefit is, that I can add attachments by copying a file into
this directory.
HTH,
Thomas
--
Thomas Guettler, http://ww
admin interface.
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post
h onclick="... location.href='...'"
HTH,
Thomas
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group
--
Thomas Guettler, http://www.thomas-guettler.de/
E-Mail: guettli (*) thomas-guettler + de
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to dj
Hi,
You get this because the transaction is 'dirty' (some statement was
executed,
but there was no commit/rollback afterwards). I guess this happens
in render_to_response in your example.
> K'
> finally:
> if result['status'] == 'OK':
> otherfile.test()
>
On unix (at least linux) you can run a script with an empty environment
like this:
env -i path/to/script
This way you can test on the shell what goes wrong.
I do all the set up in .bashrc an and run the cron job like this:
0 * * * . $HOME/.bashrc; $HOME/.../script
HTH,
Thomas
[EMAIL
Am Freitag, 1. Februar 2008 06:53 schrieb Eric Abrahamsen:
> This is kind of an extension of an earlier (mostly unresolved) issue I
> had brought up here:
> http://groups.google.com/group/django-users/browse_thread/thread/63beb7566d
>c352a8/1e6e137f5b5a434a
>
> Here's my current url conf (I've
Am Freitag, 1. Februar 2008 07:57 schrieb django_user:
> Hi,
> I am using the following in my Image model:
> file = models.ImageField(upload_to='/%y/%m/%d')
>
> I want every image to be uploaded in the users directory like '//
> %y/%m/%d' instead of all files in default location.
>
> Is it
> Could you explain how this works, please?
>
> It looks - to my uneducated eyes - if this leaves open a potential race
> condition where the mtime field could yet be changed in the database by
> another process within the "decision time" of this method. Do I
> misunderstand? It seems to me that
Am Mittwoch, 30. Januar 2008 16:18 schrieb Michael Hipp:
> Does Django have any built-in way to handle or prevent simultaneous,
> incompatible edits to a database record?
Some days ago there was a thread about optimistic locking:
I wrote an second answer some minutes ago.
Am Montag, 28. Januar 2008 10:16 schrieb Alistair Lattimore:
> Thomas,
>
> Do you use a custom manager to select out the row before issuing the
> save to make sure that the in memory timestamp matches that of the
> database?
>
No, since I don't use caching the mtime should be 'fresh'. Since
I
> def markable(checkins, project_category):
> projects = project_category.projects.all()
> res = []
> for day in checkins.group_dates():
> for ci in day: # for every checkin that day
> if ci.project in projects: # <-- HERE
> res.append(day.date)
>
Hi,
A profile is like a one to one relation. Since the future of
OneToOneField is unknown I heard you should use ForeignKey() with
unique=True.
You can modify djangos User model (e.g. in your model file), and
give it a property to make the access easier. In this
get_myprofile() method, you can
Am Sonntag, 27. Januar 2008 19:39 schrieb MariusB:
> I'm trying to take a link as an argument, open it, read it's content
> and then display the first 50 characters from it.
> First of all, I've tried to put the code in the views.py, but I didn't
> make it. Now I made a middleware component with
Hi,
There are two ways of counting:
# Bad way:
len(MyModel.objects.filter(...))
This will fetch all rows (SELECT * FROM ... WHERE ...;)
# Good way:
MyModel.objects.filter(...).count()
This will do the couting at the database
SELECT COUNT(*) FROM ... WHERE ...;
If you know how to get
Am Donnerstag, 24. Januar 2008 13:08 schrieb Tim Sawyer:
> Hi Folks,
>
> I'm just evaluating django for use on a project. I have a multiuser
> application where many users can be changing data at once.
>
> What's the status of hibernate style optimistic locking, where each object
> has a version
Am Donnerstag, 24. Januar 2008 05:02 schrieb xunSir:
> class Person(models.Model):
> PIN = models.CharField(maxlength=20, primary_key=True)
> Name = models.CharField(maxlength=20)
>
> class Burse(models.Model):
> PIN = models.ForeignKey(Person)
> Cash = models.IntegerField()
>
Am Dienstag, 22. Januar 2008 22:09 schrieb Francis:
> Hi,
>
> I'm using the attach_alternative command to send html emails.
>
> But when I use this command, I always get a "Content-Type: text/html;
> charset=utf-8" heading in all my emails.
>
> Is it possible to get rid of it?
Why do you want to
Am Dienstag, 22. Januar 2008 07:31 schrieb Chris:
> Hello I just opened a new project on google code and I was wondering
> if there was anyone that would be willing to help me work on this
> project in their free time. Check it out. http://code.google.com/p/megal/
> Please give me feed back too.
> 2. file uploads are the most vital part of freesound. While I have used
> tramline successfully with splice, it still feels like a relatively ugly
> solution to me (especially as you need to patch mod_python in order for
> it to work). As far as I know streaming file uploads have been on the
>
Hi,
I developed this method to create breadcrumbs.
What do you think about it?
Thomas
# Python
from urlparse import urljoin
# Django
from django import http
from django.core import urlresolvers
from django.core.urlresolvers import reverse
from django.conf import settings
from
Hi,
Can you access http://127.0.0.1:8000/css/idap.css ?
Maybe you have a tag in you html?
Am Mittwoch, 9. Januar 2008 13:49 schrieb [EMAIL PROTECTED]:
> Hello Django Users,
>
> I looked at the documentation about the static file serving but don't
> seem to get it to work.
>
> the url pattern
Am Dienstag, 8. Januar 2008 14:10 schrieb Alex Koshelev:
> Simpliest way is to patch model class at applications loading time:
>
> #somewhere in your own models.py file of some app
> from django.contrib.auth.models import User
>
> def user_unicode(self):
> return '%s: %s %s' % (self.username,
Hi,
our customer wants to display the username as 'username: firstname lastname'
The easiest way would be to overwrite User.__unicode__. But where
should you put code like this? Up to now I put it in our middleware.
Any comments, or better solutions?
# middleware.py
import new
from
Am Mittwoch, 2. Januar 2008 11:09 schrieb James Bennett:
> On Jan 2, 2008 3:49 AM, Thomas Guettler <[EMAIL PROTECTED]> wrote:
> > The HTTP return codes 404 and 500 can be raised with an exception.
> >
> > That's very handy. Unfortunately a Http Redirect can't be raised
Hi,
The HTTP return codes 404 and 500 can be raised with an exception.
That's very handy. Unfortunately a Http Redirect can't be raised.
Do other django users thing this would be usefull, too?
I implemented it myself. But I think something like this should be in django.
#responseutils.py
Hi,
I read this:
http://code.djangoproject.com/wiki/Signals
But I couldn't find a solution to execute code,
if the SCGI/FastCGI/WSGI server is up, ready to handle
the first request.
Or is there an other way (without signals)?
Thomas
--~--~-~--~~~---~--~~
You
Responding to myself:
I choosed solution 2 (parse HTML form) with the help of ClientForm:
http://www.djangosnippets.org/snippets/467/
Comments welcome
Am Freitag, 16. November 2007 13:03 schrieb Thomas Guettler:
> Hi,
>
> my has a lot of input widgets which are build fro
Hi,
my has a lot of input widgets which are build from several newform.form
instances.
If I want to test the form with client.post(), I need to pass all values of
the input fields in a dictionary, even if I just want to modify one value.
It would be nice if I could get all initial values in
Hi,
I have model Object and I want to store 0..N files
for each. To keep the files together the files should
be saved under a directory like this: .../objects/ID/
FileField does not support this. Now I found a simple
solution, that I want to share.
The solution is simple: I don't need
Am Dienstag, 13. November 2007 12:00 schrieb [EMAIL PROTECTED]:
> But then this N:M field would only be used some times... it doesn't
> seam as a good way to do this.
>
> I could always create a big app with all the models but I would like
> to be able have apps for each main class so my views.py
Am Dienstag, 13. November 2007 09:08 schrieb Thomas Guettler:
> Am Dienstag, 13. November 2007 03:35 schrieb [EMAIL PROTECTED]:
> > Hello,
> >
> > i'm new to django so excuse if this is a really stupid question.
> >
> > I have these three apps with are
Am Dienstag, 13. November 2007 03:35 schrieb [EMAIL PROTECTED]:
> Hello,
>
> i'm new to django so excuse if this is a really stupid question.
>
> I have these three apps with are inter dependable, how can I make this
> work in Django maintaining all of this modules separate.
Do you really need
Am Mittwoch, 7. November 2007 15:41 schrieb Florian Lindner:
> Hello,
> I'm using Django trunk.
>
> After some weeks of paused development I started my app again today. But as
> soon as I access the URL defined at the root urls.py:
>
> (r"^blog/", include("xgm.Blog.urls")),
>
> I get an error:
>
Am Mittwoch, 7. November 2007 12:25 schrieb Florian Lindner:
> Hello,
> I'm just about to start a project with Django (which will also be for
> learning Django).
>
> Should I use trunk for development? Or is there any branch better for
> development? (with regard to the introduction of newforms)
Am Mittwoch, 7. November 2007 12:02 schrieb parabol:
> Hi,
> I have a form class which is generated with form_for_model. How can I
> write my custom validator? I think I should set a clean() method for
> that class. Is it reasonable to say that;
>
> fom1.clean= def clean
You could set the
Am Dienstag, 6. November 2007 07:00 schrieb Matti Haavikko:
> Here's an alternative solution - it's based on the idea that the
> handlers are added to the logger only once. (getLogger returns the same
> logger instance each time).
>
> import logging
> logger=logging.getLogger("dws")
> if not
201 - 300 of 348 matches
Mail list logo