| | <?php |
| |
|
| | namespace Kanboard\Action; |
| |
|
| | use Kanboard\Model\TaskModel; |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | class TaskMoveColumnClosed extends Base |
| | { |
| | |
| | |
| | |
| | |
| | |
| | |
| | public function getDescription() |
| | { |
| | return t('Move the task to another column when closed'); |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | public function getCompatibleEvents() |
| | { |
| | return array( |
| | TaskModel::EVENT_CLOSE, |
| | ); |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | public function getActionRequiredParameters() |
| | { |
| | return array( |
| | 'dest_column_id' => t('Destination column'), |
| | ); |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | public function getEventRequiredParameters() |
| | { |
| | return array( |
| | 'task_id', |
| | 'task' => array( |
| | 'project_id', |
| | 'column_id', |
| | 'swimlane_id', |
| | 'is_active', |
| | ) |
| | ); |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | public function doAction(array $data) |
| | { |
| | return $this->taskPositionModel->movePosition( |
| | $data['task']['project_id'], |
| | $data['task']['id'], |
| | $this->getParam('dest_column_id'), |
| | 1, |
| | $data['task']['swimlane_id'], |
| | true, |
| | false |
| | ); |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | public function hasRequiredCondition(array $data) |
| | { |
| | return $data['task']['column_id'] != $this->getParam('dest_column_id') && $data['task']['is_active'] == 0; |
| | } |
| | } |
| |
|