Skip to content

Instantly share code, notes, and snippets.

@pije76
Created October 24, 2012 06:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pije76/3944348 to your computer and use it in GitHub Desktop.
Save pije76/3944348 to your computer and use it in GitHub Desktop.
ElephantBlog Config - 2
########## ELEPHANTBLOG CONFIGURATION
def elephantblog_entry_url_app(self):
from feincms.content.application.models import app_reverse
return app_reverse('elephantblog_entry_detail', 'elephantblog.urls', kwargs={
'year': self.published_on.strftime('%Y'),
'month': self.published_on.strftime('%m'),
'day': self.published_on.strftime('%d'),
'slug': self.slug,
})
def elephantblog_categorytranslation_url_app(self):
from feincms.content.application.models import app_reverse
return app_reverse('elephantblog_category_detail', 'elephantblog.urls', kwargs={
'slug': self.slug,
})
ABSOLUTE_URL_OVERRIDES = {
'elephantblog.entry': elephantblog_entry_url_app,
'elephantblog.categorytranslation': elephantblog_categorytranslation_url_app,
}
########## END ELEPHANTBLOG CONFIGURATION
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment