From e0c0d4b38cde20e2300e86b69414dd9851b47456 Mon Sep 17 00:00:00 2001 From: neodarz Date: Thu, 5 Sep 2019 07:05:07 +0200 Subject: ooo --- dotfiles/cheat/djangocms | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 dotfiles/cheat/djangocms (limited to 'dotfiles/cheat/djangocms') diff --git a/dotfiles/cheat/djangocms b/dotfiles/cheat/djangocms new file mode 100644 index 0000000..76c0826 --- /dev/null +++ b/dotfiles/cheat/djangocms @@ -0,0 +1,29 @@ +# Apphook theme integration + +This is maybe not the best way to do this but it's work. + +First doc is here : http://docs.django-cms.org/en/latest/introduction/05-apphooks.html + +(`.` is the root of the django-cms project) +(`myApp` is the django app to be ingreted to django-cms) + +Create another django app specialy for integrate the wanted django app. +(ex: `./myApp_cms_integration/`) + +For apply the theme you need, in the cms app create a folder, to create a +`templates` folder for the integrated django app. +(ex: `./myApp_cms_integration/templates/myApp/`) + +Copy the base.html template of myApp django app and modify the file with this +code: + +``` +{% extends "base.html" %} + +{% block apps %} +# Here come all the code from the base.html of myApp (In this example) +{% endblock %} +``` + +You also need to add somewhere in the template of the django-cms project +`{% block apps %}{% endblock %}`. -- cgit v1.2.1