Utiliser les nouvelles fonctions generer_objet_*

pull/4795/head
Matthieu Marcillaud 1 year ago
parent e18e2d115e
commit 7e5c38cd5a

@ -232,7 +232,7 @@ function formulaires_administrer_mot_traiter_dist($id_mot) {
sql_insertq('spip_mots_liens', $a);
}
sql_delete('spip_mots_liens', 'id_mot=' . $id_mot);
$link = "<a href='" . generer_url_entite($id, 'mot') . "'>" . objet_info('mot', 'texte_objet') . " #$id</a>";
$link = "<a href='" . generer_objet_url($id, 'mot') . "'>" . objet_info('mot', 'texte_objet') . " #$id</a>";
$res['message_ok'] = _T('adminmots:result_fusionner_ok', ['mot' => $link]);
}

@ -191,7 +191,7 @@ parameters:
path: formulaires/administrer_mot.php
-
message: "#^Function generer_url_entite not found\\.$#"
message: "#^Function generer_objet_url not found\\.$#"
count: 1
path: formulaires/administrer_mot.php

@ -15,7 +15,7 @@
#BOITE_OUVRIR{'','notice'}
#SET{type,#TYPE|supprimer_numero}
<p><:mots:info_delet_mots_cles{titre_mot=#TITRE,type_mot=#GET{type},texte_lie=#GET{utilise}}:></p>
[(#BOUTON_ACTION{<:mots:info_oui_suppression_mot_cle:>,#URL_ACTION_AUTEUR{supprimer_mot,#ID_MOT,#ID_GROUPE|generer_url_entite{groupe_mots}}})]
[(#BOUTON_ACTION{<:mots:info_oui_suppression_mot_cle:>,#URL_ACTION_AUTEUR{supprimer_mot,#ID_MOT,#ID_GROUPE|generer_objet_url{groupe_mots}}})]
#BOITE_FERMER
</div>
]

@ -23,7 +23,7 @@ Ce squelette n'est utile que pour l'affichage éventuel de résultats du moteur
<BOUCLE_liste_groupe_mots(GROUPES_MOTS){id_?}{where?}{recherche?}{tri #ENV{par,num titre},#GET{defaut_tri}}{par titre}{pagination #ENV{nb,10}}>
<tr class="[(#COMPTEUR_BOUCLE|alterner{row_odd,row_even})]">
<td class='picto'>[(#VAL|puce_statut{groupe_mots,#ID_GROUPE,#ID_GROUPE})]</td>
<td class='titre principale'[(#LOGO_GROUPE_MOT|non) colspan='2']><a href="[(#ID_GROUPE|generer_url_entite{groupemot})]" title="<:info_numero_abbreviation|attribut_html:> #ID_GROUPE">[(#RANG). ]#TITRE</a></td>
<td class='titre principale'[(#LOGO_GROUPE_MOT|non) colspan='2']><a href="[(#ID_GROUPE|generer_objet_url{groupemot})]" title="<:info_numero_abbreviation|attribut_html:> #ID_GROUPE">[(#RANG). ]#TITRE</a></td>
[<td class='logo'>(#LOGO_GROUPE_MOT|image_reduire{40,40})</td>]
<td class='id'>[(#AUTORISER{modifier,groupemots,#ID_GROUPE}|?{
<a href="[(#URL_ECRIRE{groupe_mots_edit,id_groupe=#ID_GROUPE})]" title="<:mots:icone_modif_groupe_mots|attribut_html:>">#ID_GROUPE</a>,

@ -19,7 +19,7 @@
</thead>
<tbody>
<BOUCLE_liste_mot(MOTS){id_?}{where?}{tri #ENV{par,num titre},#GET{defaut_tri}}{par titre}{pagination #ENV{nb,10}}>
#SET{url_voir,#AUTORISER{voir,mot,#ID_MOT}|?{#ID_MOT|generer_url_entite{mot}|parametre_url{redirect,#ENV{retour}},''}}
#SET{url_voir,#AUTORISER{voir,mot,#ID_MOT}|?{#ID_MOT|generer_objet_url{mot}|parametre_url{redirect,#ENV{retour}},''}}
#SET{url_edit,#AUTORISER{modifier,mot,#ID_MOT}|?{#URL_ECRIRE{mot_edit,id_mot=#ID_MOT}|parametre_url{redirect,#ENV{retour}},''}}
<tr class="[(#COMPTEUR_BOUCLE|alterner{row_odd,row_even})]">
<td class='picto'>[(#VAL|puce_statut{mot,#ID_MOT,#ID_GROUPE})]</td>

@ -21,7 +21,7 @@
<BOUCLE_liste_mot(MOTS){id_?}{where?}{recherche?}{tri #ENV{par,num titre},#GET{defaut_tri}}{par titre}{pagination #ENV{nb,10}}>
<tr class="[(#COMPTEUR_BOUCLE|alterner{row_odd,row_even})]">
<td class='picto'>[(#VAL|puce_statut{mot,#ID_MOT,#ID_GROUPE})]</td>
<td class='titre principale'[(#LOGO_MOT|non) colspan='2']><a href="[(#ID_MOT|generer_url_entite{mot})]" title="<:info_numero_abbreviation|attribut_html:> #ID_MOT">[<span class='rang'>(#RANG).</span> ]#TITRE</a></td>
<td class='titre principale'[(#LOGO_MOT|non) colspan='2']><a href="[(#ID_MOT|generer_objet_url{mot})]" title="<:info_numero_abbreviation|attribut_html:> #ID_MOT">[<span class='rang'>(#RANG).</span> ]#TITRE</a></td>
[<td class='logo'>(#LOGO_MOT|image_reduire{40,40})</td>]
<td class='type secondaire'>#TYPE</td>
<td class='id'>[(#AUTORISER{modifier,mot,#ID_MOT}|?{

@ -35,7 +35,7 @@ points,-1
<BOUCLE_liste_mot(MOTS){id_groupe}{id_mot !IN #ENV{exclus}}{recherche #GET{recherche}}{tri #ENV{par,titre},#GET{defaut_tri}}{par multi titre}{pagination 10 mota#ID_GROUPE}>
<tr class="[(#COMPTEUR_BOUCLE|alterner{row_odd,row_even})]">
<td class='picto'>[(#VAL|puce_statut{mot,#ID_MOT,#ID_GROUPE})]</td>
<td class='titre principale'>[(#LOGO_MOT|image_reduire{20,20})]<a href="[(#ID_MOT|generer_url_entite{mot})]"
<td class='titre principale'>[(#LOGO_MOT|image_reduire{20,20})]<a href="[(#ID_MOT|generer_objet_url{mot})]"
title="<:info_numero_abbreviation|attribut_html:> #ID_MOT">[(#RANG). ]#TITRE</a></td>
<td class='action'><button type="submit" class="btn btn_link btn_secondaire" name="#GET{action}[mot-#ID_MOT-#OBJET-#ID_OBJET]" value="+"><:mots:lien_ajouter_mot:>[ (#CHEMIN_IMAGE{add-12.svg}|balise_img)]</button></td>
</tr>

@ -25,7 +25,7 @@
<BOUCLE_liste_mot(MOTS){id_mot IN #GET{selection}}{id_groupe?}{where?}{tri #ENV{par,type},#GET{defaut_tri}}{par multi titre}{pagination #ENV{nb,10} motl}>
<tr class="[(#COMPTEUR_BOUCLE|alterner{row_odd,row_even})][(#ID_MOT|=={#ENV{id_lien_ajoute}}|oui)append]">
<td class='picto'>[(#VAL|puce_statut{mot,#ID_MOT,#ID_GROUPE})]</td>
<td class='titre principale'[(#LOGO_MOT|non)colspan="2"]><a href="[(#ID_MOT|generer_url_entite{mot})]" title="<:info_numero_abbreviation|attribut_html:> #ID_MOT">[(#RANG). ]#TITRE</a></td>
<td class='titre principale'[(#LOGO_MOT|non)colspan="2"]><a href="[(#ID_MOT|generer_objet_url{mot})]" title="<:info_numero_abbreviation|attribut_html:> #ID_MOT">[(#RANG). ]#TITRE</a></td>
[<td class="logo">(#LOGO_MOT|image_reduire{40,40})</td>]
<td class='type secondaire'>#TYPE</td>
<td class='action'><button type="submit" class="btn btn_link delete" name="supprimer_lien[mot-#ID_MOT-#OBJET-#ID_OBJET]" value="X"><:mots:info_retirer_mot:>[ (#CHEMIN_IMAGE{supprimer-12.svg}|balise_img)]</button></td>

@ -16,7 +16,7 @@
<tr class="[(#COMPTEUR_BOUCLE|alterner{row_odd,row_even})]">
<td class='picto'>#GET{picto}</td>
<td class='titre principale'><a
href="[(#ID_OBJET|generer_url_entite{#OBJET})]"
href="[(#ID_OBJET|generer_objet_url{#OBJET})]"
title="<:info_numero_abbreviation|attribut_html:> #ID_OBJET">[(#INFO_TITRE{#OBJET,#ID_OBJET}|sinon{<:info_sans_titre:>})]</a>
</td>
<td class='id'>[(#AUTORISER{modifier,#OBJET,#ID_OBJET}|?{

@ -10,7 +10,7 @@
[<:titre_groupe_mots:>
<h1>(#ENV{titre,#INFO_TITRE{groupe_mots,#ID_GROUPE}|sinon{<:mots:titre_nouveau_groupe:>}})</h1>]
</div>
#SET{redirect,#ENV{redirect,#ID_GROUPE|generer_url_entite{groupe_mots}}}
#SET{redirect,#ENV{redirect,#ID_GROUPE|generer_objet_url{groupe_mots}}}
[(#ENV{retourajax,''}|oui)
#SET{redirect,'javascript:if (window.jQuery) jQuery(".entete-formulaire .retour a").followLink();'}
<div class="ajax">

@ -13,7 +13,7 @@
<h1>(#ENV{titre,#INFO_TITRE{mot,#ID_MOT}|sinon{<:mots:texte_nouveau_mot:>}})</h1>]
</div>
#SET{redirect,#ENV{redirect,#ID_MOT|generer_url_entite{mot}}}
#SET{redirect,#ENV{redirect,#ID_MOT|generer_objet_url{mot}}}
[(#ENV{retourajax,''}|oui)
#SET{redirect,'javascript:if (window.jQuery) jQuery(".entete-formulaire .retour a").followLink();'}
<div class="ajax">

Loading…
Cancel
Save