$client=$app->db->queryOneRecord("SELECT limit_maildomain, default_mailserver FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = ?",$client_group_id);
$client=$app->db->queryOneRecord("SELECT client.mail_servers, limit_maildomain, default_mailserver FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = ?",$client_group_id);
// When the record is updated
// When the record is updated
if($this->id>0){
if($this->id>0){
// restore the server ID if the user is not admin and record is edited
// restore the server ID if the user is not admin and record is edited