Sending a filtered array to HTML

2009-03-13 Thread Ted
I want to take a table like People with entires id, Name, Sex and send it to HTML to do something like this: {% for name in people.filter(sex='M') %} Male: {{ People.Name }} {% end %} But, it's too late to do this in HTML. So, I'm trying to create an array of pre-sorted lists in views.py to sen

Re: Django Registration password reset problem

2010-10-07 Thread Ted
e('registration.auth_views.password_reset_done') 144 - post_reset_redirect = reverse('registration.auth_views.password_reset_complete') 177 - post_change_redirect = reverse('registration.auth_views.password_change_done') It also bears mentioning that name spacing registr

Re: UserProfile

2010-10-13 Thread Ted
request.user.get_profile().avatar_url Assuming you have set a AUTH_PROFILE_MODULE in settings, and send the request context when rendering. On Oct 13, 5:19 am, reduxdj wrote: > I have a simple use-case. I want the user's profile to be available to > the context instance. For instance, the user's

Admin "Bulk Edit"?

2010-10-16 Thread Ted
Is there a default option for this that I just haven't found in the docs? 2) If there isn't a default option, have you seen a recipe/community package that does this? 3) If no and no, can anyone offer advice on how that might be implemented? I haven't done much with the admin up to n

Re: Admin "Bulk Edit"?

2010-10-17 Thread Ted
I was imagining more select a subset then have a bulk action like delete. But, for this use case, list editable is sufficient. Thanks, Ted On Oct 16, 4:20 pm, ringemup wrote: > Does the list_editable feature not cover your use case? > > On Oct 16, 6:25 pm, Ted wrote: > > >

Re: e-commerce - credit cards

2010-10-21 Thread Ted
unique identifier. In the future, when you want to charge that customer's card you send the gateway the unique identifier instead of the full card. If you want to chat more about specifics, send me an email offline. Ted On Oct 21, 4:03 am, django_jedi wrote: > Hello all, > > Regar

Generic Views - do you use them?

2010-11-08 Thread Ted
What are their pros and cons? How often do you use them when you're coding? The more I code in django the less I find generic views to be useful shortcuts (direct to template being the exception). My biggest complaints are: * You don't end up saving many keystrokes unless you have 3 or more view

Re: There is no v0.92 or v0.95 release of Django

2006-05-18 Thread Ted
The best solution would be just to release 0.92 today, as is (unless it is fatally flawed which it doesn't seem to be) People know that it is not a major release since it is still a 0.xx release so nobody will complain about a few minor bugs. It is important not to scare off potential users just

Auth and Registration survey -- please help

2013-01-26 Thread Ted
me to fill out the survey. I'll be sharing results with respondents, if anyone is interested. https://www.surveymonkey.com/s/BYBXG59 Thanks, Ted -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send em

Re: ModelForm validation

2010-12-29 Thread Ted
setting the fields to "blank = True" in your model declaration. I believe this is the exact case for both a blank=True and a null=True model options. Blank is for form validation, Null is for database. Not a full solution, but perhaps gets you part of the way there. Ted On Dec 28, 12:2

Re: Number of Django powered sites?

2011-02-28 Thread Ted
I've found that using "django tutorial" and "django documentation" in google insights/trends does a pretty good job of filtering out the namespace noise. You can also append tutorial or documentation to the names of other frameworks to get an idea of relative trends.

Re: Cucumber for Python?

2009-11-07 Thread Ted Nyman
t that deter you :) http://www.pyccuracy.org/index.html <http://www.pyccuracy.org/index.html>http://github.com/heynemann/pyccuracy <http://github.com/heynemann/pyccuracy>Ted On Sat, Nov 7, 2009 at 8:52 PM, Phlip wrote: > > django-users group: > > At my last gig I grooved

Re: Generic Views - do you use them?

2010-12-10 Thread Ted Tieken
Class based generic views still have the major drawbacks of the previous version. They are a more powerful, more complicated version, but they're still a red-herring. Ted On Fri, Dec 10, 2010 at 9:37 AM, Rainy wrote: > On Dec 10, 4:04 am, Łukasz Rekucki wrote: >> You should try

Re: permalinks from cron job

2010-01-17 Thread Ted Nyman
More generally, in a crontab, you'll need to set both the PYTHONPATH and give the location of the relevant Django settings. -Ted On Jan 17, 2010, at 8:22 PM, "eric.frederich" wrote: Is there some setting somewhere to set the prefix? Can it be set via an environment var

"Unidentified Errors" message instead of ValidationError

2011-09-30 Thread Ted Gruenloh
Hey there. OK, trying to add a clean method to a ModelForm in Django.  I'm adding a simple raise statement just to see if it works, and instead of my message, I get "Unidentified Errors.  Please notify..." Here's my (simple) test: class ConfigurationForm(forms.ModelForm):     ...     def c

Re: Development Server Ignores IP-address Parameter

2015-07-16 Thread Ted Thomas
Jonathan, anotherdjangonewby, Thanks. I tried both suggestions, but there in no change in behavior. No matter what I do, the development server only takes requests at 127.0.0.1:8000. I am including my settings.py file below ( with altered secret_key): """ > Django settings

How to use Python Requests Module to upload images to Django Application?

2015-07-23 Thread Ted Thomas
I am developing a django application that primarily uses web browsers to upload scientific data that includes some image files. Currently, the application works fine when Firefox or Chrome are used. Both images and other data are correctly uploaded. Occasionally users need to upload larger am

Re: How to use Python Requests Module to upload images to Django Application?

2015-07-23 Thread Ted Thomas
My Python code started working after I changed on line. Changing: files_dct = {filename:fobj} to: files_dct = {('photo',(filename, fobj,'image/jpg'))} Now it works. My conjecture about the need for different HTTP-headers was wrong. The working code has not changed the headers receive

Re: Generic Views - do you use them?

2010-12-10 Thread R. Ted Tieken
>> Class based generic views still have the major drawbacks of the >> previous version.  They are a more powerful, more complicated version, >> but they're still a red-herring. > > Can you elaborate on this ? Taking your original concerns: Sure. First of all, I'm not opposed to class based views,