1 from feincms.content.application.models import ApplicationContent
3 def get_app_page(model, urlconf_path):
5 Returns the model entry that has been associated with the application that
6 provides the passed urlconf_path.
8 e.g. to retrieve the page associated with
10 >>> page = get_app_page(Page, 'cloudcmsblog')
11 >>> print page.get_navigation_url()
15 app_content_type = model.content_type_for(ApplicationContent)
17 blog_block = app_content_type.objects.filter(urlconf_path=urlconf_path)[0]
20 return blog_block.parent