diff --git a/auquotidien/auquotidien.py b/auquotidien/auquotidien.py index 9e1d887..daf9759 100644 --- a/auquotidien/auquotidien.py +++ b/auquotidien/auquotidien.py @@ -4,8 +4,6 @@ from wcs.qommon import _ from wcs.qommon.publisher import get_publisher_class, get_request from wcs.qommon.misc import get_cfg -from modules import formpage -from modules import template from modules import payments from modules import connectors diff --git a/auquotidien/modules/formpage.py b/auquotidien/modules/formpage.py deleted file mode 100644 index 36d94c5..0000000 --- a/auquotidien/modules/formpage.py +++ /dev/null @@ -1,31 +0,0 @@ -from quixote import get_publisher, get_request, redirect -from quixote.directory import Directory -from quixote.html import htmltext - -import os - -import wcs -import wcs.forms.root -import wcs.forms.preview -from wcs.qommon import _ -from wcs.qommon import template -from wcs.qommon import errors -from wcs.qommon.form import * -from wcs.roles import logged_users_role - -from wcs.qommon import emails - -OldFormPage = wcs.forms.root.FormPage - - -class AlternateFormPage(OldFormPage): - def form_side(self, *args, **kwargs): - form_side_html = OldFormPage.form_side(self, *args, **kwargs) - get_response().filter['gauche'] = form_side_html - get_response().filter['steps'] = form_side_html - return - - -wcs.forms.root.FormPage = AlternateFormPage -wcs.forms.root.PublicFormStatusPage.form_page_class = AlternateFormPage -wcs.forms.preview.PreviewFormPage.__bases__ = (AlternateFormPage,) diff --git a/auquotidien/modules/template.py b/auquotidien/modules/template.py deleted file mode 100644 index c6033ba..0000000 --- a/auquotidien/modules/template.py +++ /dev/null @@ -1,14 +0,0 @@ -from wcs.qommon import template - -wcs_get_decorate_vars = template.get_decorate_vars - - -def get_decorate_vars(body, response, generate_breadcrumb=True, template_context=None, **kwargs): - if template_context and 'form_side' in template_context: - # force rendering as it will put new variables in the context - template_context['form_side'] = template_context['form_side']() - - return wcs_get_decorate_vars(body, response, generate_breadcrumb) - - -template.get_decorate_vars = get_decorate_vars