Skip to content

Instantly share code, notes, and snippets.

View yakky's full-sized avatar
🐢
trying to catch up with maintainer duties

Iacopo Spalletti yakky

🐢
trying to catch up with maintainer duties
View GitHub Profile
TypeError at /de/admin/aldryn_categories/category/7/delete/
delete() takes exactly 1 argument (2 given)
Request Method: POST
Request URL: http://myproject-dev.domain.com/de/admin/aldryn_categories/category/7/delete/
Django Version: 1.6.10
Exception Type: TypeError
Exception Value:
delete() takes exactly 1 argument (2 given)
Exception Location: /home/myproject-dev/app/local/lib/python2.7/site-packages/parler/models.py in delete, line 537
Python Executable: /home/myproject-dev/app/bin/python
class ProductAdmin(admin.ModelAdmin):
list_display = ('name','thumb')
def thumb(self, obj):
return render_to_string('thumb.html',{
'image': obj.image
})
thumb.allow_tags = True

Copied from http://code.lancepollard.com/complete-list-of-html-meta-tags/

Basic HTML Meta Tags

<meta charset='UTF-8'>
<meta name='keywords' content='your, tags'>
<meta name='description' content='150 words'>
<meta name='subject' content='your website's subject'>
<meta name='copyright' content='company name'>
@yakky
yakky / migrate_filer.py
Created July 12, 2012 11:42 — forked from iivvoo/migrate_filer.py
migrate "traditional" image fields to FilerImageField
# encoding: utf-8
from django.core.management.base import BaseCommand
##
## FancyImageModel is a plugin model holding a ImageField called "oldimage" and
## FilerImageField "image". It removed duplicates based on the basename of the original
## image. This may or may not work for you.
from imageplugin.models import FancyImageModel