Sylvain Beucler <[EMAIL PROTECTED]> tapota :

> While it is up to the project admins to decide how and whether they  
> want to be notified, I guess we could add a 'Notify all admins' option  
> enabled by default on project creation.
>
> What do you think?
>
> As for existing projects, maybe we could directly warn the admins or  
> post a news item.
>

The notification works with addresses lists. We could imagine adding
the possibility to notify admin without filling a list (it may be
confusing, tough) but I think it is first up to project admin to set
up notification as they want. When an account is created, nowhere it
is said they'll be notified of posted support request.

If you feel we really need a checkbox 'notify all admins', it could be
implemented by on a branch, to keep the trunk stable enough (the
notitification is not a simple part). In the meantime, you can use the
"mail creation + trigger project creation" link, on the page where you
approve new projects, to automatically add the person that submitted
the project to the notification list from the start.
At gna!, we use this link to create the lists project-cvs that get cvs
notifications. To do so, we have in our specific content, in
admin/proj_email.txt: 

function approval_gen_email ($group_name, $unix_group_name) {

  // When sending the approval mail, create a mailing list for cvs commits
  $group_id = group_getid($unix_group_name);
  $list_password = substr(md5($GLOBALS['session_hash'] . time() . rand(0,40000))
,0,16);

  $admins = db_query("SELECT user.user_id AS user_id,user.user_name AS user_name
, user.realname AS realname, user.email AS email "
                        . "FROM user,user_group "
                        . "WHERE user_group.user_id=user.user_id AND user_group.
group_id=".$group_id." AND user_group.admin_flags = 'A'");
  $row_admins = db_fetch_array($admins);


  $sql = "INSERT INTO mail_group_list "
    . "(group_id,list_name,is_public,password,list_admin,status,description) VAL
UES ('"
    . $group_id."',"
    . "'".$unix_group_name."-cvs',"
    . "'1',"    
    . "'$list_password',"       
    . "'".$row_admins[user_id]."',"     
    . "1,"      
    . "'".htmlspecialchars("Commits on the $group_name CVS repositories.")."')";
  
  db_query($sql);

   [...]


}



-- 
Mathieu Roy

  +---------------------------------------------------------------------+
  | General Homepage:           http://yeupou.coleumes.org/             |
  | Computing Homepage:         http://alberich.coleumes.org/           |
  | Not a native english speaker:                                       |
  |     http://stock.coleumes.org/doc.php?i=/misc-files/flawed-english  |
  +---------------------------------------------------------------------+

Reply via email to