admin Exception Type: SuspiciousOperation ??

2009-12-14 Thread jl y
when I use django admin create a new book auther ( order the django book introduction ) but the "headshot" still is required and, if give any img the error as follows, Attempted access to '/tmp/avatar_005.jpeg' denied. Request Method: POST Request URL: http://127.0.0.1/admin/books/author/

Re: Multi table inheritance and reverse lookup

2009-09-23 Thread JL
We had to use a very similar solution as well in a project using multi- table inheritance. There's simply no good way to get to the actual type of the object. On Sep 23, 1:36 am, Torsten Bronger wrote: > Hallöchen! > > Jani Tiainen writes: > > [...] > > > Now it's trivial play with sub products

Re: A simple use for multidb... is this possible yet?

2009-07-20 Thread JL
I could use the django ORM to > > manipulate the data from the first database and then store it in the > > second. > > > My question is this: is there enough work done on multi-db already > > that maybe with maybe a little hack or two I could accomplish this? > &g

Re: syncdb is not doing anything

2009-07-06 Thread JL
Given that you mention that you already have a lot of data in your db, I really recommend you check out South (http://south.aeracode.org/). South is an application that adds migrations to your Django application. When I develop new applications and the dataset is small, I'll usually just use a co

Re: Easy display of table of data without a backing model

2009-05-04 Thread JL
Another hack would be to make your data structure look 'enough' like a Django model such that the generic views would work for you. Remember that Python follows duck-typing principles so if your data structures looks enough like querysets and data models, then you could use the generic views. I

Re: newbie: syncdb doesnt update schema after model change?

2009-04-17 Thread JL
What you're trying to do is called "Schema migration" or "evolution" there's been a lot of talk of it in the past. I recommend the South project for evolution. Very very flexible. Check it out here: http://south.aeracode.org/ On Apr 17, 1:30 am, Rama Vadakattu wrote: > OR you can use django-

Re: How do you retrieve a username that is not in the URL?

2009-04-15 Thread JL
Also, you might want to make sure you have an authenticated user (by either decorating your view function with @login_required) or check that the user in the request is either authenticated or not the anonymous user (by including an if statement). On Apr 14, 8:36 pm, James Bennett wrote: > On Tu