Skip to content

Commit 7659b34

Browse files
author
Mark Scherer
committed
Fixed backend.
1 parent 932b5df commit 7659b34

File tree

4 files changed

+14
-11
lines changed

4 files changed

+14
-11
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"fig-r/psr2r-sniffer": "dev-master"
2828
},
2929
"suggest": {
30-
"dereuromark/cakephp-tools": "For the Email lib and QueueEmailTask. Or write your own task here."
30+
"dereuromark/cakephp-tools": "For the Email lib and QueueEmailTask. Or write your own task here. Also for admin backend."
3131
},
3232
"support": {
3333
"source": "https://github.com/dereuromark/cakephp-queue"

src/Controller/Admin/QueueController.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
use Cake\Core\Configure;
66
use Cake\Event\Event;
7-
use Queue\Controller\AppController;
7+
use App\Controller\AppController;
88

99
class QueueController extends AppController {
1010

@@ -40,7 +40,6 @@ public function index() {
4040

4141
$this->set(compact('current', 'data', 'pendingDetails', 'status'));
4242
$this->helpers[] = 'Tools.Format';
43-
$this->helpers[] = 'Tools.Datetime';
4443
}
4544

4645
/**

src/Controller/AppController.php

Lines changed: 0 additions & 8 deletions
This file was deleted.

src/Model/Table/QueuedTasksTable.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -529,4 +529,16 @@ public function clearKey() {
529529
$this->_key = null;
530530
}
531531

532+
/**
533+
* truncate()
534+
*
535+
* @return void
536+
*/
537+
public function truncate() {
538+
$sql = $this->schema()->truncateSql($this->_connection);
539+
foreach ($sql as $snippet) {
540+
$this->_connection->execute($snippet);
541+
}
542+
}
543+
532544
}

0 commit comments

Comments
 (0)