* Adjust code style.
This commit is contained in:
@@ -157,7 +157,7 @@ class task extends control
|
||||
elseif($this->post->after == 'toTaskList')
|
||||
{
|
||||
setcookie('moduleBrowseParam', 0, 0, $this->config->webRoot, '', false, false);
|
||||
$taskLink = $this->createLink('project', 'task', "projectID=$projectID&status=bymodule¶m=$moduleID&orderBy=id_desc");
|
||||
$taskLink = $this->createLink('project', 'task', "projectID=$projectID&status=unclosed¶m=0&orderBy=id_desc");
|
||||
$response['locate'] = $taskLink;
|
||||
$this->send($response);
|
||||
}
|
||||
@@ -1028,9 +1028,10 @@ class task extends control
|
||||
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
|
||||
if(!empty($changes))
|
||||
if($this->post->comment != '' or !empty($changes))
|
||||
{
|
||||
$actionID = $this->action->create('task', $taskID, 'Closed', $this->post->comment);
|
||||
$action = (!empty($changes)) ? 'Closed' : 'Commented';
|
||||
$actionID = $this->action->create('task', $taskID, $action, $this->post->comment);
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
|
||||
|
||||
@@ -1677,12 +1677,12 @@ class taskModel extends model
|
||||
*
|
||||
* @param int $taskID
|
||||
* @access public
|
||||
* @return void
|
||||
* @return array
|
||||
*/
|
||||
public function close($taskID)
|
||||
{
|
||||
$oldTask = $this->dao->select('*')->from(TABLE_TASK)->where('id')->eq($taskID)->fetch();
|
||||
if($oldTask->status == 'closed') return;
|
||||
if($oldTask->status == 'closed') return array();
|
||||
|
||||
$now = helper::now();
|
||||
$task = fixer::input('post')
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->task->realStarted;?></th>
|
||||
<td><div class='datepicker-wrapper'><?php echo html::input('realStarted', $task->realStarted != '0000-00-00' ? $task->realStarted : '', "class='form-control form-datetime'");?></div></td><td></td>
|
||||
<td><div class='datepicker-wrapper'><?php echo html::input('realStarted', $task->realStarted != '0000-00-00 00:00:00' ? $task->realStarted : '', "class='form-control form-datetime'");?></div></td><td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->task->finishedDate;?></th>
|
||||
|
||||
Reference in New Issue
Block a user