public function clear() {
		$this->request->allowMethod('post', 'delete');
		$ds = $this->QueueInfo->getDataSource();
		if ($ds->truncate($this->QueueInfo)) {
			$this->Flash->success(__d('cake_settings_app', 'The task queue has been cleared.'));
		} else {
			$this->Flash->error(__d('cake_settings_app', 'The task queue could not be cleared. Please, try again.'));
		}

		$urlRedirect = ['plugin' => 'cake_settings_app', 'controller' => 'queues', 'action' => 'index'];
		return $this->redirect($urlRedirect);
	}
public function clear() {
		$this->request->allowMethod('post', 'delete');
		$ds = $this->QueueInfo->getDataSource();
		if ($ds->truncate($this->QueueInfo)) {
			$this->Flash->success(__d('cake_settings_app', 'The task queue has been cleared.'));
		} else {
			$this->Flash->error(__d('cake_settings_app', 'The task queue could not be cleared. Please, try again.'));
		}

		$urlRedirect = ['plugin' => 'cake_settings_app', 'controller' => 'queues', 'action' => 'index'];
		return $this->redirect($urlRedirect);
	}
public function clear ( ) { $ this -> request -> allowMethod ( 'post' , 'delete' ) ; $ ds = $ this -> QueueInfo -> getDataSource ( ) ; if ( $ ds -> truncate ( $ this -> QueueInfo ) ) { $ this -> Flash -> success ( __d ( 'cake_settings_app' , 'The task queue has been cleared.' ) ) ; } else { $ this -> Flash -> error ( __d ( 'cake_settings_app' , 'The task queue could not be cleared. Please, try again.' ) ) ; } $ urlRedirect = [ 'plugin' => 'cake_settings_app' , 'controller' => 'queues' , 'action' => 'index' ] ; return $ this -> redirect ( $ urlRedirect ) ; }
Action `clear`. Used to clear queue of tasks

@return void
Action clear . Used to clear queue of tasks