علامة حسابات متعددة على أنها حسابات معلقة

When a user is marked as suspended from the UI, the backend updates the suspended_at and suspended_till fields in the user table. I have 500 users whose profiles need to be marked as suspended. I’m planning to retrieve these user IDs based on their group ID and set the suspended_at field to: current date
and the suspended_till field to:
‘Sun, 01 Aug 3024 02:30:00.000000000 UTC +00:00’

Can anyone suggest the best way to accomplish this?

I think you would need to do this either through the API or using the rails console.

Are you familiar with either of these options?

إعجابَين (2)

Yes i am planning to do this using rails console

إعجاب واحد (1)

There’s some advice on this in Administrative Bulk Operations

إعجاب واحد (1)

Figure out how to get the users and then use update_all.

I think ChatGPT can tell you pretty well

إعجاب واحد (1)

Thank you so much everyone. I always find it pretty cool to see replies. Big love!