Thank you guys for your reply .. Actually i am using django+satchmo (sorry
for not mentioning that.. my bad).. I thought admin interface related stuffs
are related to Django only.. Thats why i didn't mentioned satchmo...
In satchmo there is a patch for my particular problem explicitly ..
http://w
Hi all,
I am currently using an implementation of the django.files.storage API to
read/write files from Amazon S3 using the django storage API. This has
worked well except for in cases where one wants to read from one stream and
write to the storage API.
One case I am running into is that I would
Hello,
I've written a few decorators for my views. Each of the decorators operate
on the same object obtained from the db backend using ORM and each checks
different things. I'll chain them together sometimes, but not always. In
the decorated view I'll usually be doing yet another
MyObjectClass
Wiadomość napisana w dniu 2009-05-21, o godz. 10:16, przez mark
hellewell:
> I've written a few decorators for my views. Each of the decorators
> operate on the same object obtained from the db backend using ORM
> and each checks different things. I'll chain them together
> sometimes, b
I´d use a slightly different approach:
class Course(models.Model):
name = ...
class Material(models.Model):
course = models.ForeignKey(Course)
media = FileBrowseField(max_length=200, blank=True, null=True)
order = models.PositiveIntegerField("Order", blank=True,
null=True)
the p
2009/5/21 Jarek Zgoda
> Use low-level Django cache framework to cache retrieved object but
> don't forget to invalidate the cache upon each change to this object.
> Like:
>
> obj = cache.get(obj_key)
> if not obj:
> obj = ObjClass.objects.get(pk=obj_pk)
> cache.set(obj_key, obj)
> return
Rodrigo Aliste P. wrote:
> OH! It does it alone! Another awesome thing to my awesomeness list of
> django.
What was your solution in the end? I'm always interested this kind of
batching of results, and I'm very new to Django...
Chris
--
Simplistix - Content Management, Zope & Python Consulti
First of all thanks for all responses.
I've still one more question which is connected to that one particular
issue. What if classes are importing each other.
models/
__init__.py
one.py
two.py
== __init__.py ===
from one import ModelOne
from two import ModelTwo
=== one.py
On Thu, May 21, 2009 at 5:10 AM, Chris Withers wrote:
> What was your solution in the end? I'm always interested this kind of
> batching of results, and I'm very new to Django...
The Django tutorial mentions this -- a Django QuerySet is "lazy",
which means that it doesn't do a query until it abs
On 20 май, 23:13, Alex Gaynor wrote:
> On Wed, May 20, 2009 at 12:01 PM, Dmitriy Sodrianov wrote:
>
>
>
>
>
> > Hi, there!
>
> > I've configured bilingual site. At this site some forms are present.
> > All the forms field 'verbose_name' attribute are marked with ugettext
> > utility.
>
> > The pr
I have some DB servers with similar structure but with different data.
I want to select a connection manually. How can I do it?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this gr
Greetings.
I have to deploy a Django application in Ubuntu for my current
assignment. I've already finished my application on Windows, yet I'm
having trouble migrating it to Ubuntu. It runs just fine when I use
Django's server (python manage.py runserver). However, my assignment
specifically requ
I have a model/table with a field declaration:
money=models.DecimalField(max_digits=12,
decimal_places=2,verbose_name=u'π/υ').
When I see this field in the Admin pages, this field is just a box,
without any formatting,
e.g. thousand separation marks, which is important for the visibility
of the
Hi kg, Thanks for your prompt reply. It was really helpful. Is there
any tutorial which explains on how to migrate the Applications
developed using Django. Django has been setup in our server. Our task
would be to setup the application in our server from the current
server.
Thanks again for timel
On Thu, May 21, 2009 at 2:48 AM, Daniel Roseman <
roseman.dan...@googlemail.com> wrote:
>
> On May 20, 11:56 pm, Sean Brant wrote:
> > Traceback (most recent call last):
> >[snip]
> > File "/home/58124/containers/django/contest/apps/entries/management/
> > commands/grabentries.py", line 73, in
I see I specified the unicode string incorrectly in my shell example. Turns
out it doesn't make a difference in this case except for the specifics of
the exception, but what it should have been was:
>>> u = u'\u2013'
>>> stderr = open('/tmp/stderr.ascii.out', 'w')
>>> print >> stderr, '%s' % u
Tr
Just to see what all the fuss is about, most of that video is the guy
configuring his particular application. The actual Django install is
very straightforward.
On May 21, 1:53 am, Kenneth Gonsalves wrote:
> On Thursday 21 May 2009 11:15:29 LeonTheCleaner wrote:
>
> > @sdc, yeah I plan to try we
Hi,
Given that my apache uses many VirtualHosts and within each a ServerName,
how can I get that ServerName into a variable in my settings.py file?
I am using WSGI and mod_python. (different setups on dev vs. server)
The reason is that I need to be able to build the whole http://servername in
I want to create a list of items from the most recently added to the
oldest. I tried this
message = Message.objects.reverse('date_added')
It still returned the oldest items first. What is the best way to
return the newest item first?
--~--~-~--~~~---~--~~
You rece
Never mind I figured it out.
On May 21, 10:42 am, CrabbyPete wrote:
> I want to create a list of items from the most recently added to the
> oldest. I tried this
> message = Message.objects.reverse('date_added')
>
> It still returned the oldest items first. What is the best way to
> return the n
Hi,
I'm trying to use Open Flash Chart 2 with django.
+ Installation
- I've downloaded OFC2 in this address :
http://sourceforge.net/project/showfiles.php?group_id=201148
- In my Django Project, I've created a directory (openFlashChart) for
the module with a __init__.py file inside.
--- I put i
Thanks Karen.
This is a script that fetched some json from a remote service. I
switched from using the normal simplejson module to the one provided
by Django and that seems to decode things in a unicode safe way.
On May 21, 2009, at 8:48 AM, Karen Tracey wrote:
> I see I specified the unic
I've just installed python-cjson 1.0.5 available here :
http://pypi.python.org/pypi/python-cjson/1.0.5
But the problem remains.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this gro
if ur using the Linux u can get the "django-admin.py" on ur command
shell in any dirctry
eg..
ash...@pylone$
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email t
Another change you made was to replace the ManyToMany on Course with a
Foreign key to Course from Material.
Could you explain the benefit of that?
On May 21, 4:36 am, patrickk wrote:
> I´d use a slightly different approach:
>
> class Course(models.Model):
> name = ...
>
> class Material(mode
I'm having the same problem - using a modelform
I've got two fields jad_file and jar_file, I notice when I look at the
html that they turn into
id_jad_file
and
id_jar_file
Is there a reason for this?
On May 20, 7:13 pm, Karen Tracey wrote:
> On Wed, May 20, 2009 at 2:39 AM, watad wrote:
>
> >
So i have to install svn on mymachine? Why people make download so
complicated...
On May 20, 10:22 pm, jai wrote:
> svn checkouthttp://django-simple-captcha.googlecode.com/svn/trunk/
> django-simple-captcha-read-only
>
> On May 21, 9:30 am, online wrote:
>
> > Could anyone please recommend
because its easy for them and they don't really get anything from doing it
otherwise? ;)
You'll find you have to head to SVN quite often to get projects in Django
I'm afraid, it just seems to be fairly common practice. Although, many
people are moving to github and it offers a download.
Cheers,
D
I'm using a CustomUploadHandler for one of my views, but the form is
always invalid - also request.FILES is also blank ?
I'm a bit new to django, so not entirely sure whats going on
## form
class UploadMidletPairForm(ModelForm):
class Meta:
model = MidletPair
### uploadhandler
class
Reposted as own subject with all the details
On May 21, 5:18 pm, "Stu.Axon" wrote:
> I'm having the same problem - using a modelform
>
> I've got two fields jad_file and jar_file, I notice when I look at the
> html that they turn into
> id_jad_file
> and
> id_jar_file
>
> Is there a reason for t
as mentioned before, one benefit is to _order_ the materials for each
course.
second, I just prefer to use edit-inlines (foreign keys) instead of
m2m-fields (the interface with many-to-many is not really useful,
IMHO).
patrick
On 21 Mai, 17:42, "eric.frederich" wrote:
> Another change you made
Hello,
I have just started using Django - looks very promising!
I am trying to implement something resembling a web-based shop. A
simplified overview of my situation is as follows:
models.py
---
class Country(models.Model)
name = CharField(max_length = 100)
currency
On Wed, 2009-05-20 at 11:06 -0700, Lokesh wrote:
> Hi Karen,
>
> In one of my HTML page I have included 2 forms, where both the forms
> have required=True fields and have submit buttons respectively.
> The problem is when a user submits one form (by clicking one of submit
> button form the page)
On Thu, 2009-05-21 at 16:24 +1000, Joshua Partogi wrote:
> Sorry for this lame question.
>
> I just saw an application called suggestionbox.com and it's able to
> write subdomain based on the customer id. Do we access and write BIND
> configuration on the fly for this? Or is there a better way to
Figured this out somewhat: To get around this, you can do something
like this when referencing external apps in auth templates:
{% url project.other_app.views.other_view as view %}
This won't raise an error if that reference doesn't work.
Still, this feels a bit hackish. I think brittle auth te
Here is one interesting open source implementation:
http://uswaretech.com/blog/2009/03/django-subdomains-easily-create-subscription-based-subdomains-enabled-webapps/
On Fri, May 22, 2009 at 12:20 AM, Tom Evans wrote:
>
> On Thu, 2009-05-21 at 16:24 +1000, Joshua Partogi wrote:
> > Sorry for this
any ideas?
--~--~-~--~~~---~--~~
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.
Here is the error message. I've googled everywhere and tried
everything, so anybody got any ideas. mod_python, leopard 10.5.X, Mac
Intel
MOD_PYTHON ERROR
ProcessId: 800
Interpreter:'teachingbystandards.com'
ServerName: 'teachingbystandards.com'
DocumentRoot: '/Library/WebServer/D
Hello,
I have i question, how can a change the data displayed in a template
only when the user changes from one view to another, for example i
have a template that displays some deleted users, but only the recent
ones are marked by a different colour from the other, how can i handle
that wuen the
Contrib.comments seems to provide a lot of permissions beyond the
obvious add / change / delete for comments themselves. What do the
following permissions grant that the former do not?
'can_moderate',
'add_commentflag',
'change_commentflag',
'delete_commentflag',
Hi all,
I've generated and compiled the locales, under my app path,
locale/LANG/LC_MESSAGES (django.mo and the .po of course)
When I select the language, some of the strings appears translated
(the ones shared with django), but no the strings on the django.mo
file (the one I created - they are a
Hi, not on my computet so will keep it short. Try to google "django
form trick" the top result should be a blog post by colin grady.
Basically what you need to do is to override the init method.
~Jakob
On May 21, 8:44 pm, Joakim Hove wrote:
> Hello,
>
> I have just started using Django - looks
I found Collin's Blog entry, and that looked very promising.
Thanks a lot.
Joakim
--~--~-~--~~~---~--~~
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.
Hi,
I have the following models :
--->
class Warehouse(models.Model):
name = models.CharField(max_length=100)
shortname = models.CharField(max_length=3)
description = models.CharField(max_length=1000)
class Product(models.Model):
name = models.CharField(max_length=300)
categ
There are some solutions posted here, maybe it would help you.
http://lethain.com/entry/2009/feb/13/when-psycopg2-can-t-import-tz/
--
With kind regards,
Petar Radosevic
W: wunki.org
PGP Fingerprint: CCDD 7545 4907 D40D C0AC 3AC2 FDDC 2E15 AC44 2A15
PGP Publickey : http://wunki.org/pgp/
pgp
+1 to Webfaction.
The support is fantastic, 10 points to the uptime and for the admin
panel.
Apart from Django, I also usit for SVN, TRAC, web redirections and
mail, with the same service quality.
Matías.-
On May 21, 3:42 am, LeonTheCleaner wrote:
> Thanks for replying. When you mention like
On 5/16/2009 10:28 PM, Glenn Maynard wrote:
> This is just a quick hack for anyone else bit by this: tzinfo is never
> set when reading DateTimeFields out of the database, at least with
> Postgresql.
>
> Now, I have no idea why anyone would want to set TIME_ZONE to anything
> but UTC (and the def
On May 21, 11:51 pm, Donn Ingle wrote:
> Hi,
> Given that my apache uses many VirtualHosts and within each a ServerName,
> how can I get that ServerName into a variable in my settings.py file?
>
> I am usingWSGIand mod_python. (different setups on dev vs. server)
>
> The reason is that I need t
+1. I used both and some of their competitors => in my opinion
slicehost and webfaction are the best in their respective classes.
Thanks,
Eugene Lazutkin
http://lazutkin.com/
On May 20, 1:59 pm, Lakshman Prasad wrote:
> In a sentence, to sum it up, Use Slicehost for VPS and Webfaction for shar
Thanks for replying. But what about dreamhost which claims to have
unlimited traffic, etc. Do you guys think what webfaction offers is
reasonable?
On May 21, 5:20 pm, Eugene Lazutkin wrote:
> +1. I used both and some of their competitors => in my opinion
> slicehost and webfaction are the best i
Thanks guys. So after I install django, I can install the project I
want, but when I say change a python file, would it update
automatically when I relaunch the website?
Thanks.
On May 21, 7:35 am, Chris Lawlor wrote:
> Just to see what all the fuss is about, most of that video is the guy
>
On Fri, May 22, 2009 at 3:08 AM, Andrew Fong wrote:
>
> Figured this out somewhat: To get around this, you can do something
> like this when referencing external apps in auth templates:
>
> {% url project.other_app.views.other_view as view %}
>
> This won't raise an error if that reference doesn'
Hello,
I have a Django application that works fine on Ubuntu Intrepid with Python 2.5
and Ubuntu Jaunty with Python 2.6.
When I try to get it to work with Debian Lenny however, I keep getting
NoReverseMatch errors.
louie:/home/django/photos# ./manage.py shell
Python 2.5.2 (r252:60911, Jan 4
Thanks,
That really helps :-) Just what I was looking for.
On May 22, 5:09 am, Lakshman Prasad wrote:
> Here is one interesting open source
> implementation:http://uswaretech.com/blog/2009/03/django-subdomains-easily-create-su...
>
--~--~-~--~~~---~--~~
You rec
I'm doing my best to give away a few books, however, due to my very
poor site traffic, I'm not having much luck. So, if you are new to
Django and you are interested a free book (Django 1.0 Website
Development, published by Packt), or if you know someone who could
benefit from a good Django book,
How about I pay someone $20 to do this for me? I just wanna work on
the python codet, instead of dealing with django installation. Seems
like a fair trade for me.
On May 21, 5:34 pm, LeonTheCleaner wrote:
> Thanks guys. So after I install django, I can install the project I
> want, but when I sa
Hi guys,
I'm trying to figure out if what is going on with the pages i'm
building and how to fix it.
I have an object of User which I put into the sessions:
class User:
def _get_points(self):
return UserModel.point.current_value
def _set_points(self, value):
pass
points = property
On Fri, May 22, 2009 at 10:06:50AM +1000, Brian May wrote:
> urlpatterns = patterns('',
> [...]
> (r'^(.*)', include('microcomaustralia.zoph.urls'))
> [...]
> )
Errr... Sorry, found out it was my fault. That should be:
(r'^', include('microcomaustralia.zoph.urls'))
I suspect I must have got th
I know how to reload a regular Python module within a regular Python
interpreter session. For some reason, I am having trouble doing that
within Django's "manage.py shell" interpreter session. To recreate my
issue, start the basic Django tutorial found here:
http://docs.djangoproject.com/en/dev/i
Hi All,
I have searched around but not really found an answer to this. For a
project I am working on the customer wants a list of publications to be
sorted alphabetically, but ignoring the definite/indefinite articles
"the/a/an".
Eg, the list should sort like
Adherence to ...
The Effec
Forgot one thing, this is on Django 1.0.2.
Regards
Darryl
On 22/05/2009 11:40 AM, Darryl Ross wrote:
> Hi All,
>
> I have searched around but not really found an answer to this. For a
> project I am working on the customer wants a list of publications to be
> sorted alphabetically, but ignoring
I've had the same problem, and can't figure out how to resolve it. It
seems to have nothing to do with the amount of data being transfered:
it happens occasionally on the smallest of page requests/responses.
It also doesn't seem to be related to browser, unless several
different versions of IE *a
On May 22, 10:51 am, LeonTheCleaner wrote:
> How about I pay someone $20 to do this for me? I just wanna work on
> the python codet, instead of dealing with django installation. Seems
> like a fair trade for me.
>
> On May 21, 5:34 pm, LeonTheCleaner wrote:
>
> > Thanks guys. So after I instal
On May 21, 10:10 pm, Darryl Ross wrote:
> I have searched around but not really found an answer to this. For a
> project I am working on the customer wants a list of publications to be
> sorted alphabetically, but ignoring the definite/indefinite articles
> "the/a/an".
You could create a new fie
On May 22, 12:31 pm, Jeff FW wrote:
> I've had the same problem, and can't figure out how to resolve it. It
> seems to have nothing to do with the amount of data being transfered:
> it happens occasionally on the smallest of page requests/responses.
> It also doesn't seem to be related to brow
I have the following code in a view, where UserSurveyForm is a
ModelForm.
f = UserSurveyForm(request.POST, instance=thisuser)
if f.is_valid():
[...]
When I try submitting valid data, this works fine. However, when I
submit an incomplete form, I get the following traceback:
[...]
50.
Reloading your models module is not going to give you different model
classes, because django tracks these classes by name. This is why the
tutorial instructs you to start a new shell after you've modified your
models.
sdc
--~--~-~--~~~---~--~~
You received this
On 22/05/2009 12:12 PM, Sam Chuparkoff wrote:
> On May 21, 10:10 pm, Darryl Ross wrote:
>> I have searched around but not really found an answer to this. For a
>> project I am working on the customer wants a list of publications to be
>> sorted alphabetically, but ignoring the definite/indefinite
I have a model/table including a field declaration:
money=models.DecimalField(max_digits=12,
decimal_places=2,verbose_name=u'π/υ').
When I see this field in the Admin pages, this field is just a box,
without any formatting,
e.g. thousand separation marks, which is important for the visibility
o
I have a model/table including a field declaration:
money=models.DecimalField(max_digits=12,
decimal_places=2,verbose_name=u'π/υ').
When I see this field in the Admin pages, this field is just a box,
without any formatting,
e.g. thousand separation marks, which is important for the visibility
of
Hi,
I have some functionality which needs to be part of a class,which I
don't want to persist in database.Where should I put such a class? In
models.py?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users"
Hi:
We are a non-profit charity organization having 25+ websites and want
to maintain a centralized database for the various events happening at
different places. The database (MySql) has been implemented and we use
the django framework admin module to communicate with the database.
Our different
Anyone familiar with using twisted and hooking it to a model?
On May 16, 8:55 pm, Timboy wrote:
> I am looking to make a webmail client proof of concept in django. I
> ran across twisted mail and this
> post:http://clemesha.org/blog/2009/apr/23/Django-on-Twisted-using-latest-t...
> showing how
Oops... thanks a lot, Karen... just a silly error, trying to include
urlpatterns from inexistant urls modules... :-P
Also, thanks for the hint, Daniel! I'll post the stacktrace here from
the box... :-)
Diogo
On May 20, 10:26 am, Karen Tracey wrote:
> On Wed, May 20, 2009 at 1:33 AM, Diogo Ba
Hi,
How to convert mysql 10 digit date format to django date format?
example:
mysql date - 1219848914
to django date - "22-05-09"
thanks.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To pos
Hi Group,
I'd like to announce the first release of django-emailauth, a Django
application which tries to provide all models/views/functionality for
implementing hassle-free user registration and authentication based on
users' emails instead of usernames.
It's hosted on github: http://github.com
I have run into an issue and was wondering how I might be able to solve it
in the best way:
For storage backends that are http based some (such as S3) require that you
submit a Content-Length header upfront.
This is not necessarily a problem for the save method which takes a file
like object sinc
Hi
AJAX doesn't care what tech is serving the data as long as the format
is what it expects (JSON). Doing cross domain AJAX calls it a bit more
tricky, but you can do it with JSONP. It's not hard to setup when you
have control of the json output. I know jQuery has it, but try to
google it, there a
Hi
It looks like a unix timestamp. I cant remember what python uses to
convert unix to a date objecr but should be pretty simple. Maybe
strftime/strptime or you can just google it.
~Jakob
On May 22, 8:13 am, laspal wrote:
> Hi,
>
> How to convert mysql 10 digit date format to django date format
79 matches
Mail list logo