* finish task #1393.
This commit is contained in:
@@ -548,6 +548,8 @@ class bug extends control
|
||||
|
||||
foreach($allChanges as $bugID => $changes)
|
||||
{
|
||||
if(empty($changes)) continue;
|
||||
|
||||
$actionID = $this->action->create('bug', $bugID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
$this->sendmail($bugID, $actionID);
|
||||
|
||||
@@ -244,11 +244,10 @@ class product extends control
|
||||
{
|
||||
foreach($allChanges as $productID => $changes)
|
||||
{
|
||||
if(!empty($changes))
|
||||
{
|
||||
$actionID = $this->loadModel('action')->create('product', $productID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
if(empty($changes)) continue;
|
||||
|
||||
$actionID = $this->loadModel('action')->create('product', $productID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
}
|
||||
die(js::locate($this->session->productList, 'parent'));
|
||||
|
||||
@@ -931,11 +931,10 @@ class project extends control
|
||||
{
|
||||
foreach($allChanges as $projectID => $changes)
|
||||
{
|
||||
if(!empty($changes))
|
||||
{
|
||||
$actionID = $this->loadModel('action')->create('project', $projectID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
if(empty($changes)) continue;
|
||||
|
||||
$actionID = $this->loadModel('action')->create('project', $projectID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
}
|
||||
die(js::locate($this->session->projectList, 'parent'));
|
||||
|
||||
@@ -308,6 +308,8 @@ class story extends control
|
||||
{
|
||||
foreach($allChanges as $storyID => $changes)
|
||||
{
|
||||
if(empty($changes)) continue;
|
||||
|
||||
$actionID = $this->action->create('story', $storyID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
$this->sendmail($storyID, $actionID);
|
||||
|
||||
@@ -276,23 +276,22 @@ class task extends control
|
||||
{
|
||||
foreach($allChanges as $taskID => $changes)
|
||||
{
|
||||
if(!empty($changes))
|
||||
{
|
||||
$actionID = $this->loadModel('action')->create('task', $taskID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
$this->sendmail($taskID, $actionID);
|
||||
if(empty($changes)) continue;
|
||||
|
||||
$task = $this->task->getById($taskID);
|
||||
if($task->fromBug != 0)
|
||||
$actionID = $this->loadModel('action')->create('task', $taskID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
$this->sendmail($taskID, $actionID);
|
||||
|
||||
$task = $this->task->getById($taskID);
|
||||
if($task->fromBug != 0)
|
||||
{
|
||||
foreach($changes as $change)
|
||||
{
|
||||
foreach($changes as $change)
|
||||
if($change['field'] == 'status')
|
||||
{
|
||||
if($change['field'] == 'status')
|
||||
{
|
||||
$confirmURL = $this->createLink('bug', 'view', "id=$task->fromBug");
|
||||
$cancelURL = $this->server->HTTP_REFERER;
|
||||
die(js::confirm(sprintf($this->lang->task->remindBug, $task->fromBug), $confirmURL, $cancelURL, 'parent', 'parent'));
|
||||
}
|
||||
$confirmURL = $this->createLink('bug', 'view', "id=$task->fromBug");
|
||||
$cancelURL = $this->server->HTTP_REFERER;
|
||||
die(js::confirm(sprintf($this->lang->task->remindBug, $task->fromBug), $confirmURL, $cancelURL, 'parent', 'parent'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -484,6 +484,8 @@ class testcase extends control
|
||||
{
|
||||
foreach($allChanges as $caseID => $changes )
|
||||
{
|
||||
if(empty($changes)) continue;
|
||||
|
||||
$actionID = $this->loadModel('action')->create('case', $caseID, 'Edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
|
||||
@@ -210,11 +210,10 @@ class todo extends control
|
||||
$allChanges = $this->todo->batchUpdate();
|
||||
foreach($allChanges as $todoID => $changes)
|
||||
{
|
||||
if(!empty($changes))
|
||||
{
|
||||
$actionID = $this->loadModel('action')->create('todo', $todoID, 'edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
if(empty($changes)) continue;
|
||||
|
||||
$actionID = $this->loadModel('action')->create('todo', $todoID, 'edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
}
|
||||
|
||||
die(js::locate($this->session->todoList, 'parent'));
|
||||
|
||||
Reference in New Issue
Block a user