Re: "Recent Actions"

2006-08-06 Thread Carl Holm
Malcom, Not a problem - I now have two good suggestions. Regards, CL Malcolm Tredinnick wrote: >On Sun, 2006-08-06 at 20:15 -0500, Adrian Holovaty wrote: > > >>On 8/6/06, CL <[EMAIL PROTECTED]> wrote: >> >> >>>Is there a way to edit the "Recent Actions" list that appears on the >>>admin

Re: "Recent Actions"

2006-08-06 Thread Carl Holm
Adrian, Thanks - that's exactly what I was looking for. Regards, CL Adrian Holovaty wrote: >On 8/6/06, CL <[EMAIL PROTECTED]> wrote: > > >>Is there a way to edit the "Recent Actions" list that appears on the >>admin index page? >> >> > >Hey CL, > >If you don't want to deal directly with

Re: Django Can't Find 'Tag' Class

2006-08-06 Thread Malcolm Tredinnick
On Sun, 2006-08-06 at 19:48 -0700, Tyson Tate wrote: > I'm trying to add in per-tag feeds for my blog, but for some reason > Python refuses to "see" my Tag class, which is inside the same > models.py file that my Entry class in. > > Every time I visit "/feeds/tag/slug", I get the following

Django Can't Find 'Tag' Class

2006-08-06 Thread Tyson Tate
I'm trying to add in per-tag feeds for my blog, but for some reason Python refuses to "see" my Tag class, which is inside the same models.py file that my Entry class in. Every time I visit "/feeds/tag/slug", I get the following error: http://paste.e-scribe.com/1035/ Here's the related

Re: Work with FileField directly

2006-08-06 Thread bernie2004
Adam Seering wrote: > I'm trying to make a form that, among other things, allows a user to > upload one or more files (the number of files will vary; it's a form to > upload images that are missing on a vaguely-Wiki-like page). Each > uploaded file creates a new table entry; the non-FileFields

Re: Using custom forms with generic views

2006-08-06 Thread Malcolm Tredinnick
On Sat, 2006-08-05 at 08:36 -0700, jeffmikels wrote: > I'm trying to create a site that has entries of different types and > tags that can link to any type of entry. > > In my models, I have a > > tags = models.ManyToManyField(Tag, blank=True, > filter_interface=models.HORIZONTAL,

Re: multiple choices in model

2006-08-06 Thread Alan Green
On 8/5/06, Michael <[EMAIL PROTECTED]> wrote: > Hello, > > From dajngo documentaytion: > > > > A choices list looks like this: YEAR_IN_SCHOOL_CHOICES = ( > ('FR', 'Freshman'), > ('SO', 'Sophomore'), > ('JR', 'Junior'), > ('SR', 'Senior'), > ('GR', 'Graduate'), > ) > > Is it possible to have

Re: How can I use variables in included URLConf's before they are sent to views?

2006-08-06 Thread Ahmad Alhashemi
Ian Holsman wrote: > If I'm understanding your question correctly, you could write a function > similar to gen_pop_pattern (http://svn.zyons.python-hosting.com/trunk/ > zilbo/common/counter/urls.py ) Actually, I'm already doing something very similar. This is what my main (entry point) urls.py

Re: "Recent Actions"

2006-08-06 Thread Malcolm Tredinnick
On Sun, 2006-08-06 at 20:15 -0500, Adrian Holovaty wrote: > On 8/6/06, CL <[EMAIL PROTECTED]> wrote: > > Is there a way to edit the "Recent Actions" list that appears on the > > admin index page? > > Hey CL, > > If you don't want to deal directly with the database as Malcolm > suggested, you

Re: "Recent Actions"

2006-08-06 Thread Adrian Holovaty
On 8/6/06, CL <[EMAIL PROTECTED]> wrote: > Is there a way to edit the "Recent Actions" list that appears on the > admin index page? Hey CL, If you don't want to deal directly with the database as Malcolm suggested, you can use the Django database API. The model is

Re: How can I use variables in included URLConf's before they are sent to views?

2006-08-06 Thread Todd O'Bryan
On Aug 6, 2006, at 8:01 PM, Ahmad Alhashemi wrote: > > Todd O'Bryan wrote: >> A very straightforward way to do this would be to map the main url to >> a view-like function, build the queries you need, and then, based on >> the rest of the url, pass control to the actual view function you >>

Re: Django model -> DOT converter

2006-08-06 Thread limodou
On 8/7/06, Antonio Cavedoni <[EMAIL PROTECTED]> wrote: > > On 6 Aug 2006, at 15:10, limodou wrote: > > It seems that _meta.one_to_one_field is not a list or tuple. So for > > field in o._meta.one_to_one_field will be failed. And I think to > > deal with OneToOne relationship should just like deal

Re: Code to spawn a new, independent process

2006-08-06 Thread Corey Oordt
Martina, Mostly because I'm new to python and in my research no one mentioned it! You are right, this does look like a better fit. Live and learn! Corey On Aug 6, 2006, at 12:40 PM, oefe wrote: > > > Corey wrote: >> Hey everyone, >> >> I've seen references and questions in previous posts

Work with FileField directly

2006-08-06 Thread Adam Seering
I'm trying to make a form that, among other things, allows a user to upload one or more files (the number of files will vary; it's a form to upload images that are missing on a vaguely-Wiki-like page). Each uploaded file creates a new table entry; the non-FileFields in the table are

Re: Django model -> DOT converter

2006-08-06 Thread limodou
On 8/7/06, Antonio Cavedoni <[EMAIL PROTECTED]> wrote: > > On 6 Aug 2006, at 14:20, limodou wrote: > > And you can also add these code at the top of your script: > > > > import settings > > from django.core.management import setup_environ > > setup_environ(settings) > > > > So you don't need to

Re: How can I use variables in included URLConf's before they are sent to views?

2006-08-06 Thread Ahmad Alhashemi
Todd O'Bryan wrote: > A very straightforward way to do this would be to map the main url to > a view-like function, build the queries you need, and then, based on > the rest of the url, pass control to the actual view function you want. Is there an easy and supported way of passing control back

Re: How can I use variables in included URLConf's before they are sent to views?

2006-08-06 Thread [EMAIL PROTECTED]
Ahmad, do you perhaps mean something like this? ## URLconf (main) (r'^(?P[a-z]{2})/section/', include('myproject.myapp.urls')), ## URLconf (myapp) ... some logic that depends on ... (r'^list/?$', 'django.views.generic.list_detail.object_list', dict(info_dict)), I don't know a solution,

Re: problem with the structure of our site (sharing user-data)

2006-08-06 Thread Alan Green
On 8/4/06, patrickk <[EMAIL PROTECTED]> wrote: > we´d really appreciate some help with this problem: Hi Patrick, Here's a few thoughts. > 1. we´re having several sites sharing basic userdata (first name, > last name, username ...) - so every user can login to all of the > sites using the same

Re: How can I use variables in included URLConf's before they are sent to views?

2006-08-06 Thread Ian Holsman
If I'm understanding your question correctly, you could write a functionsimilar to gen_pop_pattern (http://svn.zyons.python-hosting.com/trunk/zilbo/common/counter/urls.py )and then include it alaurlpatterns += gen_pop_pattern( models='Conversation', extra_context=context,

Re: AttributeError: 'module' object has no attribute 'createsuperuser'

2006-08-06 Thread [EMAIL PROTECTED]
You're absolutely right! How could I be so blind. Thanks for your patient and quick help - its much appreciated. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send

Re: How can I use variables in included URLConf's before they are sent to views?

2006-08-06 Thread Todd O'Bryan
A very straightforward way to do this would be to map the main url to a view-like function, build the queries you need, and then, based on the rest of the url, pass control to the actual view function you want. Maybe I'm not understanding what you mean. Are the captured regexes from the

Re: AttributeError: 'module' object has no attribute 'createsuperuser'

2006-08-06 Thread Todd O'Bryan
It looks like you didn't get rid of the older version (notice the 0.90) and the path is confused. Try deleting the old version from your site-packages, making sure that whatever version of django-admin.py you're running in pointing at the right place, and give it another go. Todd On Aug

How can I use variables in included URLConf's before they are sent to views?

2006-08-06 Thread Ahmad Alhashemi
Hello everyone, My problem is like this. I have a main URLconf that will include another, application specific, URLconf. In the application specific, I'm preparing some querysets to pass to some generic views. The problem is that the querysets I need to make in the application URLconf depend on

AttributeError: 'module' object has no attribute 'createsuperuser'

2006-08-06 Thread [EMAIL PROTECTED]
I've had Django working before so I'm a bit confused by this. What makes it all the more unusual is I've done a Google search and not come across anyone else who's had this issue. I get htis error message when I attempt to "startproject" straight after a fresh install on Windows XP of Django

Re: Django model -> DOT converter

2006-08-06 Thread Antonio Cavedoni
On 6 Aug 2006, at 14:20, limodou wrote: > And you can also add these code at the top of your script: > > import settings > from django.core.management import setup_environ > setup_environ(settings) > > So you don't need to setup DJANGO_SETTING_MODULE env variable any > more. But the settings

Re: Django model -> DOT converter

2006-08-06 Thread Antonio Cavedoni
On 6 Aug 2006, at 14:25, Paul Sargent wrote: > One thought about how ForeignKeys are represented. At the moment > you can't tell which field points to which model. I'm looking at > zyons-comment.pdf and can only tell the which model a ForeignKey > uses because the attribute names are

Re: Code to spawn a new, independent process

2006-08-06 Thread oefe
Corey wrote: > Hey everyone, > > I've seen references and questions in previous posts about how to spawn > a process to do some hefty processing. I had that need (processing of > 1.6 million records at a time). > > I created this code with help from other places on the net and it seems > to work

Re: Django model -> DOT converter

2006-08-06 Thread Antonio Cavedoni
On 6 Aug 2006, at 6:08, limodou wrote: > A very cool tool. And a question: > > It seems that it can not display OneToOne relationship. I just fixed it to support both OneToOneFields and GenericRelations. I also added lots of samples from Ian’s Zyons project:

Re: Generate static HTML files

2006-08-06 Thread Malcolm Tredinnick
On Sun, 2006-08-06 at 11:26 +0200, Maciej Bliziński wrote: > Hello Djangoers, > > I've created a website some time ago. It stores data in XML and uses > XSLT transformation to generate static HTML files. Further development > of the website is more and more painful, to add a new feature would be