This snippet is an improved version of the [ifusergroup](http://djangosnippets.org/snippets/1576/) tag that allows spaces in any of the group names. It also fixes a small bug where if a group didn't exist none of the subsequent groups would be checked.
Here's the python code to produce an admin related widget with the edit and delete link also.
* [RelatedFieldWidgetWrapper](http://djangosnippets.org/snippets/2562)
* [related-widget-wrapper.html](http://djangosnippets.org/snippets/2563)
* [related-widget-wrapper.js](http://djangosnippets.org/snippets/2564)
* [RelatedWidgetWrapperAdmin](http://djangosnippets.org/snippets/2565)
Here's the python code to produce an admin related widget with the edit and delete link also.
* [RelatedFieldWidgetWrapper](http://djangosnippets.org/snippets/2562)
* [related-widget-wrapper.html](http://djangosnippets.org/snippets/2563)
* [related-widget-wrapper.js](http://djangosnippets.org/snippets/2564)
* [RelatedWidgetWrapperAdmin](http://djangosnippets.org/snippets/2565)
Here's the python code to produce an admin related widget with the edit and delete link also.
* [RelatedFieldWidgetWrapper](http://djangosnippets.org/snippets/2562)
* [related-widget-wrapper.html](http://djangosnippets.org/snippets/2563)
* [related-widget-wrapper.js](http://djangosnippets.org/snippets/2564)
* [RelatedWidgetWrapperAdmin](http://djangosnippets.org/snippets/2565)
Here's the python code to produce an admin related widget with the edit and delete link also.
* [RelatedFieldWidgetWrapper](http://djangosnippets.org/snippets/2562)
* [related-widget-wrapper.html](http://djangosnippets.org/snippets/2563)
* [related-widget-wrapper.js](http://djangosnippets.org/snippets/2564)
* [RelatedWidgetWrapperAdmin](http://djangosnippets.org/snippets/2565)
Use this to send emails to your users, takes one template and renders it as html or text as needed.
Credits to
"""
Jutda Helpdesk - A Django powered ticket tracker for small enterprise.
(c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details.
lib.py - Common functions (eg multipart e-mail)
"""
MIT licence
I only removed the specific project parts and made it general to use.
The original project repository https://github.com/rossp/django-helpdesk/
Based on [http://djangosnippets.org/snippets/1697/](http://djangosnippets.org/snippets/1697/)
but improved with multiline fields, and unicode chars.
Also it generates an xls file, not a csv one.
Requires, pyExcelerator
*Usage:*
Add the code to your project, e.g. a file called actions.py in the project root.
Register the action in your apps admin.py:
from myproject.actions import export_as_xls
class MyAdmin(admin.ModelAdmin):
actions = [export_as_xls]
To enable "clean url" mode, install [django-pagination](http://code.google.com/p/django-pagination/),
then just add to settings.py
PAGINATION_CLEAN_URL = True
and replace '.../pagination/templatetags/pagination_tags.py' with follow, and so
add to 'pagination/templates/pagination/' folder
pagination_clean_url.html
file, with following code
**Note:**
in urls.py
should be like this:
url(r'^/foo/bar/\d*/?$', foobar_list_handle),
This code allows you to upload a mp3 to the Admin Frontend. The ID3 tags are automatically read out and filled in to the according fields.
This should work for other filetypes as well. As long as they have an id3 tag.