Best practice forum (Archived)

Changed recertification window not taking affecting already enrolled users

 
Gavin Williamson-King
Changed recertification window not taking affecting already enrolled users
di Gavin Williamson-King - Friday, 4 September 2015, 02:51
 

One of our clients has set up a certification initially with a recertification window of 3 months before expiry. They have since changed the recertification window to 1 day before expiry, but users who were assigned to the certification before this change seem to still have the 3month window.

All users are assigned to the certification via a dynamic audience.

So i have a few questions on how to proceed with this.

Would unassigning and reassigning the audience to the certification cause the window to be updated?

Would there be any adverse effects to doing this e.g. would users lose their certification completions and expiry dates?

Also, would we need to wait for overnight cron to run inbetween unassigning and reassigning?

 

Alternatively, would it be possible to update the recertification window data in the database(MySQL) using something along the lines of

UPDATE mdl_certif_completion SET timewindowopens = (timeexpires - 86400);

so that all assignments have a window of 1 day, or is that likely to confuse the system?

 

We are running v2.6.12

? ?
Re: Changed recertification window not taking affecting already enrolled users
di ? ? - Friday, 4 September 2015, 10:38
 

+1 Gavin, I actually have a similar issue to yours so I'm interested in the answer as well.

Nathan Lewis
Re: Changed recertification window not taking affecting already enrolled users
di Nathan Lewis - Sunday, 6 September 2015, 15:24
Gruppo Totara

Hi Gavin and Patricia.

Changing the window period or the active period doesn't have an effect on users who are currently certified. The next time they recertify, the new periods will be used to calculate the next window open date and expiry date. Users who are assigned but not yet certified will use the new settings.

Unassigning and reassigning would cause the period to be updated, but that's not a good idea. The completion information might be restored correctly. There is a tool available to fix records that have been restored incorrectly, but you're better off not getting in that situation to start with.

The reset due to unassigning and reassigning only happens if the user assignments are actually processed in between. If there are more than 200 users involved in the cert, user assignment processing will be delayed until the next cron run (deferred user assignments are processed every cron run, not nightly). If you unassign and reassign before cron runs then it should be the same as making no change (and the window open dates wouldn't be changed either).

I probably shouldn't be suggesting this, but your db update is probably fairly safe. Especially since the window open date is fairly isolated (it's used to open the window and nothing else). But I don't recommend getting in the habit of fixing things this way. Just make really sure that you're updating the correct records - add a "WHERE timeexpires > 0 AND timewindowopens > 0" just to be safe, and obviously make sure it's the correct set of users/certs. And do a db backup first!

But if you can wait a bit longer, there is currently a tool in development which is designed to do exactly what you want to do. It lets you apply any changes you've made to the active period or the window period to users who are already certified. It will be a separate download, but integrates into Totara. It's currently being tested, and should be released soon (hopefully within the next month) if no other problems are identified.

One more thing: Window period of 1 day means that the window will open one day before expiry and the user must complete all courses required for recertification in that same day, or else their certification will expiry. There's nothing to stop you doing that, but it sounds unusual.

Nathan