From 981d6bb2fbf8a249dd5cde339da8bc029b23794b Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Jacob?= Date: Tue, 13 Jan 2009 15:47:24 +0100 Subject: [PATCH] Watches search_names instead of nom and nick for notification. --- include/notifs.inc.php | 2 +- modules/profile/general.inc.php | 2 +- upgrade/newdirectory-0.0.1/14_watchnames.sql | 13 +++++++++++++ 3 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 upgrade/newdirectory-0.0.1/14_watchnames.sql diff --git a/include/notifs.inc.php b/include/notifs.inc.php index 14472b2..c8c9c0a 100644 --- a/include/notifs.inc.php +++ b/include/notifs.inc.php @@ -138,7 +138,7 @@ function select_notifs($mail, $uid=null, $last=null, $iterator=true) // {{{ global $prf_desc; -$prf_desc = array('nom' => 'Son patronyme', +$prf_desc = array('search_names' => 'L\'un de ses noms', 'freetext' => 'Le texte libre', 'mobile' => 'Son numéro de téléphone portable', 'nationalite' => 'Sa nationalité', diff --git a/modules/profile/general.inc.php b/modules/profile/general.inc.php index 3b26ddd..7fd9816 100644 --- a/modules/profile/general.inc.php +++ b/modules/profile/general.inc.php @@ -374,7 +374,7 @@ class ProfileGeneral extends ProfilePage $this->watched= array('freetext' => true, 'tels' => true, 'networking' => true, 'edus' => true, 'nationalite' => true, 'nationalite2' => true, - 'nationalite3' => true); + 'nationalite3' => true, 'search_names' => true); } protected function _fetchData() diff --git a/upgrade/newdirectory-0.0.1/14_watchnames.sql b/upgrade/newdirectory-0.0.1/14_watchnames.sql new file mode 100644 index 0000000..8baebda --- /dev/null +++ b/upgrade/newdirectory-0.0.1/14_watchnames.sql @@ -0,0 +1,13 @@ +ALTER TABLE watch_profile MODIFY field enum('search_names', 'nom', 'freetext', 'mobile', 'nationalite', + 'nationalite2', 'nationalite3', 'nick', 'web', 'networking', + 'edus', 'addresses', 'section', 'binets', 'medals', 'cv', + 'jobs', 'photo'); + +UPDATE watch_profile SET field = 'search_names' WHERE field = 'nom' OR field = 'nick'; + +ALTER TABLE watch_profile MODIFY field enum('search_names', 'freetext', 'mobile', 'nationalite', + 'nationalite2', 'nationalite3', 'web', 'networking','edus', + 'addresses', 'section', 'binets', 'medals', 'cv', 'jobs', + 'photo'); + +# vim:set syntax=mysql: -- 2.1.4