aboutsummaryrefslogtreecommitdiffstats
path: root/jm2l/templates/trash/Intendance_Dialog.mako
diff options
context:
space:
mode:
Diffstat (limited to 'jm2l/templates/trash/Intendance_Dialog.mako')
-rw-r--r--jm2l/templates/trash/Intendance_Dialog.mako142
1 files changed, 0 insertions, 142 deletions
diff --git a/jm2l/templates/trash/Intendance_Dialog.mako b/jm2l/templates/trash/Intendance_Dialog.mako
deleted file mode 100644
index c0e40d7..0000000
--- a/jm2l/templates/trash/Intendance_Dialog.mako
+++ /dev/null
@@ -1,142 +0,0 @@
-<%namespace name="h" file="jm2l:templates/helpers.mako"/>
-## -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-<%def name="AddProposal(Type, form)">
-<%
-if Type=='H':
- CurTitle = u"un hébergement"
- CurIcon = "icon-home"
-elif Type=='C':
- CurTitle = "un co-voiturage"
- CurIcon = "icon-road"
-elif Type=='M':
- CurTitle = u"un prêt de matériel"
- CurIcon = "icon-shopping-cart"
-%>
- <!-- Modal -->
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
- <h3 id="AddProp${Type}ModalLabel"> Je propose ${CurTitle} !</h3>
- </div>
- <div class="modal-body">
- %if 'exch_id' in form._fields.keys():
- <form id="ModalForm" action="javascript:DoPost('/2015/modal/Prop${Type}/${form.exch_id.data}');">
- %else:
- <form id="ModalForm" action="javascript:DoPost('/2015/modal/Prop${Type}/0');">
- %endif
- <p>Je propose mes service pour ${CurTitle}</p>
- % if Type=='H':
- ${Heberg_Proposal(form)}
- % elif Type=='C':
- ${Covoit_Proposal(form)}
- % elif Type=='M':
- ${Matos_Proposal(form)}
- % endif
- </form>
- </div>
- <div class="modal-footer">
- <button class="btn" data-dismiss="modal" aria-hidden="true">Fermer</button>
- <button class="btn btn-primary" onclick="javascript:document.forms['ModalForm'].submit();">
- <i class="${CurIcon} icon-white"></i> Proposer !</button>
- </div>
-</%def>
-## -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-<%def name="AddAsk(Type, form)">
-<%
-if Type=='H':
- CurTitle = u"un hébergement"
- CurIcon = "icon-home"
-elif Type=='C':
- CurTitle = "un co-voiturage"
- CurIcon = "icon-road"
-elif Type=='M':
- CurTitle = u"un prêt de matériel"
- CurIcon = "icon-shopping-cart"
-%>
- <!-- Modal -->
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
- <h3 id="AddAsk${Type}ModalLabel"> Je demande ${CurTitle} !</h3>
- </div>
- <div class="modal-body">
- % if 'exch_id' in form._fields.keys():
- <form id="ModalForm" action="javascript:DoPost('/2015/modal/Ask${Type}/${form.exch_id.data}');">
- % else:
- <form id="ModalForm" action="javascript:DoPost('/2015/modal/Ask${Type}/0');">
- %endif
- <p>Je demande ${CurTitle}</p>
- % if Type=='H':
- ${Heberg_Ask(form)}
- % elif Type=='C':
- ${Covoit_Ask(form)}
- % elif Type=='M':
- ${Matos_Ask(form)}
- % endif
- </form>
- </div>
- <div class="modal-footer">
- <button class="btn" data-dismiss="modal" aria-hidden="true">Fermer</button>
- <button class="btn btn-primary" onclick="javascript:document.forms['ModalForm'].submit();">
- <i class="${CurIcon} icon-white"></i> Demander !</button>
- </div>
-</%def>
-
-<%def name="Show(Type, Exch)"> \
-<%
-if Exch.exch_type=='H':
- CurTitle = u"de l'hébergement"
- CurIcon = "icon-home"
-elif Exch.exch_type=='C':
- CurTitle = "du co-voiturage"
- CurIcon = "icon-road"
-elif Exch.exch_type=='M':
- CurTitle = u"du prêt de matériel"
- CurIcon = "icon-shopping-cart"
-%>
- <!-- Modal -->
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
- <i class="${CurIcon}"></i> <strong>Détails ${CurTitle}</strong>
- </div>
- <div class="modal-body">
- % if Type=='H':
- ${ShowH(Exch)}
- % elif Type=='C':
- ${ShowC(Exch)}
- % elif Type=='M':
- ${ShowM(Exch)}
- % endif
- % if Exch.exch_state=='Ask':
- <form id="ModalForm" action="javascript:DoPost('/2015/exchange/Ask${Type}/${Exch.exch_id}/deal');"></form>
- % elif Exch.exch_state=='Proposal':
- <form id="ModalForm" action="javascript:DoPost('/2015/exchange/Prop${Type}/${Exch.exch_id}/deal');"></form>
- % endif
- </div>
- <div class="modal-footer">
- % if not Exch.exch_done and (Exch.asker_id is None or Exch.provider_id is None):
- % if Exch.exch_state=='Proposal' and Exch.provider_id!=request.user.uid:
- <button class="btn btn-info" data-dismiss="modal" aria-hidden="true"
- onclick="javascript:document.forms['ModalForm'].submit();">
- % if Type=='H':
- Je lui demande pour dormir chez lui/elle !
- % elif Type=='C':
- Je lui demande de venir me chercher !
- % elif Type=='M':
- Je lui demande de me prêter son matériel !
- % endif
- </button>
- % elif Exch.exch_state=='Ask' and Exch.asker_id!=request.user.uid:
- <button class="btn btn-info" data-dismiss="modal" aria-hidden="true"
- onclick="javascript:document.forms['ModalForm'].submit();">
- % if Type=='H':
- Je propose de l'héberger !
- % elif Type=='C':
- Je propose de venir le/la chercher !
- % elif Type=='M':
- Je lui propose mon matériel !
- % endif
- </button>
- % endif
- % endif
- <button class="btn" data-dismiss="modal" aria-hidden="true">Fermer</button>
- </div>
-</%def> \