Re: delete obsolete content type entries...

2013-02-10 Thread vijay shanker
we can delete all obsolete ContentType entries manually. >>>for each in ContentType.objects.filter(app_label=appname): each.delete() thanks On Friday, May 4, 2007 8:42:51 PM UTC+5:30, Jens Diemer wrote: > > > I have delete some app models. So, in the internal django tables >

Re: Problems doing ajax post with ImageField

2013-02-10 Thread Jani Tiainen
Hi, There is no way to save files through XHR, (not at least without HTML5 features). One quite common approach is to use temporary, hidden iframe where form is duplicated along the filefield and then submit that form as normal page submit and then to read response one way or another. I

Re: how to render data coming from server to template using ajax!

2013-02-10 Thread mulianto
hi, the basic is the same with full html site, except in ajax you only render part of your html output. so in ajax you can use ajax call the target url, and the output from the html output is display in the div specified. use jquery or prototype for easy manipulation. hope help Sent from my

Re: forign key no forms

2013-02-10 Thread Sandeep kaur
2013/2/11 Carlos Andre : > Olá pessoal! > Olha, preciso que um foreign key seja acessível com o forms! > Tentei de algumas maneiras e não consegui! materiais também não tão > sucintos! > alguém pode me ajudar com essa questão? > Obrigado pela a atenção! > The foreign key is by

How many sites about Django like djangoXXX?

2013-02-10 Thread Jingqiang Zhang
As far as I know: - https://www.djangoproject.com/ - http://www.djangosites.org/ - http://www.djangobook.com/ - https://www.django-cms.org/ - http://djangolinks.com/ - http://djangosnippets.org/ - http://djangostars.com/ - http://geodjango.org/ Any others? -- You

Re: Appscale and Django

2013-02-10 Thread Chris Bunch
Hello, You can certainly run Django apps on AppScale, provided that your app works fine on App Engine. There's an out of date article (https://developers.google.com/appengine/articles/django) that details what the transition process tends to look like, and it mostly boils down to how you

Re: createsuperuser with a custom User model

2013-02-10 Thread mack the finger
Ah, I didn't add my fields to REQUIRED_FIELDS, thanks. I was thinking createsuperuser would look at the fields I had included in create_superuser's signature... On Sunday, February 10, 2013 7:04:59 PM UTC-5, Russell Keith-Magee wrote: > > > On Mon, Feb 11, 2013 at 7:48 AM, mack the finger >

Re: how to render data coming from server to template using ajax!

2013-02-10 Thread Amit
Hi, Javascript does not understand django template syntax. In your case you can return a template rendered with django, and replace the html. Thannks, On Sunday, February 10, 2013 3:12:47 PM UTC+5:30, doniyor wrote: > > hey guys, i am stuck in this problem. i posted the problem on >

Re: createsuperuser with a custom User model

2013-02-10 Thread Russell Keith-Magee
On Mon, Feb 11, 2013 at 7:48 AM, mack the finger wrote: > I created a custom User model. It has a few extra fields, most notably a > "date_of_birth" field. Now when I try to crete a new superuser instance via > the management command, I get this error: > > TypeError:

createsuperuser with a custom User model

2013-02-10 Thread mack the finger
I created a custom User model. It has a few extra fields, most notably a "date_of_birth" field. Now when I try to crete a new superuser instance via the management command, I get this error: TypeError: create_superuser() takes exactly 4 arguments (3 given) My "create_superuser" manager

forign key no forms

2013-02-10 Thread Carlos Andre
Olá pessoal! Olha, preciso que um foreign key seja acessível com o forms! Tentei de algumas maneiras e não consegui! materiais também não tão sucintos! alguém pode me ajudar com essa questão? Obrigado pela a atenção! -- You received this message because you are subscribed to the Google Groups

Problems doing ajax post with ImageField

2013-02-10 Thread bobhaugen
Here's the relevant parts of the model: class Resource(models.Model): photo = ThumbnailerImageField(_("photo"), upload_to='photos', blank=True, null=True) This works fine in admin and with regular form posts. Trying to use jquery.post in one situation to post a photo without

Re: django-admin.py and manage.py both fail in dev

2013-02-10 Thread David
Problem solved. Once I straightened out my path issues it came down to the following: *python manage.py validate* works fine while * manage.py validate* does not. It just returns the help text as if I had run *manage.py* with no parameters. Clearly either Win7 or Python33 or Django 1.6dev

Re: Collectstatic not working

2013-02-10 Thread Brad
The problem is that you have your STATIC_ROOT as one of the STATICFILES_DIRS. The STATIC_ROOT directory should be empty, that is where all the static files from different places will be gathered when you run collectstatic. You should probably create a static directory under the myapp directory and

Re: Collectstatic not working

2013-02-10 Thread Lucas Magnum
Remove the os.path.join(PROJECT_PATH, 'static'), >From staticfiles_dir by default this already included. []'s Lucas Magnum. 2013/2/10 Satinderpal Singh > I am trying to configure the static files for my project by following the > Django guide

Reset userdata at a specific time without refreshing

2013-02-10 Thread Jak
Hello, I am creating an app that keeps track of how many classes a person attends a month. Basically a person gets 10 classes a month, and each time they come to a class I deduct a class from their total. On the 1st of each month at 12:01am I want the class packs to reset. I've created some

Announcing django-modeltranslation-0.5

2013-02-10 Thread Dirk Eschler
Hello, i'm pleased to announce a new release of django-modeltranslation, a Django app used to translate dynamic content using a registration approach. The 0.5 release is an important milestone which sorts out many caveats and inconsistencies that have been present in earlier versions. It adds

Re: Recursive Query

2013-02-10 Thread esatterwh...@wi.rr.com
Although an old thread, I think it is still relevant. postgresql does support recursive queries http://www.postgresql.org/docs/8.4/static/queries-with.html And while not directly support by Django's ORM, could be done using the extra clause. Might be an interesting experiment to create a

Raw query with "where-in" clause

2013-02-10 Thread Thanos Diacakis
Hey all, I have the following query: cursor.execute( "select * from MyTable where Foo=%s or Bar in %s", [some_id, some_array] ) This seems to work fine if len(some_array) > 1 but it blows up if there are zero or one items in the array (invalid SQL syntax). Is there a better way to do this?

Re: django-admin.py and manage.py both fail in dev

2013-02-10 Thread Ramiro Morales
On Sun, Feb 10, 2013 at 3:22 AM, David Flory wrote: > When I run either django-admin.py or manage.py all I get is the help screen > for the command regardless of the parameters I give. > > For example: > django-admin.py startproject mysite > returns the help screen. It

Re: django-admin.py and manage.py both fail in dev

2013-02-10 Thread David
and that the code fragment in my OP works and returns the dev version. On Sunday, February 10, 2013 10:43:14 AM UTC-5, David Flory wrote: > > I should have said that I am running Windows 7 (64 bit) and 64 bit VC10 > versions of my software. -- You received this message because you are

django generate pdf with tables and charts

2013-02-10 Thread Jaimin Patel
I am trying to generate pdf using django template, also need some support of javascript code. I have tried PISA, ReportLib and wkhtmltopdf but it seems that it doesn't wait for Javascript. Can someone suggest good solution or example? -- You received this message because you are subscribed

Re: Locating the Django admin Page

2013-02-10 Thread vikalp sahni
I hope you have settled up admin contrib app properly on your settings.py https://docs.djangoproject.com/en/dev/ref/contrib/admin/ On Sunday, February 10, 2013, Thota Madhu Sudhan Rao wrote: > I am running apache tomcat server in Amazon EC2 and running django > application > The admin page of

Re: IntegrityError when creating a brand new model instance

2013-02-10 Thread Some Developer
On 10/02/13 15:07, Bill Freeman wrote: Did you previously have a field named 'title' in this model that was marked unique, that you have since removed? If so, the column may still be in the database with a unique constraint. Since it's no longer in the model, some default may be being used

django-admin.py and manage.py both fail in dev

2013-02-10 Thread David Flory
I should have said that I am running Windows 7 (64 bit) and 64 bit VC10 versions of my software. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to

Busting template fragment caches inside a sitewide cache: possible?

2013-02-10 Thread Matt Andrews
Hi all. I have a site which makes use of Google's Analytics API which allows me to grab the most-viewed content on my site and then show it in various ways around the site ("most popular articles" etc). The query against this API is slow (takes a couple of seconds) so I've been caching it as

Locating the Django admin Page

2013-02-10 Thread Thota Madhu Sudhan Rao
I am running apache tomcat server in Amazon EC2 and running django application The admin page of Django is not here http://ipaddress:8080/admin Where do I find it -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group

django-admin.py and manage.py both fail in dev

2013-02-10 Thread David Flory
When I run either django-admin.py or manage.py all I get is the help screen for the command regardless of the parameters I give. For example: *django-admin.py startproject mysite* returns the help screen. It does not create mysite/. I am working with Python33 and the Dev version of Django

Re: IntegrityError when creating a brand new model instance

2013-02-10 Thread Bill Freeman
Did you previously have a field named 'title' in this model that was marked unique, that you have since removed? If so, the column may still be in the database with a unique constraint. Since it's no longer in the model, some default may be being used when you save, and that's obviously not

Multipple apps

2013-02-10 Thread Hum
Hello, how can I service several apps in one project using wsgi? Thanks for the help -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to

how to render data coming from server to template using ajax!

2013-02-10 Thread doniyor
hey guys, i am stuck in this problem. i posted the problem on stackoverflow.com also, http://stackoverflow.com/questions/14787772/sorting-queryset-of-search-result-and-render-back-thru-ajax but till now no one could answer there, so i am asking here again. anyone can help me? :( -- You