Re: beginner . problem simple form.

2016-08-22 Thread Andromeda Yelton
Is 'dojo.views.reportaralumnos' an appropriate argument for redirect()? See https://docs.djangoproject.com/en/1.10/topics/http/shortcuts/#redirect - it's looking for the name of a URL or the actual callable view object (such as you might feed to reverse() -

Re: DateField default value

2016-08-22 Thread Rich Shepard
On Mon, 22 Aug 2016, Tim Graham wrote: What do you mean by "not accepted"? Is there some error message? What you wrote should work as far as I know. Tim, Yes, there was an error message that was not saved. from datetime import date That's probably the cause: my missing that import in

Re: DateField default value

2016-08-22 Thread Tim Graham
What do you mean by "not accepted"? Is there some error message? What you wrote should work as far as I know. from datetime import date pub_date = models.DateField(default=date.today) On Monday, August 22, 2016 at 7:04:11 PM UTC-4, Rich Shepard wrote: > > Reading the doc for DateField() I

Re: DateField default value

2016-08-22 Thread Mike Dewhirst
On 23/08/2016 9:03 AM, Rich Shepard wrote: Reading the doc for DateField() I tried to set the default as today's date, but 'default=date.today' is not accepted. If there is a way to set today's data as the default for a DateField() please point me to the doc for it.

DateField default value

2016-08-22 Thread Rich Shepard
Reading the doc for DateField() I tried to set the default as today's date, but 'default=date.today' is not accepted. If there is a way to set today's data as the default for a DateField() please point me to the doc for it. Thanks, Rich

Re: beginner . problem simple form.

2016-08-22 Thread ludovic coues
The second form tag is in an html comment. Everything inside won't be rendered. 2016-08-22 14:31 GMT+02:00 Vijay Khemlani : > Also, why do you have two form tags in your html? > > On Sun, Aug 21, 2016 at 10:40 AM, ludovic coues wrote: >> >> Do you have any

Re: receiving PNG file in django

2016-08-22 Thread Larry Martell
On Mon, Aug 22, 2016 at 12:11 PM, Bill Freeman wrote: > The most appropriate thing is for the source to use the correct content > type, in which case I believe that Django just works (it certainly used to). > But I'm assuming that you can change that. The stuff I suggested

Re: receiving PNG file in django

2016-08-22 Thread Larry Martell
On Mon, Aug 22, 2016 at 11:14 AM, Michal Petrucha wrote: > On Mon, Aug 22, 2016 at 11:10:38AM -0400, Larry Martell wrote: >> On Mon, Aug 22, 2016 at 11:00 AM, Michal Petrucha >> wrote: >> > On Mon, Aug 22, 2016 at 10:11:49AM -0400,

Re: TypeError: 'class Meta' got invalid attribute(s): indexes

2016-08-22 Thread Dennis Kornbluh
I think I solved the problem by commenting out the two options elements. If there's a better way to address this, please let me know. Thanks, Dennis On Mon, Aug 22, 2016 at 9:01 AM, Dennis Kornbluh wrote: > Hi Markus, > > Yes, you're right. When I started the

Re: TypeError: 'class Meta' got invalid attribute(s): indexes

2016-08-22 Thread Dennis Kornbluh
Hi Markus, Yes, you're right. When I started the tutorial I got the latest source from github, but then I uninstalled and reinstalled 1.10 using pip. Something remained from 1.11, perhaps in the database? import datetime from django.db import models from django.utils import timezone class

Re: TypeError: 'class Meta' got invalid attribute(s): indexes

2016-08-22 Thread Markus Holtermann
Hi Dennis, "indexes" is a new thing in the upcoming Django version. I'm fairly certain that you accidentially used Django's development version at some point while going through the tutorial. Could you please paste your models.py and the migration files Django created for you when you ran

Re: receiving PNG file in django

2016-08-22 Thread Michal Petrucha
On Mon, Aug 22, 2016 at 11:10:38AM -0400, Larry Martell wrote: > On Mon, Aug 22, 2016 at 11:00 AM, Michal Petrucha > wrote: > > On Mon, Aug 22, 2016 at 10:11:49AM -0400, Larry Martell wrote: > >> When I get the request, request.FILES is empty. Yet the content type >

Re: TypeError: 'class Meta' got invalid attribute(s): indexes

2016-08-22 Thread Tim Graham
What Django version are you using? Meta.indexes is a new feature in Django 1.11 -- are you using it in your models? On Monday, August 22, 2016 at 10:58:51 AM UTC-4, Dennis Kornbluh wrote: > > Going through the Django tutorial > , now at

Re: receiving PNG file in django

2016-08-22 Thread Larry Martell
On Mon, Aug 22, 2016 at 11:00 AM, Michal Petrucha wrote: > On Mon, Aug 22, 2016 at 10:11:49AM -0400, Larry Martell wrote: >> When I get the request, request.FILES is empty. Yet the content type >> is multipart/form-data and the method is POST: >> >> (Pdb) print

Re: receiving PNG file in django

2016-08-22 Thread Michal Petrucha
On Mon, Aug 22, 2016 at 10:11:49AM -0400, Larry Martell wrote: > When I get the request, request.FILES is empty. Yet the content type > is multipart/form-data and the method is POST: > > (Pdb) print request.META['CONTENT_TYPE'] > multipart/form-data; >

GDAL API vsicurl Support

2016-08-22 Thread benji
Hi there Does anyone know if the GDAL API supports the vsicurl protocol for reading in GeoTIFFS from a URL? Thanks! -- 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

TypeError: 'class Meta' got invalid attribute(s): indexes

2016-08-22 Thread Dennis Kornbluh
Going through the Django tutorial , now at part 5, section "Running tests". Followed the directions precisely, copy/pasted to create polls/test.py, After running $ python manage.py test polls got a stacktrace

Re: receiving PNG file in django

2016-08-22 Thread Larry Martell
On Fri, Aug 19, 2016 at 4:58 PM, Bill Freeman wrote: > If the original data truly isn't on the request object somewhere, you might > be able to grab it earlier by writing a request midleware. You might have > to put it pretty early in the chain. > > The first thing to try is

Re: Starting new project -- version 1.10

2016-08-22 Thread Rich Shepard
On Mon, 22 Aug 2016, Michal Petrucha wrote: Just to add to what Tim wrote, there's no reason why you couldn't use the crm package created by startproject as an “app”, too – all you have to do is create a models.py file in there (next to the existing urls.py, if you need any models), views.py

Re: Parent initialization don't working

2016-08-22 Thread RompePC
Sorry for the late response, have been busy. In communication, their activity is almost null (just see the response to issues). Every problem I had has to be fixed by me with no help. About english docs, they were supossed to be finished 2 years ago. And if you think you can check code to know

Re: receiving PNG file in django

2016-08-22 Thread Larry Martell
When I get the request, request.FILES is empty. Yet the content type is multipart/form-data and the method is POST: (Pdb) print request.META['CONTENT_TYPE'] multipart/form-data; boundary="boundary_.oOo._NzEwNjIzMTM4MTI4NjUxOTM5OQ==MTY2NjE4MDk5Nw==" (Pdb) print request.META['REQUEST_METHOD'] POST

Re: Django m2m through model with classic admin widget

2016-08-22 Thread 'Federico Capoano' via Django users
Glad to know there's an accepted ticket for this. Right now I'm not sure I'll be able to work on it and will probably use a less pretty workaround, but I'm coming to Django Under The Hood and I'm pretty sure I will participate in the sprints, so if I cannot work on it now I already have a

Re: beginner . problem simple form.

2016-08-22 Thread Vijay Khemlani
Also, why do you have two form tags in your html? On Sun, Aug 21, 2016 at 10:40 AM, ludovic coues wrote: > Do you have any message in the console where you run "python manage.py > runserver" ? > > 2016-08-21 12:16 GMT+02:00 Jordi Fernandez : > > hi,

Re: Django m2m through model with classic admin widget

2016-08-22 Thread Tim Graham
I haven't look into what's needed to make this work on current Django versions, however, if you're interested in contributing to Django, there's an open ticket to allow using the widget as long as there aren't any extra required fields on the through model:

Django m2m through model with classic admin widget

2016-08-22 Thread 'Federico Capoano' via Django users
Hi, this is a tough question, i've posted it to stackoverflow here: http://stackoverflow.com/questions/39076392/django-m2m-through-model-with-classic-admin-widget I include the text of the question here to make it easier to respond: I need to customise a through model of a many-to-many

Re: Starting new project -- version 1.10

2016-08-22 Thread Michal Petrucha
On Fri, Aug 19, 2016 at 02:05:18PM -0700, Rich Shepard wrote: > On Fri, 19 Aug 2016, Tim Graham wrote: > > >Don't use the same name for your app and project. When you "startproject > >crm", the project settings.py, urls.py, and wsgi.py are placed in a module > >named "crm" so you can't use the

Re: [Feedback requested] Django Debug Toolbar: Removal of automatic setup

2016-08-22 Thread James Schneider
On Fri, Aug 19, 2016 at 3:12 AM, Matthias Kestenholz wrote: > Hi everyone, > > I wanted to solicit some feedback on the removal of automatic setup before > moving forward with it. There's a pull request[1] by Jon Dufresne which > removes the feature, and if anyone feels