Jump to content

Confirmation message and popup on manual execution of scheduled tasks


mutu310

Recommended Posts

mutu310

I've created a scheduled task without a task trigger in my plugin (BlurN) and I'd like it to display some confirmation message in a popup to make sure that the user understands the implications of running the tasks (basically clearing the plugin's database, which cannot be undone). If we could perhaps have a property to set a confirmation message I think it would help improve usability and the end user experience.

Link to comment
Share on other sites

Scheduled tasks are designed to be completely non-interactive - meaning they don't require a user to be at a console when they run.  How would the server know where to produce this message?

 

If you need this type of thing, you should probably handle it in your plug-in config page instead.

Link to comment
Share on other sites

mutu310

@@Luke, no I don't mean the config screen, where it can be explained through the description.

 

@@ebr, what I mean is that the confirmation modal popup would ONLY show when the user is trying to manually run the task. It would avoid users clicking on it by mistake and then having no means to undo it. And only for scheduled tasks that require it. A sort of "Are you sure you want to xxxxxx?"

Link to comment
Share on other sites

Yes, but, in your case, if the task is never actually supposed to be run on a schedule and, instead is a manual "clear" operation, then I think maybe it would be better implemented as a part of the plug-in configuration instead of a scheduled task - where someone could create a schedule for it.

 

Unless, of course, that is what you intend - for people to schedule it periodically.

Link to comment
Share on other sites

mutu310

Yes, but, in your case, if the task is never actually supposed to be run on a schedule and, instead is a manual "clear" operation, then I think maybe it would be better implemented as a part of the plug-in configuration instead of a scheduled task - where someone could create a schedule for it.

 

Unless, of course, that is what you intend - for people to schedule it periodically.

Well, yes and no. To be honest clearing out a database should neither be a scheduled task nor a configuration, but these are the options we are limited with.

 

In any case my suggestion still holds. Some scheduled tasks that either take a long time processing or may involve editing data in a way that may not be intended would benefit from a confirmation popup to prevent unwanted and unintentional manual clicks in the scheduled tasks page. If anything to make sure the user understands the repercussions of running a task that may not even be scheduled.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...