'Services' => Array (
'Envoyer un mail' => 'sendmail.php' ,
'Forums & PA' => 'banana/' ,
- 'Listes de diffusion' => '###url###' ,
+ 'Listes de diffusion' => 'listes/' ,
'Micropaiements' => 'paiement/' ,
'Patte cassée' => 'pattecassee.php' ,
),
background: inherit;
}
+table.tinybicol td, table.bicol td { padding-left: 4px; padding-right: 4px; }
td.half { width: 50%; padding: 4px; }
td.titre {
}
/* vim: set et ts=4 sts=4 sw=4: */
-/* $Id: default.css,v 1.41 2004-09-06 06:25:07 x2000coic Exp $ */
+/* $Id: default.css,v 1.42 2004-09-10 11:52:36 x2000habouzit Exp $ */
--- /dev/null
+<?php
+/***************************************************************************
+ * Copyright (C) 2003-2004 Polytechnique.org *
+ * http://opensource.polytechnique.org/ *
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ * This program is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+ * GNU General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU General Public License *
+ * along with this program; if not, write to the Free Software *
+ * Foundation, Inc., *
+ * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *
+ ***************************************************************************
+ $Id: index.php,v 1.1 2004-09-10 11:52:36 x2000habouzit Exp $
+ ***************************************************************************/
+
+require("auto.prepend.inc.php");
+new_skinned_page('listes/index.tpl', AUTH_COOKIE);
+include('xml-rpc-client.inc.php');
+$res = $globals->db->query("SELECT password FROM auth_user_md5 WHERE user_id={$_SESSION['uid']}");
+list($pass) = mysql_fetch_row($res);
+mysql_free_result($res);
+
+$client = new xmlrpc_client("http://{$_SESSION['uid']}:$pass@localhost:4949");
+
+$listes = $client->get_lists();
+$page->assign_by_ref('listes',$listes);
+$page->run();
+?>
#* Foundation, Inc., *
#* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *
#***************************************************************************
-# $Id: mailman-rpc.py,v 1.13 2004-09-10 07:02:02 x2000habouzit Exp $
+# $Id: mailman-rpc.py,v 1.14 2004-09-10 11:52:37 x2000habouzit Exp $
#***************************************************************************
import base64, MySQLdb
is_owner = userdesc.address in mlist.owner
is_admin = mm_cfg.ADMIN_ML_OWNER in mlist.owner
if ( mlist.advertised ) or ( perms == 'admin' and is_admin ) or is_member or is_owner:
- result.append( (name,1-mlist.advertised+is_admin,is_member,is_owner) )
+ result.append( {
+ 'list' : name,
+ 'desc' : mlist.description,
+ 'diff' : mlist.generic_nonmember_action,
+ 'ins' : mlist.subscribe_policy > 0,
+ 'priv' : (1-mlist.advertised)+2*is_admin,
+ 'you' : is_member + 2*is_owner
+ } )
return result
def get_members((userdesc,perms),listname):
--- /dev/null
+{***************************************************************************
+ * Copyright (C) 2003-2004 Polytechnique.org *
+ * http://opensource.polytechnique.org/ *
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ * This program is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+ * GNU General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU General Public License *
+ * along with this program; if not, write to the Free Software *
+ * Foundation, Inc., *
+ * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *
+ ***************************************************************************
+ $Id: index.tpl,v 1.1 2004-09-10 11:52:37 x2000habouzit Exp $
+ ***************************************************************************}
+
+ {dynamic}
+
+<div class="rubrique">
+ Listes de diffusion publiques
+</div>
+
+<table class='bicol' cellpadding='0' cellspacing='0'>
+ <tr>
+ <th>Liste</th>
+ <th>Description</th>
+ <th>Diffusion</th>
+ <th>Inscription</th>
+ </tr>
+ {foreach from=$listes item=liste}
+ {if $liste.priv eq 0}
+ <tr class='{cycle values="impair,pair"}'>
+ <td>{$liste.list}{if $liste.you>1}*{/if}</td>
+ <td>{$liste.desc}</td>
+ <td class='center'>{if $liste.diff}modérée{else}libre{/if}</td>
+ <td class='right'>{if $liste.you is odd}désinscription{elseif $liste.ins}ins modérée{else}inscription{/if}</td>
+ </tr>
+ {/if}
+ {/foreach}
+</table>
+
+<div class="rubrique">
+ Listes de diffusion privées
+</div>
+
+<table class='bicol' cellpadding='0' cellspacing='0'>
+ <tr>
+ <th>Liste</th>
+ <th>Description</th>
+ <th>Diffusion</th>
+ <th>Inscription</th>
+ </tr>
+ {foreach from=$listes item=liste}
+ {if $liste.priv eq 1}
+ <tr class='{cycle values="impair,pair"}'>
+ <td>{$liste.list}{if $liste.you>1}*{/if}</td>
+ <td>{$liste.desc}</td>
+ <td class='center'>{if $liste.diff}modérée{else}libre{/if}</td>
+ <td class='right'>{if $liste.you is odd}désinscription{elseif $liste.ins}ins modérée{else}inscription{/if}</td>
+ </tr>
+ {/if}
+ {/foreach}
+</table>
+
+<div class="rubrique">
+ Listes d'administration
+</div>
+
+<table class='bicol' cellpadding='0' cellspacing='0'>
+ <tr>
+ <th>Liste</th>
+ <th>Description</th>
+ <th>Diffusion</th>
+ <th>Inscription</th>
+ </tr>
+ {foreach from=$listes item=liste}
+ {if $liste.priv > 1}
+ <tr class='{cycle values="impair,pair"}'>
+ <td>{$liste.list}{if $liste.you>1}*{/if}</td>
+ <td>{$liste.desc}</td>
+ <td class='center'>{if $liste.diff}modérée{else}libre{/if}</td>
+ <td class='right'>{if $liste.you is odd}désinscription{elseif $liste.ins}ins modérée{else}inscription{/if}</td>
+ </tr>
+ {/if}
+ {/foreach}
+</table>
+
+{/dynamic}
+
+{* vim:set et sw=2 sts=2 sws=2: *}