Switch Execution State to Running when executing
This commit is contained in:
parent
16c1b5c506
commit
f892db7dda
@ -34,6 +34,10 @@ public abstract class TrangaTask
|
|||||||
this.language = language;
|
this.language = language;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Set state to running
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="taskManager"></param>
|
||||||
public abstract void Execute(TaskManager taskManager);
|
public abstract void Execute(TaskManager taskManager);
|
||||||
|
|
||||||
/// <returns>True if elapsed time since last execution is greater than set interval</returns>
|
/// <returns>True if elapsed time since last execution is greater than set interval</returns>
|
||||||
|
@ -8,6 +8,7 @@ public class DownloadNewChaptersTask : TrangaTask
|
|||||||
|
|
||||||
public override void Execute(TaskManager taskManager)
|
public override void Execute(TaskManager taskManager)
|
||||||
{
|
{
|
||||||
|
this.state = ExecutionState.Running;
|
||||||
Publication pub = (Publication)this.publication!;
|
Publication pub = (Publication)this.publication!;
|
||||||
Connector connector = taskManager.GetConnector(this.connectorName);
|
Connector connector = taskManager.GetConnector(this.connectorName);
|
||||||
|
|
||||||
|
@ -8,6 +8,7 @@ public class UpdateKomgaLibraryTask : TrangaTask
|
|||||||
|
|
||||||
public override void Execute(TaskManager taskManager)
|
public override void Execute(TaskManager taskManager)
|
||||||
{
|
{
|
||||||
|
this.state = ExecutionState.Running;
|
||||||
if (taskManager.komga is null)
|
if (taskManager.komga is null)
|
||||||
return;
|
return;
|
||||||
Komga komga = taskManager.komga;
|
Komga komga = taskManager.komga;
|
||||||
|
Loading…
Reference in New Issue
Block a user