Commit a7388815 authored by jlaval's avatar jlaval
Browse files

* Fix sas

parent 55888ee8
......@@ -762,8 +762,10 @@ class utilisateur extends stdentity
if (!$derniere_cotiz)
return $fragment;
$fragment = '('.$fragment.' OR ('.$id_groupe.' = \'ae_membres\' AND '.$date_field.' <= '.$derniere_cotiz.'))';
if ( is_null($this->groupes) )
$this->load_groups();
$fragment = '('.$fragment.' OR ('.$id_groupe.' = '.array_search('ae_membres', $this->groupes).' AND '.$date_field.' <= '.$derniere_cotiz.'))';
}
/* Extra infos management */
......
......@@ -255,7 +255,7 @@ class catphoto extends basedb
"WHERE " .
"id_catph_parent='".$this->id."' AND " .
"((droits_acces_catph & 0x1) OR " .
"((droits_acces_catph & 0x10) AND ".$user->get_grps_authorization_fragment('date_debut_catph', $grps).") OR " .
"((droits_acces_catph & 0x10) AND ".$user->get_grps_authorization_fragment('date_debut_catph', $grps, 'id_groupe').") OR " .
"(id_groupe_admin IN ($grps)) OR " .
"((droits_acces_catph & 0x100) AND id_utilisateur='".$user->id."')) ";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment