Re: Complete book

2019-10-19 Thread Greg Hicks
A big thanks from me also. This looks current and definitive. Greg -- 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 django-users+unsubscr...@google

Method Flowchart for Generic Editing Views

2017-01-10 Thread Greg Schmit
In the documentation, I notice that for the base views and the generic display views, there exists a descriptive "method flowchart" that I can use to figure out which method I need to use to perform a task. However, for the generic editing views this seems to be missing. I end up looking throug

Django default transaction behaviour

2015-06-25 Thread Greg Kempe
, but a good choice of defaults can save many new (and not so new) users from surprises. Thanks, Greg [1] https://docs.djangoproject.com/en/1.8/topics/db/transactions/ -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from

Django session key collision

2015-06-02 Thread Greg
I've noticed a number of apparent session collisions (i.e., two or more users getting the same session key and therefore each others session data) on a site I manage. The site is on django 1.3.7, which shouldn't have any issues with session key collisions (there were some in earlier django vers

Re: Avoiding Keyboard Input for Removing Stale Content Types Automatically (migrations and automatic deployment)

2015-05-26 Thread Greg Shikhman
Thanks for documenting your trouble, I ran into the same problem today. The kludge solution that I came up with was: 'yes yes | python manage.py migrate' in my deployment script -- decidedly suboptimal. My preference would be for the yes/no decision of dropping stale models to be recorded withi

Django migrations directly import custom fields?

2014-09-08 Thread Greg
#x27;ll post it there. Thanks, Greg -- 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 django-users+unsubscr...@googlegroups.com. To post to this group, s

Best Django apps/extensions

2014-06-27 Thread Greg Niewisiewicz
Hi, I'm working on a short guide about setting up a new Django project. I'd like to ask you for apps that you think are indispensable in every project (e.g. south or django-debug-toolbar). What are your favorite apps/extensions that you install in most of your projects? Best regar

Random auth_permission + content_type errors during test runs

2014-04-02 Thread Greg Taylor
I've got a project running Django 1.4, Postgres 3, Python 2.7. Our tests get about halfway through, then we get a sudden flood of errors showing that the django_content_type table may be empty: ..

Admin interface is calling a custom method on my model?

2014-03-04 Thread Greg Barker
ing on here? Thanks! Greg -- 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 django-users+unsubscr...@googlegroups.com. To post to this group, send em

Re: properly passing form post data to get_context_data() in detailview

2013-06-07 Thread Greg Maruszeczka
lagged by validation errors. It appears to work as intended and now I can review again in light of best practices. If anyone has suggestions on that I would appreciate it Thanks, GM On Tuesday, 4 June 2013 17:51:24 UTC-7, Greg Maruszeczka wrote: > > Hi, > > I'm

properly passing form post data to get_context_data() in detailview

2013-06-04 Thread Greg Maruszeczka
Hi, I'm trying to process a form through a detailview that adds a comment to a blog post. Here's my view code: class PostDetailView(DetailView): model = Post template_name = 'blog_detail.html' queryset = Post.objects.filter(published=True) form_class = CommentForm def

Re: Pickling of dinamically created models.Model subclasses: "attribute lookup failed", django 1.5

2013-04-18 Thread Greg H
Running into a similar issue on my own project, seems to be when you try an cache a model which has a related model which in turn has a many to many field. So for example, I have an instance of a Student, which has a ForeignKey to Book, which in turn has a ManyToMany to Author. If I try and cac

view_func.__module__ suddenly broken

2013-02-26 Thread Greg Donald
de python-problem-report 2.0.1-0ubuntu15.1 2.0.1-0ubuntu17.1 2013-01-25 03:41:06 upgrade python-apport 2.0.1-0ubuntu15.1 2.0.1-0ubuntu17.1 I also tried rearranging my middleware list, didn't help. Any idea what else might be causing this issue? Thanks. -- Greg Donald -- You re

Re: Polls tutorial receive object not object representation

2013-02-01 Thread Greg
> Now the only thing is that when I call p.choice_set.all() I don't get the representation 'The sky' or 'Just Hacking again' . I receive choice object itself. Is this normal? It should be said that yes, that is normal. p.choice_set.all() is a list of Choice objects, not a list of strings attrib

Re: last changed by User

2012-09-27 Thread Greg Donald
On Thu, Sep 27, 2012 at 10:28 PM, Lachlan Musicman wrote: > I wanted to display the user that last changed a model instance. I use django-reversion for this: https://github.com/etianen/django-reversion -- Greg Donald -- You received this message because you are subscribed to the Goo

Getting Started

2012-09-24 Thread Greg Lindstrom
o the applications). I'm eager to learn Django; can someone please give me a kick in the proper direction? --greg -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.

django 1.4 memory issues

2012-06-12 Thread Greg Donald
igured it couldn't hurt. So everything is running fine again, but something changed in Django 1.4 that causes my same project code to leak memory. I'd sure like to figure it out. Thanks. -- Greg Donald -- You received this message because you are subscribed to the Google Groups &quo

Re: Documentation for the url template tags in 1.4

2012-05-09 Thread Greg Nicholas
Great, thanks for looking into it! On Wednesday, May 9, 2012 9:27:08 PM UTC-4, Russell Keith-Magee wrote: > > Hi Greg, > > Thanks for the report. From the look of it, the problem is actually > with Django's documentation site, not with the documentation itself. > &

Documentation for the url template tags in 1.4

2012-05-09 Thread Greg Nicholas
Correct me if I'm wrong, but I think 1.4's documentation has jumped the gun in describing the url template tag's syntax. According to 1.4's documentation : {% url 'path.to.some_view' v1 v2 %} >> > The first argument is a path to

Re: South with multiple virtual hosts

2012-03-02 Thread Greg
As a kind soul nicely pointed out to me elsewhere, I don't have a problem. The migration history is DB specific, so simply run the schemamigration using any settings file, then do the migrate with all settings files. Doh! It's been a long week. On Mar 2, 3:55 pm, Greg wrote

South with multiple virtual hosts

2012-03-02 Thread Greg
Hi, We have a setup where multiple domains via Apache's VirtualHost are pointed to individual settings.py files using WSGI. Works great. Each domain shares the same codebase and each domain has its own DB specified in the settings file. Again, works great. Now the problem. If I need to do a So

Re: Django vs. Ruby on Rails

2012-01-28 Thread Greg Donald
s on this > comparison. Rails seems risky to me. Django feels like a sure bet. Maybe I'm just old, but sometimes I get the feeling Rails is being built by some kids in someone's basement. -- Greg Donald -- You received this message because you are subscribed to the Google Group

Re: Logging into CSRF protected Django site using Curl?

2012-01-08 Thread Greg Donald
ted. Is this the only to login to a Django > site that uses CSRF protection? https://docs.djangoproject.com/en/1.3/ref/contrib/csrf/#exceptions I use this on views that my mobile apps post to. -- Greg Donald -- You received this message because you are subscribed to the Google Groups "

Re: Which Linux distro to use on EC2?

2011-11-20 Thread Greg Donald
tion: http://www.freebsd.org/commercial/isp.html -- Greg Donald -- 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

Re: Which Linux distro to use on EC2?

2011-11-15 Thread Greg Donald
yourself. Things will land in the same place, so dependency issues are usually extremely low. -- Greg Donald -- 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 u

Re: Helping someone move from Joomla to Django

2011-10-06 Thread Greg Maruszeczka
On Thu, 6 Oct 2011 06:12:21 -0700 (PDT) graeme wrote: > Joomla may have those shortcomings, but its not the only alternative. > If someone likee PHP, already knows PHP or has to use PHP, there are > a lot of PHP fraeworks: from light ones, to ones feature comparable > to > Django (although I do

Re: Django Development environment

2011-08-22 Thread Greg Maruszeczka
On Mon, 22 Aug 2011 15:07:24 -0700 (PDT) Stephen Jackson wrote: > I am new to the world of Django. I would like to hear from other > django developers describe their dev environment (tools, os, editors, > etc.). > fedora, eclipse (pydev), mercurial, virtualenv, postgres, apache (wsgi) -- You

Re: sorl thumbnail

2011-06-15 Thread Greg Donald
So what does one use for thumbnails when sorl thumbnail works great in development but fails on two different production servers? -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.

Moving Away from if/else Template Logic

2011-06-14 Thread Greg Corradini
Hello All, I'm try to get away from doing if/else in a template: {% if x.message|regtest == "True" %} do something cool {% else %} do something less cool {% endif %} given this template filter: @register.filter(name='regtest') def regtest(value): regex = re.compile(r'^\*\*(?P.*)\*\*

Re: sorl thumbnail

2011-06-11 Thread Greg Donald
and my uploaded image is not corrupt. The only thing left is permissions, and they are as open as they can be. -- Greg Donald destiney.com | gregdonald.com -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send emai

Re: sorl thumbnail

2011-06-10 Thread Greg Donald
ImageField. It is, it's a sorl thumbnail ImageField to be exact. -- Greg Donald destiney.com | gregdonald.com -- 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.c

Re: sorl thumbnail

2011-06-10 Thread Greg Donald
On Fri, Jun 10, 2011 at 11:59 AM, Greg Donald wrote: >  File "/usr/local/lib/python2.6/dist-packages/PIL/ImageFile.py", line > 52, in raise_ioerror >   raise IOError(message + " when reading image file") > > IOError: broken data stream when reading image file

sorl thumbnail

2011-06-10 Thread Greg Donald
raise IOError(message + " when reading image file") IOError: broken data stream when reading image file The error isn't very helpful since the file is there and is readable by all. I'm not sure how to get a more explicit error, or what to try and fix. Stuck. Thanks, --

Re: Passing extra context data to class-based generic views?

2011-06-09 Thread Greg
I've created a reusable view which allows for an extra_context argument, see https://github.com/gregplaysguitar/django-baseclasses/blob/master/baseclasses/views.py +1 on this functionality being added to django itself though. -- You received this message because you are subscribed to the Googl

Re: ImageField issue

2011-06-08 Thread Greg Donald
    f = open('/tmp/hello.world') >     myfile = File(f) >     et.image.save( image_name, myfile ) > > https://docs.djangoproject.com/en/1.3/ref/models/fields/#django.db.models.FieldFile.save I see now.. got it working. Thanks. -- Greg Donald destiney.com | gregdonald.com -- You

ImageField issue

2011-06-08 Thread Greg Donald
ot sure why image_file.read() is returning a str, it spews a bunch of what appears to be image data when I debug it. Any idea what I'm doing wrong? Thanks. -- Greg Donald destiney.com | gregdonald.com -- You received this message because you are subscribed to the Google Groups "

Re: boolean default

2011-05-17 Thread Greg Donald
expected, but that's not what I get. See the code I posted. My Form Model complains that my BooleanField type is missing when I do not supply it explicitly. Further, if I exclude it, to make my Form Model happy, I get a DatabaseError exception since the field in my database has no default set

Re: boolean default

2011-05-17 Thread Greg Donald
not provide a value at all when I created a new record. -- Greg Donald destiney.com | gregdonald.com -- 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

boolean default

2011-05-15 Thread Greg Donald
How do I set a default for a BooleanField() ? I tried foo = models.BooleanField( default=False ) but that only produces foo boolean NOT NULL, Docs do not mention how as far as I can tell http://docs.djangoproject.com/en/1.3/ref/models/fields/#booleanfield -- Greg Donald destiney.com

Re: existing data failing validation

2011-05-15 Thread Greg Donald
se the company no longer exists when I post the form, even though it's right there in the post data. This is so overly complicated. What is the point of having a model form if you're just going to exclude important things from it to cheat to get by an edit form? -- Greg Donald destin

Re: existing data failing validation

2011-05-15 Thread Greg Donald
hen I don't include previously set data? ipdb> form.errors {'company': [u'This field is required.']} -- Greg Donald destiney.com | gregdonald.com -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to thi

Re: existing data failing validation

2011-05-14 Thread Greg Donald
arField( max_length=32 ) class ContactForm( ModelForm ): class Meta: model = Contact name = CharField( required=True ) The fields failing validation are ones I'm not re-submitting back in my edit form. Am I supposed to list company again in my ContactForm class? Guess

existing data failing validation

2011-05-14 Thread Greg Donald
, I get errors about not providing fields already set. form = ContactForm( request.POST, instance=contact ) form.errors says I need to provide a company, but it is already saved in the database. What am I missing here? -- Greg Donald destiney.com | gregdonald.com -- You received this mes

Re: form new versus edit

2011-05-14 Thread Greg Donald
getting my name field HTML rendered, I naturally tried {{ form.id }}, but it doesn't seem to know about Django conventions I don't guess. -- Greg Donald destiney.com | gregdonald.com -- You received this message because you are subscribed to the Google Groups "Django user

Re: form new versus edit

2011-05-14 Thread Greg Donald
=TextInput( attrs={ 'class':'myclass' } ) ) in a single place for all my CharField types? -- Greg Donald destiney.com | gregdonald.com -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send ema

Re: form new versus edit

2011-05-14 Thread Greg Donald
into the > project, and if something's there it's probably for a really good reason. > When you choose not to follow a Django convention and run into a problem > then don't be surprised. I didn't realize trying to access my own form data directly was unconv

Re: form new versus edit

2011-05-14 Thread Greg Donald
e {{ form.name }} then I have to set CSS attributes for every field using: name = forms.CharField( widget=forms.TextInput(attrs={'class':'special'})) How is that better than just writing a simple field myself? -- Greg Donald destiney.com | gregdonald.com -- You received

Re: form new versus edit

2011-05-14 Thread Greg Donald
On Sat, May 14, 2011 at 4:08 PM, Shawn Milochik wrote: > On 05/14/2011 05:04 PM, Greg Donald wrote: >> >> I have a "new" contact form.  If I post it, and it has error, I found >> (while debugging, not documented that I can find) that I can redraw >> the sub

form new versus edit

2011-05-14 Thread Greg Donald
.name.data throws an exception. What am I doing wrong? I'd really like to just have my one _form.html template included in both my add.html and my edit.html templates. How can I do that when the form doesn't even work the same between new versus editing? Thanks. -- Greg Donald destine

Re: using django on a server?

2011-05-09 Thread Greg Donald
On Mon, May 9, 2011 at 11:02 PM, Eric Chamberlain wrote: > We use Amazon Web Services and can change our setup on an hourly basis. Do they support DNS yet, or are you still responsible for that yourself? -- Greg Donald destiney.com | gregdonald.com -- You received this message because

Re: using django on a server?

2011-05-09 Thread Greg Donald
all what you want. The question of "Does my host support that?" becomes irrelevant. You can support whatever because you can install whatever. -- Greg Donald destiney.com | gregdonald.com -- You received this message because you are subscribed to the Google Groups "Django u

Re: using django on a server?

2011-05-09 Thread Greg Donald
nything nowadays. -- Greg Donald destiney.com | gregdonald.com -- 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+un

Re: Encrpting urls to hide PKs

2011-05-09 Thread Greg Donald
n identifier of that data. Yeah, sounds exactly like a session-based cookie. -- Greg Donald destiney.com | gregdonald.com -- 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@googlegrou

Using Django to white-label sites for multiple clients

2011-03-02 Thread Greg Pelly
e others tried this? Are there existing strategies? Perhaps a django app that takes care of this? Thanks, Greg -- 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 unsub

Re: label_tag in queryset

2011-02-24 Thread Greg Corey
me know. But it seems to work quite well. Greg On Thu, Feb 24, 2011 at 9:15 AM, Greg Corey wrote: > Pardon the continued confusion, but the problem is that I don't know how to > access the model field to get it's associated label like I can when > rendering a form. I don'

Re: label_tag in queryset

2011-02-24 Thread Greg Corey
he label, I can change it in the model and then I don't have to worry about my templates because they just reference the model (DRY). Thanks for you help. Greg On Wed, Feb 23, 2011 at 5:22 PM, Mike Ramirez wrote: > On Wednesday, February 23, 2011 04:16:51 pm Greg Corey wrote: > >

Re: label_tag in queryset

2011-02-23 Thread Greg Corey
e the model field to get the label? Greg On Wed, Feb 23, 2011 at 4:53 PM, Mike Ramirez wrote: > On Wednesday, February 23, 2011 02:15:40 pm geraldcor wrote: > > > Hello all, > > > > > > When rendering a list of data for a particular model instance, I am > >

Re: Newbie problems with "get"

2011-02-11 Thread Greg
Thanks for heading me in the right direction. I had several errors in my urls.py. On Feb 11, 11:46 am, Shawn Milochik wrote: > Without testing it, I suspect the period in your 'request.GET' is the > problem. Try replacing it with request_get and see what happens. > > Shawn -- You received this

validation "warnings" in the admin?

2011-02-11 Thread Greg Humphreys
I can do this easily enough with my own custom object creation view, but I'd like to let my people still use the admin interface. I'd like to be able to do some validation of a created or changed object and issue a WARNING before allowing the user to commit the object to the database. For examp

Re: Newbie problems with "get"

2011-02-11 Thread Greg
Shawn see below. from django.conf.urls.defaults import * from mysite.my_clts import views #from mysite.books import views # Uncomment the next two lines to enable the admin: from django.contrib import admin admin.autodiscover() urlpatterns = patterns('', (r'^my_clts/$', 'my_clts.views.index

Newbie problems with "get"

2011-02-11 Thread Greg
I am getting the bad charecter in group name error when using a form. Environment: Request Method: GET Request URL: http://localhost:8000/search-form/ Django Version: 1.2.3 Python Version: 2.7.1 Installed Applications: ['django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessi

Database synchronization with sometimes-connected mobile client

2011-02-05 Thread Greg Humphreys
Hi everyone. I've developed a django website of medium complexity (about 50,000 lines of python), and the company I work for is now asking for a subset of the functionality to be available on an iPad. I'm familiar with iPad development, so I'm not worried about that, but all the research I've done

Re: New to Django, sheet music organization site

2011-01-03 Thread Greg Turner
eger or a string of an integer, as it comes from a URL), then you want: Song.objects.all().filter(artist__id=myartist) (the .all() is unneccessary, by the way). Greg. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group

Re: Too many items in my drowndown list

2011-01-03 Thread Greg Turner
users+unsubscr...@googlegroups.com > . > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en. > > -- Dr Greg Turner Director, the Interaction Consortium http://interaction.net.au Phone: +61 2 8060 1067 skype: gregturner Follow us on twitter:

Re: render_to_response

2011-01-03 Thread Greg Turner
ith an underscore, such as _my_fnc) ) Hope this helps, Greg On 3 January 2011 20:45, gintare wrote: > > How formulate correctly the code below: > > [code] > #views.py > > def search(request): > .. >answ = my_fnc(roots) >return render_t

Efficient Grouping of Database Query

2010-12-27 Thread greg
d setting lifts and then sort them into a dictionary? Thanks, Greg Kerr -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, se

Re: Database Setup

2010-10-14 Thread Greg Fuller
This can be a pain on windows, because there is usually no compiler for setup to build the "binary" version of the adaptor. The easiest course of action is to find a binary for the version of python you are running. I haven't seen any for 2.7 yet but searching for "python msqldb windows binary" w

Re: Django.contrib.gis.gdal Questions

2010-10-10 Thread Greg Corradini
the scenes to do interop to other data formats? Or is the point of these wrappers more as a utility for users to inspect data (mainly shapefiles)? Just wondering :) On Oct 9, 7:50 am, Greg Corradini wrote: > I'm wondering if django.contrib.gis.gdal Python wrappers were only > meant to

Django.contrib.gis.gdal Questions

2010-10-09 Thread Greg Corradini
I'm wondering if django.contrib.gis.gdal Python wrappers were only meant to implement read functionality of OGR? It seems that way. I don't see any implementation of CreateDatasource in the driver.py class. Is this correct or is there a way to write to shapefiles with these bindings that I'm missin

Re: Displaying images

2010-08-19 Thread Greg Pelly
ref/templates/api/ If TEMPLATE_CONTEXT_PROCESSORS contains this processor, every RequestContext will contain a variable MEDIA_URL, providing the value of the MEDIA_URL setting. Greg On Thu, Aug 19, 2010 at 10:54 AM, Bradley Hintze < bradle...@aggiemail.usu.edu> wrote: > Greg, that

Re: Displaying images

2010-08-19 Thread Greg Pelly
try this: def math_form(request): return render_to_response('form.html', {}, context_instance=RequestContext(request)) greg On Thu, Aug 19, 2010 at 10:35 AM, Bradley Hintze < bradle...@aggiemail.usu.edu> wrote: > I am sorry. I am using render to response. > > #

Re: generating random keys/passwords

2010-08-13 Thread Greg Pelly
And to answer your more general question about email signups, have a look at Django Registration. It should have everything you need. http://bitbucket.org/ubernostrum/django-registration/wiki/Home On Fri, Aug 13, 2010 at 3:44 PM, Greg Pelly wrote: > have a look at Django Command Extensi

Re: generating random keys/passwords

2010-08-13 Thread Greg Pelly
have a look at Django Command Extensions: http://code.google.com/p/django-command-extensions/ sample usage: $ ./manage.py generate_secret_key xr7+43ak=i^2+ommc_e6xn$6vph)_$ffb$n3kp#o1!675euxdu Greg On Fri, Aug 13, 2010 at 3:32 PM, bagheera wrote: > Hi, i'm looking for python m

Re: scaling my site

2010-07-23 Thread Greg Pelly
ehost ($20/month), which we ultimately chose. In any event, it sounds like you should find a sysadmin to help you with these decisions/tasks. Greg On Fri, Jul 23, 2010 at 12:43 PM, Tony wrote: > I have just about finished all the logic for my site. In short, I > need the site to be pretty

Re: What is a good source code control software?

2010-07-16 Thread Greg Pelly
bed to the Google Groups > "Django users" group. > To post to this group, send email to django-us...@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com > . > For more options, visit this group at > http://group

Re: Temporary group membership tally - Any clever way to do it?

2010-07-15 Thread Greg Pelly
ango-us...@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com > . > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en. > > -- Greg Pelly CEO / CTO, Munchly Inc. -- You rece

Deleting sessions without Request object

2010-07-09 Thread Greg Pelly
admin app and manually delete a user's entry? Thanks, Greg -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django

virtual currency / check-in apps

2010-06-22 Thread Greg Pelly
Can anyone recommend any apps/tools for implementing either virtual currency or "check-ins" in Django? Thanks, Greg -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@

Re: Query Posts By Date

2010-05-30 Thread greg
ear=year, > publish_date__month=month). > -Justin > > On May 30, 12:34 am, greg wrote: > > > Hello, > > > I'm (almost) done coding up my blog in Django. > > > Right now I'm working to implement a search by date function. So my > > class Post h

Query Posts By Date

2010-05-30 Thread greg
Hello, I'm (almost) done coding up my blog in Django. Right now I'm working to implement a search by date function. So my class Post has a DateTimeField() called publish_date. For the date search, I want to put two dropdown boxes on the web-page so the users can pick a Month and Year and then it

"select for update" with models

2010-05-18 Thread Greg Pelly
705 Has anyone successfully used this code in a production environment? Any workarounds that people can think of? Greg -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com.

Re: How do I manually set the "GROUP BY" for a django queryset?

2010-02-15 Thread Greg Brown
Max('application__creation_date'), ).order_by('-application__creation_date__max').select_related() but that raises FieldError: Invalid field name: 'userprofile__ird_number' Greg On 16 February 2010 10:13, Dj Gilcrease wrote: > On Mon, Feb 15, 2010 at 1:43 PM, Greg B

Re: How do I manually set the "GROUP BY" for a django queryset?

2010-02-15 Thread Greg Brown
Max('user__application__creation_date'), ).order_by('-user__application__creation_date__max') I'm beginning to think it might be a bug - because UserProfile and User are joined by a one-to-one relationship, it's sufficient to group by one of their primary keys, an

How do I manually set the "GROUP BY" for a django queryset?

2010-02-14 Thread Greg
I have a large-ish query which is taking ~10 seconds to run, but I can get it down to less than a second by changing the group by part of the query from GROUP BY `refunds_userprofile`.`ird_number` , `auth_user`.`first_name` , `auth_user`.`last_name` , `refunds_userprofile`.`user_id` , `auth_us

Re: Help about models

2009-11-08 Thread Greg Brown
What you need is to keep your Education model as is (with no Lawyer Foreignkey) and add a ManyToManyField on your Lawyer class pointing to Education. Then you can go Lawyer.objects.filter(education__school='...') I think that will solve your problem Greg 2009/11/9 Zeynel : > &

Re: Django admin stops showing all apps

2009-11-04 Thread Greg Brown
this, the model doesn't show up in the admin homepage. The related content still shows in the front end of the site though. I'm a bit confused, but I've refactored the code so the offending import isn't required, and so far so good. Greg 2009/11/5 Diego Ucha : > > Hel

Django admin stops showing all apps

2009-11-01 Thread Greg
.handlers.wsgi import WSGIHandler > > os.environ['DJANGO_SETTINGS_MODULE'] = 'nzmusic.settings' > os.environ['LD_LIBRARY_PATH'] = '/PATH/lib' > application = WSGIHandler() Thanks, Greg --~--~-~--~~~---~--~~

Re: What JavaScript framework do you use and why?

2009-09-29 Thread Greg Fuller
In addition to mochaui,there's jxlib for mootools: http://jxlib.org/. On Sep 29, 3:12 am, Sid wrote: > You might wanna check out -http://mochaui.com/demo/if you're > planning to use MooTools. > Although i haven't used it yet, but it looks awesome and i haven't > found a  UI framework for jQuery

how to efficiently use many to many relationships with through tables

2009-09-14 Thread Greg Aumann
I am trying to write my first django app and am unclear about good ways to deal with many to many relationships with through tables. My app is like a bibliography but with lots of links between entries in the bibliography. For example, I want to store links to all the entries cited by other entrie

Re: Django Project Management App

2009-09-13 Thread Greg Brown
ss, albeit much simpler - per-project todo lists, time tracking, and invoice generation are pretty much all it can do for now. Anyway, once I've found some time to clean it up, I'll unleash it on the world and see what happens... Cheers, Greg 2009/9/11 Thomas Guettler : > > Greg

Django Project Management App

2009-09-10 Thread Greg
x27;t seem to be any out there. Any thoughts? Greg --~--~-~--~~~---~--~~ 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

Django POST data errors

2009-08-30 Thread Greg
h) Does anyone have any ideas on what might be causing this? The form has one image upload field, otherwise it's just select boxes and text inputs. Thanks in advance, Greg --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Goog

Re: Non-intrusive way to authenticate phpBB against Django

2009-08-04 Thread Greg Fuller
Thanks! I suspect I will need this soon. On Aug 4, 12:25 pm, Chris McCormick wrote: > Hi All, > > Just uploaded this:http://code.google.com/p/phpbb-json-auth/ > > Hope it's useful to someone else. > > Best, > > Chris. > > ---http://mccormick.cx --~--~-~--~~--

Re: templatetag issue

2009-07-29 Thread Greg Fuller
Are you missing a __init__.py in the tags directory? On Jul 29, 7:57 am, Daymien wrote: > Hallo, > > I created a templatetag, wich I use to display some notes on admin > index template. > With the bildin develop webserver all works fine. > > But when I start the apache server with mod_wsgi or

Re: Empty [] using objects.all() on legacy database

2009-06-23 Thread Greg Corey
Ok. I will work on opening a ticket based on your recommendation, though I will not have your depth of analysis on the problem. Mind if I quote your most recent explanation if needed? Greg On Tue, Jun 23, 2009 at 8:41 AM, Karen Tracey wrote: > On Mon, Jun 22, 2009 at 2:19 PM, Erik Vor

Re: Empty [] using objects.all() on legacy database

2009-06-22 Thread Greg Corey
I figured it wasn't a bug and I just had to do the right escape sequence, but Karen mentioned that it might be a bug. Guess not. Hope this helps someone else in the future. Greg On Mon, Jun 22, 2009 at 12:19 PM, Erik Vorhes wrote: > > On Mon, Jun 22, 2009 at 12:52 PM, Greg

Re: Empty [] using objects.all() on legacy database

2009-06-22 Thread Greg Corey
Karen, the double % ( i.e. 'discount%%') worked. Is this a big enough bug that it should be reported? I'm not sure what is a bug and what is just my ignorance. Thank you sooo much for the help. Greg On Fri, Jun 19, 2009 at 8:09 PM, Greg Corey wrote: > I will try that tomorro

Re: Empty [] using objects.all() on legacy database

2009-06-19 Thread Greg Corey
I will try that tomorrow and let you know. The DB is an old Microsoft Access database that was then migrated to MySQL. It was designed by a definite novice so it has quirks, but it still pumps along. It is a DB of testing results for our small laboratory. Greg On Fri, Jun 19, 2009 at 8:00 PM

Re: Webpy vs Django [and how to ask questions the smart way]

2009-04-22 Thread Greg Fuller
>> I'm not sure where you got Web2Py from Well, it was mentioned in the reply before my first reply, which is why I picked up on it. It's here: http://web2py.com/ webpy is here: http://webpy.org/ On Apr 22, 2:04 pm, Phil Mocek wrote: > On Wed, Apr 22, 2009 at 07:46:48PM +0200, Stef Mientki wro

Re: Webpy vs Django

2009-04-22 Thread Greg Fuller
Oops, webpy not web2py. My bad. On Apr 22, 1:43 pm, Greg Fuller wrote: > I flirted with Web2py for a while, but came back to Django. > > Web2py has some compelling features, including: > > * ORM supports Google App Engine  (with limitations of course). > > * Distributio

  1   2   3   4   5   >