Hi,
I have a project that's working fine (apache2/mod_python)
I wrote a new app to add to it, which works fine with dev server.
In my root urls.py I added the urls.py from the new app with an
include ( (r'^inventory/', include('stuff.retail.urls') ),
('retail' being the new app) I also added stuf
2009/9/2 Mike Dewhirst :
>
> Joakim Hove wrote:
>> Hello,
>>
>> I have a (simplified) model like this
>>
>> class Customer(models.Model):
>> name = models.CharField(max_length = 100)
>> date = models.DateTimeField()
>> email = models.EmailField()
>>
>>
>> When showing thi
Joakim Hove wrote:
> Hello,
>
> I have a (simplified) model like this
>
> class Customer(models.Model):
> name = models.CharField(max_length = 100)
> date= models.DateTimeField()
> email = models.EmailField()
>
>
> When showing this in the (100 % default) admin view
Knight,
I do not think this is the recommended use case, and would take some hacking.
If you would like to update/edit/delete records from the DB i think
its best to create standard forms which let you do all of that.
http://docs.djangoproject.com/en/dev/topics/forms/
/i
On Tue, Sep 1, 2009 a
Hello,
I have a (simplified) model like this
class Customer(models.Model):
name = models.CharfField(max_length = 100)
date= models.DateTimeField()
email = models.EmailField()
When showing this in the (100 % default) admin view I get up nice
entry boxes for the fields
On my django run website, I've this sidebar which calls 5 random
pictures from entries.. here's the code that does it :-
{% for entry in thumb_entries %}
{% endfor %}
My website, say www.example.com, has a section www.e
On Tuesday 01 September 2009 12:29:56 pm Amir Habibi wrote:
> How can I serialize a Queryset along with the related records. For
> example, in Poll and Choice case, I need each poll to have the choices
> encoded in json format.
>
> Thanks
>
you'll want to look at the docs on serialization [1], it
2009/9/2 Kenneth Gonsalves :
>
> On Tuesday 01 Sep 2009 10:55:18 pm mrsource wrote:
>> - It has many tools for safety, with a normal opensource CMS you have
>> many more issues with security holes because all the code is public.
>
> this is sheer FUD to say that 'many more issues with security hol
I have the same issue only with one view except mine takes exactly 5
minutes! :)
I just switched to using apache on localhost and now no issues.
On Tue, Sep 1, 2009 at 11:18 AM, Jumpfroggy wrote:
>
> I have a strange problem that's popped up just recently, and it's
> puzzling to me.
>
> I'm r
On Tuesday 01 September 2009 10:25:18 am mrsource wrote:
> Two points:
> - Django has good performance and scales well.
> - It has many tools for safety, with a normal opensource CMS you have
> many more issues with security holes because all the code is public.
>
Isn't django's code public, why w
Thanks
On Aug 31, 3:22 pm, Antoni Aloy wrote:
> 2009/8/31 Julián C. Pérez :
>
>
>
> > Anyone has experience with using web services in Django??
> > I mean, not necessarily with ZSI but others methods...
>
> Yes, we have many of the working. But this is no a Django issue is
> more a Python progra
On Tuesday 01 Sep 2009 10:55:18 pm mrsource wrote:
> - It has many tools for safety, with a normal opensource CMS you have
> many more issues with security holes because all the code is public.
this is sheer FUD to say that 'many more issues with security holes because
all the code is public.' O
Has anyone had web services successfully consumed from a .NET client
using python 2.6 /django 1.1/SOAPLIB 0.8.1? I'd love to know how you
did it.
I've patched my SOAPLIB install to fix the WSDL issue and the unicode
issue as detailed in my previous thread.
My issue currently is that the SOAP EN
On Tue, Sep 1, 2009 at 4:18 PM, Ozymandias wrote:
>
> Greetings,
>
> I admit to being very confused at the moment. I'm simply wanting to
> change the style sheets on the Admin Site. I'm mostly just wanting to
> change the color scheme. Nothing terribly complicated. I'm using
> Django 1.1 runn
I have some objects that have garbage UTF-8 in their titles
!俾爀最愀渀稀愀 ⠀吀爀愀渀猀瀀愀爀攀渀琀 䐀甀戀⤀ (for the amusement of our Chinese friends)
The admin for these objects has a TabularInline which would also repeat that
title, and I think this the clue to the problem.
When debug is off the TabularInline does
Greetings,
I admit to being very confused at the moment. I'm simply wanting to
change the style sheets on the Admin Site. I'm mostly just wanting to
change the color scheme. Nothing terribly complicated. I'm using
Django 1.1 running in the Development Server on a Linux Mint machine.
Here's wh
Hello Joost,
I came across http://code.google.com/p/django-tinymce/issues/detail?id=14
link in django-tinymce and
from that, it occurs that I do not have en dictionary installed. I
checked in python prompt and it returns false.
I need to install these dictionaries on web server. Can you please
di
If you ever wanted to create formsets without needing to know all of the
initial data at once, this might help you out.
http://www.djangosnippets.org/snippets/1711/
I used it in a data entry table where the forms of the formset were
intermingled with rows of already created data. I tried to do it
python manage.py runserver 0.0.0.0:8000
should bind the dev server to every IP on the machine
On Tue, Sep 1, 2009 at 3:27 PM, ringemup wrote:
>
> Never mind, I figured it out. Just need to start a separate instance
> for each IP.
>
> On Sep 1, 4:26 pm, ringemup wrote:
>> I've got some screwy D
On Sep 1, 3:17 pm, Joshua Russo wrote:
> On Tue, Sep 1, 2009 at 10:09 AM, buttman wrote:
>
> > On Sep 1, 4:52 am, Joshua Russo wrote:
>
> > > Why are you using commit=False?
>
> > If I don't, I get a database error saying "user_id column can't be
> > null".
>
> You might want to look at the cle
Hello Joost,
I had previously commented out t.editor.windowManager.alert(e.errstr
|| ('Error response: ' + x.responseText)); line in tiny_mce/plugins/
spellchecker/edotor_plugin.js as I was getting some error when I click
spellchecker with empty text area. Hence, the error messages were
misleadin
On Sep 1, 11:30 pm, Alex Robbins
wrote:
> Graham,
>
> I'm interested in understanding what you just said. It seems like you
> are saying you can get the X-Forwarded-SSL environment variable to
> automatically be set, without needing the django middleware. Seems
> simple enough.
X-Forwarded-SSL
Never mind, I figured it out. Just need to start a separate instance
for each IP.
On Sep 1, 4:26 pm, ringemup wrote:
> I've got some screwy DNS stuff going on on my local machine and need
> the development server to respond to requests on two IP addresses at
> once (127.0.0.1 and 192.168.1.7).
I've got some screwy DNS stuff going on on my local machine and need
the development server to respond to requests on two IP addresses at
once (127.0.0.1 and 192.168.1.7). Is there any way to wrangle that?
Thanks!
--~--~-~--~~~---~--~~
You received this message be
> I work as a web developer at a reasonably large company in London. We
> are just about to completely re brand and rebuild the companies website
> (s) and implement a CMS. I'm having a meeting tomorrow to discuss
> different avenues we can go down in regards to what technologies we
> can use. I
How can I serialize a Queryset along with the related records. For
example, in Poll and Choice case, I need each poll to have the choices
encoded in json format.
Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
Just to throw my two cents in. My background is high-traffic fantasy
sports websites (a different sort of geekness) and I've dealt with
connection pooling and connection persistence separately on other
ancient platforms. I will +1 Alex's observation that connection
pooling and persistent connectio
On Tue, Sep 1, 2009 at 10:09 AM, buttman wrote:
>
> On Sep 1, 4:52 am, Joshua Russo wrote:
> >
> > Why are you using commit=False?
>
> If I don't, I get a database error saying "user_id column can't be
> null".
You might want to look at the clean methods of the form to set the user.
These shou
Ooops, sorry - I used port 587, port 465 was only my last try before I
posted the message, so I copied the wrong part ...
It also does not work with 587. 587 works with send_mail (but not on
the Win server with Django 1.0.2) but not with the EmailMessage
object.
--~--~-~--~~-
On Tue, Sep 1, 2009 at 2:26 PM, Katja wrote:
>
> I have the following settings:
> EMAIL_HOST = "smtp.gmail.com"
> EMAIL_PORT = 465
> EMAIL_HOST_USER = MYLOGIN
> EMAIL_HOST_PASSWORD = MYPASSWORD
> EMAIL_USE_TLS = True
>
> And the mailing part:
> subject = "New data outputs are available"
> recip
Hi,
I want to turn off the login when going to the admin page url.
I want to enter to admin pages as anonymous/no user and require login
only in 2 specific urls.
How can I turn off the login request in the beginning?
Thanks, Arshavski Alexander.
--~--~-~--~~~---~--~--
I have the following settings:
EMAIL_HOST = "smtp.gmail.com"
EMAIL_PORT = 465
EMAIL_HOST_USER = MYLOGIN
EMAIL_HOST_PASSWORD = MYPASSWORD
EMAIL_USE_TLS = True
And the mailing part:
subject = "New data outputs are available"
recipients = ["m...@here.com"]
sender = "some...@else.com"
email =
I just ran into the same issue this past weekend, same stack as you.
The apache error log was full of memcache related errors (see below
for examples), so I tried to switch to version 0.91 based on
recommendations I saw. But the errors didn't stop until I switched to
python-memcache. Now, it is wo
yes problem is django version missmatch.
django 1.0 final and its not compatible with tagging 2.*
for it you must use tagging 0.3
On Jul 26, 1:23 pm, todd12 wrote:
> Hi T,
>
> I found this in the tagging issues from 2008 but it worked:
>
> if your like me then you get this message from within th
> The check for unique fields is done in the base ModelForm clean method. By
> overriding clean without calling the superclass clean you are causing the
> checks to be bypassed.
I read up on it while you were posting your reply :)
http://docs.djangoproject.com/en/dev/topics/forms/modelforms/#ov
I have a strange problem that's popped up just recently, and it's
puzzling to me.
I'm running the "manage.py runserver" dev server for development.
Normally, right after I save a file, the server reloads the new code
and is ready to go right away. However, recently one of my apps has a
strange p
Two points:
- Django has good performance and scales well.
- It has many tools for safety, with a normal opensource CMS you have
many more issues with security holes because all the code is public.
On 1 Set, 18:52, "Rob B (uk)" wrote:
> I work as a web developer at a reasonably large company in
On Tue, Sep 1, 2009 at 12:51 PM, aa56280 wrote:
>
> You're right, I did leave out something - the clean() method. Nothing
> unusual there. In fact, if I take out everything from the method and
> leave the shell:
>
> def clean(self):
> return self.cleaned_data
>
> It still craps out. However, if
Add the filesystem template loader, put it before app directories loader,
and put the (absolute) path to your templates directory (e.g.;
/home/moho/myapp/templates) in TEMPLATES_DIR.
Bill
On Tue, Sep 1, 2009 at 11:52 AM, Aljosa Mohorovic <
aljosa.mohoro...@gmail.com> wrote:
>
> admin app uses te
I work as a web developer at a reasonably large company in London. We
are just about to completely re brand and rebuild the companies website
(s) and implement a CMS. I'm having a meeting tomorrow to discuss
different avenues we can go down in regards to what technologies we
can use. I'm hoping
You're right, I did leave out something - the clean() method. Nothing
unusual there. In fact, if I take out everything from the method and
leave the shell:
def clean(self):
return self.cleaned_data
It still craps out. However, if I take away the entire method, then I
do get the validation erro
Ok so I will write a custom form.
I think that I will also write a custom field to do some specific
things (for example add a url method to get
png ...). I need to understand better the methods :
- contribute_to_class,
-validate, validate_full
-formfield
I found nothing in django's doc, and f
Hi,
I'm saving and loading snapshots of a database (controlled and
accessed via Django models) to and from source control. I've written
routines using django.core.management.call_command and the
serialization framework to dump and load the database contents
periodically. This is usually just befo
I want to run internationalization.
I get into /django/ and enter bin/make-messages.py -a (because already
done one time).
I don't have the permission and when I want to change the permission
for xrw, my Mac computer tells me I can't change it.
So I make "su" and enter a password, but my mac again
On Tue, Sep 1, 2009 at 12:52 PM, Aljosa
Mohorovic wrote:
>
> admin app uses templates/admin/base_site.html but when i move that
> file in myapp/templates/admin/base_site.html it is ignored.
> is there an additional step to ensure admin app uses templates from
> app templates folder?
AFAIK You can
On Tue, Sep 1, 2009 at 12:02 PM, Alessandro Ronchi <
alessandro.ron...@soasi.com> wrote:
> When I return a 500 error I need to have my context_processor, in which I
> store some important vars used in my template. Is it possible?
>
Your subject line says 404 errors but your text says 500. Which
When I return a 500 error I need to have my context_processor, in which I
store some important vars used in my template. Is it possible?
--
Alessandro Ronchi
SOASI
Sviluppo Software e Sistemi Open Source
http://www.soasi.com
--~--~-~--~~~---~--~~
You received thi
On Tue, Sep 1, 2009 at 10:54 AM, NMarcu wrote:
>
> Hello all,
>
> I'm very new in python, Django... I have a Django project. If I run
> it like: python manage.py runserver, everything is OK. When I run it
> in Apache2 I got this error:
> OperationalError at /login
>
> FATAL: Ident authenticati
admin app uses templates/admin/base_site.html but when i move that
file in myapp/templates/admin/base_site.html it is ignored.
is there an additional step to ensure admin app uses templates from
app templates folder?
i do have
'django.template.loaders.app_directories.load_template_source' in
TEMPL
Hey Folks - I did load testing on my amazon ec2
ubuntu+django+postgresql+memcached setup. I discovered that under
load, cmemcache seems to fail on get cache requests. It causes django
to make a bunch of set cache calls, even though the key exists in
memcached. switching to python-memcache fixed th
On Tue, Sep 1, 2009 at 11:19 AM, Joru wrote:
>
> Hi
>
> I got name error in my models when using models.ManyToManyField
> Here are my models
>
> class Ank(models.Model):
> route = models.ManyToManyField(Dek)
> intercity = models.BooleanField()
>
> class Dek(models.Model):
> ank = models.M
Hello all,
I'm very new in python, Django... I have a Django project. If I run
it like: python manage.py runserver, everything is OK. When I run it
in Apache2 I got this error:
OperationalError at /login
FATAL: Ident authentication failed for user "nmarcu"
How can be this possible? In Djang
Hi
I got name error in my models when using models.ManyToManyField
Here are my models
class Ank(models.Model):
route = models.ManyToManyField(Dek)
intercity = models.BooleanField()
class Dek(models.Model):
ank = models.ManyToManyField(Ank)
How come I got "NameError: name 'Dek' is n
2009/9/1 Daniel Roseman
>
> On Sep 1, 12:17 pm, ANIL KARADAĞ wrote:
> > 2009/9/1 Daniel Roseman
> >
> > > On Sep 1, 10:35 am, ANIL KARADAĞ wrote:
> > > > hello everbody,
> >
> > > > i have en error for a week. i did not resolve and i did not find it's
> > > > solution.
> >
> > > > Sometimes sy
thanks,I have solved it by using python2.5.
thank you again.
On 9月1日, 下午8时18分, mrsource wrote:
> I suppose that you have downloaded the latest version of psycopg2:
> psycopg2-2.0.12.win32-py2.6-pg8.4.0-release.exe.
> In that case use the previous release psycopg2-2.0.10.win32-py2.6-
> pg8.3.7-re
Thanks guys for all the feedback, I have done what Francis said, we are
using nginx and apache/mod_wsgi in the back. Nginx handles the ssl and it
works great.
Thanks for the help.
Vitaly Babiy
On Tue, Sep 1, 2009 at 9:30 AM, Alex Robbins
wrote:
>
> Graham,
>
> I'm interested in understanding wha
Hi friends, I haver another problem. I created a custom permission, but when
I write a condition, always return False. For example:
---models.py
class Book(models.Model):
title = models.CharField(verbose_name = "Title", max_length = 150)
author = mode
On Tue, Sep 1, 2009 at 1:20 AM, aa56280 wrote:
>
> ### Model ###
> class School(models.Model):
>url = models.SlugField(max_length=50, unique=True)
>name = models.CharField(max_length=255)
>...
>
>
> ### Form ###
> class SchoolForm(ModelForm):
>
>class Meta:
>model = School
Graham,
I'm interested in understanding what you just said. It seems like you
are saying you can get the X-Forwarded-SSL environment variable to
automatically be set, without needing the django middleware. Seems
simple enough.
The middleware also handles redirects, so that someone accidentally
g
I guess the question is when you know the additional keyword argument.
If you already know what that extra keyword is when you are
constructing the form list, you could use a partial[1] to put in the
arguments you know already. Partials are python 2.5+ only, you can use
a lambda instead if you are
Hi,
I've got a problem with a custom manager on an abstract model. I've
something like this:
class CommonModelManager(models.Manager):
def get_query_set(self):
return super(CommonModelManager, self).get_query_set().filter
(time_deleted__isnull=True).filter
(registration_site=Site.obj
Hi friends, I'm using Django 1.1, and I want to change the widget by default
on ManyToManyField for it looks as user permissions field in Django.
For that, in my admin.py I wrote:
from django.contrib import admin
from myproject.app.models import Book
class BookAdmin(admin.ModelAdmin):
filter_
Hi,
Up to now Model Validation is not possible with django. You need to use
a ModelForm. The documentation contains examples how to do custom validation.
alain31 schrieb:
> Hello, I wrote a model to manage small TeX fragments:
>
> class LaTeX(models.Model):
> latex = models.TextField(help_
Hi,
I have the following (pseudocode) models.py:
class Attachment:
file = FileField(upload_to=...)
type = CharField(max_length=2, choices=ABSTRACT_CHOICES)
lang = CharField(max_length=2, choices=LANG_CHOICES)
# some other fields, too...
class Meta:
abstract = True
cl
I suppose that you have downloaded the latest version of psycopg2:
psycopg2-2.0.12.win32-py2.6-pg8.4.0-release.exe.
In that case use the previous release psycopg2-2.0.10.win32-py2.6-
pg8.3.7-release.exe that you can find here
http://stickpeople.com/projects/python/win-psycopg/index.2.0.9.html,
the
I don´t think it´s possible to change an app-name. you can change the
name of the models though.
regards,
patrick
On 1 Sep., 10:50, Joshua Russo wrote:
> On Tue, Sep 1, 2009 at 1:10 AM, Joshua Partogi
> wrote:
>
> > Dear all,
> > How do we change the displayed application name in django admin
On Sep 1, 12:17 pm, ANIL KARADAĞ wrote:
> 2009/9/1 Daniel Roseman
>
> > On Sep 1, 10:35 am, ANIL KARADAĞ wrote:
> > > hello everbody,
>
> > > i have en error for a week. i did not resolve and i did not find it's
> > > solution.
>
> > > Sometimes system is sent an error:
>
> > > File
> > "/usr/l
def save_model(self, request, obj, form, change):
obj.save()
urfunction(aa,aa,aa,a)
On Tue, Sep 1, 2009 at 3:59 PM, ANIL KARADAĞ wrote:
> you can override model save method:
>
> for example
>
> class Student(models.Model):
> name = models.CharField(blabla)
>
> def save(self, *fo
just overide save method
and inside that method call ur function ,*do import it *
for ex
def save_model():
call ur function here
myfunction(xx,aaa,aa)
obj.save()
On Tue, Sep 1, 2009 at 3:59 PM, ANIL KARADAĞ wrote:
> you can override model save method:
>
> for example
>
> class Student
On Aug 31, 1:55 pm, LaundroMat wrote:
> I seem to remember being able to have template tags and filters
> localized in Django, but I can't find any information on this back.
> Did I misremember, or have my search skill deteriorated?
>
> I'm particularly looking for a Dutch localization of the tim
2009/9/1 Daniel Roseman
>
> On Sep 1, 10:35 am, ANIL KARADAĞ wrote:
> > hello everbody,
> >
> > i have en error for a week. i did not resolve and i did not find it's
> > solution.
> >
> > Sometimes system is sent an error:
> >
> > File
> "/usr/lib/python2.5/site-packages/django/db/models/fields/
On Sep 1, 10:35 am, ANIL KARADAĞ wrote:
> hello everbody,
>
> i have en error for a week. i did not resolve and i did not find it's
> solution.
>
> Sometimes system is sent an error:
>
> File "/usr/lib/python2.5/site-packages/django/db/models/fields/__init__.py",
> line 353, in get_db_prep_value
On Sep 1, 4:52 am, Joshua Russo wrote:
>
> Why are you using commit=False?
If I don't, I get a database error saying "user_id column can't be
null".
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" gro
hello everbody,
i have en error for a week. i did not resolve and i did not find it's
solution.
Sometimes system is sent an error:
File "/usr/lib/python2.5/site-packages/django/db/models/fields/__init__.py",
line 353, in get_db_prep_value
return int(value)
ValueError: invalid literal for int
you can override model save method:
for example
class Student(models.Model):
name = models.CharField(blabla)
def save(self, *force_insert=False*, *force_update=False*):
# call spesific python method
# operations
super(Student, self).save(force_insert=force_insert,
Hi Friends,
I want to call a python function, while saving each model... How can I
do this?
For example I have many application in a project
I have field in each model of the application and I have to access
the field just before the any model object is saved and alter a value
of that f
hi,guys
According to the django documents(http://docs.djangoproject.com/en/dev/
topics/install/),I have downloaded the psycopg(http://stickpeople.com/
projects/python/win-psycopg/) and switched the database in the
settings. However,when I sync the database or run server,there are
some error occurr
Wait a moment: this solution doesn't solve my problem.
Remember that the form I need has to be used on the admin site, so I can't
deal with it directly (in fact, I can't instantiate it and provide
additional arguments).
Are there any other way to accomplish that?
On Tue, Sep 1, 2009 at 10:48 AM,
On Tue, Sep 1, 2009 at 5:52 AM, nbv4 wrote:
>
> (Pdb) f0
>
> (Pdb) f0.cleaned_data
> {'ipc': False, 'xc': 0, 'app': 0, 'pic': 0, 'cfi_checkride': False,
> 'dual_r': 0, 'date': datetime.date(2009, 9, 5), 'dual_g': 0, 'total':
> 5.5996, 'id': None, 'sic': 0, 'night_l': 0, 'holding':
>
On Tue, Sep 1, 2009 at 1:10 AM, Joshua Partogi wrote:
> Dear all,
> How do we change the displayed application name in django admin? Let's say
> I have an application called foo, I wanted it to be displayed as bar instead
> of foo in the admin system.
>
> I've searched the document but failed to g
Thank you very much, your solution is simple and efficient :-)
On Mon, Aug 31, 2009 at 10:57 PM, Matthias Kestenholz <
matthias.kestenh...@gmail.com> wrote:
>
> On Fri, Aug 28, 2009 at 10:34 AM, Enrico
> Sartorello wrote:
> > Hi,
> > i'm developing a Django application where i need to differentia
Probably want to look into using Q
http://docs.djangoproject.com/en/dev/topics/db/queries/#complex-lookups-with-q-objects
On Aug 31, 7:18 pm, Gyanit wrote:
> Hi All,
>
> I don't seem to find good source to help me write a complex where condition
> in the django.
>
> The where condition is gener
82 matches
Mail list logo