本文整理汇总了PHP中notice::delete_vedette_links方法的典型用法代码示例。如果您正苦于以下问题:PHP notice::delete_vedette_links方法的具体用法?PHP notice::delete_vedette_links怎么用?PHP notice::delete_vedette_links使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类notice
的用法示例。
在下文中一共展示了notice::delete_vedette_links方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: del_notice
static function del_notice($id)
{
global $dbh, $class_path, $pmb_synchro_rdf, $pmb_notice_img_folder_id;
//Suppression de la vignette de la notice si il y en a une d'uploadée
if ($pmb_notice_img_folder_id) {
$req = "select repertoire_path from upload_repertoire where repertoire_id ='" . $pmb_notice_img_folder_id . "'";
$res = pmb_mysql_query($req, $dbh);
if (pmb_mysql_num_rows($res)) {
$rep = pmb_mysql_fetch_object($res);
$img = $rep->repertoire_path . "img_" . $id;
@unlink($img);
}
}
//synchro_rdf (à laisser en premier : a besoin des éléments de la notice pour retirer du graphe rdf)
if ($pmb_synchro_rdf) {
$synchro_rdf = new synchro_rdf();
$synchro_rdf->delRdf($id, 0);
}
$p_perso = new parametres_perso("notices");
$p_perso->delete_values($id);
$requete = "DELETE FROM notices_categories WHERE notcateg_notice='{$id}'";
@pmb_mysql_query($requete, $dbh);
$requete = "DELETE FROM notices_langues WHERE num_notice='{$id}'";
@pmb_mysql_query($requete, $dbh);
$requete = "DELETE FROM notices WHERE notice_id='{$id}'";
@pmb_mysql_query($requete, $dbh);
audit::delete_audit(AUDIT_NOTICE, $id);
// Effacement de l'occurence de la notice ds la table notices_global_index :
$requete = "DELETE FROM notices_global_index WHERE num_notice=" . $id;
@pmb_mysql_query($requete, $dbh);
// Effacement des occurences de la notice ds la table notices_mots_global_index :
$requete = "DELETE FROM notices_mots_global_index WHERE id_notice=" . $id;
@pmb_mysql_query($requete, $dbh);
// Effacement des occurences de la notice ds la table notices_fields_global_index :
$requete = "DELETE FROM notices_fields_global_index WHERE id_notice=" . $id;
@pmb_mysql_query($requete, $dbh);
$requete = "delete from notices_relations where num_notice='{$id}' OR linked_notice='{$id}' ";
@pmb_mysql_query($requete, $dbh);
// elimination des docs numeriques
$req_explNum = "select explnum_id from explnum where explnum_notice=" . $id . " ";
$result_explNum = @pmb_mysql_query($req_explNum, $dbh);
while ($explNum = pmb_mysql_fetch_object($result_explNum)) {
$myExplNum = new explnum($explNum->explnum_id);
$myExplNum->delete();
}
// Clean des vedettes
notice::delete_vedette_links($id);
$requete = "DELETE FROM responsability WHERE responsability_notice='{$id}'";
@pmb_mysql_query($requete, $dbh);
$requete = "DELETE FROM bannette_contenu WHERE num_notice='{$id}'";
@pmb_mysql_query($requete, $dbh);
$requete = "delete from caddie_content using caddie, caddie_content where caddie_id=idcaddie and type='NOTI' and object_id='" . $id . "' ";
@pmb_mysql_query($requete, $dbh);
$requete = "delete from analysis where analysis_notice='" . $id . "' ";
@pmb_mysql_query($requete, $dbh);
$requete = "update bulletins set num_notice=0 where num_notice='" . $id . "' ";
@pmb_mysql_query($requete, $dbh);
//Suppression de la reference a la notice dans la table suggestions
$requete = "UPDATE suggestions set num_notice = 0 where num_notice=" . $id;
@pmb_mysql_query($requete, $dbh);
//Suppression de la reference a la notice dans la table lignes_actes
$requete = "UPDATE lignes_actes set num_produit=0, type_ligne=0 where num_produit='" . $id . "' and type_ligne in ('1','5') ";
@pmb_mysql_query($requete, $dbh);
//suppression des droits d'acces user_notice
$requete = "delete from acces_res_1 where res_num=" . $id;
@pmb_mysql_query($requete, $dbh);
// suppression des tags
$rqt_del = "delete from tags where num_notice=" . $id;
@pmb_mysql_query($rqt_del, $dbh);
//suppression des avis
$requete = "delete from avis where num_notice=" . $id;
@pmb_mysql_query($requete, $dbh);
//suppression des droits d'acces empr_notice
$requete = "delete from acces_res_2 where res_num=" . $id;
@pmb_mysql_query($requete, $dbh);
// Supression des liens avec les titres uniformes
$requete = "DELETE FROM notices_titres_uniformes WHERE ntu_num_notice='{$id}'";
@pmb_mysql_query($requete, $dbh);
//Suppression dans les listes de lecture partagées
$requete = "SELECT id_liste, notices_associees from opac_liste_lecture";
$res = pmb_mysql_query($requete, $dbh);
$id_tab = array();
while ($notices = pmb_mysql_fetch_object($res)) {
$id_tab = explode(',', $notices->notices_associees);
for ($i = 0; $i < sizeof($id_tab); $i++) {
if ($id_tab[$i] == $id) {
unset($id_tab[$i]);
}
}
$requete = "UPDATE opac_liste_lecture set notices_associees='" . addslashes(implode(',', $id_tab)) . "' where id_liste='" . $notices->id_liste . "'";
pmb_mysql_query($requete, $dbh);
}
// Suppression des résas
$requete = "DELETE FROM resa WHERE resa_idnotice=" . $id;
pmb_mysql_query($requete, $dbh);
// Suppression des transferts_demande
$requete = "DELETE FROM transferts_demande using transferts_demande, transferts WHERE num_transfert=id_transfert and num_notice=" . $id;
pmb_mysql_query($requete, $dbh);
// Suppression des transferts
$requete = "DELETE FROM transferts WHERE num_notice=" . $id;
//.........这里部分代码省略.........
示例2: VALUES
$requete = 'INSERT INTO notices_relations VALUES("' . $id . '","' . $f_rel_id . '","' . $f_rel_type . '","' . $f_rel_rank . '")';
@pmb_mysql_query($requete);
} elseif ($f_rel_direction == 'down') {
$requete = 'INSERT INTO notices_relations VALUES("' . $f_rel_id . '","' . $id . '","' . $f_rel_type . '","' . $f_rel_rank . '")';
@pmb_mysql_query($requete);
}
}
}
// nomenclature
global $pmb_nomenclature_activate;
if ($pmb_nomenclature_activate) {
$nomenclature = new nomenclature_record_ui($id);
$nomenclature->save_form();
}
// Clean des vedettes
notice::delete_vedette_links($id);
// traitement des auteurs
$rqt_del = "delete from responsability where responsability_notice='{$id}' ";
$res_del = pmb_mysql_query($rqt_del);
$rqt_ins = "INSERT INTO responsability (responsability_author, responsability_notice, responsability_fonction, responsability_type, responsability_ordre) VALUES ";
$i = 0;
$var_name = 'notice_role_composed';
$role_composed = ${$var_name};
$var_name = 'notice_role_autre_composed';
$role_composed_autre = ${$var_name};
$var_name = 'notice_role_secondaire_composed';
$role_composed_secondaire = ${$var_name};
while ($i <= count($f_aut) - 1) {
$id_aut = $f_aut[$i]['id'];
if ($id_aut) {
$fonc_aut = $f_aut[$i]['fonction'];