How to extend time of all suspended users by one command?

Is it possible to extend the suspension to all users (only those who have been suspended) for another week/month etc ?

1 Like

You can look at Administrative Bulk Operations for some hints.

3 Likes

Okay, thanks.
Now I managed to suspend the users of the trust_group_0 in
but in that too… myself

How to separate trust_level_0 but only users from this group and not to all (trust 1 , trust 2 and staff account include in trust 0 group ?)

have try somethink like this:

users = User.joins(:group_users).where(group_users: {group_id: Group.find_by_name("trust_level_0").id } && "user_stats.post_count = 0 ")

or

target_group = Group.find_by_name(“trust_level_0”)
users = User.joins(:group_users).where(group_users: {group_id: target_group.id} && "user_stats.post_count = 0)