removed (last) dtml methods: entreprises
This commit is contained in:
parent
9b9ed47e96
commit
09f9124b01
@ -1,62 +0,0 @@
|
|||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'E', do_entreprise_list( args={ 'entreprise_id' : entreprise_id } )[0])">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'curtime', ZopeTime().strftime('%d/%m/%Y') )">
|
|
||||||
<dtml-call "REQUEST.set( 'link_create_corr', make_link_create_corr(entreprise_id) )">
|
|
||||||
<dtml-call "REQUEST.set( 'correspondants',
|
|
||||||
do_entreprise_correspondant_listnames( args={ 'entreprise_id' : entreprise_id }) )">
|
|
||||||
<dtml-if "len(correspondants) == 0">
|
|
||||||
<dtml-call "REQUEST.set( 'correspondants', [ ('inconnu','') ])">
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<h2 class="entreprise_contact">Nouveau "contact" avec l'entreprise <dtml-var "E['nom']"></h2>
|
|
||||||
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set('tf', TrivialFormulator( URL0, REQUEST.form,
|
|
||||||
(
|
|
||||||
('entreprise_id', { 'input_type' : 'hidden', 'default' : entreprise_id }),
|
|
||||||
|
|
||||||
('type_contact', { 'input_type' : 'menu', 'title' : 'Objet',
|
|
||||||
'allowed_values' : ('Prospection', 'Stage étudiant',
|
|
||||||
'Contrat Apprentissage DUT GTR1',
|
|
||||||
'Contrat Apprentissage DUT GTR2',
|
|
||||||
'Contrat Apprentissage Licence SQRT',
|
|
||||||
'Projet', 'Autre' ),
|
|
||||||
'default' : 'Stage étudiant'
|
|
||||||
}),
|
|
||||||
|
|
||||||
('date', { 'size' : 12, 'title' : 'Date du contact (j/m/a)', 'allow_null' : False,
|
|
||||||
'default': curtime }),
|
|
||||||
|
|
||||||
('entreprise_corresp_id', { 'input_type' : 'menu', 'title' : 'Correspondant entreprise',
|
|
||||||
'explanation' : link_create_corr, 'allow_null' : True,
|
|
||||||
'labels' : [ x[0] for x in correspondants ],
|
|
||||||
'allowed_values' : [ x[1] for x in correspondants ] }),
|
|
||||||
|
|
||||||
('etudiant', { 'size' : 16, 'title' : 'Etudiant concerné', 'allow_null' : True,
|
|
||||||
'explanation' : 'nom (si pas ambigu) ou code' }),
|
|
||||||
('enseignant', { 'size' : 16, 'title' : 'Enseignant (tuteur)', 'allow_null' : True }),
|
|
||||||
('description', { 'input_type' : 'textarea', 'rows' : 3, 'cols': 40, 'title' : 'Description' }),
|
|
||||||
|
|
||||||
),
|
|
||||||
cancelbutton='Annuler',
|
|
||||||
submitlabel = 'Ajouter ce contact', readonly = REQUEST['_read_only']
|
|
||||||
))">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'etudok', do_entreprise_check_etudiant(etudiant) )">
|
|
||||||
|
|
||||||
<dtml-if "(tf[0] == 0) or (etudok[0] == 0)">
|
|
||||||
<dtml-if "etudok[0] == 0">
|
|
||||||
<p class="entreprise_warning"><dtml-var "etudok[1]"></p>
|
|
||||||
</dtml-if>
|
|
||||||
<dtml-var "tf[1]">
|
|
||||||
<dtml-elif "tf[0] == -1">
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 )">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-call "tf[2].update( { 'etudid' : etudok[1] })">
|
|
||||||
<dtml-var "REQUEST.set( 'matiere_id', do_entreprise_contact_create( tf[2] ) )">
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 )">
|
|
||||||
</dtml-if tf>
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,27 +0,0 @@
|
|||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'F', do_entreprise_contact_list( args={ 'entreprise_contact_id' : entreprise_contact_id } )[0])">
|
|
||||||
|
|
||||||
<h2>Suppression du contact</h2>
|
|
||||||
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set('tf', TrivialFormulator( URL0, REQUEST.form,
|
|
||||||
( ('entreprise_contact_id', { 'input_type' : 'hidden' }),
|
|
||||||
),
|
|
||||||
initvalues = F,
|
|
||||||
submitlabel = 'Confirmer la suppression',
|
|
||||||
cancelbutton = 'Annuler', readonly = REQUEST['_read_only']
|
|
||||||
))">
|
|
||||||
|
|
||||||
<dtml-if "tf[0] == 0">
|
|
||||||
<dtml-var "tf[1]">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-if "tf[0] == -1">
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 )">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-call "do_entreprise_contact_delete( F['entreprise_contact_id'] )">
|
|
||||||
<dtml-call "RESPONSE.redirect(URL1)">
|
|
||||||
</dtml-if>
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,62 +0,0 @@
|
|||||||
<dtml-call "REQUEST.set( 'F', do_entreprise_contact_list( args={ 'entreprise_contact_id' : entreprise_contact_id } )[0])">
|
|
||||||
<dtml-call "REQUEST.set( 'entreprise_id', F['entreprise_id'])">
|
|
||||||
<dtml-call "REQUEST.set( 'link_create_corr', make_link_create_corr(F['entreprise_id']) )">
|
|
||||||
<dtml-call "REQUEST.set( 'E', do_entreprise_list( args={ 'entreprise_id' : F['entreprise_id'] } )[0])">
|
|
||||||
<dtml-call "REQUEST.set( 'correspondants',
|
|
||||||
do_entreprise_correspondant_listnames( args={ 'entreprise_id' : F['entreprise_id'] })+ [ ('inconnu','') ])">
|
|
||||||
|
|
||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
<h2 class="entreprise_contact"><dtml-var title_or_id></h2>
|
|
||||||
|
|
||||||
|
|
||||||
<h3>Contact avec entreprise <dtml-var "E['nom']"></h3>
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set('tf', TrivialFormulator( URL0, REQUEST.form,
|
|
||||||
( ('entreprise_contact_id', { 'default' : entreprise_contact_id, 'input_type' : 'hidden' }),
|
|
||||||
|
|
||||||
('entreprise_id', { 'input_type' : 'hidden', 'default' : F['entreprise_id'] }),
|
|
||||||
|
|
||||||
('type_contact', { 'input_type' : 'menu', 'title' : 'Objet',
|
|
||||||
'allowed_values' : ('Prospection', 'Stage étudiant', 'Contrat Apprentissage', 'Projet', 'Autre' ),
|
|
||||||
}),
|
|
||||||
|
|
||||||
('date', { 'size' : 12, 'title' : 'Date du contact (j/m/a)', 'allow_null' : False }),
|
|
||||||
|
|
||||||
('entreprise_corresp_id', { 'input_type' : 'menu', 'title' : 'Correspondant entreprise',
|
|
||||||
'explanation' : link_create_corr,
|
|
||||||
'allow_null' : True,
|
|
||||||
'labels' : [ x[0] for x in correspondants ],
|
|
||||||
'allowed_values' : [ x[1] for x in correspondants ] }),
|
|
||||||
|
|
||||||
('etudiant', { 'size' : 16, 'title' : 'Etudiant concerné', 'allow_null' : True,
|
|
||||||
'default' : F['etudid'],
|
|
||||||
'explanation' : 'nom (si pas ambigu) ou code' }),
|
|
||||||
('enseignant', { 'size' : 16, 'title' : 'Enseignant (tuteur)', 'allow_null' : True }),
|
|
||||||
('description', { 'input_type' : 'textarea', 'rows' : 3, 'cols': 40, 'title' : 'Description' }),
|
|
||||||
),
|
|
||||||
cancelbutton = 'Annuler',
|
|
||||||
initvalues = F,
|
|
||||||
submitlabel = 'Modifier les valeurs', readonly = REQUEST['_read_only']
|
|
||||||
))">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'etudok', do_entreprise_check_etudiant(etudiant) )">
|
|
||||||
|
|
||||||
<dtml-if "(tf[0] == 0) or (etudok[0] == 0)">
|
|
||||||
<dtml-if "etudok[0] == 0">
|
|
||||||
<p class="entreprise_warning"><dtml-var "etudok[1]"></p>
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<dtml-var "tf[1]">
|
|
||||||
<dtml-unless "REQUEST['_read_only']">
|
|
||||||
<p class="entreprise_descr"><a class="entreprise_delete" href="entreprise_contact_delete?entreprise_contact_id=<dtml-var entreprise_contact_id>">Supprimer ce contact</a> </p>
|
|
||||||
</dtml-unless>
|
|
||||||
<dtml-elif "tf[0] == -1">
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 )" >
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-call "tf[2].update( { 'etudid' : etudok[1] })">
|
|
||||||
<dtml-call "do_entreprise_contact_edit( tf[2] )">
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 + '/entreprise_contact_list?entreprise_id=' + str(F['entreprise_id']) )" >
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,54 +0,0 @@
|
|||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
|
|
||||||
<dtml-if entreprise_id>
|
|
||||||
<dtml-call "REQUEST.set( 'E', do_entreprise_list( args={ 'entreprise_id' : entreprise_id } )[0])">
|
|
||||||
<dtml-call "REQUEST.set( 'C', do_entreprise_contact_list( args={ 'entreprise_id' : entreprise_id }) )">
|
|
||||||
|
|
||||||
<h2 class="entreprise_contact">Listes des contacts avec l'entreprise <dtml-var "E['nom']"> </h2>
|
|
||||||
|
|
||||||
<dtml-else>
|
|
||||||
<h2 class="entreprise_contact">Listes des contacts</h2>
|
|
||||||
<dtml-call "REQUEST.set( 'C', do_entreprise_contact_list( args={ }))">
|
|
||||||
</dtml-if entreprise_id>
|
|
||||||
|
|
||||||
<table class="contact_list">
|
|
||||||
|
|
||||||
<tr><th>Date</th><th>Objet</th><dtml-unless entreprise_id><th>Entreprise</th></dtml-unless><th>Etudiant</th><th>Description</th></tr>
|
|
||||||
|
|
||||||
<dtml-in "C">
|
|
||||||
<dtml-let F="_['sequence-item']">
|
|
||||||
<dtml-call "REQUEST.set( 'Ec', do_entreprise_list( args={ 'entreprise_id' : F['entreprise_id'] } )[0])">
|
|
||||||
|
|
||||||
<tr class="<dtml-if sequence-odd>contact_list_odd<dtml-else>contact_list_even</dtml-if>">
|
|
||||||
|
|
||||||
<td><a class="contact_edit" href="entreprise_contact_edit?entreprise_contact_id=<dtml-var "F['entreprise_contact_id']">">
|
|
||||||
<dtml-var "F['date']">
|
|
||||||
</td>
|
|
||||||
|
|
||||||
<td class="contact_descr"><dtml-var "F['type_contact']"></td>
|
|
||||||
<dtml-unless entreprise_id><td class="contact_descr"><dtml-var "Ec['nom']"></td></dtml-unless>
|
|
||||||
<td class="contact_descr">
|
|
||||||
<dtml-if "F['etudid']">
|
|
||||||
<dtml-in "getEtudInfo(etudid=F['etudid'],filled=1)" mapping>
|
|
||||||
<a href="<dtml-var ScoURL>/ficheEtud?etudid=<dtml-var "F['etudid']">"><dtml-var nomprenom></a>
|
|
||||||
</dtml-in>
|
|
||||||
</dtml-if etudid>
|
|
||||||
</td>
|
|
||||||
<td class="contact_descr"><dtml-var "F['description']"></td>
|
|
||||||
</tr>
|
|
||||||
</dtml-let F>
|
|
||||||
|
|
||||||
<dtml-else>
|
|
||||||
<tr><td colspan="4"><font color="red"><em>Aucun contact !</em></font></td></tr>
|
|
||||||
</dtml-in>
|
|
||||||
</table>
|
|
||||||
|
|
||||||
<dtml-unless "REQUEST['_read_only']">
|
|
||||||
<dtml-if entreprise_id>
|
|
||||||
<p class="entreprise_create">
|
|
||||||
<a class="entreprise_create" href="entreprise_contact_create?entreprise_id=<dtml-var "E['entreprise_id']">">nouveau "contact"</a>
|
|
||||||
</p>
|
|
||||||
</dtml-if>
|
|
||||||
</dtml-unless>
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,43 +0,0 @@
|
|||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'UE', do_entreprise_list( args={ 'entreprise_id' : entreprise_id } )[0])">
|
|
||||||
|
|
||||||
|
|
||||||
<h2 class="entreprise_correspondant"><dtml-var title_or_id> dans l'entreprise <dtml-var "UE['nom']"></h2>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set('tf', TrivialFormulator( URL0, REQUEST.form,
|
|
||||||
( ('entreprise_id', { 'input_type' : 'hidden', 'default' : entreprise_id }),
|
|
||||||
('civilite', { 'input_type' : 'menu',
|
|
||||||
'labels' : [ 'M.', 'Mme' ], 'allowed_values' : [ 'M.', 'Mme' ] }),
|
|
||||||
('nom', { 'size' : 25, 'title' : 'Nom', 'allow_null' : False }),
|
|
||||||
('prenom', { 'size' : 25, 'title' : 'Prénom' }),
|
|
||||||
('fonction', { 'input_type' : 'menu',
|
|
||||||
'allowed_values' : ('Directeur', 'RH', 'Resp. Administratif', 'Tuteur', 'Autre'),
|
|
||||||
'default' : 'Tuteur',
|
|
||||||
'explanation' : 'fonction via à vis de l\'IUT' }),
|
|
||||||
('phone1', { 'size' : 14, 'title' : 'Téléphone 1', }),
|
|
||||||
('phone2', { 'size' : 14, 'title' : 'Téléphone 2', }),
|
|
||||||
('mobile', { 'size' : 14, 'title' : 'Tél. mobile', }),
|
|
||||||
('fax', { 'size' : 14, 'title' : 'Fax', }),
|
|
||||||
('mail1', { 'size' : 25, 'title' : 'e-mail', }),
|
|
||||||
('mail2', { 'size' : 25, 'title' : 'e-mail 2', }),
|
|
||||||
|
|
||||||
('note', { 'input_type' : 'textarea', 'rows' : 3, 'cols': 40, 'title' : 'Note' }),
|
|
||||||
|
|
||||||
),
|
|
||||||
cancelbutton='Annuler',
|
|
||||||
submitlabel = 'Ajouter ce correspondant', readonly = REQUEST['_read_only']
|
|
||||||
))">
|
|
||||||
|
|
||||||
<dtml-if "tf[0] == 0">
|
|
||||||
<dtml-var "tf[1]">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-var "REQUEST.set( 'matiere_id', do_entreprise_correspondant_create( tf[2] ) )">
|
|
||||||
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 )">
|
|
||||||
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,27 +0,0 @@
|
|||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'F', do_entreprise_correspondant_list( args={ 'entreprise_corresp_id' : entreprise_corresp_id } )[0])">
|
|
||||||
|
|
||||||
<h2>Suppression du correspondant <dtml-var "F['nom']"> <dtml-var "F['prenom']"></h2>
|
|
||||||
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set('tf', TrivialFormulator( URL0, REQUEST.form,
|
|
||||||
( ('entreprise_corresp_id', { 'input_type' : 'hidden' }),
|
|
||||||
),
|
|
||||||
initvalues = F,
|
|
||||||
submitlabel = 'Confirmer la suppression',
|
|
||||||
cancelbutton = 'Annuler', readonly = REQUEST['_read_only']
|
|
||||||
))">
|
|
||||||
|
|
||||||
<dtml-if "tf[0] == 0">
|
|
||||||
<dtml-var "tf[1]">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-if "tf[0] == -1">
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 )">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-call "do_entreprise_correspondant_delete( F['entreprise_corresp_id'] )">
|
|
||||||
<dtml-call "RESPONSE.redirect(URL1)">
|
|
||||||
</dtml-if>
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,41 +0,0 @@
|
|||||||
<dtml-call "REQUEST.set( 'F', do_entreprise_correspondant_list( args={ 'entreprise_corresp_id' : entreprise_corresp_id } )[0])">
|
|
||||||
<dtml-call "REQUEST.set( 'entreprise_id', F['entreprise_id'])">
|
|
||||||
|
|
||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
<h2 class="entreprise_correspondant"><dtml-var title_or_id></h2>
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set('tf', TrivialFormulator( URL0, REQUEST.form,
|
|
||||||
( ('entreprise_corresp_id', { 'default' : entreprise_corresp_id, 'input_type' : 'hidden' }),
|
|
||||||
('civilite', { 'input_type' : 'menu',
|
|
||||||
'labels' : [ 'M.', 'Mme' ], 'allowed_values' : [ 'M.', 'Mme' ] }),
|
|
||||||
('nom', { 'size' : 25, 'title' : 'Nom', 'allow_null' : False }),
|
|
||||||
('prenom', { 'size' : 25, 'title' : 'Prénom' }),
|
|
||||||
('fonction', { 'input_type' : 'menu',
|
|
||||||
'allowed_values' : ('Directeur', 'RH', 'Resp. Administratif', 'Tuteur', 'Autre'),
|
|
||||||
'explanation' : 'fonction via à vis de l\'IUT' }),
|
|
||||||
('phone1', { 'size' : 14, 'title' : 'Téléphone 1', }),
|
|
||||||
('phone2', { 'size' : 14, 'title' : 'Téléphone 2', }),
|
|
||||||
('mobile', { 'size' : 14, 'title' : 'Tél. mobile', }),
|
|
||||||
('fax', { 'size' : 14, 'title' : 'Fax', }),
|
|
||||||
('mail1', { 'size' : 25, 'title' : 'e-mail', }),
|
|
||||||
('mail2', { 'size' : 25, 'title' : 'e-mail 2', }),
|
|
||||||
|
|
||||||
('note', { 'input_type' : 'textarea', 'rows' : 3, 'cols': 40, 'title' : 'Note' }),
|
|
||||||
),
|
|
||||||
cancelbutton = 'Annuler',
|
|
||||||
initvalues = F,
|
|
||||||
submitlabel = 'Modifier les valeurs', readonly = REQUEST['_read_only']
|
|
||||||
))">
|
|
||||||
|
|
||||||
<dtml-if "tf[0] == 0">
|
|
||||||
<dtml-var "tf[1]">
|
|
||||||
<dtml-elif "tf[0] == -1">
|
|
||||||
<dtml-call "RESPONSE.redirect( REQUEST.HTTP_REFERER )" >
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 + '/entreprise_correspondant_list?entreprise_id=' + str(F['entreprise_id']) )" >
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-call "do_entreprise_correspondant_edit( tf[2] )">
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 + '/entreprise_correspondant_list?entreprise_id=' + str(F['entreprise_id']) )" >
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,52 +0,0 @@
|
|||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'E', do_entreprise_list( args={ 'entreprise_id' : entreprise_id } )[0])">
|
|
||||||
|
|
||||||
<h2>Listes des correspondants dans l'entreprise <dtml-var "E['nom']"> </h2>
|
|
||||||
|
|
||||||
<table class="corr_list">
|
|
||||||
|
|
||||||
<tr><th>Nom</th><th>Entreprise</th><th>Fonction</th><th>Téléphone</th><th>Mail</th><th>Note</th></tr>
|
|
||||||
|
|
||||||
<dtml-in "do_entreprise_correspondant_list( args={ 'entreprise_id' : entreprise_id })">
|
|
||||||
<dtml-let F="_['sequence-item']">
|
|
||||||
|
|
||||||
<tr class="<dtml-if sequence-odd>corr_list_odd<dtml-else>corr_list_even</dtml-if>">
|
|
||||||
|
|
||||||
<td><a class="corr_edit" href="entreprise_correspondant_edit?entreprise_corresp_id=<dtml-var "F['entreprise_corresp_id']">">
|
|
||||||
<dtml-if "F['nom']"><dtml-var "F['nom'].lower().capitalize()"></dtml-if>
|
|
||||||
<dtml-if "F['prenom']"> <dtml-var "F['prenom'].lower().capitalize()"></dtml-if>
|
|
||||||
</a>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
<td class="corr_descr"><dtml-var "E['nom']"></td>
|
|
||||||
|
|
||||||
<td class="corr_descr"><dtml-var "F['fonction']"></td>
|
|
||||||
|
|
||||||
<td class="corr_descr">
|
|
||||||
<dtml-if "F['phone1']"><dtml-var "F['phone1']"></dtml-if>
|
|
||||||
<dtml-if "F['phone2']"> / <dtml-var "F['phone2']"></dtml-if>
|
|
||||||
<dtml-if "F['mobile']"> / <dtml-var "F['mobile']"></dtml-if>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
<td class="corr_descr">
|
|
||||||
<dtml-if "F['mail1']"> <a href="mailto:<dtml-var "F['mail1']">"><dtml-var "F['mail1']"></a></dtml-if>
|
|
||||||
<dtml-if "F['mail1']"> <br> <a href="mailto:<dtml-var "F['mail2']">"><dtml-var "F['mail2']"></a></dtml-if>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
<td class="corr_descr"><dtml-var "F['note']"></td>
|
|
||||||
|
|
||||||
<td class="corr_descr"><a class="corr_delete" href="entreprise_correspondant_edit?entreprise_corresp_id=<dtml-var "F['entreprise_corresp_id']">">modifier</a> </td>
|
|
||||||
<td class="corr_descr"><a class="corr_delete" href="entreprise_correspondant_delete?entreprise_corresp_id=<dtml-var "F['entreprise_corresp_id']">">supprimer</a> </td>
|
|
||||||
</tr>
|
|
||||||
</dtml-let>
|
|
||||||
<dtml-else>
|
|
||||||
<tr><td colspan="4"><font color="red"><em>Aucun correspondant dans cette entreprise !</em></font></td></tr>
|
|
||||||
</dtml-in>
|
|
||||||
</table>
|
|
||||||
|
|
||||||
<p class="entreprise_create"><a class="entreprise_create" href="<dtml-var "URL1 + '/entreprise_correspondant_create?entreprise_id=' + entreprise_id">">
|
|
||||||
Ajouter un correspondant dans l'entreprise <dtml-var "E['nom']"> </a><p>
|
|
||||||
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,60 +0,0 @@
|
|||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'F', do_entreprise_list( args={ 'entreprise_id' : entreprise_id } )[0])">
|
|
||||||
|
|
||||||
|
|
||||||
<h2>Suppression de l'entreprise <dtml-var "F['nom']"> </h2>
|
|
||||||
|
|
||||||
<p class="entreprise_warning">Attention: supression définitive de l'entreprise, de ses correspondants et contacts.
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'Cl', do_entreprise_correspondant_list( args={ 'entreprise_id' : entreprise_id }))">
|
|
||||||
|
|
||||||
<dtml-if "len(Cl)">
|
|
||||||
<h3>Correspondants dans l'entreprise <dtml-var "F['nom']"> (seront <em>supprimés</em>):</h3>
|
|
||||||
<ul>
|
|
||||||
<dtml-in Cl>
|
|
||||||
<dtml-let c="_['sequence-item']">
|
|
||||||
<li><dtml-if "c['nom']"><dtml-var "c['nom'].lower().capitalize()"></dtml-if>
|
|
||||||
<dtml-if "c['prenom']"> <dtml-var "c['prenom'].lower().capitalize()"></dtml-if>
|
|
||||||
(<dtml-var "c['fonction']">)
|
|
||||||
</li>
|
|
||||||
</dtml-let c>
|
|
||||||
</dtml-in Cl>
|
|
||||||
</ul>
|
|
||||||
</dtml-if Cl>
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set( 'Cts', do_entreprise_contact_list( args={ 'entreprise_id' : entreprise_id }))">
|
|
||||||
<dtml-if "len(Cts)">
|
|
||||||
<h3>Contacts avec l'entreprise <dtml-var "F['nom']"> (seront <em>supprimés</em>):</h3>
|
|
||||||
<ul>
|
|
||||||
<dtml-in Cts>
|
|
||||||
<dtml-let c="_['sequence-item']">
|
|
||||||
<li><dtml-if "c['date']"><dtml-var "c['date']"></dtml-if>
|
|
||||||
<dtml-if "c['description']">(<dtml-var "c['description']">)</dtml-if>
|
|
||||||
</li>
|
|
||||||
</dtml-let c>
|
|
||||||
</dtml-in Cts>
|
|
||||||
</ul>
|
|
||||||
</dtml-if Cts>
|
|
||||||
|
|
||||||
<dtml-call "REQUEST.set('tf', TrivialFormulator( URL0, REQUEST.form,
|
|
||||||
( ('entreprise_id', { 'input_type' : 'hidden' }),
|
|
||||||
),
|
|
||||||
initvalues = F,
|
|
||||||
submitlabel = 'Confirmer la suppression',
|
|
||||||
cancelbutton = 'Annuler', readonly = REQUEST['_read_only']
|
|
||||||
))">
|
|
||||||
|
|
||||||
<dtml-if "tf[0] == 0">
|
|
||||||
<dtml-var "tf[1]">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-if "tf[0] == -1">
|
|
||||||
<dtml-call "RESPONSE.redirect( URL1 )">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-call "do_entreprise_delete( F['entreprise_id'] )">
|
|
||||||
<dtml-call "RESPONSE.redirect(URL1)">
|
|
||||||
</dtml-if>
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
@ -1,139 +0,0 @@
|
|||||||
<dtml-var "entreprise_header(REQUEST=REQUEST)">
|
|
||||||
|
|
||||||
<script type="text/javascript">
|
|
||||||
function entsub(event,ourform) {
|
|
||||||
if (event && event.which == 13)
|
|
||||||
ourform.submit();
|
|
||||||
else
|
|
||||||
return true;}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<dtml-if entreprise_page_size>
|
|
||||||
<dtml-call "REQUEST.set( 'entreprise_page_size', int(entreprise_page_size))">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-call "REQUEST.set( 'entreprise_page_size', 10 )">
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<h2><dtml-var title_or_id></h2>
|
|
||||||
|
|
||||||
<dtml-comment>
|
|
||||||
<p class="entreprise_warning">
|
|
||||||
Attention: version test préliminaire. Signaler les problèmes à <a href="mailto:viennet@lipn.univ-paris13.fr">Emmanuel</a>
|
|
||||||
</p>
|
|
||||||
</dtml-comment>
|
|
||||||
|
|
||||||
<dtml-unless sort_type><dtml-call "REQUEST.set( 'sort_type', 'nom' )"></dtml-unless>
|
|
||||||
<dtml-call "REQUEST.set( 'sort_on_contact', False )">
|
|
||||||
|
|
||||||
<dtml-if "sort_type=='nom'">
|
|
||||||
<dtml-call "REQUEST.set( 'sort_key', 'nom' )">
|
|
||||||
<dtml-elif "sort_type=='datecontact'">
|
|
||||||
<dtml-call "REQUEST.set( 'sort_on_contact', True )">
|
|
||||||
<dtml-call "REQUEST.set( 'sort_key', None )">
|
|
||||||
<dtml-elif "sort_type=='qualite_relation'">
|
|
||||||
<dtml-call "REQUEST.set( 'sort_key', 'qualite_relation desc, nom asc' )">
|
|
||||||
<dtml-elif "sort_type=='date_creation'">
|
|
||||||
<dtml-call "REQUEST.set( 'sort_key', 'date_creation desc, nom asc' )">
|
|
||||||
<dtml-else>
|
|
||||||
<p class="entreprise_warning">valeur invalide pour 'sort_type' !</p>
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<dtml-if etud_nom>
|
|
||||||
<dtml-call "REQUEST.set( 'Elist', do_entreprise_list_by_etud( args=REQUEST.form, sort_on_contact=sort_on_contact ) )">
|
|
||||||
<dtml-else>
|
|
||||||
<dtml-call "REQUEST.set( 'Elist', do_entreprise_list( args=REQUEST.form, test='~*', sort_on_contact=sort_on_contact, sortkey=sort_key ) )">
|
|
||||||
</dtml-if>
|
|
||||||
|
|
||||||
<dtml-unless start><dtml-call "REQUEST.set( 'start', 1)"></dtml-unless>
|
|
||||||
|
|
||||||
|
|
||||||
<form action="" method="GET">
|
|
||||||
<table><tr>
|
|
||||||
<th>nom</th><td><input type="text" name="nom" size="12" value="<dtml-if nom><dtml-var nom></dtml-if>" onkeypress="return entsub(event,this.form)"></input></td>
|
|
||||||
<th>ville</th><td><input type="text" name="ville" size="12" value="<dtml-if ville><dtml-var ville></dtml-if>" onkeypress="return entsub(event,this.form)"></input></td>
|
|
||||||
<th>étudiant</th><td><input type="text" name="etud_nom" size="12" value="<dtml-if etud_nom><dtml-var etud_nom></dtml-if>" onkeypress="return entsub(event,this.form)"></input></td>
|
|
||||||
|
|
||||||
<td><input type="submit" value="rechercher"></input></td>
|
|
||||||
<td> </td>
|
|
||||||
<td>Tri par: <select name="sort_type" onchange="this.form.submit()">
|
|
||||||
<option value="nom" <dtml-if "sort_type=='nom'">selected</dtml-if>>nom entreprise</option>
|
|
||||||
<option value="datecontact" <dtml-if "sort_type=='datecontact'">selected</dtml-if>>date dernier contact</option>
|
|
||||||
<option value="qualite_relation" <dtml-if "sort_type=='qualite_relation'">selected</dtml-if>>relation IUT/Entreprise</option>
|
|
||||||
<option value="date_creation" <dtml-if "sort_type=='date_creation'">selected</dtml-if>>date saisie entreprise</option>
|
|
||||||
</select></td>
|
|
||||||
</tr></table>
|
|
||||||
</form>
|
|
||||||
|
|
||||||
<table class="entreprise_list">
|
|
||||||
|
|
||||||
<dtml-in Elist size=entreprise_page_size start=start overlap=1>
|
|
||||||
<dtml-if sequence-start>
|
|
||||||
<table class="entreprise_list_title">
|
|
||||||
<tr class="entreprise_list_title"><td class="entreprise_list_title">Entreprises</td>
|
|
||||||
<td class="entreprise_list_title_res">Résultats <b><dtml-var start></b> - <b><dtml-try><dtml-var "_['next-sequence-start-number']"><dtml-except><dtml-var "len(Elist)"></dtml-try></b> sur <b><dtml-var "len(Elist)"> </b>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</table>
|
|
||||||
<table class="entreprise_list">
|
|
||||||
</dtml-if sequence-start>
|
|
||||||
|
|
||||||
<dtml-let F="_['sequence-item']">
|
|
||||||
<dtml-call "REQUEST.set( 'Cl', do_entreprise_correspondant_list( args={ 'entreprise_id' : F['entreprise_id'] }))">
|
|
||||||
<dtml-call "REQUEST.set( 'Ct', do_entreprise_contact_list( args={ 'entreprise_id' : F['entreprise_id'] }))">
|
|
||||||
|
|
||||||
<tr class="<dtml-if sequence-odd>entreprise_list_odd<dtml-else>entreprise_list_even</dtml-if>">
|
|
||||||
|
|
||||||
<td colspan="5" class="entreprise_descr_name"><a class="entreprise_edit" href="entreprise_edit?entreprise_id=<dtml-var "F['entreprise_id']">&start=<dtml-var start>"><dtml-var "F['nom']"></a></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="<dtml-if sequence-odd>entreprise_list_odd<dtml-else>entreprise_list_even</dtml-if>">
|
|
||||||
<td> </td>
|
|
||||||
<td class="entreprise_descr"><dtml-var "str_abbrev(F['ville'], 22)"></td>
|
|
||||||
<td class="entreprise_descr"><dtml-var "F['secteur']"> </td>
|
|
||||||
|
|
||||||
<td class="entreprise_descr_link">
|
|
||||||
<a class="entreprise_delete" href="entreprise_correspondant_list?entreprise_id=<dtml-var "F['entreprise_id']">"><dtml-var "len(Cl)"> corr.</a>
|
|
||||||
<dtml-if "sort_type=='qualite_relation'"><b><dtml-var "{100:'TB',75:'B',50:'M',25:'!' }.get(F['qualite_relation'],'?')"></b></dtml-if>
|
|
||||||
</td>
|
|
||||||
<td class="entreprise_descr_link"><a class="entreprise_delete" href="entreprise_contact_list?entreprise_id=<dtml-var "F['entreprise_id']">"><dtml-var "len(Ct)"> contacts</a>
|
|
||||||
<dtml-try>(<dtml-var "F['etud_nom']">)<dtml-except></dtml-try>
|
|
||||||
<dtml-try>(<dtml-var "F['date']">)<dtml-except></dtml-try>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
</tr>
|
|
||||||
</dtml-let>
|
|
||||||
<dtml-if sequence-end>
|
|
||||||
</table>
|
|
||||||
</dtml-if sequence-end>
|
|
||||||
<dtml-else Elist>
|
|
||||||
<p class="entreprise_warning">Aucune entreprise !</p>
|
|
||||||
</dtml-in>
|
|
||||||
|
|
||||||
|
|
||||||
<p>
|
|
||||||
<form action="setPageSizeCookie" method="GET">
|
|
||||||
<input type="hidden" name="target_url" value="<dtml-var "URL0+'?'+QUERY_STRING">"></input>
|
|
||||||
|
|
||||||
<dtml-in Elist size=entreprise_page_size start=start overlap=1>
|
|
||||||
<dtml-if sequence-start>
|
|
||||||
<dtml-if previous-sequence>
|
|
||||||
<a href="<dtml-var URL><dtml-var sequence-query>start=<dtml-var previous-sequence-start-number>">
|
|
||||||
page précédente</a>
|
|
||||||
</dtml-if previous-sequence>
|
|
||||||
</dtml-if sequence-start>
|
|
||||||
<dtml-if sequence-end>
|
|
||||||
<dtml-if next-sequence>
|
|
||||||
<a href="<dtml-var URL><dtml-var sequence-query>start=<dtml-var next-sequence-start-number>">
|
|
||||||
page suivante</a>
|
|
||||||
</dtml-if next-sequence>
|
|
||||||
</dtml-if sequence-end>
|
|
||||||
</dtml-in Elist>
|
|
||||||
Résultats par page :
|
|
||||||
<select name="entreprise_page_size" onchange="this.form.submit()">
|
|
||||||
<dtml-in "((5,5),(10,10),(15,15),(20,20),(30,30),(50,50),(1000,'Tous'))" prefix="label">
|
|
||||||
<option value="<dtml-var "label_key">" <dtml-if "label_key == entreprise_page_size">selected</dtml-if>><dtml-var label_item></option>
|
|
||||||
</dtml-in>
|
|
||||||
</select>
|
|
||||||
</form>
|
|
||||||
|
|
||||||
</p>
|
|
||||||
<dtml-var "entreprise_footer(REQUEST=REQUEST)">
|
|
Loading…
Reference in New Issue
Block a user