django-admin

Is it possible to have one 'master' Django website and N satelite websites

I am thinking of a configuration where I have one master website at : www.masterdomain.com and N satelite domains where I can access the satelite domains as follows: www.masterdomain.com/some_url/satetlite1.html www.masterdomain.com/some_url/satetlite2.html ... www.masterdomain.com/some_url/satetliteN.html Is this possible? ...

When should you use django-admin.py verus manage.py?

Background: When I run the django-admin.py loaddata example.json I get this error. "ImportError: Settings cannot be imported, because environment variable DJANGO_SETTINGS_MODULE is undefined." I understand the problem. It needs the DJANGO_SETTINGS_MODULE to be able to access the database to do this import. I've had this problem before a...

(Django) prepopulate field, and forbid editing

How can I set a field in admin to be at the same time non-editable and prepopulated from other field ? ...

Admin field fails to save with tinymce and filebrowser in django

I'm using django-tinymce together with the no grappelli branch of django-filebrowser running django 1.2. I use the tinymce HTMLField model definition for the model field that I would like to have WYSIWYG. I've added the correct javascript to my AdminModel, and the filebrowser works great, adding the image to the textarea with no proble...

Django AdZone and problem in the admin

Hi guys, im would like to use the cool app Django-AdZone, i thinks is a nice work , but i have a litter problem: i have 2 website, django-adzone is working very nice in one of those website, but in the second website is not working. I cant see in the django admin the app adzone, i dont know why, i did the same steps for both website, a...

Putting 2 fields in the same column in the Django Admin?

Two of my model's fields are "title" and "summary". Right now, "title" is the first field in the ModelAdmin's list_display, which makes it link to the change page. I have some other fields in list_display as well. I'd like to make the admin change list page display "summary" under "title" in plain, unlinked text, in the same column as "...

Change the way the Django Admin sorts integers?

The model has an IntegerField with null=True, blank=True, so it allows the field to have a value of None. When the column is sorted, the Nones are always treated as the lowest values. Is it possible to make Django treat them as the highest values? So when sorted in descending order, instead of: 100 43 7 None It would go: None 100 43 7...

Custom error message in Django admin actions

I've written custom admin actions that basically do QuerySet.update() for certain fields in the model. There are times when these actions shouldn't be allowed to complete -- instead, they should display an error and not do anything. I've tried message_user, but that displays a green checkmark, whereas I'd like it to display the Django ad...

Limiting Acess to django admin via applicatins

Is it possible to limit what admin pages a user is able to VIEW and modify i know it is currently possible to limit changes to them, but is it possibly to limit a user via permissions or otherwise to only the administration views for one app. If possibly i am also aiming that superusers can access the standard django admin Looking aroun...

django admin panel changelist submit

I have used list_editable setting to make several fields editable on my model in the admin panel. The problem is, that when I edit the values and hit Enter, the browser behaves as if I clicked Go button next to actions drop-down list. I get the javascript popup warning: You have unsaved changes on individual editable fields. If you ru...

Django: Correct way to extend a certain field in the admin change form with HTML?

Let's say I have a model with a field based on the ImageField class. class Foo(models.Model): imagefile = models.ImageField('File', upload_to='foo/%Y/%m%/%d/') Django adds - after first upload - an input tag of type file to let me change it and a link to the image to view it. I want this original field specific (HTML) code as is...

How to sort list_filter labels for foreign key filters in Django admin?

List_filter labels for foreign key filters in django admin are always ordered by id and that can cause a pretty mess when there are many filters in the list. I have been searching for simple solution how to order those labels alphabetically or by date for some time now. It seemed that besides of using FilterSpec there is no solution for...

Is there an equivalent django-admin like feature for ASP.NET?

I'm looking for anything that allows similar editing of tables and doesn't have a software cost associated to it. ...

Hours of attempting to install django and stuck on an urls.py error

I have spend the past 6 hours getting an ubuntu 10.04 server setup with django and mysql. I am using django 1.2.1, and maybe that's my problem. I have everything as I'd think it should be and am receiving this error when I hit http://localhost/admin Request URL: http://192.168.1.153/mydangoproject/admin Django Version: 1.2.1 Excep...

Django's admin pages are missing their typical formatting/style, have I set it up wrong?

I finally got my django install working, however I'm noticing that the typical look and feel of the admin pages are missing, and it's as if there are no styles applied to the structure of the pages. Do I have some kind of setup issue or pathing issue that's preventing the style sheets from being found? Where are they stored? My pages loo...

Customizing Django Admin Result List

How can I change the output result from Django Admin Result List? I've been looking into the change_result_list.html template file but all I can find is : {% for item in result %}{{ item }}{% endfor %} Which will be outputting something like : <tr> <td> <input type="checkbox" class="action-select" value="2" name="_selecte...

Customising the admin site in django.

Hi, In my django app i have the admin site and I am trying to customise it so that i can keep adding people to the event attendance. My models look like this: class Talk(models.Model): title = models.CharField(max_length=200, primary_key=True) speaker = models.CharField(max_length=200) date_of_talk = models.DateField('date_of_talk') de...

How do I retroactively make AutoFields that don't break django-admin?

I created the models in a Django app using manage.py inspectdb on an existing postgres database. This seemed to work except that all the primary keys were described in the models as IntegerFields, which made them editable in the admin panel, and had to be hand-entered based on knowledge of the id of the previous record. I just learned ab...

Django - Custom dashboard view authentication issues

Django version 1.1.1 I have a custom dashboard view set up to override the django admin default like: (r'^admin/$', 'dashboard.views.dashboard'), (r'^admin/', include(admin.site.urls)), dashboard view authenticates with the @staff_member_required decorator This has been working fine with all users having superuser permissions but whe...

Building a blog-like app with django, should I normalize images outside of the blog entry's model?

Just wondering because at the moment I am keeping the ImageFields as part of the BlogPost model. If I want to support the potential for 20 images, I have 20 such fields, when often almost 19 of them will never be used. But if I normalize them into a separate model, it's not as intuitive to add images to a post in the admin page, since yo...