Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Automatically Disable user based on data from custom field

Karen Waters November 19, 2019

Hello there,

 

I am trying to achieve disabling of users based on dates which are entered in a custom field. This could be useful for temp staff who have a start and end date. Would like an automation to automatically deactivate the user once this time is up. I have looked at automation for jira doing this but not sure the property key can be updated by automation.

 

Any ideas would be appreciated.

 

Thank you

1 answer

1 accepted

0 votes
Answer accepted
Brant Schroeder
Community Champion
November 19, 2019

You can use scriptrunner to automatically disable and enable users.  They have an example here: https://library.adaptavist.com/entity/deactivate-idle-users?_ga=2.114642631.1582705835.1574107332-1726082589.1570807866  You would just need to change the logic to look at your custom field and not at last login.  You can then use scriptrunners scheduled jobs to run the script every night for instance or every hour.

Suggest an answer

Log in or Sign up to answer