django...@googlegroups.com

2023-04-14 Thread WILSON TALENGA
Hello, i have an issue with my django project, the created students are not reflecting when i run the server? below is my views.py and index.html what could the issue be? -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this

Re: Report a Django bug how

2023-04-14 Thread WILSON TALENGA
Hey guys, i need help, i have created my django project, added students to the system as admin but they don't reflect when i run the server. what could the issue be. below is views.py and index.html On Friday, April 14, 2023 at 11:07:25 AM UTC+3 Kasper Laudrup wrote: > On 14/04/2023 01.06, Micha

Re: Invite to join WhatsApp group

2022-08-08 Thread Wilson De Caro Puertas
Hi, how are you? The group is full El vie., 5 de agosto de 2022 10:47 a. m., Satyajit Barik < satyajitbarik@gmail.com> escribió: > Hey, > > Join in Whatsapp python group using the below link to get solve your > Python and Django related problems. > > https://chat.whatsapp.com/Bq2jcxLJVG50v9W

Re: Debug=False , heroku static files missing

2021-04-16 Thread sherry wilson
Use whitenoice On Sat, 17 Apr 2021, 5:15 am Emran Ibn Shayed, wrote: > When I set Debug=False in setting.py , images got missing from my app on > heroku. how do I solve it. > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To unsubscribe

Re: can anyone help me

2020-08-31 Thread sherry wilson
contact on whatsapp i will clear your issues +916238639239 if its not yet cleared On Mon, Aug 31, 2020 at 11:45 AM Deepraj Devikar wrote: > yes you have to forgot upload_to in models.py imagefield > > you can refer my repository > https://github.com/Deepraj-devikar/image-upload-react-django > >

How to Run script on remote server from Django Webserver - Help needed

2020-05-12 Thread Wilson Duarte
Hi, I prefer developer this solution, using REST API, it is more elegante. -- 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...@googlegroup

Re: stack

2020-04-20 Thread Tim Wilson
ango-users+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/django-users/CALFh0xExmi-KVt%2Bh0uxwUG_4MC94Ev0uGMVzEkfMXPbAk8LCxA%40mail.gmail.com > > <https://groups.google.com/d/msgid/django-users/CALFh0xExmi-KVt%2Bh0uxw

Re: user visit count

2020-04-15 Thread Tim Wilson
e%3Dgx4YnJj_%2BWLuVD-iTaeNy0BhMR4U1_bAXa93ObAMg%40mail.gmail.com > > <https://groups.google.com/d/msgid/django-users/CAJY8mfxe%3Dgx4YnJj_%2BWLuVD-iTaeNy0BhMR4U1_bAXa93ObAMg%40mail.gmail.com?utm_medium=email&utm_source=footer>. -- Tim Wilson President, Savvy Technology Group phone: 612-599-

Scanning Uploaded Files

2020-04-13 Thread 'Aaron Wilson' via Django users
What is the recommended method to scan uploaded files for viruses? I see a lot of information about pyclamd which appears to be unmaintained. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving ema

Send endpoint commands through runserver

2017-05-26 Thread U.G. Wilson
Is it possible to send endpoint commands through runserver? In daphne I can do this: daphne -v2 -e ssl:443:privateKey=key.pem:certKey=cert.pem main.asgi: channel_layer but I have to have a worker in a separate process and run redis. If I could do something like this: python manage.py runserver

Re: Access request body in the django.request logger

2016-11-07 Thread Justin Wilson
Sorry, I had those reversed. It works find WITH uWSGI, and fails with the Django dev server. On Monday, November 7, 2016 at 2:48:14 PM UTC-7, Justin Wilson wrote: > > Stumbled across this post while trying to solve the same issue > *(we've had this issue since 1.10 release, but

Re: Access request body in the django.request logger

2016-11-07 Thread Justin Wilson
Stumbled across this post while trying to solve the same issue *(we've had this issue since 1.10 release, but have kept with 1.9 due to this issue).*We're only getting this with Django 1.10+ when running behind uWSGI. The issue goes away if we just run the Django dev server. On Thursday, Septem

uploadhandler.py comparing str with int

2015-04-07 Thread Jason Wilson
Line 167 in django/core/files/uploadhandler.py printing the type of the object settings.FILE_UPLOAD_MAX_MEMORY_SIZE shows this object is read as a string at this point in the code. Therefore, the comparison always returns False and self.activated is True ' ---

Re: Having LiveServerTestCase use same database as tests

2014-08-01 Thread Chris Wilson
Hi Phil, On Sunday, October 21, 2012 5:37:45 PM UTC+1, Phil Gyford wrote: > > No, I'm afraid not. I didn't get any replies (nor to a StackOverflow > question http://stackoverflow.com/q/12041315/250962 ) and haven't gone > back to try again. I'd tried everything I could think of already. Good >

"Connecting Small Biz with the World".

2011-03-12 Thread Melisa wilson
The site is called Alamead.com, helping small business owners market their goods/services efficiently and effectively. We will offering website design, logo design, face book page design for only $99. http://alamead.com/about-us -- You received this message because you are subscribed to the Goog

Re: Django CMS 2.1 Release Candidate 3 was just released!

2011-01-14 Thread Todd Wilson
nd of information was available in an overview document on the django-cms project homepage.) Todd Wilson Jonas Obrist wrote, on 01/14/2011 09:31 AM: > The django CMS core team just released the third release candidate for > version 2.1. > > Download: http://pypi.python.org/pypi/dja

Re: Django on a hosting service

2010-12-12 Thread Todd Wilson
any sort of virtualhost file? I honestly can't > say I've ever tried it with an .htaccess. It would be rather > inefficient because it would be read on every connection. I'm not > sure, but I think that might force a reload on every connection. > > -Mark > > On

Re: Django on a hosting service

2010-12-11 Thread Todd Wilson
elf with an .htaccess file? --Todd > On Dec 9, 8:56 pm, Todd Wilson wrote: >> A couple of weeks ago I sent the message quoted below to the list. One >> reader (Daniel Roseman) replied and suggested that I might not need to >> ask the hosting service to install anything, quoting

Re: Django on a hosting service

2010-12-09 Thread Todd Wilson
can be done with an .htaccess file, and how much I will have to ask them to do for me? Thanks, --Todd Todd Wilson wrote, on 11/27/2010 07:20 PM: > I'm helping some friends improve a portal website they have created > using PHP, but which would be ideal for Django, in the sense that a lot >

Choices vs. ForeignKeys (was: Django - Alternative to using NULLs? (for integer and FK fields).)

2010-11-29 Thread Todd Wilson
Mike Dewhirst wrote, on 11/29/2010 10:33 PM: > I'm keeping track of companies, divisions and people with their > relationships. For example, divisions can be traded between companies > and people consult to companies or own trading entities. I can also keep > track of pretty much any relationship o

Re: Django on a hosting service

2010-11-28 Thread Todd Wilson
In response to my question about deploying Django on a shared hosting service that doesn't seem to have the necessary Apache modules installed, ... Daniel Roseman wrote, on 11/28/2010 02:10 AM: > I've never tried this, but if I understand the documentation here > correctly: > http://docs.djangopro

Django on a hosting service

2010-11-27 Thread Todd Wilson
I'm helping some friends improve a portal website they have created using PHP, but which would be ideal for Django, in the sense that a lot of the work they've already done, and would like to do as they improve the site, would be easy to do in Django. They have a hosting contract with Intermedia (

Hosting multiple projects

2010-11-22 Thread Todd Wilson
I teach a course in which I have students developing unrelated Django projects on servers of their own choice. As we near the end of the semester, I would like to set up a single server where I can host all of these student projects together. I will obviously create a new user, as well as a new m

Re: Clean URL Design: List Views and Details Views

2009-04-17 Thread Col Wilson
/products/by-popularity/ /products/featured/ /products/page/5/ /products/add/ /products/elvis/ /product/in-the-ghetto/ /product/jail-house-rock/ /product/love-me-tender/ On Apr 16, 2:29 pm, Aidas Bendoraitis wrote: > Hello, > > Recently, we are solving a conceptual question of designing clean ur

Re: Authenication for django.views.generic Views

2009-04-16 Thread Col Wilson
Thanks all. I have some reading to do, but I have also noticed in the meantime that generic views docs (http://docs.djangoproject.com/en/dev/ ref/generic-views/#ref-generic-views) have a hook into the auth system. Look for 'login_required'. Having said that, I still have a bit of reading to do.

Authenication for django.views.generic Views

2009-04-16 Thread Col Wilson
I'm using generic views to render my pages (django.views.generic.date_based, django.views.generic.list_detail etc) and they're very handy. However, the app I'm trying to build would like a security and on reading the "User Authentication in Django" document, it just talks about adding authenticat

Re: Admin Inlines astray

2009-04-11 Thread Andy Wilson
fixed after trying all sorts of approaches I finally got it to work by chmod'ing o+r to the files under the django/contrib/admin directory. Most of them already had read permissions but I could see that a few didn't. a On Sat, 2009-04-11 at 19:58 +0100, Andy Wilson wrote: > p

Re: Admin Inlines astray

2009-04-11 Thread Andy Wilson
ps. I used the 'song' and 'recording' models as an example, in fact I have several apps that use inlines, and on the one installation they are missing in every case. No errors are thrown and I can see nothing relevant in the logs. On Sat, 2009-04-11 at 19:50 +0100, Andy

Admin Inlines astray

2009-04-11 Thread Andy Wilson
has anyone any idea why the inlines might go missing? I have a model 'song' and a model 'recording'. I've created a recordingInline class, and in the modelAdmin I set: inlines = [recordingInline] this all works fine on my Ubuntu installation running python 2.5.2 and django 1.0.2, but on another

Combining Model Forms

2009-03-05 Thread Andy Wilson
ld be applied to both instances. -- [][][] Andy Wilson| mob: +44 (0)7739 908 253 [][] Managing Director | tel: +44 (0)20 7729 7060 [] [] LShift Ltd | web: www.lshift.net --~--~-~--~~~---~--~~ You received this message because you are subscri

Populating list_display with data from two models?

2009-02-26 Thread Jamie Richard Wilson
I've extended the User model with a UserPofile model and have inline editing working. Setup is something like this: class UserProfile(models.Model): user = models.ForeignKey( User, unique=True, ) position = models.ForeignKey(Position) ...etc... I need a lis

Re: InlineModelAdmin objects question

2009-02-25 Thread Jamie Richard Wilson
This might answer your question: http://groups.google.com/group/django-developers/browse_thread/thread/45bce29f331acb5e Kevin Coyner wrote: > I am using the Auth system in django and have a separate app People > that I'm using to keep more detailed info (i.e. address, phone, etc) > on my users.

Admin interface for user management

2009-02-25 Thread Jamie Richard Wilson
I'm working on an online newsroom project and have a need to extend the user profile beyond the included basics. I also need to grant permissions to allow the online editorial staff to create new user accounts to associate with new content if the account doesn't already exist. In most cases there

Anyone have any good solutions for site navigation?

2008-10-24 Thread Matt Wilson
My site has a global-navigation header, with links to 5 sections of the site. I highlight the section that the viewer is currently viewing in the global header. Other than the highlighting, the header is the same on every page of the site. Then I also have a "local" navigation that shows differ

Are a lot of people using SQLAlchemy with Django?

2008-10-01 Thread Matt Wilson
I've been working with TurboGears 1.0 (kid and SQLObject) and I have some time to do a rewrite. I'm considering either going to TG 2.0 (genshi and SQLAlchemy) or Django. I'd love to be able to use SQLAlchemy with Django. I've heard some people are working with this, but I want to know if people

relationships problem

2008-05-21 Thread Col Wilson
I'm brand new to django from rails, and I'm a bit stuck trying to get relationships to work. RawPlaces table is full of place names and data already. My model looks like this: from django.db import models import sys, os class RawPlace(models.Model): name = models.CharField(max_length=64

Django experts wanted

2008-05-19 Thread Jim R. Wilson
engagements or user groups at which you've presented * Significant contributions to documentation * Other? (I'm sure I didn't think of everything) I'll be happy to answer any questions, and I look forward to hearing from you! -- Jim R. Wilson (jimbojw) --~--~-~--~---

Access control

2008-03-29 Thread Wilson Acha
Hello, django have any library that allows include a login and enable restrict access to different parts of the application according to roles and / or profiles Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: tutorial 01

2008-02-09 Thread Wilson MacGyver
Jeff Anderson wrote: > the command isn't found because it isn't in your path. > Are you sure you installed it correctly? > > On mac os x, I recommend installing django through fink if you are new > to *nix commands and shells and the like. > > You can also change to the directory that has djang

Re: i'm tired

2008-02-09 Thread Wilson MacGyver
newbiedoobiedoo wrote: > please take your instructions and put them up somewhere OFFICIAL, > because > I was following directions that were MUCH more complicated. > > I just did what you said... and now I have django. I will proceed to > try and set up Mysql > now, so that I can get to testing t

Re: i'm tired

2008-02-09 Thread Wilson MacGyver
I think you made it more complex than it really has to be, especially for learning. For a straight OSX install when I first started messing around with django. here is what I did. Step 1: download and install macpython from the python.org url is http://www.python.org/ftp/python/2.5.1/python-2.5.

Re: Template tags and python paths

2008-02-04 Thread Jon Wilson
/to/trunk/myapp2/templatetags') but like you said earlier, it really should work by default. :p -- Jon Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this grou

Re: Template tags and python paths

2008-02-04 Thread Jon Wilson
he project path included like with apache kind of defeats that purpose. However, at least in the mean time, as you had found, it works by calling that. I'll have to look and see if there is a way to fix the templatetags loading to fix that, maybe by overriding it somewhere. ... -- Jon Wilson

Re: Template tags and python paths

2008-02-04 Thread Jon Wilson
- models.py > - settings.py > - etc... > > > The problem is with "myapp2_tags.py". That file starts with this: > from myapp2.models import MyModel > I've found that in a production environme

Re: using re.sub with unicode string in response middleware

2008-01-08 Thread Gary Wilson Jr.
Malcolm Tredinnick wrote: > Hey Gary, > > On Tue, 2008-01-08 at 00:35 -0600, Gary Wilson Jr. wrote: > [...] >> So, looking at a couple places in Django trunk where response.content is >> used, >> these look like bugs: >> >> >> django.contrib

Re: using re.sub with unicode string in response middleware

2008-01-07 Thread Gary Wilson Jr.
Malcolm Tredinnick wrote: > On Mon, 2008-01-07 at 18:28 -0600, Gary Wilson Jr. wrote: >> Malcolm Tredinnick wrote: >>> On Sun, 2008-01-06 at 15:25 -0600, Gary Wilson Jr. wrote: >>>> It appears that at this point, response.content is a utf8-encoded >>&g

Re: using re.sub with unicode string in response middleware

2008-01-07 Thread Gary Wilson Jr.
Malcolm Tredinnick wrote: > On Sun, 2008-01-06 at 15:25 -0600, Gary Wilson Jr. wrote: >> It appears that at this point, response.content is a utf8-encoded bytestring. >> I'm playing with a response middleware doing something like: >> >> MY_RE.sub(u'%s' %

using re.sub with unicode string in response middleware

2008-01-06 Thread Gary Wilson Jr.
It appears that at this point, response.content is a utf8-encoded bytestring. I'm playing with a response middleware doing something like: MY_RE.sub(u'%s' % text, response.content) which raises a UnicodeDecodeError if response.content contains non-ascii. I understand that the strings need to be

Re: Need help creating a composite database index

2008-01-03 Thread Matt Wilson
Thanks! On Jan 3, 1:32 pm, Rajesh Dhawan <[EMAIL PROTECTED]> wrote: > Hi, > > On Jan 3, 12:28 pm, Matt Wilson <[EMAIL PROTECTED]> wrote: > > > This is the postgresql index I want to create: > > > CREATE UNIQUE INDEX v2category_nameIndex ON v2category

Need help creating a composite database index

2008-01-03 Thread Matt Wilson
This is the postgresql index I want to create: CREATE UNIQUE INDEX v2category_nameIndex ON v2category (v2organization_id, parent_category, lower(name)); How do I create this index with the Django model? TIA Matt --~--~-~--~~~---~--~~ You received this message be

Re: learning django and python

2007-11-14 Thread Wilson MacGyver
I don't know about the Instant Django on OSX, but Django itself is very easy. I use the python universal binary from http://www.python.org/download then download Django, untar it, and go into the extracted Django directory, run "sudo python setup.py install" That's it, Django is installed and r

Re: Request for Leopard users

2007-10-31 Thread Wilson MacGyver
On 11/1/07, Karen Tracey <[EMAIL PROTECTED]> wrote: > On 11/1/07, Wilson MacGyver <[EMAIL PROTECTED]> wrote: > > > > I too can confirm this. > > > > echo $LANG gives en_US.UTF-8 > > > > but using both /usr/bin/python which is the one that came

Re: Request for Leopard users

2007-10-31 Thread Wilson MacGyver
I too can confirm this. echo $LANG gives en_US.UTF-8 but using both /usr/bin/python which is the one that came with OSX Leopard, or using the MacPython downloaded from www.python.org at the path /Library/Frameworks/Python.framework/Versions/Current/bin/python in both cases, >>> import locale >

Re: @url tag - getting rid of urlpatterns

2007-08-30 Thread Gary Wilson
On Aug 30, 3:08 am, Ilya Semenov <[EMAIL PROTECTED]> wrote: > Second, I think the use of generic views is over-estimated. I tend to agree a bit here. I like having all my URLs in one file and all my views in another. Using generic views usually clutters the urls file too much for me. Generic v

How to reuse a component in numerous templates, like turbogears widgets?

2007-08-15 Thread Matt Wilson
I'm working on a django view for my office's homemade ticket-based workflow system. I have a view that shows all tickets assigned to each employee. I also have a view that shows all tickets attached to parent tickets. I want to define just once how to render any arbitrary lists of tickets into

Re: There's got to be a better way

2007-07-27 Thread Gary Wilson
On Jul 26, 1:22 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > In my view, I have: > future_events = Event.objects.filter(start_date__gte=now) > pacific_events = future_events.filter(club__region='Pacific') > rocky_mountain_events = future_events.filter(club__region='Rocky > Mountain

Re: a very slow view, > 30secs to load

2007-03-29 Thread Gary Wilson
On Mar 29, 2:26 pm, "Milan Andric" <[EMAIL PROTECTED]> wrote: > But in the dev environment I can see pretty well that the view is > functioning very quickly. So your hunch about the problem lying in > the templates is probably right. If you aren't seeing the slowdown on your dev server, then you

newforms and form_from_instance

2007-03-28 Thread Gary Wilson
Starting to play around with newforms and I am trying to create a form with fewer fields than the model and post-fill those fields in the view. With the following example models and form: class Book(models.Model): author = models.CharField(maxlength=100, blank=True) title = models.C

Re: django admin - too many sql-queries

2007-02-18 Thread Gary Wilson
On Feb 18, 10:48 am, "Honza Král" <[EMAIL PROTECTED]> wrote: > On 2/18/07, Tom? Pokorn? <[EMAIL PROTECTED]> wrote: > > > models.py attached. > > > On Sun, 2007-02-18 at 16:51 +0100, Honza Kr?l wrote: > > > > that's odd can you post your Model definition? > > definitely odd, list_select_related ap

Windows install

2007-02-08 Thread Dale Wilson
Hi, As a newbie to Django I failed to read the install doc correctly and tried to run setup.py rather than simply checking django out of svn directly into site-packages. Reading the doc more carefully solved my problem, but in the meantime I found a "buglet" in setup.py that should probably be f

duplicate error messages above FileField in admin interface

2006-11-14 Thread Gary Wilson
I've got a FieldField using the RequiredIfOtherFieldNotGiven validator, and when I try to save the object without filling in the "other field," I get two duplicate error messages above the file upload box. I assume this has something to do with FileField really using two form field widgets, but i

Re: Dojo vs Mochikit for Django dev?

2006-10-17 Thread Wilson Miner
Dojo is designed to be flexible, but can be too heavyweight for small tasks. Mochikit is designed to be super-lightweight but has a much more limited scope as far as what it's capable of. On 10/17/06, iain duncan <[EMAIL PROTECTED]> wrote: > > I have not dug into either Dojo or Mochikit yet and a

Re: Django and Media Temple Grid Server

2006-10-17 Thread Wilson Miner
Sounds like they're leaning toward adding a Django option in the future, but I think we can help speed them along by letting them know there's plenty of demand out there. They suggest contacting their sales staff to let them know if you'd be interested in a Django grid server: http://www.mediatem

Re: Re: Why I'm giving up on Django

2006-09-29 Thread Wilson Miner
That was actually a conscious decision to keep from needing support images for the debug pages. I wanted them to be completely self-contained, which is why we used the unicode glyph for the disclosure triangle (a pretty universal UI indicator) to indicate that those sections could be expanded. On

Re: Importing models from each other.

2006-09-27 Thread Gary Wilson
Gacha wrote: > I have two model files, the first is: > --- > from proj.base.models import Choice > > class User(meta.Model): > ... > param = model.ForeignKey(Choice) > >

Re: Setting up an new app with a models directory

2006-09-27 Thread Gary Wilson
Malcolm Tredinnick wrote: > You also need to have the model in the __all__ export of > models/__init__.py, otherwise it doesn't get imported into the > appropriate namespace as part of "import myapp.models". Well, adding the model modules to __all__ doesn't work either (isn't this for when you do

Re: Setting up an new app with a models directory

2006-09-27 Thread Gary Wilson
Malcolm Tredinnick wrote: > When you have models in a deeper structure like this, you need to > explicitly tell the model what the app name is. You do this as follows: > > class SimpleTest(models.Model): > ... > class Meta: > app_label="appfolder" > > This

Re: Strange Error when 404 or 500 error

2006-09-18 Thread Gary Wilson
[EMAIL PROTECTED] wrote: > File "/usr/lib/python2.4/site-packages/django/views/debug.py", line > 144, in technical_404_response > t = Template(TECHNICAL_404_TEMPLATE, name='Technical 404 template') > > TypeError: __init__() got an unexpected keyword argument 'name' > <---

Re: Mac vs. PC for Django work.

2006-09-13 Thread Wilson MacGyver
On OSX, one of the first thing I do is download and installthe latest Python from http://www.python.org/downloadIt's straight forward and let you have up to date python so you can avoid problems like that.On 9/13/06, Eric Walstad <[EMAIL PROTECTED]> wrote: One of the developers on my team works on

Re: group traffic

2006-08-31 Thread Gary Wilson
A Django forum would be another option. IMO, forums have more of a community feel, and are also probably a little more friendly for newbies. And, unlike with this mailing list, you would be able to reply to posts that are more than 30 days old. --~--~-~--~~~---~--~-

Re: viewing generated SQL without running the query

2006-08-29 Thread Gary Wilson
Malcolm Tredinnick wrote: > On Tue, 2006-08-29 at 03:53 +, Gary Wilson wrote: > > I see that there is a _get_sql_clause() method, but is there a function > > that will return the constructed query string? > > Deja vu. I tried to implement something like this a little wh

Re: python sets and objects returned in queries

2006-08-29 Thread Gary Wilson
Ivan Sagalaev wrote: > Gary Wilson wrote: > > Why can't objects be used in python sets? Example: > > > >>>> [u.username for u in User.objects.all()] > > ['bar', 'foo', 'foobar'] > >>>> a = User.objects.f

python sets and objects returned in queries

2006-08-28 Thread Gary Wilson
Why can't objects be used in python sets? Example: >>> [u.username for u in User.objects.all()] ['bar', 'foo', 'foobar'] >>> a = User.objects.filter(username__contains='foo') >>> b = User.objects.filter(username__contains='bar') >>> set.intersection(set(a), set(b)) set([]) but... >>> a [, ] >>

Re: Finding entries with multiple tags

2006-08-28 Thread Gary Wilson
[EMAIL PROTECTED] wrote: > > def tags(request, url): > > # Don't need the last item in the list since it will > > # always be an empty string since Django will append > > # a slash character to the end of URLs by default. > > tags = url.split('/')[:-1] > > posts = Post.objects.

viewing generated SQL without running the query

2006-08-28 Thread Gary Wilson
I see that there is a _get_sql_clause() method, but is there a function that will return the constructed query string? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, sen

Re: Filter "date" and FormFieldWrapper attribute error

2006-08-27 Thread Gary Wilson
Andres Luga wrote: > when displaying a form for a new object, I'm trying to set a default > value for a date field using a filter in a template, like so: > > > {{ form.somefield|date:"Y-m-d" }} > > This gives me an error: > 'FormFieldWrapper' object has no attribute 'year'. > What am I doing wron

Re: Finding entries with multiple tags

2006-08-27 Thread Gary Wilson
[EMAIL PROTECTED] wrote: > Hello - > > I'm playing around with a blog application and I want it to have a > tagging feature. I have the usual ManyToMany relationship set up with > Post and Tag (I'm not going to past my model since I think everyone is > familiar with this kind of setup). > > I have

Re: SQL initial data for auth

2006-08-27 Thread Gary Wilson
> Hence, I've put a list of users into my 'auth/sql/User.sql' file, but > ./manage.py syncdb doesn't seem to pick up the existence of the file. > I have no doubt it's in the wrong place, but my question is which is > the correct place? :-) I think the file needs to be placed at django/contrib/aut

Re: Limit view to group members: what function for the @user_passes_test decorator?

2006-08-27 Thread Gary Wilson
cyberco wrote: > I want to limit a view to certain group members, so I'm using the > following decorator: > > @user_passes_test(lambda u: Group.objects.get(name='admin') in > u.groups.all(), login_url='/accounts/login/') > > This seems a little verbose. Is there a better way? user_passes_test is

Re: database newby question

2006-08-26 Thread Gary Wilson
[EMAIL PROTECTED] wrote: > i imported 2 users in the model LoginInfo the first is lab_id = '100' > and the second is lab_id = '200' > how do i put in the data in the class Modules ? > > what i thought i had to do was first create a object from the LoginInfo > class like > p = LoginInfo.objects.get

Re: customizing admin templates

2006-08-01 Thread Wilson Miner
Try putting this in your main base_site.html template: {{ app.name|default:"Django" }} Administration I'm not sure if the app info is available in the changelist/change form contexts, but it's worth a shot. On 8/1/06, Tamara D. Snyder <[EMAIL PROTECTED]> wrote: > > I'm sorry to keep bothering t

Re: How would Django handle a large number of records

2006-06-21 Thread Wilson Miner
> The World Online admin > interface (where Django was born) has a number of content types with > tens of thousands -- if not hundreds of thousands -- of records. 393,181 stories and counting... On 6/21/06, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > On 6/21/06, Patrick Anderson <[EMAIL PROTE

Re: Template variables

2006-06-20 Thread Wilson Miner
Hi Patrick, You might find some helpful responses in this thread: http://groups.google.com/group/django-users/browse_frm/thread/50ee1c147854769/a79890af3059229d?q=menu&rnum=3#a79890af3059229d On 6/20/06, Patrick <[EMAIL PROTECTED]> wrote: > > Hi i'm newbie and i want to publish my Django websit

Re: Divide list in a template

2006-06-17 Thread Wilson Miner
I don't know of a way to do this by a calculated fraction of the total items in the list, but you can use the slice filter to break it up into groups of a set number: {% for object in object_list|slice:":5" %} {% for object in object_list|slice:"5:10" %} etc. There's also a handy trick if you

Re: Django Article on Developerworks

2006-06-07 Thread Wilson Miner
Ha - that's great! On 6/6/06, Ian Maurer <[EMAIL PROTECTED]> wrote: Thanks guys for the feedback. Hopefully the changes will getincorporated tomorrow.Also, I like the art IBM put together for the front page of the linux section... http://www-128.ibm.com/developerworks/linux/I hope it meets with the

Re: Change cols and row in generic update page textarea

2006-06-06 Thread Wilson Miner
Or specify the dimensions in ems if you want a closer equivalent to rows and columns. On 6/6/06, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > On 6/6/06, tomass <[EMAIL PROTECTED]> wrote: > > Wondering if there's a way to specify how many rows and columns the > > generic update page uses for a t

Re: Additional controls in admin interface?

2006-06-06 Thread Wilson Miner
y the field you specify: http://www.djangoproject.com/documentation/model_api/#ordering Cheers, Wilson On 6/6/06, James Mulholland <[EMAIL PROTECTED]> wrote: > > Excuse me if this is a daft question -- I'm new to both Python and > Django, but I guess it's a credit to b

Re: confused again: a "home page" can't be some special case

2006-06-06 Thread Wilson Miner
Another option is to create it as a flat page with the url "/" and pull in all your content using template tags. On 6/6/06, James Bennett <[EMAIL PROTECTED]> wrote: > > On 6/6/06, Douglas Campos <[EMAIL PROTECTED]> wrote: > > 1) create a homepage app to aggregate it all (don't be worried, it can

Re: Searching on a calculated value

2006-05-25 Thread Gary Wilson
Adrian Holovaty wrote: > You're best off searching by the exact fields rather than messing with > derived fields. Would you offer some insight please? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users"

Re: Searching on a calculated value

2006-05-24 Thread Gary Wilson
Adrian Holovaty wrote: > On 5/23/06, Gary Wilson <[EMAIL PROTECTED]> wrote: > > Yes, I guess I could split the text entered and then do a search for > > each word in both first_name and last_name like the admin interface > > does... just seems like this would return ma

Re: How fix the "feature" of not serving static files?

2006-05-24 Thread Wilson Miner
Seems like you would get better results from your time by writing a script to replace relative paths with absolute urls. On 5/24/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Ok. > > Like I say, I understand the reason in separate the dynamic from the > static, despite the fact this is the

Re: How fix the "feature" of not serving static files?

2006-05-23 Thread Wilson Miner
Is there a particular reason you can't just use the full media url in your templates? ie. "http://media.coolsite.com/files/css/shadow.css"; instead of "../css/shadow.css"? On 5/23/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > I'm building a CMS for my internal use... I own a web developmen

Re: Searching on a calculated value

2006-05-23 Thread Gary Wilson
Waylan Limberg wrote: > For an example of how the admin app does this see search_fields > http://www.djangoproject.com/documentation/model_api/#search-fields > > -- > > Waylan Limberg > [EMAIL PROTECTED] Yes, I guess I could split the text entered and then do a search for each word in both f

Searching on a calculated value

2006-05-23 Thread Gary Wilson
calculated full name in the database)? Something like... User.objects.filter(get_full_name__iequals="Gary Wilson") --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To pos

Re: authentication style select box

2006-05-17 Thread Wilson Miner
Sean, You're looking for the filter_interface argument for the ManyToManyField: http://www.djangoproject.com/documentation/model_api/#many-to-many-relationships On 5/17/06, Sean <[EMAIL PROTECTED]> wrote: > > Hi, > I was wondering if the searchable select box as used in the add user > interface

Re: sites in django.contrib ?

2006-05-10 Thread Wilson Miner
It's generally used as a ManyToMany in other apps to assign objects (blog posts, stories, e.g.) to be published to one or more sites at a time. On 5/10/06, Zeuxis <[EMAIL PROTECTED]> wrote: > > Hi, > > I wonder what it the purpose of the sites app in django.contrib ? It > does not > seem

Re: Comment options not appearing in admin

2006-05-10 Thread Wilson Miner
With comments installed you can use the comments template tags to attach a comment thread to any object in the template. For example, for a hypothetical blog post, the template code to get the list of free comments for the object might look like this: {% load comments %} {% get_free_comment_list

Re: Django-Powered Game in Beta - MyDarkSecret.com

2006-05-09 Thread Wilson Miner
Cool! Very interesting to see a totally different kind of Django app. I'll have to try it out. On 5/8/06, ZebZiggle <[EMAIL PROTECTED]> wrote: > > Hey everyone! > > As you may or may not know (or are sick of hearing about) ... I've > been dabbling on a web-game for a while now. It's called "My Da

Re: Django Admin CSS Problems in Safari

2006-05-09 Thread Wilson Miner
I can confirm that i'm seeing this padding issue in safari and the > > webkit inspector shows: > > padding-top:10px; > > padding-right:20px; > > padding-bottom:10px; > > padding-left:20px; > > > > I've been seeing it since wilson did the split o

Re: Admin Functionality Enhancement

2006-05-08 Thread Wilson Miner
This is actually along the lines of some of the big-picture admin changes I've been thinking about. Another side effect is that if each app has it's own dashboard/changelist/filters, it also opens up the actual index page for some additional functionality. On 5/8/06, Rudolph <[EMAIL PROTECTED]> w

  1   2   >