Use router parameters in Admin modules

- Remove 10 @TODO tags

# Conflicts:
#	src/Module/Admin/DBSync.php
#	src/Module/Admin/Themes/Details.php
#	src/Module/Admin/Themes/Embed.php
This commit is contained in:
Hypolite Petovan 2020-09-08 10:38:35 -04:00
parent 98eb53c20f
commit 2ce15cae1a
8 changed files with 427 additions and 501 deletions

View file

@ -42,13 +42,10 @@ class Queue extends BaseAdmin
{
parent::content($parameters);
$a = DI::app();
// @TODO: Replace with parameter from router
$deferred = $a->argc > 2 && $a->argv[2] == 'deferred';
$status = $parameters['status'] ?? '';
// get jobs from the workerqueue table
if ($deferred) {
if ($status == 'deferred') {
$condition = ["NOT `done` AND `retrial` > ?", 0];
$sub_title = DI::l10n()->t('Inspect Deferred Worker Queue');
$info = DI::l10n()->t("This page lists the deferred worker jobs. This are jobs that couldn't be executed at the first time.");