Merge pull request #196 from bornhack/feature/improve_shop_product_admin

Erhm...
This commit is contained in:
Víðir Valberg Guðmundsson 2018-01-07 17:25:20 +01:00 committed by GitHub
commit f8379e2fda
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -35,13 +35,13 @@ class ProductCategoryAdmin(admin.ModelAdmin):
def available_from(product): def available_from(product):
if product.available_in: if product.available_in.lower:
return product.available_in.lower.strftime("%c") return product.available_in.lower.strftime("%c")
return "None" return "None"
available_from.short_description = 'Available from' available_from.short_description = 'Available from'
def available_to(product): def available_to(product):
if product.available_in: if product.available_in.upper:
return product.available_in.upper.strftime("%c") return product.available_in.upper.strftime("%c")
return "None" return "None"
available_to.short_description = 'Available to' available_to.short_description = 'Available to'