- Modifies cron router/UI to display proper status message when WP task

scheduler is configured and cron is not running
- Updates sending queue worker and related components to stop (delete)
  cron when all processing is done
This commit is contained in:
Vlad
2016-07-19 09:02:58 -04:00
parent 5ed0a5819c
commit a438f13bb0
6 changed files with 65 additions and 13 deletions

View File

@ -53,10 +53,13 @@ define(
}.bind(this));
},
render: function() {
if(this.state.status === 'loading') {
return(<div>{MailPoet.I18n.t('loadingDaemonStatus')}</div>);
}
switch(this.state.status) {
case 'loading':
return(
<div>
{MailPoet.I18n.t('loadingDaemonStatus')}
</div>
);
case 'started':
return(
<div>
@ -85,6 +88,20 @@ define(
</div>
);
break;
case 'wordpress_task_scheduler_enabled':
return(
<div>
{MailPoet.I18n.t('wordpressTaskSchedulerEnabled')}
</div>
);
break;
case false:
return(
<div>
{MailPoet.I18n.t('daemonNotRunning')}
</div>
);
break;
}
}
});