Merge branch 'master' of https://gitlab.zcorp.cc/easycorp/zentaopms into importExport

This commit is contained in:
tanghucheng
2022-07-08 11:00:38 +08:00
35 changed files with 677 additions and 286 deletions
+68 -68
View File
@@ -11,13 +11,13 @@ class Subversion
public $svnVersion;
/**
* Construct
*
* @param string $client
* @param string $root
* @param string $account
* @param string $password
* @param string $encoding
* Construct
*
* @param string $client
* @param string $root
* @param string $account
* @param string $password
* @param string $encoding
* @access public
* @return void
*/
@@ -37,10 +37,10 @@ class Subversion
}
/**
* List files.
*
* @param string $path
* @param string $revision
* List files.
*
* @param string $path
* @param string $revision
* @access public
* @return array
*/
@@ -91,10 +91,10 @@ class Subversion
/**
* Get tags.
*
* @param string $path
* @param string $revision
* @param bool $onlyDir
*
* @param string $path
* @param string $revision
* @param bool $onlyDir
* @access public
* @return array
*/
@@ -129,7 +129,7 @@ class Subversion
/**
* Get branch.
*
*
* @access public
* @return array
*/
@@ -140,9 +140,9 @@ class Subversion
/**
* Get last log.
*
* @param string $path
* @param int $count
*
* @param string $path
* @param int $count
* @access public
* @return array
*/
@@ -170,8 +170,8 @@ class Subversion
foreach($parsedComments->logentry as $entry)
{
$log = new stdclass();
$log->committer = (string)$entry->author;
$log->revision = (int)$entry['revision'];
$log->committer = (string)$entry->author;
$log->revision = (int)$entry['revision'];
$log->comment = trim((string)$entry->msg);
$log->time = date('Y-m-d H:i:s', strtotime($entry->date));
$log->change = array();
@@ -188,12 +188,12 @@ class Subversion
/**
* Get log.
*
* @param string $path
* @param int $fromRevision
* @param string $toRevision
* @param int $count
* @param bool $quiet
*
* @param string $path
* @param int $fromRevision
* @param string $toRevision
* @param int $count
* @param bool $quiet
* @access public
* @return array
*/
@@ -229,17 +229,17 @@ class Subversion
foreach($parsedComments->logentry as $entry)
{
$log = new stdclass();
$log->committer = (string)$entry->author;
$log->revision = (int)$entry['revision'];
$log->committer = (string)$entry->author;
$log->revision = (int)$entry['revision'];
$log->comment = trim((string)$entry->msg);
$log->time = date('Y-m-d H:i:s', strtotime($entry->date));
$log->change = array();
if(!empty($entry->paths))
{
foreach($entry->paths->path as $path)
foreach($entry->paths->path as $path)
{
$pathInfo = array();
foreach($path->attributes() as $attr => $value) $pathInfo[$attr] = (string)$value;
foreach($path->attributes() as $attr => $value) $pathInfo[$attr] = (string)$value;
$log->change[(string)$path] = $pathInfo;
}
}
@@ -257,9 +257,9 @@ class Subversion
/**
* Blame file.
*
* @param string $path
* @param int $revision
*
* @param string $path
* @param int $revision
* @access public
* @return array
*/
@@ -298,7 +298,7 @@ class Subversion
{
foreach($parsedResult->target->entry as $line)
{
if($line->commit['revision'] != $revision)
if($line->commit['revision'] != $revision)
{
$blame = array();
$blame['revision'] = (int)$line->commit['revision'];
@@ -327,10 +327,10 @@ class Subversion
/**
* Diff file.
*
* @param string $path
* @param int $fromRevision
* @param int $toRevision
*
* @param string $path
* @param int $fromRevision
* @param int $toRevision
* @access public
* @return array
*/
@@ -355,9 +355,9 @@ class Subversion
/**
* Cat file.
*
* @param string $entry
* @param string $revision
*
* @param string $entry
* @param string $revision
* @access public
* @return string
*/
@@ -380,9 +380,9 @@ class Subversion
/**
* Get info.
*
* @param string $entry
* @param string $revision
*
* @param string $entry
* @param string $revision
* @access public
* @return object
*/
@@ -421,8 +421,8 @@ class Subversion
/**
* Exec svn cmd.
*
* @param string $cmd
*
* @param string $cmd
* @access public
* @return array
*/
@@ -434,8 +434,8 @@ class Subversion
/**
* Parse diff.
*
* @param array $lines
*
* @param array $lines
* @access public
* @return array
*/
@@ -514,9 +514,9 @@ class Subversion
/**
* Get commit count.
*
* @param int $commits
* @param int $lastVersion
*
* @param int $commits
* @param int $lastVersion
* @access public
* @return int
*/
@@ -547,7 +547,7 @@ class Subversion
/**
* Get first revision.
*
*
* @access public
* @return int
*/
@@ -561,7 +561,7 @@ class Subversion
/**
* Get latest revision.
*
*
* @access public
* @return int
*/
@@ -573,9 +573,9 @@ class Subversion
/**
* Get commits.
*
* @param string $version
* @param int $count
*
* @param string $version
* @param int $count
* @access public
* @return array
*/
@@ -608,8 +608,8 @@ class Subversion
foreach($parsedComments->logentry as $entry)
{
$parsedLog = new stdClass();
$parsedLog->committer = (string)$entry->author;
$parsedLog->revision = (int)$entry['revision'];
$parsedLog->committer = (string)$entry->author;
$parsedLog->revision = (int)$entry['revision'];
$parsedLog->comment = trim((string)$entry->msg);
$parsedLog->time = date('Y-m-d H:i:s', strtotime($entry->date));
$logs['commits'][$parsedLog->revision] = $parsedLog;
@@ -632,8 +632,8 @@ class Subversion
/**
* Replace svn auth.
*
* @param string $cmd
*
* @param string $cmd
* @access public
* @return string
*/
@@ -643,11 +643,11 @@ class Subversion
}
/**
* Build command.
*
* @param string $path
* @param string $action
* @param string $param
* Build command.
*
* @param string $path
* @param string $action
* @param string $param
* @access public
* @return string
*/
@@ -668,8 +668,8 @@ class Subversion
/**
* Get SVN version.
*
* @param string $client
*
* @param string $client
* @access public
* @return string
*/
+6 -4
View File
@@ -138,10 +138,11 @@ class action extends control
* Undelete an object.
*
* @param int $actionID
* @param string $browseType
* @access public
* @return void
*/
public function undelete($actionID)
public function undelete($actionID, $browseType = 'all')
{
$oldAction = $this->action->getById($actionID);
$extra = $oldAction->extra == ACTIONMODEL::BE_HIDDEN ? 'hidden' : 'all';
@@ -149,7 +150,7 @@ class action extends control
$this->action->undelete($actionID);
$sameTypeObjects = $this->action->getTrashes($oldAction->objectType, $extra, 'id_desc', null);
$browseType = $sameTypeObjects ? $oldAction->objectType : 'all';
$browseType = ($sameTypeObjects and $browseType != 'all') ? $oldAction->objectType : 'all';
return print(js::locate($this->createLink('action', 'trash', "browseType=$browseType&type=$extra"), 'parent'));
}
@@ -158,17 +159,18 @@ class action extends control
* Hide an deleted object.
*
* @param int $actionID
* @param string $browseType
* @access public
* @return void
*/
public function hideOne($actionID)
public function hideOne($actionID, $browseType = 'all')
{
$oldAction = $this->action->getById($actionID);
$this->action->hideOne($actionID);
$sameTypeObjects = $this->action->getTrashes($oldAction->objectType, 'all', 'id_desc', null);
$browseType = $sameTypeObjects ? $oldAction->objectType : 'all';
$browseType = ($sameTypeObjects and $browseType != 'all') ? $oldAction->objectType : 'all';
return print(js::locate($this->createLink('action', 'trash', "browseType=$browseType"), 'parent'));
}
+2 -2
View File
@@ -139,8 +139,8 @@
<td><?php echo $action->date;?></td>
<td>
<?php
common::printLink('action', 'undelete', "actionid=$action->id", $lang->action->undelete, 'hiddenwin');
if($type == 'all') common::printLink('action', 'hideOne', "actionid=$action->id", $lang->action->hideOne, 'hiddenwin');
common::printLink('action', 'undelete', "actionid=$action->id&browseType=$currentObjectType", $lang->action->undelete, 'hiddenwin');
if($type == 'all') common::printLink('action', 'hideOne', "actionid=$action->id&browseType=$currentObjectType", $lang->action->hideOne, 'hiddenwin');
?>
</td>
</tr>
+77 -20
View File
@@ -997,13 +997,26 @@ class bug extends control
if(isonlybody())
{
$execution = $this->loadModel('execution')->getByID($bug->execution);
if(isset($execution->type) and $execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($bug->execution, $this->session->execLaneType ? $this->session->execLaneType : 'all', 'id_desc', 0, $kanbanGroup, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
if(isset($execution->type) and $execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($bug->execution, $execLaneType, 'id_desc', 0, $kanbanGroup, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($bug->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'bug' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"bug\", $kanbanData)"));
}
}
else
{
@@ -1621,16 +1634,27 @@ class bug extends control
if(isonlybody())
{
$execution = $this->loadModel('execution')->getByID($bug->execution);
if(isset($execution->type) and $execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($bug->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
if(isset($execution->type) and $execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($bug->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($bug->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'bug' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"bug\", $kanbanData)"));
}
}
else
{
@@ -1716,16 +1740,27 @@ class bug extends control
parse_str($extra, $output);
if(isonlybody())
{
if(isset($execution->type) and $execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($bug->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if(isset($execution->type) and $execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($bug->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($bug->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'bug' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"bug\", $kanbanData)"));
}
}
else
{
@@ -1879,16 +1914,27 @@ class bug extends control
if(isonlybody())
{
$execution = $this->loadModel('execution')->getByID($bug->execution);
if(isset($execution->type) and $execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($bug->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if(isset($execution->type) and $execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($bug->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($bug->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'bug' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"bug\", $kanbanData)"));
}
}
else
{
@@ -2086,7 +2132,18 @@ class bug extends control
if($this->viewType == 'json') return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess));
if(isonlybody()) return print(js::reload('parent.parent'));
if($from == 'taskkanban') return print(js::reload('parent'));
if($from == 'taskkanban')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($bug->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'bug' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban(\"bug\", $kanbanData)"));
}
$locateLink = $this->session->bugList ? $this->session->bugList : inlink('browse', "productID={$bug->product}");
return print(js::locate($locateLink, 'parent'));
+1 -1
View File
@@ -119,7 +119,7 @@ foreach(explode(',', $config->bug->create->requiredFields) as $field)
<td>
<div class='input-group'>
<div class="input-control has-icon-right">
<?php echo html::input("title[$i]", $bugTitle, "class='form-control'") . html::hidden("uploadImage[$i]", $fileName);?>
<?php echo html::input("title[$i]", $bugTitle, "class='form-control title-import'") . html::hidden("uploadImage[$i]", $fileName);?>
<div class="colorpicker">
<button type="button" class="btn btn-link dropdown-toggle" data-toggle="dropdown"><span class="cp-title"></span><span class="color-bar"></span><i class="ic"></i></button>
<ul class="dropdown-menu clearfix">
+1
View File
@@ -2416,6 +2416,7 @@ EOD;
($module == 'my' and strpos('|changepassword|preference|', "|{$method}|") !== false) or
($module == 'file' and strpos('|read|download|uploadimages|ajaxwopifiles|', "|{$method}|") !== false) or
($module == 'sso' and $method == 'login') or
($module == 'report' && $method == 'annualdata') or
($module == 'traincourse' and $method == 'ajaxuploadlargefile'))
{
return;
+9 -1
View File
@@ -113,13 +113,21 @@ class deptModel extends model
krsort($deptMenu);
$topMenu = array_pop($deptMenu);
$topMenu = explode("\n", trim((string)$topMenu));
$lastMenu[] = '/' . $this->lang->dept->noDepartment;
if($this->app->tab == 'report')
{
$lastMenu[] = '/' . $this->lang->dept->noDepartment;
}
else
{
$lastMenu[] = '/';
}
foreach($topMenu as $menu)
{
if(!strpos($menu, '|')) continue;
list($label, $deptID) = explode('|', $menu);
$lastMenu[$deptID] = $label;
}
return $lastMenu;
}
+2 -1
View File
@@ -589,7 +589,8 @@ class doc extends control
if($from == 'lib')
{
$response['locate'] = $this->createLink('doc', 'objectLibs', "type=$objectType&objectID=0&libID={$doc->lib}");
$objectID = $objectType == 'project' ? $doc->project : $doc->product;
$response['locate'] = $this->createLink('doc', 'objectLibs', "type=$objectType&objectID={$objectID}&libID={$doc->lib}");
}
}
return $this->send($response);
+37 -17
View File
@@ -1376,16 +1376,17 @@ class execution extends control
list($begin, $end) = $this->execution->getBeginEnd4CFD($execution);
$dateList = date::getDateList($begin, $end, 'Y-m-d', '');
list($cycleTimeAvg, $throughput) = $this->execution->getCFDStatistics($executionID, $dateList, $type);
//list($cycleTimeAvg, $throughput) = $this->execution->getCFDStatistics($executionID, $dateList, $type);
$chartData = $this->execution->buildCFDData($executionID, $dateList, $type);
if(isset($chartData['line'])) $chartData['line'] = array_reverse($chartData['line']);
$this->view->title = $this->lang->execution->CFD;
$this->view->type = $type;
$this->view->execution = $execution;
$this->view->executionName = $execution->name;
$this->view->executionID = $executionID;
$this->view->chartData = $this->execution->buildCFDData($executionID, $dateList, $type);
$this->view->cycleTimeAvg = $cycleTimeAvg;
$this->view->throughput = $throughput;
$this->view->chartData = $chartData;
$this->display();
}
@@ -1397,10 +1398,9 @@ class execution extends control
* @access public
* @return void
*/
public function computeCFD($reload = 'no', $executionID = 0, $date = '')
public function computeCFD($reload = 'no', $executionID = 0)
{
$date = date('Y-m-d', strtotime($date));
$this->execution->computeCFD($executionID, $date);
$this->execution->computeCFD($executionID);
if($reload == 'yes') return print(js::reload('parent'));
}
@@ -3065,14 +3065,24 @@ class execution extends control
if(isonlybody())
{
if($this->app->tab == 'execution' and $object->type == 'kanban')
if($this->app->tab == 'execution')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$kanbanData = $this->loadModel('kanban')->getRDKanban($objectID, $execLaneType, 'id_desc', 0, $execGroupBy);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban($kanbanData)"));
if($object->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($objectID, $execLaneType, 'id_desc', 0, $execGroupBy);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($objectID, $execLaneType, $execGroupBy);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban(\"story\", $kanbanData)"));
}
}
else
{
@@ -3212,15 +3222,25 @@ class execution extends control
}
$execution = $this->execution->getByID($executionID);
if($this->app->tab == 'execution' and $execution->type == 'kanban')
if($this->app->tab == 'execution')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban($kanbanData)"));
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($executionID, $execLaneType, $execGroupBy);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban(\"story\", $kanbanData)"));
}
}
return print(js::reload('parent'));
+5 -4
View File
@@ -4,26 +4,27 @@
.pull-left .input-control {margin-right: 10px;}
#cfdWrapper {max-width: 1450px; padding: 25px 0px 10px; position: relative}
#cfdChart {margin: 0 auto;}
@media screen and (max-width: 1920px)
{
#cfdChart {width:1400px !important; height:600px !important}
#mainContent {min-width: 1550px !important;}
#mainContent {min-width: 1400px !important;}
#burnStatistics {left: 1400px !important;}
}
@media screen and (max-width: 1680px)
{
#cfdChart {width:1150px !important; height:500px !important}
#mainContent {min-width: 1350px !important;}
#mainContent {min-width: 1150px !important;}
#burnStatistics {left: 1150px !important;}
}
@media screen and (max-width: 1366px)
{
#cfdChart {width:1000px !important; height:400px !important}
#mainContent {min-width: 1200px !important;}
#mainContent {min-width: 1000px !important;}
#burnStatistics {left: 1000px !important;}
}
#mainContent {min-width: 1400px;}
#mainContent {min-width: 1200px;}
#burnStatistics {position: absolute; width: 180px; left: 1200px; height: 200px; top: 20%; margin-top: -30px; line-height: 30px; color: #838A9D; font-size: 12px; border: 1px solid #dcdcdc; background-color: #F8F8F8; padding: 15px 20px; color: #3c4353; border-radius: 8px;}
#burnStatistics .bg-primary {margin-right: 5px;}
#burnStatistics .icon-help {color: black;}
+52 -42
View File
@@ -2,30 +2,37 @@ $(function()
{
$('[data-toggle=tooltip]').tooltip();
if(Object.keys(chartData).length || 1)
{
var i = 0;
var series = [];
var colors = ['#33B4DB', '#7ECF69', '#FFC73A', '#FF5A61', '#50C8D0', '#AF5AFF', '#4EA3FF', '#FF8C5A', '#6C73FF'];
//var background = ['#E1F4FA', '#ECF8E9', '#FFF7E2', '#FFE7E8', '#E5F7F8', '#F3E7FF', '#E5F1FF', '#FFEEE7', '#E9EAFF'];
var i = 0;
var series = [];
var colors = ['#33B4DB', '#7ECF69', '#FFC73A', '#FF5A61', '#50C8D0', '#AF5AFF', '#4EA3FF', '#FF8C5A', '#6C73FF'];
//var background = ['#E1F4FA', '#ECF8E9', '#FFF7E2', '#FFE7E8', '#E5F7F8', '#F3E7FF', '#E5F1FF', '#FFEEE7', '#E9EAFF'];
if(Object.keys(chartData).length)
{
$.each(chartData['line'], function(label, set)
{
series.push({
name: label,
type: 'line',
stack: 'Total',
series.push({
name: label,
type: 'line',
stack: 'Total',
color: colors[i],
areaStyle: {
color: colors[i],
areaStyle: {
color: colors[i],
opacity: 0.2
},
emphasis: {
focus: 'series'
},
data: eval(set)
})
i ++;
opacity: 0.2
},
itemStyle: {
normal: {
lineStyle:{
width:1//设置线条粗细
}
}
},
emphasis: {
focus: 'series'
},
data: eval(set)
})
i ++;
})
var chartDom = document.getElementById('cfdChart');
@@ -40,10 +47,13 @@ $(function()
label: {
backgroundColor: '#6a7985'
}
},
textStyle: {
fontWeight: 100
}
},
legend: {
data: Object.keys(chartData['line'])
data: Object.keys(chartData['line']).reverse()
},
grid: {
left: '3%',
@@ -52,46 +62,46 @@ $(function()
containLabel: true
},
xAxis: [
{
{
type: 'category',
boundaryGap: false,
data: chartData['labels'],
name: XUnit,
axisLine:
{
show: true,
lineStyle:
{
color: '#999',
width:1
}
show: true,
lineStyle:
{
color: '#999',
width:1
}
}
}],
}],
yAxis: [
{
{
type: 'value',
minInterval: 1,
name: YUnit,
nameTextStyle:
{
fontWeight: 'normal'
fontWeight: 'normal'
},
axisPointer:
{
label:
{
show: true,
precision: 0
},
label:
{
show: true,
precision: 0
},
},
axisLine:
{
show: true,
lineStyle:
{
color: ['#999'],
width: 1
}
show: true,
lineStyle:
{
color: ['#999'],
width: 1
}
}
}
],
+4 -4
View File
@@ -3006,9 +3006,9 @@ class executionModel extends model
* @access public
* @return array
*/
public function computeCFD($executionID = 0, $date = '')
public function computeCFD($executionID = 0)
{
$today = $date ? $date : helper::today();
$today = helper::today();
$executions = $this->dao->select('id, code')->from(TABLE_EXECUTION)
->where('type')->eq('kanban')
->andWhere('status')->notin('done,closed,suspended')
@@ -3319,7 +3319,7 @@ class executionModel extends model
foreach($lane->items['closed'] as $item)
{
$diffTime = $type == 'story' ? strtotime($item['lastEditedDate']) - strtotime($item['openedDate']) : strtotime($item['closedDate']) - strtotime($item['openedDate']);
$day = floor($diffTime / (3600 * 24));
$day = round($diffTime / (3600 * 24), 1);
if($day > 0) $cycleTime[$item['id']] = $day;
}
}
@@ -3327,7 +3327,7 @@ class executionModel extends model
$itemCount = count($cycleTime);
if(!$itemCount) return array('', '');
$cycleTimeAvg = round(array_sum($cycleTime) / $itemCount);
$cycleTimeAvg = round(array_sum($cycleTime) / $itemCount, 1);
$throughput = round(($itemCount * 7) / $cycleTimeAvg, 1) . "{$this->lang->execution->kanbanCardsUnit}/" . $this->lang->execution->week;
return array($cycleTimeAvg, $throughput);
+9 -3
View File
@@ -33,14 +33,20 @@
</div>
<div id='mainContent' class='main-content'>
<h2 class='text-center'><?php echo $executionName . ' - ' . zget($lang->execution->cfdTypeList, $type) . $lang->execution->CFD;?></h2>
<?php if(isset($chartData['labels']) and count($chartData['labels']) != 1): ?>
<div id="cfdWrapper">
<div id="cfdChart" style="width: 1200px; height: 600px"></div>
<div id="burnStatistics">
<div id="burnStatistics" class="hidden">
<div class="stat-title"><span class="bg-primary">&nbsp;</span> <?php echo $lang->execution->charts->cfd->cycleTime;?> <i class="icon icon-help" data-toggle="tooltip" data-tip-class="tooltip-help" data-placement="bottom" title="<?php echo $lang->execution->charts->cfd->cycleTimeTip;?>"></i></div>
<h3><?php echo $cycleTimeAvg ? ($cycleTimeAvg . $lang->day) : $lang->noData;?></h3>
<h3><?php echo !empty($cycleTimeAvg) ? ($cycleTimeAvg . $lang->day) : $lang->noData;?></h3>
<div class="stat-title"><span class="bg-primary">&nbsp;</span> <?php echo $lang->execution->charts->cfd->throughput;?> <i class="icon icon-help" data-toggle="tooltip" data-tip-class="tooltip-help" data-placement="bottom" title="<?php echo $lang->execution->charts->cfd->throughputTip;?>"></i></div>
<h3><?php echo $throughput ? $throughput : $lang->noData;?></h3>
<h3><?php echo !empty($throughput) ? $throughput : $lang->noData;?></h3>
</div>
</div>
<?php else:?>
<div class="table-empty-tip">
<p><span class="text-muted"><?php echo $lang->execution->noPrintData;?></span></p>
</div>
<?php endif; ?>
</div>
<?php include '../../common/view/footer.html.php';?>
+1 -1
View File
@@ -228,7 +228,7 @@
</tr>
<tr>
<th id='c-name'><?php echo $lang->kanban->laneHeight;?></th>
<td class='laneHeightBox' colspan='2'><?php echo nl2br(html::radio('heightType', $lang->kanbanlane->heightTypeList, 'auto', "onclick='setCardCount(this.value);'"));?></td>
<td class='laneHeightBox' colspan='3'><?php echo nl2br(html::radio('heightType', $lang->kanbanlane->heightTypeList, 'auto', "onclick='setCardCount(this.value);'"));?></td>
</tr>
<tr class="hidden" id='cardBox'>
<th class='c-count'><?php echo $lang->kanban->cardCount;?></th>
+1 -1
View File
@@ -160,7 +160,7 @@ js::set('priv',
$width = $this->app->getClientLang() == 'en' ? '750' : '650';
if($printCreateRegion) $actions .= '<li>' . html::a(helper::createLink('kanban', 'createRegion', "kanbanID=$execution->id&from=execution", '', true), '<i class="icon icon-plus"></i>' . $lang->kanban->createRegion, '', "class='iframe btn btn-link text-left'") . '</li>';
$kanbanActions = '';
if(common::hasPriv('execution', 'edit')) $kanbanActions .= '<li>' . html::a(helper::createLink('execution', 'edit', "executionID=$execution->id", '', true), '<i class="icon icon-edit"></i>' . $lang->kanban->edit, '', "class='iframe btn btn-link text-left' data-width='75%'") . '</li>';
if(common::hasPriv('execution', 'edit')) $kanbanActions .= '<li>' . html::a(helper::createLink('execution', 'edit', "executionID=$execution->id", '', true), '<i class="icon icon-edit"></i>' . $lang->kanban->edit, '', "class='iframe btn btn-link text-left' data-width='80%'") . '</li>';
if(common::hasPriv('execution', 'start')) $kanbanActions .= '<li class="startButton hidden">' . html::a(helper::createLink('execution', 'start', "executionID=$execution->id&from=kanban", '', true), '<i class="icon icon-play"></i>' . $lang->execution->start, '', "class='iframe btn btn-link text-left' data-width='75%'") . '</li>';
if(common::hasPriv('execution', 'putoff')) $kanbanActions .= '<li class="putoffButton hidden">' . html::a(helper::createLink('execution', 'putoff', "executionID=$execution->id&from=kanban", '', true), '<i class="icon icon-calendar"></i>' . $lang->execution->putoff, '', "class='iframe btn btn-link text-left' data-width='75%'") . '</li>';
if(common::hasPriv('execution', 'suspend')) $kanbanActions .= '<li class="suspendButton hidden">' . html::a(helper::createLink('execution', 'suspend', "executionID=$execution->id&from=kanban", '', true), '<i class="icon icon-pause"></i>' . $lang->execution->suspend, '', "class='iframe btn btn-link text-left' data-width='75%'") . '</li>';
+2 -2
View File
@@ -121,11 +121,11 @@
<?php $i = 0;?>
<?php foreach($docLibs as $libID => $docLib):?>
<?php if($i > 8) break;?>
<div class="col-xs-6">
<div class="col-xs-6 text-ellipsis">
<?php if($libID == 'files'):?>
<?php echo html::a($this->createLink('doc', 'showFiles', "type=execution&objectID=$execution->id"), "<i class='icon icon-folder text-yellow'></i> " . $docLib->name);?>
<?php else:?>
<?php echo html::a($this->createLink('doc', 'objectLibs', "type=execution&objectID={$execution->id}&libID=$libID"), "<i class='icon icon-folder text-yellow'></i> " . $docLib->name, '', "data-app='execution'");?>
<?php echo html::a($this->createLink('doc', 'objectLibs', "type=execution&objectID={$execution->id}&libID=$libID"), "<i class='icon icon-folder text-yellow'></i> " . $docLib->name, '', "data-app='execution' title='$docLib->name'");?>
<?php endif;?>
</div>
<?php $i++;?>
+2
View File
@@ -7,6 +7,8 @@
<style>
.files-list>li>a {display: inline; word-wrap: break-word;}
.files-list>li>.right-icon {opacity: 1;}
.files-list>li>.right-icon>a {padding-left: 7px;}
html[lang|="zh"] .files-list>li>.right-icon>a {padding-left: 3px;}
</style>
<script>
/* Delete a file. */
+2
View File
@@ -8,6 +8,8 @@
<style>
.files-list>li>a {display: inline; word-wrap: break-word;}
.files-list>li>.right-icon {opacity: 1;}
.files-list>li>.right-icon>a {padding-left: 7px;}
html[lang|="zh"] .files-list>li>.right-icon>a {padding-left: 3px;}
</style>
<script>
/* Delete a file. */
+5 -1
View File
@@ -1,4 +1,8 @@
$(document).ready(function()
{
$('#agree').change(function(){$('.btn-install').attr('disabled', !$(this).prop('checked'));});
$('#agree').change(function()
{
$('.btn-install').attr('disabled', !$(this).prop('checked'));
$('.btn-install').css('pointer-events', $(this).prop('checked') ? 'auto' : 'none');
});
});
+1 -1
View File
@@ -22,7 +22,7 @@ class job extends control
public function __construct($moduleName = '', $methodName = '')
{
parent::__construct($moduleName, $methodName);
if($methodName != 'browse') $this->loadModel('ci')->setMenu();
if($this->app->methodName != 'browse') $this->loadModel('ci')->setMenu();
$this->projectID = isset($_GET['project']) ? $_GET['project'] : 0;
}
+1 -1
View File
@@ -50,7 +50,7 @@
<th><?php echo $lang->kanbanlane->color;?></th>
<td colspan='3'>
<div id='color-picker'></div>
<?php echo html::input('color', '#7ec5ff', "class='hidden'");?>
<?php echo html::input('color', '#3C4353', "class='hidden'");?>
</td>
</tr>
<tr>
+1 -1
View File
@@ -1,6 +1,6 @@
$(function()
{
if(manageLinePriv && (programID || systemMode == 'classic')) $('#line_chosen').addClass('hidden');
if(manageLinePriv && (hiddenLine || systemMode == 'classic')) $('#line_chosen').addClass('hidden');
$('#lineName').css('border-left-color', '');
})
/**
+7 -3
View File
@@ -35,12 +35,15 @@
<?php if(common::hasPriv('product', 'manageLine') and ($config->systemMode == 'classic' or $programID)):?>
<td>
<div class='input-group'>
<?php echo html::select("line", $lines, '', "class='form-control hidden line-exist chosen'");?>
<?php echo html::input("lineName", '', "class='form-control line-no-exist'");?>
<?php $hiddenLine = count($lines) > 1 ? '' : 'hidden';?>
<?php $hiddenLineName = $hiddenLine ? '' : 'hidden';?>
<?php $checkedNewLine = $hiddenLine ? 'checked' : '';?>
<?php echo html::select("line", $lines, '', "class='form-control line-exist chosen $hiddenLine'");?>
<?php echo html::input("lineName", '', "class='form-control line-no-exist $hiddenLineName'");?>
<?php if(count($lines)):?>
<span class='input-group-addon'>
<div class="checkbox-primary">
<input type="checkbox" name="newLine" value="0" checked onchange="toggleLine(this)" id="newLine0" />
<input type="checkbox" name="newLine" value="0" <?php echo $checkedNewLine;?> onchange="toggleLine(this)" id="newLine0" />
<label for="newLine0"><?php echo $lang->product->newLine;?></label>
</div>
</span>
@@ -123,4 +126,5 @@
</form>
</div>
</div>
<?php js::set('hiddenLine', $hiddenLine);?>
<?php include '../../common/view/footer.html.php';?>
+1 -1
View File
@@ -25,7 +25,7 @@
<tr>
<th><?php echo $lang->release->name;?></th>
<td><?php echo html::input('name', '', "class='form-control' required");?></td>
<td class='muted'>
<td>
<div id='markerBox' class='checkbox-primary'>
<input id='marker' name='marker' value='1' type='checkbox' />
<label for='marker'><?php echo $lang->release->marker;?></label>
+9 -2
View File
@@ -1321,9 +1321,16 @@ class repo extends control
}
elseif($repo->SCM == 'Git')
{
$gitDir = scandir($repo->path);
$files = '';
foreach($gitDir as $path)
{
if(!in_array($path, array('.', '..', '.git'))) $files .= $repo->path . DS . "$path,";
}
$this->app->loadClass('pclzip', true);
$zip = new pclzip($fileName);
if($zip->create($repo->path, PCLZIP_OPT_REMOVE_PATH, $repo->path) === 0) return print(js::alert($zip->errorInfo()) . js::close());
if($zip->create($files, PCLZIP_OPT_REMOVE_PATH, $repo->path) === 0) return print(js::alert($zip->errorInfo()) . js::close());
$url = DS . 'data' . DS . 'repo' . DS . $repo->name . '.zip';
}
@@ -1333,7 +1340,7 @@ class repo extends control
chdir($savePath);
$this->scm = $this->app->loadClass('scm');
$this->scm->setEngine($repo);
$this->scm->exec('checkout ' . $repo->path);
$this->scm->exec('export ' . $repo->path);
/* Get repo name. */
$pathList = explode('/', trim($repo->path, '/'));
+3 -3
View File
@@ -12,17 +12,17 @@
?>
<style>
#dropMenu .tree li {padding: 3px 0 0 10px;}
#dropMenu .tree li.has-list.open:before {border-left: 0px;}
#dropMenu .tree li > a {max-width: 100%; line-height: 20px; border-radius: 2px; padding-top: 5px;}
#dropMenu .col-left {padding: 0;}
#dropMenu .label {margin-left: 3px;}
#dropMenu .hide-in-search {padding-left: 8px;}
#dropMenu .hide-in-search .hidden {display: block !important; visibility: inherit !important;}
#dropMenuRepo > div.table-row > div > div > ul > li > div {padding-left: 10px;}
#dropMenu .tree li.has-list.open:before {border-left: 0px;}
#dropMenu ul.tree-angles {margin-bottom: 0;}
#dropMenu {margin: 0;}
#dropMenu ul > li > ul > li > a:hover {color: white; background-color: #0c64eb; text-decoration: none;}
#dropMenu .tree li > a {max-width: 100%;}
#dropMenu .tree li > a {line-height: 20px; border-radius: 2px;}
#dropMenu .tree .has-list > ul > li {padding-top: 0;}
li > a.selected {color: #3123ae !important; background: #f2eafc !important; line-height: 20px; border-radius: 5px;}
.search-list .list-group {padding: 7px 10px;}
#swapper li>div.hide-in-search>a:focus, #swapper li>div.hide-in-search>a:hover {color: #838a9d; cursor: default;}
+2 -2
View File
@@ -30,7 +30,7 @@
<ul class="tree tree-angles" data-ride="tree" data-idx="0">
<li data-idx='branch' data-id='branch' class='has-list open in' style='cursor: pointer;'>
<i class='list-toggle icon'></i>
<div class='hide-in-search'><a class='text-muted' title='<?php echo $lang->repo->branch;?>'><?php echo $lang->repo->branch;?></a></div>
<div class='hide-in-search'><a class='text-muted not-list-item' title='<?php echo $lang->repo->branch;?>'><?php echo $lang->repo->branch;?></a></div>
<ul data-idx='branch'>
<?php
foreach($branches as $branchName)
@@ -45,7 +45,7 @@
</li>
<li data-idx='tag' data-id='tag' class='has-list open in' style='cursor: pointer;'>
<i class='list-toggle icon'></i>
<div class='hide-in-search'><a class='text-muted' title='<?php echo $lang->repo->tag;?>'><?php echo $lang->repo->tag;?></a></div>
<div class='hide-in-search'><a class='text-muted not-list-item' title='<?php echo $lang->repo->tag;?>'><?php echo $lang->repo->tag;?></a></div>
<ul data-idx='tag'>
<?php
foreach($tags as $tagName)
+7
View File
@@ -315,6 +315,13 @@ class report extends control
$users[''] = $this->lang->report->annualData->allUser;
$depts = $this->loadModel('dept')->getOptionMenu();
if($this->app->tab == 'report')
{
$noDepartment = $depts[0];
unset($depts[0]);
$depts += array('0' => $noDepartment);
}
$accounts = array();
if($userID)
{
+5 -2
View File
@@ -64,7 +64,10 @@ $formId = 'searchForm-' . uniqid('');
html[lang^='zh-'] .fieldWidth {width: 110px !important;}
html[lang^='zh-'] .operatorWidth {width: 90px !important;}
.table tbody tr td input {display: block !important;}
#save-query {color: #0061f2;}
#save-query {float: unset !important; position: absolute; right: 50px;}
#save-query .text {top: 0px;}
#save-query .text:after {border-bottom: 0px solid #0c64eb;}
</style>
<?php if($style != 'simple'):?>
<div id='toggle-queries'>
@@ -245,7 +248,7 @@ foreach($fieldParams as $fieldName => $param)
echo html::submitButton($lang->search->common, '', 'btn btn-primary') . " &nbsp; ";
if($style != 'simple') echo html::commonButton($lang->search->reset, '', 'btn-reset-form btn');
echo html::commonButton('<i class="icon icon-chevron-double-down"></i>', '', 'btn-expand-form btn btn-info pull-right');
if($style != 'simple' and common::hasPriv('search', 'saveQuery')) echo html::a($this->createLink('search', 'saveQuery', "module=$module&onMenuBar=$onMenuBar"), '<i class="icon-bug-confirmBug icon-ok"></i> ' . $lang->search->saveCondition, '', "class='btn-save-form btn btn-link iframe pull-right' id='save-query'");
if($style != 'simple' and common::hasPriv('search', 'saveQuery')) echo html::a($this->createLink('search', 'saveQuery', "module=$module&onMenuBar=$onMenuBar"), '<span class="text"><i class="icon-bug-confirmBug icon-ok"></i> ' . $lang->search->saveCondition . '</span>', '', "class='btn-save-form btn btn-link btn-active-text text iframe' id='save-query'");
echo html::hidden('formType', zget($formSession, 'formType', 'lite'));
?>
</td>
+120 -24
View File
@@ -193,15 +193,27 @@ class story extends control
if(isonlybody())
{
$execution = $this->execution->getByID($this->session->execution);
if($this->app->tab == 'execution' and $execution->type == 'kanban')
if($this->app->tab == 'execution')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true, 'callback' => "parent.updateKanban($kanbanData, 0)"));
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true, 'callback' => "parent.updateKanban($kanbanData, 0)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($execution->id, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true, 'callback' => "parent.updateKanban(\"story\", $kanbanData)"));
}
}
else
{
@@ -504,15 +516,26 @@ class story extends control
{
$executionID = $executionID ? $executionID : $this->session->execution;
$execution = $this->execution->getByID($executionID);
if($this->app->tab == 'execution' and $execution->type == 'kanban')
if($this->app->tab == 'execution')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($execution->id, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"story\", $kanbanData)"));
}
}
else
{
@@ -724,13 +747,26 @@ class story extends control
if(isonlybody())
{
$execution = $this->execution->getByID($this->session->execution);
if($this->app->tab == 'execution' and $execution->type == 'kanban')
if($this->app->tab == 'execution')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $this->session->execLaneType ? $this->session->execLaneType : 'all', 'id_desc', 0, $kanbanGroup, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $execLaneType, 'id_desc', 0, $kanbanGroup, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($execution->id, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"story\", $kanbanData)"));
}
}
else
{
@@ -1043,15 +1079,25 @@ class story extends control
if(isonlybody())
{
$execution = $this->execution->getByID($this->session->execution);
if($this->app->tab == 'execution' and $execution->type == 'kanban')
if($this->app->tab == 'execution')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($execution->id, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"story\", $kanbanData)"));
}
}
else
{
@@ -1268,7 +1314,17 @@ class story extends control
if(defined('RUN_MODE') && RUN_MODE == 'api') return $this->send(array('status' => 'success'));
if($this->app->tab == 'execution' and $from == 'taskkanban') return print(js::reload('parent'));
if($this->app->tab == 'execution' and $from == 'taskkanban')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($this->session->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban(\"story\", $kanbanData)"));
}
if(isonlybody()) return print(js::reload('parent.parent'));
@@ -1301,7 +1357,36 @@ class story extends control
$this->executeHooks($storyID);
if(isonlybody()) return print(js::reload('parent.parent'));
if(isonlybody())
{
$execution = $this->execution->getByID($this->session->execution);
if($this->app->tab == 'execution')
{
$this->loadModel('kanban')->updateLane($this->session->execution, 'story', $storyID);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($this->session->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"story\", $kanbanData)"));
}
}
else
{
return print(js::closeModal('parent.parent', 'this', "function(){parent.parent.location.reload();}"));
}
}
$module = $from == 'project' ? 'projectstory' : 'story';
if(defined('RUN_MODE') and RUN_MODE == 'api') return $this->send(array('status' => 'success', 'data' => $storyID));
@@ -1422,16 +1507,27 @@ class story extends control
if(isonlybody())
{
$execution = $this->execution->getByID($this->session->execution);
if($this->app->tab == 'execution' and $execution->type == 'kanban')
if($this->app->tab == 'execution')
{
$this->loadModel('kanban')->updateLane($this->session->execution, 'story', $storyID);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($this->session->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'story' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"story\", $kanbanData)"));
}
}
else
{
+1
View File
@@ -11,6 +11,7 @@
*/
?>
<?php include './header.html.php';?>
<?php if($forceReview) $config->story->create->requiredFields .= ',review';?>
<?php js::set('showFields', $showFields);?>
<?php js::set('requiredFields', $config->story->create->requiredFields);?>
<div id="mainContent" class="main-content">
+230 -71
View File
@@ -44,9 +44,10 @@ class task extends control
$extra = str_replace(array(',', ' '), array('&', ''), $extra);
parse_str($extra, $output);
$execution = $this->execution->getById($executionID);
$executions = $this->execution->getPairs(0, 'all', !common::canModify('execution', $execution) ? 'noclosed' : '');
if(!empty($executionID)) $execution = $this->execution->getById($executionID);
$executions = $this->execution->getPairs(0, 'all', isset($execution) ? (!common::canModify('execution', $execution) ? 'noclosed' : '') : 'noclosed');
$executionID = $this->execution->saveState($executionID, $executions);
$execution = $this->execution->getById($executionID);
$this->execution->setMenu($executionID);
$this->execution->getLimitedExecution();
@@ -182,15 +183,27 @@ class task extends control
/* If link from no head then reload. */
if(isonlybody())
{
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true, 'callback' => "parent.updateKanban($kanbanData, 0)"));
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true, 'callback' => "parent.updateKanban($kanbanData, 0)"));
}
else
{
$kanbanData = $this->kanban->getExecutionKanban($executionID, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true, 'callback' => "parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -357,15 +370,27 @@ class task extends control
/* If link from no head then reload. */
if(isonlybody())
{
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, 0)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, 0)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($executionID, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -517,14 +542,28 @@ class task extends control
if(isonlybody())
{
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $this->session->execLaneType ? $this->session->execLaneType : 'all', 'id_desc', 0, $kanbanGroup, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', 0, $execGroup, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -743,15 +782,29 @@ class task extends control
if($this->viewType == 'json' or (defined('RUN_MODE') && RUN_MODE == 'api')) return $this->send(array('result' => 'success'));
if(isonlybody())
{
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $this->session->execLaneType ? $this->session->execLaneType : 'all', 'id_desc', 0, $kanbanGroup, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', 0, $execGroup, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -993,17 +1046,29 @@ class task extends control
if(isonlybody())
{
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -1058,16 +1123,28 @@ class task extends control
if(isonlybody())
{
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -1196,17 +1273,29 @@ class task extends control
if(isonlybody())
{
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -1286,18 +1375,30 @@ class task extends control
if(isonlybody())
{
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -1345,17 +1446,29 @@ class task extends control
if(isonlybody())
{
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -1421,16 +1534,28 @@ class task extends control
}
}
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -1585,18 +1710,30 @@ class task extends control
if(isonlybody())
{
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -1644,18 +1781,30 @@ class task extends control
if(isonlybody())
{
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
if($execution->type == 'kanban' and $this->app->tab == 'execution')
if($this->app->tab == 'execution' or $this->config->vision == 'lite')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$task = $this->task->getById($taskID);
$execution = $this->execution->getByID($task->execution);
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
if($execution->type == 'kanban')
{
$regionID = !empty($output['regionID']) ? $output['regionID'] : 0;
$kanbanData = $this->loadModel('kanban')->getRDKanban($task->execution, $execLaneType, 'id_desc', $regionID, $execGroupBy, $rdSearchValue);
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData, $regionID)"));
}
else
{
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($task->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban(\"task\", $kanbanData)"));
}
}
else
{
@@ -1712,7 +1861,17 @@ class task extends control
$this->executeHooks($taskID);
if(isonlybody()) return print(js::reload('parent.parent'));
if($from == 'taskkanban') return print(js::reload('parent'));
if($from == 'taskkanban')
{
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
$kanbanData = $this->loadModel('kanban')->getExecutionKanban($this->session->execution, $execLaneType, $execGroupBy, $rdSearchValue);
$kanbanType = $execLaneType == 'all' ? 'task' : key($kanbanData);
$kanbanData = $kanbanData[$kanbanType];
$kanbanData = json_encode($kanbanData);
return print(js::closeModal('parent', '', "parent.updateKanban(\"task\", $kanbanData)"));
}
$locateLink = $this->session->taskList ? $this->session->taskList : $this->createLink('execution', 'task', "executionID={$task->execution}");
return print(js::locate($locateLink, 'parent'));
+1 -1
View File
@@ -262,7 +262,7 @@
<div class="modal fade modal-team" id="modalTeam" data-scroll-inside='false'>
<div class="modal-dialog">
<div class="modal-header">
<button type="button" class="close hidden" data-dismiss="modal">
<button type="button" class="close" data-dismiss="modal">
<i class="icon icon-close"></i>
</button>
<h4 class="modal-title"><?php echo $lang->task->team?></h4>
+1 -1
View File
@@ -419,7 +419,7 @@ class tree extends control
if(!empty($_POST))
{
$this->tree->updateOrder($_POST['orders']);
if($viewType == 'story' and !empty($rootID) and !empty($moduleID)) $this->action->create('module', $rootID, 'moved', '', $moduleID);
if($viewType == 'story' and !empty($rootID) and !empty($moduleID)) $this->loadModel('action')->create('module', $rootID, 'moved', '', $moduleID);
die(js::reload('parent'));
}
}
+1 -1
View File
@@ -969,7 +969,7 @@ class user extends control
}
else
{
$loginExpired = !(preg_match("/(m=|\/)(index)(&f=|-)(index)(&|-|\.)?/", strtolower($this->referer), $output) or $this->referer == $this->config->webRoot or empty($this->referer));
$loginExpired = !(preg_match("/(m=|\/)(index)(&f=|-)(index)(&|-|\.)?/", strtolower($this->referer), $output) or $this->referer == $this->config->webRoot or empty($this->referer) or preg_match("/\/www\/$/", strtolower($this->referer), $output));
$this->loadModel('misc');
$this->loadModel('extension');