Re: What is the best server for Django

2011-03-10 Thread Tom Christie
And again, +1 webfaction, they really do rock. -- 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...@googlegrou

AttributeError at / polls / in Django Tutorial

2011-03-10 Thread Alberto Morales Fernández
Hi guys, I'm a rookie in django, I am doing the tutorial intro of the official URL Django, in chapter 3 but I get the following error when I access the url of my application { AttributeError at / polls / type object 'Poll' has no attribute 'objetcs' Request Method: GET Request URL: http://lo

join when it is not needed

2011-03-10 Thread aiko
Can anyone me explain why django here uses join. Let say I have: class List(models.Model): property = models.ForeignKey(Property, related_name="List") class Property(models.Model): name = models.CharField(...) property = Property.objects.get(pk=100) list = List.objects.get(property=prop

Re: AttributeError at / polls / in Django Tutorial

2011-03-10 Thread delegbede
The spelling is what the problem is. You have typed 'objetcs' instead of 'objects'. Always study the error trace very well. Best regards. Sent from my BlackBerry wireless device from MTN -Original Message- From: Alberto Morales Fernández Sender: django-users@googlegroups.com Date: W

Re: AttributeError at / polls / in Django Tutorial

2011-03-10 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 15:53 -0500, Alberto Morales Fernández wrote: > 'objetcs' objects -- regards KG http://lawgon.livejournal.com Coimbatore LUG rox http://ilugcbe.techstud.org/ -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this

Re: Error 503 Service Unavailable from 127.0.0.1

2011-03-10 Thread pjstunna
Thanks for your response. Yes I have DEBUG = True in settings.py -- 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+uns

Failed to build documentation (solved)

2011-03-10 Thread Thomas Guettler
Hi, the problem is solved, this is just for other people who have the same error. When you try to build the documentation and get the following error: File "/home/user/_django-trunk/docs/_ext/djangodocs.py", line 86, in run xrefs = roles.XRefRole()('doc', linktext, linktext, self.lineno,

Re: Satchmo Error - Invalid block tag: 'thumbnail', expected 'else' or 'endif'

2011-03-10 Thread pols
Check in settings.py installed apps for the entry 'satchmo_utils.thumbnail', If not istalled add this.If you are using new version you may need to add {% endthumbnail %} in the templates before closing endif -- You received this message because you are subscribed to the Google Groups "Django use

Re: Tracking Model's History

2011-03-10 Thread Tomasz Zieliński
On 7 Mar, 05:06, Venkatraman S wrote: > Hi, > > Similar to the way, the admin tracks the changes, i was looking for > something which can be used in my app and stumbled on > this > . > Q is : How efficient is this? I mean,

Re: How to delete ONLY m2m relation?

2011-03-10 Thread Tomasz Zieliński
On 9 Mar, 16:12, Casey Greene wrote: > In that case, I believe you can remove it with > > user.province_set.remove(province) > user.save() > User.save() is unnecessary here because remove() changes m2m intermediate table and save() changes only User table. > > I am going from memory here.  I tri

Re: Tracking Model's History

2011-03-10 Thread Venkatraman S
2011/3/10 Tomasz Zieliński > > One of the answers there was to use django-reversion - you can try if > it fits your needs. > It stores previous states of the model instance using XML notation, > which makes it possible to migrate models without loosing history. > Actually, i ended up cloning con

Re: Error 503 Service Unavailable from 127.0.0.1

2011-03-10 Thread Jirka Vejrazka
Most likely, you have a proxy defined in your browser and "bypass proxy for local machines" is not checked. Cheers Jirka On 09/03/2011, pjstunna wrote: > Hi, > > I just recently discovered Django and I'm following the Django > tutorial as it is written on the website ( > http://docs.dja

Problem with FileField (file upload) and generic views

2011-03-10 Thread Simon
I'm writing an app to allow users in a school to upload newsletters to our website, but I'm having problems using models.FileField in a generic view. I've set MEDIA_ROOT = '/data/school/media/' and MEDIA_URL is also set to a valid location. I've checked and re-checked permissions on the direc

Re: Problem with FileField (file upload) and generic views

2011-03-10 Thread Matthias Kestenholz
Hey Simon On Thu, Mar 10, 2011 at 11:49 AM, Simon wrote: > I'm writing an app to allow users in a school to upload newsletters to our > website, but I'm having problems using models.FileField in a generic view. > I've set > MEDIA_ROOT = '/data/school/media/' > and MEDIA_URL is also set to a valid

Re: Problem with FileField (file upload) and generic views

2011-03-10 Thread Simon
Spot on. Thanks. -- Simon -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more opt

how to log model inserts,updates and deletes

2011-03-10 Thread sushanth Reddy
hi, how to log model inserts,updates and deletes? I am not using django admin,in my app there are multiple tables i just want to records only which model or table name, field name,previous value,who edited,and what time to one log table? Who edited (my app uses SSO,it should pick up remote user

Re: Satchmo Error - Invalid block tag: 'thumbnail', expected 'else' or 'endif'

2011-03-10 Thread chris hendrix
both of these are done and we're still getting the error. On 03/10/2011 04:32 AM, pols wrote: Check in settings.py installed apps for the entry 'satchmo_utils.thumbnail', If not istalled add this.If you are using new version you may need to add {% endthumbnail %} in the templates before closing

Re: Error 503 Service Unavailable from 127.0.0.1

2011-03-10 Thread pjstunna
I just checked. I am using Firefox and my proxy settings is set to "No Proxy" On Mar 10, 11:41 am, Jirka Vejrazka wrote: > Most likely, you have a proxy defined in your browser and "bypass > proxy for local machines" is not checked. > >   Cheers > >      Jirka > > On 09/03/2011, pjstunna wrote:

Re: join when it is not needed

2011-03-10 Thread Karen Tracey
On Thu, Mar 10, 2011 at 1:26 AM, aiko wrote: > Can anyone me explain why django here uses join. > > Let say I have: > > class List(models.Model): >property = models.ForeignKey(Property, related_name="List") > > class Property(models.Model): >name = models.CharField(...) > > property = Pro

Probable bug - not importing force_unicode silently fails

2011-03-10 Thread Venkatraman S
I stumbled on this 'probable' bug and thought would share it with the group to ensure that it indeed is a bug and not something that i have been hallucinating :) When you try using force_unicode without importing it, the django console does not report an error; for eg, when i was playing around wit

Re: Probable bug - not importing force_unicode silently fails

2011-03-10 Thread Karen Tracey
On Thu, Mar 10, 2011 at 7:10 AM, Venkatraman S wrote: > I stumbled on this 'probable' bug and thought would share it with the group > to ensure that it indeed is a bug and not something that i have been > hallucinating :) > When you try using force_unicode without importing it, the django console

Re: Probable bug - not importing force_unicode silently fails

2011-03-10 Thread Tom Evans
On Thu, Mar 10, 2011 at 12:10 PM, Venkatraman S wrote: > I stumbled on this 'probable' bug and thought would share it with the group > to ensure that it indeed is a bug and not something that i have been > hallucinating :) > When you try using force_unicode without importing it, the django console

Re: Probable bug - not importing force_unicode silently fails

2011-03-10 Thread Gennadiy Zlobin
CTRL + F5 on Firefox and Chrome to force reload page with no caching - Gennadiy On Thu, Mar 10, 2011 at 6:22 PM, Tom Evans wrote: > On Thu, Mar 10, 2011 at 12:10 PM, Venkatraman S > wrote: > > I stumbled on this 'probable' bug and thought would share it with the > group > > to ensure that i

Re: Satchmo Error - Invalid block tag: 'thumbnail', expected 'else' or 'endif'

2011-03-10 Thread pols
try re-installing thumbnail easy_install sorl-thumbnail==3.2.5 -- 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+unsub

Re: Probable bug - not importing force_unicode silently fails

2011-03-10 Thread Venkatraman S
I did not have the code inside try-catch block. I had a hyperlink (lets say from page A) to another page(B) which was to displayed using 'thickbox'; during the display of this page B, the variables sent to Page B were not being used and i was getting a blank page inside the div(i.e, thickbox ) - s

Re: Satchmo Error - Invalid block tag: 'thumbnail', expected 'else' or 'endif'

2011-03-10 Thread chris hendrix
yeah we've followed all the instructions On 03/10/2011 08:00 AM, pols wrote: try re-installing thumbnail easy_install sorl-thumbnail==3.2.5 -- 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@g

acces to dict

2011-03-10 Thread Szabo, Patrick (LNG-VIE)
Hi, I'm passing a dict of lists on to a template like this: return render_to_response('reports.html', {'produkte': prod_pool} ,context_instance=RequestContext(request)) prod_pool looks like this: defaultdict(, {'Dumme G\xc3\xa4nge revisited': ['Absatzkontrolle'], 'Das Sparschwein i

Re: acces to dict

2011-03-10 Thread Matias Aguirre
Hi The problem is that django template system tries __getkey__ first and as you are using a defaultdict get key call is creating a new entry with key "items" and empty list as value. Try passing dict(prod_pool) to your template. Regards, Matías Excerpts from Szabo, Patrick \(LNG-VIE\)'s message

AW: acces to dict

2011-03-10 Thread Szabo, Patrick (LNG-VIE)
Hi, Thx for the hint...works like a charme :-) Kind regards . . . . . . . . . . . . . . . . . . . . . . . . . . Patrick Szabo XSLT Developer LexisNexis Marxergasse 25, 1030 Wien mailto:patrick.sz...@lexisnexis.at Tel.: +43 (1) 534 52 - 1573 Fax: +43 (1) 534 52 - 146 -Ursprüngliche N

Re: What is the best server for Django

2011-03-10 Thread Eugene MechanisM
I've server (4x 2.66+ GHz, 8GB RAM, 2TB HDD, Debian 6) at http://ovh.co.uk they're offers really great up-time/performance/service/broadband speed. I'm serving radio stations streams, several django sites(of coz nginx- varnish-uwsgi).. -- You received this message because you are subscribed to th

Re: Template Referencing Dictionary By Name

2011-03-10 Thread octopusgrabbus
Thanks. As you pointed out, I had to remove the '-' in the dictionary key. On Mar 9, 9:31 pm, Karen Tracey wrote: >  On Wed, Mar 9, 2011 at 1:30 PM, octopusgrabbus > wrote: > > > This is for Django 1.2 and MySQL 5.x > > > How does a template know a dictionary's name, if a dictionary is > > suppli

Admin Action - getting the 'entire' query set

2011-03-10 Thread tom
Hi, I want to be able to perform an Action on the full query set I have after filtering. Assume I have 100,000 objects on my DB. After filtering- 1,000 remain, and are divided into 10 pages of display. Now I want to delete all of them, I check the appropriate checkbox but the action 'delete select

Django sitemap framework

2011-03-10 Thread Sithembewena Lloyd Dube
Hi everyone, Does Django Sitemap Framework handle paginated content? I have a Django sitemap generating URLs for articles, and the articles are paginated on the site. Thanks. -- Regards, Sithembewena Lloyd Dube -- You received this message because you are subscribed to the Google Groups "Dja

Re: Why does Django Fail on Date Field?

2011-03-10 Thread octopusgrabbus
Could my problem be related to the fact that my views.py module first performs a get (sql select) on the table in question, and if the record is not there, then inserts it? try: temp_ept_id = CsRemove.objects.get(endpointid=requested_serial_number)

Re: What is the best server for Django

2011-03-10 Thread octopusgrabbus
Server or Hosted Service? I was confused by the question. We host our own applications (at least for now). For server hardware, we use IBM e-server, non-virtual at the moment. For OS software, Red Hat Enterprise EL WS 5 in production. Eventually, will be rebuilt using CentOS. For development Ub

acces lists by index

2011-03-10 Thread Szabo, Patrick (LNG-VIE)
Hi, I'm trying to acces the last index of a list in my template but list[-1] throws the following error: Could not parse the remainder: '[-1]' from 'list[-1]' How can i do it right !? Kind regards . . . . . . . . . . . . . . . . . . . . . . . . . . Patrick Szabo XSLT Develop

AW: acces lists by index

2011-03-10 Thread Szabo, Patrick (LNG-VIE)
Nevermind: This did it: {% for x in akt %} {% if forloop.last %} {{ x }} {% endif %} {% endfor %} Von: django-users@googlegroups.com [mailto:django-users@googlegroups.com] Im Auftrag von Szabo, Patrick (LNG-VIE) Gesendet: Donnerstag, 10.

Re: acces lists by index

2011-03-10 Thread Amao Zhao
django do not sport list[-n] index! On Thu, Mar 10, 2011 at 11:24 PM, Szabo, Patrick (LNG-VIE) < patrick.sz...@lexisnexis.at> wrote: > Hi, > > > > I’m trying to acces the last index of a list in my template but list[-1] > throws the following error: > > > > *Could not parse the remainder: '[-1]

Re: Why does Django Fail on Date Field?

2011-03-10 Thread Tom Evans
On Thu, Mar 10, 2011 at 3:18 PM, octopusgrabbus wrote: > Could my problem be related to the fact that my views.py module first > performs a get (sql select) on the table in question, and if the > record is > not there, then inserts it? No, it's probably because you are trying to set a datetime to

Re: What is the best server for Django

2011-03-10 Thread Tiago Almeida
I've been using a shared hosting at djangohosting.ch and I am happy. Lowest plans start at 4€/month, you only have to pay 3 months in advance. Servers physically in europe (might be important due to response times) and very simple web based installer for django apps. Good luck. On 9 Mar, 09:53, C

django random template tag

2011-03-10 Thread Jonas Geiregat
Hello, I've ran into a situation where I might need a random generator in my templates. I'm aware that the default template tag set doesn't support any random generator. Previous attempts in adding one to the default set where ignored because off out of scope issues with the standard set. Anywa

Re: acces lists by index

2011-03-10 Thread Brett Parker
{% for x in akt|slice:"-1" %} {{ x }} {% endfor %} Maybe quicker. -- Brett Parker -- 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, s

Re: AttributeError at / polls / in Django Tutorial-Solved

2011-03-10 Thread Alberto Morales Fernández
On 03/10/2011 03:28 AM, delegb...@dudupay.com wrote: The spelling is what the problem is. You have typed 'objetcs' instead of 'objects'. Always study the error trace very well. Best regards. Sent from my BlackBerry wireless device from MTN Ups!!, sorry, I did not see "objects" when I wrote i

render_to_response a HTML msg

2011-03-10 Thread Thiago Carvalho D' Ávila
I'm having some problem while trying to render some HTML code as a template variable. What I am doing is: *view.py* def view(request, id): thing = get_object_or_404(Object, pk=id) if blablabla: return render_to_response('template.html'), {'html_message': ' We recommend that you click

Re: render_to_response a HTML msg

2011-03-10 Thread Tom Evans
2011/3/10 Thiago Carvalho D' Ávila : > I'm having some problem while trying to render some HTML code as a template > variable. > > What I am doing is: > > view.py > def view(request, id): >    thing = get_object_or_404(Object, pk=id) >    if blablabla: >       return render_to_response('template.ht

Re: render_to_response a HTML msg

2011-03-10 Thread Gennadiy Zlobin
try {% if html_message %}{{ html_message|safe }}{% endif %} but I would do: {% if html_message %} We recommend that you click here {% endif %} - Gennadiy 2011/3/10 Thiago Carvalho D' Ávila > I'm having some problem while trying to render some HTML code as a template > vari

Re: render_to_response a HTML msg

2011-03-10 Thread Bill Freeman
Use: {% if html_message %}{{ html_message|safe }}{% endif %} Presuming that you believe that the variable's content is, indeed, safe. Bill 2011/3/10 Thiago Carvalho D' Ávila : > I'm having some problem while trying to render some HTML code as a template > variable. > > What I am doing is: > >

Re: Error when trying to deploy Django.

2011-03-10 Thread Tom Evans
On Thu, Mar 10, 2011 at 4:21 PM, balu wrote: > Hi all > > I'm trying to deploy django for the first time. During this process > I'm getting the following error. Please help me to correct this. > > balu@balu-varanasi:/etc/apache2/sites-available$ /etc/init.d/apache2 > reloadSyntax error on line 10

Error when trying to deploy Django.

2011-03-10 Thread balu
Hi all I'm trying to deploy django for the first time. During this process I'm getting the following error. Please help me to correct this. balu@balu-varanasi:/etc/apache2/sites-available$ /etc/init.d/apache2 reloadSyntax error on line 10 of /etc/apache2/sites-enabled/mysite: Invalid command 'WSG

Re: render_to_response a HTML msg

2011-03-10 Thread Thiago Carvalho D' Ávila
Oh, thanks a lot. That worked, but now I have one more doubt... What are the security issues related to the use of safe variable? When can I consider it safe? Is it possible to make some kind of injection using it this way? Is autoescape a better option? 2011/3/10 Bill Freeman > Use: > > {% if

AttributeError on _strptime_time

2011-03-10 Thread Massimiliano della Rovere
The error was trapped by django-sentry and does *not* occur in python interpreter, thus I can't understand it! Please can anybody enlighten me? Here the details: Exception Type: AttributeError Exception Value: _strptime_time The error is raised by line #698 in /usr/local/lib/python2.6/dist-pack

Re: render_to_response a HTML msg

2011-03-10 Thread Tom Evans
2011/3/10 Thiago Carvalho D' Ávila : > Oh, thanks a lot. That worked, but now I have one more doubt... > > What are the security issues related to the use of safe variable? When can I > consider it safe? Is it possible to make some kind of injection using it > this way? Is autoescape a better optio

django remove unicode from query result ?

2011-03-10 Thread sushanth Reddy
Hi, Django query gives me below output format,but i want below format date=`[{'total': 1744, 'name: u'x'}, {'total': 13, 'name': u'm'}, {'total': 126, 'role': name'n'}]` m=[] for i in m: m.append(i.values()) print m it give me output [[1744,u'x'], [13,u'

Re: render_to_response a HTML msg

2011-03-10 Thread Bill Freeman
On Thu, Mar 10, 2011 at 12:14 PM, Tom Evans wrote: > 2011/3/10 Thiago Carvalho D' Ávila : >> Oh, thanks a lot. That worked, but now I have one more doubt... >> >> What are the security issues related to the use of safe variable? When can I >> consider it safe? Is it possible to make some kind of i

Re: What is the best server for Django

2011-03-10 Thread Venkatraman S
On Thu, Mar 10, 2011 at 8:51 PM, Tiago Almeida wrote: > I've been using a shared hosting at djangohosting.ch and I am happy. > Lowest plans start at 4€/month, you only have to pay 3 months in > advance. Servers physically in europe (might be important due to > response times) and very simple web b

Re: django remove unicode from query result ?

2011-03-10 Thread Bill Freeman
If you know your content only has characters that exist in your default, you can say: m.append([str(s) for s in i.values()]) Or, read up on the encode method of unicode objects to see about how to ignore characters that don't translate, or for encoding into other than your default characer se

using Django from cron

2011-03-10 Thread Sells, Fred
I'm sure the solution is out there somewhere, but my google search is giving me too many false positives. I have a stand along python program that will be run as a cron job and I don't know how to launch it so it picks up the django settings, etc. I can run it like this >python manage.py shell >

Re: Why does Django Fail on Date Field?

2011-03-10 Thread Tom Evans
On Thu, Mar 10, 2011 at 5:31 PM, octopusgrabbus wrote: > The code's in the last post. What other code would you like to see? > If you'd like help, please reply to the list, not to me directly. Thanks. *Some* code is in the post. Your problem is that you are formatting a date as a string, and try

Re: Why does Django Fail on Date Field?

2011-03-10 Thread octopusgrabbus
I'm confused as to how this code isn't using the model? Here's the model I'm using. The table is in a MySQL database. class CsRemove(models.Model): action = models.CharField(max_length=3, db_column='Action') # Field name made lowercase. endpointid = models.IntegerField(primary_key=True, db

Re: using Django from cron

2011-03-10 Thread Shawn Milochik
import os os.environ['DJANGO_SETTINGS_MODULE'] = 'mysite.settings' >From the docs: http://docs.djangoproject.com/en/dev/topics/settings/ Shawn -- 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@

Re: using Django from cron

2011-03-10 Thread Tom Evans
On Thu, Mar 10, 2011 at 5:42 PM, Sells, Fred wrote: > I'm sure the solution is out there somewhere, but my google search is > giving me too many false positives. > > I have a stand along python program that will be run as a cron job and I > don't know how to launch it so it picks up the django set

Re: Why does Django Fail on Date Field?

2011-03-10 Thread Jirka Vejrazka
Will this answer your question? >>> import datetime >>> datetime.datetime(year=, month=00, day=00) Traceback (most recent call last): File "", line 1, in ValueError: year is out of range Jirka -- You received this message because you are subscribed to the Google Groups "Django users"

Re: Why does Django Fail on Date Field?

2011-03-10 Thread Tom Evans
On Thu, Mar 10, 2011 at 5:46 PM, octopusgrabbus wrote: > I'm confused as to how this code isn't using the model? > > Here's the model I'm using. The table is in a MySQL database. > class CsRemove(models.Model): >    action = models.CharField(max_length=3, db_column='Action') # > Field name made lo

Packaging and development workflow for decoupled apps.

2011-03-10 Thread DaleB
Hi all, i could use some advice for a good packaging workflow. So far i used to put an "apps"-folder in my project root and i stored all individual apps in a sub-folder. This works, but i thought: "Okay, try to decouple things a bit more and try to create some 'real' reusable apps." So i followe

Re: using Django from cron

2011-03-10 Thread Bill Freeman
On Thu, Mar 10, 2011 at 12:49 PM, Tom Evans wrote: > On Thu, Mar 10, 2011 at 5:42 PM, Sells, Fred > wrote: >> I'm sure the solution is out there somewhere, but my google search is >> giving me too many false positives. >> >> I have a stand along python program that will be run as a cron job and I

Re: Packaging and development workflow for decoupled apps.

2011-03-10 Thread Bill Freeman
On Thu, Mar 10, 2011 at 12:57 PM, DaleB wrote: > Hi all, > > i could use some advice for a good packaging workflow. > > So far i used to put an "apps"-folder in my project root and i stored > all individual apps in a sub-folder. > This works, but i thought: "Okay, try to decouple things a bit more

Re: Packaging and development workflow for decoupled apps.

2011-03-10 Thread Mike Ramirez
On Thursday, March 10, 2011 09:57:29 am DaleB wrote: > I see that this is really great for the distribution of an app. > But what about development and "continuous packaging"? > I mean, my project consists of more than five apps. One side of me > would rather turn them all into installable package

Re: Packaging and development workflow for decoupled apps.

2011-03-10 Thread Tom Evans
On Thu, Mar 10, 2011 at 5:57 PM, DaleB wrote: > Hi all, > > i could use some advice for a good packaging workflow. > > So far i used to put an "apps"-folder in my project root and i stored > all individual apps in a sub-folder. > This works, but i thought: "Okay, try to decouple things a bit more

Re: Why does Django Fail on Date Field?

2011-03-10 Thread octopusgrabbus
I converted my date, and it all works fine. Thanks for your help. On Mar 10, 12:54 pm, Tom Evans wrote: > On Thu, Mar 10, 2011 at 5:46 PM, octopusgrabbus > > > > wrote: > > I'm confused as to how this code isn't using the model? > > > Here's the model I'm using. The table is in a MySQL database.

Insert an "editable" extra field on admin change list.

2011-03-10 Thread Marc Aymerich
Hi, I spend all day trying to figure out how to insert an "editable" extra field (not a model field) in admin change list. Is there an easy way to do that? Thanks! -- Marc -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, s

mysql OperationalError

2011-03-10 Thread Brian Craft
When a long-running script loses the db connection, I get this exception: _mysql_exceptions.OperationalError Is there any way to trap this in a database-agnostic way? Or must I hard-code it to mysql? -- You received this message because you are subscribed to the Google Groups "Django users" g

Re: Admin Action - getting the 'entire' query set

2011-03-10 Thread Karen Tracey
On Thu, Mar 10, 2011 at 9:15 AM, tom wrote: > I want to be able to perform an Action on the full query set I have > after filtering. > > Assume I have 100,000 objects on my DB. After filtering- 1,000 remain, > and are divided into 10 pages of display. Now I want to delete all of > them, I check t

Use admin interface in public facing pages?

2011-03-10 Thread gbl
The admin interface is perfect for the site I'm working on. Automatic pagination, customizable search fields, filter via boolean or date fields in a sidebar, clickable sorting on column headings. Easy to modify Is there really no way to use all this code in a read-only situation? Do I have to

What is it with Django and 2008?

2011-03-10 Thread Benjamin Roberts
So I don't mean to be confrontational at all. I am learning Django and really like it. I'm forming a startup and we've already decided to go with it to build our applications. I look forward to getting involved in the community, too. Something has me a bit weirded out though, it seems 75% of wh

Skinning/extending the admin for sub-admin interfaces?

2011-03-10 Thread br
So I'm taking over a project (which already has a strong start in Django) from a few guys. I'm new to the framework (but experienced as a programmer) and excited for everything about it (the project, Python, and Django). I have one general design question. But first, some background The site is s

Re: django remove unicode from query result ?

2011-03-10 Thread Kenneth Gonsalves
On Thu, 2011-03-10 at 09:29 -0800, sushanth Reddy wrote: > print m > it give me output > > [[1744,u'x'], [13,u'm'], [126,u'n']] > > but i need output in > how to remove unicode symbol from output > > why do you want to remove it? unicode is a great advance - why are you going backward in

Re: Why does Django Fail on Date Field?

2011-03-10 Thread Kenneth Gonsalves
On Thu, 2011-03-10 at 09:46 -0800, octopusgrabbus wrote: > load_date = '-00-00' what on earth is this? -- regards KG http://lawgon.livejournal.com Coimbatore LUG rox http://ilugcbe.techstud.org/ -- You received this message because you are subscribed to the Google Groups "Django users" gro

Re: Skinning/extending the admin for sub-admin interfaces?

2011-03-10 Thread Kenneth Gonsalves
On Thu, 2011-03-10 at 16:55 -0800, br wrote: > So the question is, for each of the "dashboards"--which are > essentially limited admin interfaces--would it make sense to extend or > inherit from Django Admin in some way? Or should I just design these > like I would client-side pages, with specific

Simple Django Report Generator

2011-03-10 Thread Patrick McDonnell
Hello - I'm wondering if anyone has any suggestions/recommendations for a flexible Django report generator. Basically, I'd like to give user's the ability to query a given model based on user-defined filters. For example, for an application that tracks information about a company's employees, of

Re: django remove unicode from query result ?

2011-03-10 Thread sushanth Reddy
I using jplot in my app .if list is in unicode(u) ,it not displaying the charts,thats the reason i want to remove it ... -- 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 unsu

Re: django remove unicode from query result ?

2011-03-10 Thread Kenneth Gonsalves
On Thu, 2011-03-10 at 17:26 -0800, sushanth Reddy wrote: > I using jplot in my app .if list is in unicode(u) ,it not displaying > the > charts,thats the reason i want to remove it ... I do not think that is a good reason. Why not use a python or js library? http://wiki.python.org/moin/NumericAn

Re: django remove unicode from query result ?

2011-03-10 Thread Jason Culverhouse
On Mar 10, 2011, at 5:26 PM, sushanth Reddy wrote: > I using jplot in my app .if list is in unicode(u) ,it not displaying the > charts,thats the reason i want to remove it ... > Pass a json string then have the Java(?) side convert it back into "objects" In [1]: import json In [2]: json.dumps

Re: Simple Django Report Generator

2011-03-10 Thread Venkatraman S
On Fri, Mar 11, 2011 at 6:54 AM, Patrick McDonnell wrote: > Clearly, these kind of reports are trivial for me to hard code using > Django's ORM, but a much more ideal solution would be to provide users with > a (dare I say it) MS Access-like query builder, that would allow them to > choose the co

Re: Logging raw sql

2011-03-10 Thread Marwan Al-Sabbagh
Hi, There are three different possible solutions you could investigate to do this logging on the django/python level: 1) use django's new logging feature that as per the docs will log "every SQL statement executed by a request". The beauty of this approach is that you can use python's excellent

Re: How to get next and previous element in a forloop in the template

2011-03-10 Thread Derek
On Mar 7, 10:43 pm, Ariel wrote: > Could you give some idea ??? > I am sorry about the previous message I had not finished. > > Any help is appreciated. > Regards. > > > > > > > > On Mon, Mar 7, 2011 at 3:39 PM, Ariel wrote: > > Hi everybody: > > > I would want to know in the django template tags

Re: When do we stop using Django admin?

2011-03-10 Thread Derek
On Mar 8, 8:16 am, ajaishankar wrote: > Thanks Viklap > > We have been doing a lot of ModelAdmin & ModelForm tweaking as > mentioned in those slides. > > But still kind of skeptical we should be opening up the admin to other > companies; and go through the gymnastics of restricting say a foreign >

RE: Multiple modelforms in single POST

2011-03-10 Thread Anoop Thomas Mathew
Hi all, I have a Profile model, which has a ForiegnKey to User model. I want to edit both of it at same form. this is what I tried, http://dpaste.de/ODOJ/ Still, no success. Please help. regards, atm -- You received this message because you are subscribed to the Google Groups "Django users" g

Re: Simple Django Report Generator

2011-03-10 Thread Bruno Tikami
On Thu, Mar 10, 2011 at 11:44 PM, Venkatraman S wrote: > > On Fri, Mar 11, 2011 at 6:54 AM, Patrick McDonnell wrote: > >> Clearly, these kind of reports are trivial for me to hard code using >> Django's ORM, but a much more ideal solution would be to provide users with >> a (dare I say it) MS Acc