This repository has been archived on 2023-02-21. You can view files and clone it, but cannot push or open issues or pull requests.
tabellio.contest/tabellio/contest/contest_templates/view.pt

100 lines
3.3 KiB
XML

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
xmlns:tal="http://xml.zope.org/namespaces/tal"
xmlns:metal="http://xml.zope.org/namespaces/metal"
xmlns:i18n="http://xml.zope.org/namespaces/i18n"
lang="en"
metal:use-macro="context/main_template/macros/master"
i18n:domain="tabellio.contest">
<body>
<metal:main fill-slot="main">
<tal:main-macro metal:define-macro="main"
tal:define="toLocalizedTime nocall:context/@@plone/toLocalizedTime">
<div tal:replace="structure provider:plone.abovecontenttitle" />
<h1 class="documentFirstHeading" tal:content="context/title" />
<div tal:replace="structure provider:plone.belowcontenttitle" />
<div tal:condition="context/active">
<div tal:condition="view/can_manage" id="manage-contest">
<form action="@@manage">
<input type="submit" name="close" value="Fermer le concours"/>
<input type="submit" name="participants"
value="Voir la liste des participants"/>
</form>
</div>
<p tal:content="context/intro">
Lorem ipsum.
</p>
<div tal:replace="structure provider:plone.abovecontentbody" />
<form tal:condition="context/active" action="@@play" method="post">
<p class="question" tal:content="context/question1">
</p>
<div class="reponse">
<span tal:repeat="answer view/question1answerslist">
<label><input type="radio" name="answer1" tal:attributes="value answer"/>
<span tal:replace="answer"></span></label>
</span>
</div>
<p class="question" tal:content="context/question2">
</p>
<div class="reponse">
<span tal:repeat="answer view/question2answerslist">
<label><input type="radio" name="answer2" tal:attributes="value answer"/>
<span tal:replace="answer"></span></label>
</span>
</div>
<div class="participant">
<p class="mention-required">
Les champs nom, adresse, code postal, localité et courriel sont
obligatoires.
</p>
<p><label>Prénom / Nom</label> <input name="name"/></p>
<p><label>Adresse</label> <input name="address"/></p>
<p><label>Code postal</label> <input name="zipcode"/></p>
<p><label>Localité</label> <input name="locality"/></p>
<p><label>Tél./GSM</label> <input name="phone"/></p>
<p><label>Courriel</label> <input type="email" name="email"/></p>
</div>
<input type="submit" name="submit" value="Envoyer"/>
</form>
</div>
<div tal:condition="not:context/active">
<p tal:condition="view/can_manage">
<form action="@@manage">
<input type="submit" name="open" value="Ouvrir le concours"/>
<input type="submit" name="participants"
tal:condition="context/objectValues" value="Voir la liste des participants"/>
</form>
</p>
<p>
Ce concours est fermé.
</p>
</div>
<div tal:replace="structure provider:plone.belowcontentbody" />
</tal:main-macro>
</metal:main>
</body>
</html>