How to get group_id of Current User in redmine
Added by anhkhoa Michel over 7 years ago
Hi all. I want to get group_id of current user And I used: User.current.group.id but This error. Please help me!!!!
A user can actually have several groups.
That's why in order to collect the array of Ids you should use:
isSuporte = false User.current.group_ids.each do |item| if item == 8 isSuporte = true end end