public function taskSave()
    {
        $taskId = $this->getTaskId();
        $tasks = self::taskFileLoad();
        if (empty($taskId)) {
            $task_ids = array_keys($tasks);
            $this->setTaskId(array_pop($task_ids) + 1);
            $this->setTs(date('Y-m-d H:i:s'));
        }

        $tasks[$this->getTaskId()] = $this;
        return $this->taskFileSave($tasks);
    }