Merge branch 'dev' into frederic/fix_1865_api_expose_pj_champ
This commit is contained in:
commit
a5835a9777
2 changed files with 4 additions and 3 deletions
|
@ -237,9 +237,10 @@ module NewGestionnaire
|
|||
|
||||
when 'user', 'etablissement', 'entreprise'
|
||||
if filter['column'] == 'date_creation'
|
||||
date = filter['value'].to_date rescue nil
|
||||
dossiers
|
||||
.includes(filter['table'])
|
||||
.where("#{filter['table'].pluralize}.#{filter['column']} = ?", filter['value'].to_date)
|
||||
.where("#{filter['table'].pluralize}.#{filter['column']} = ?", date)
|
||||
else
|
||||
dossiers
|
||||
.includes(filter['table'])
|
||||
|
|
|
@ -35,8 +35,8 @@ module Flipflop::Strategies
|
|||
end
|
||||
|
||||
def find_current_administrateur
|
||||
if request.session["warden.user.user.key"]
|
||||
administrateur_id = request.session["warden.user.user.key"][0][0]
|
||||
if request.session["warden.user.administrateur.key"]
|
||||
administrateur_id = request.session["warden.user.administrateur.key"][0][0]
|
||||
Administrateur.find_by(id: administrateur_id)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue