function handlers()
{
return array(
- 'lists' => $this->make_hook('lists', AUTH_MDP),
- 'lists/ajax' => $this->make_hook('ajax', AUTH_MDP, 'user', NO_AUTH),
- 'lists/create' => $this->make_hook('create', AUTH_MDP, 'lists'),
-
- 'lists/members' => $this->make_hook('members', AUTH_COOKIE),
- 'lists/csv' => $this->make_hook('csv', AUTH_COOKIE),
- 'lists/annu' => $this->make_hook('annu', AUTH_COOKIE),
- 'lists/archives' => $this->make_hook('archives', AUTH_COOKIE),
+ 'lists' => $this->make_hook('lists', AUTH_PASSWD, 'user'),
+ 'lists/ajax' => $this->make_hook('ajax', AUTH_PASSWD, 'user', NO_AUTH),
+ 'lists/create' => $this->make_hook('create', AUTH_PASSWD, 'lists'),
+
+ 'lists/members' => $this->make_hook('members', AUTH_COOKIE, 'user'),
+ 'lists/csv' => $this->make_hook('csv', AUTH_COOKIE, 'user'),
+ 'lists/annu' => $this->make_hook('annu', AUTH_COOKIE, 'user'),
+ 'lists/archives' => $this->make_hook('archives', AUTH_COOKIE, 'user'),
'lists/archives/rss' => $this->make_hook('rss', AUTH_PUBLIC, 'user', NO_HTTPS),
- 'lists/moderate' => $this->make_hook('moderate', AUTH_MDP),
- 'lists/admin' => $this->make_hook('admin', AUTH_MDP),
- 'lists/options' => $this->make_hook('options', AUTH_MDP),
- 'lists/delete' => $this->make_hook('delete', AUTH_MDP),
+ 'lists/moderate' => $this->make_hook('moderate', AUTH_PASSWD, 'user'),
+ 'lists/admin' => $this->make_hook('admin', AUTH_PASSWD, 'user'),
+ 'lists/options' => $this->make_hook('options', AUTH_PASSWD, 'user'),
+ 'lists/delete' => $this->make_hook('delete', AUTH_PASSWD, 'user'),
- 'lists/soptions' => $this->make_hook('soptions', AUTH_MDP),
- 'lists/check' => $this->make_hook('check', AUTH_MDP),
- 'admin/lists' => $this->make_hook('admin_all', AUTH_MDP, 'admin'),
- 'admin/aliases' => $this->make_hook('aaliases', AUTH_MDP, 'admin')
+ 'lists/soptions' => $this->make_hook('soptions', AUTH_PASSWD, 'user'),
+ 'lists/check' => $this->make_hook('check', AUTH_PASSWD, 'user'),
+ 'admin/lists' => $this->make_hook('admin_all', AUTH_PASSWD, 'admin'),
+ 'admin/aliases' => $this->make_hook('aaliases', AUTH_PASSWD, 'admin')
);
}
$list = list_fetch_basic_info(list_extract_members($members[1]));
pl_cached_content_headers('text/x-csv', 1);
- echo "email,nom,promo\n";
+ echo "nom,promo\n";
echo implode("\n", $list);
exit;
}
$page->kill("La liste n'existe pas ou tu n'as pas le droit d'en voir les détails.");
}
- global $platal;
list(,$members) = $this->client->get_members($liste);
- $users = array();
- foreach ($members as $m) {
- $users[] = $m[1];
+
+ if ($action == 'moderators') {
+ $users = $owners;
+ $show_moderators = true;
+ $action = $subaction;
+ $subaction = '';
+ } else {
+ $show_moderators = false;
+ $users = array();
+ foreach ($members as $m) {
+ $users[] = $m[1];
+ }
}
+
require_once 'userset.inc.php';
- $view = new ArraySet($users);
- $view->addMod('trombi', 'Trombinoscope', true, array('with_promo' => true));
+ $view = new UserArraySet($users);
+ $view->addMod('trombi', 'Trombinoscope', false, array('with_promo' => true));
+ $view->addMod('listmember', 'Annuaire', true);
if (empty($GLOBALS['IS_XNET_SITE'])) {
$view->addMod('minifiche', 'Mini-fiches', false);
}
- // TODO: Reactivate when the new map is completed.
- // $view->addMod('geoloc', 'Planisphère');
+ $view->addMod('map', 'Planisphère');
$view->apply("lists/annu/$liste", $page, $action, $subaction);
- if ($action == 'geoloc' && $subaction) {
- return;
- }
$page->changeTpl('lists/annu.tpl');
- $moderos = list_sort_owners($owners[1]);
$page->assign_by_ref('details', $owners[0]);
- $page->assign_by_ref('owners', $moderos);
+ $page->assign('show_moderators', $show_moderators);
}
function handler_archives($page, $liste = null, $action = null, $artid = null)
case 'marketu': case 'markets':
require_once 'emails.inc.php';
+ $user = User::get($uids[$key]);
$mail = valide_email($mails[$key]);
- if (isvalid_email_redirection($mail)) {
+ if (isvalid_email_redirection($mail, $user)) {
$from = ($action == 'marketu') ? 'user' : 'staff';
$market = Marketing::get($uids[$key], $mail);
if (!$market) {