Merge branch '15.0.beta3' of http://gitlab.zcorp.cc/easycorp/zentaopms into 15.0.beta3
This commit is contained in:
@@ -376,13 +376,13 @@ class baseRouter
|
||||
$this->loadClass('dao', $static = true);
|
||||
$this->loadClass('mobile', $static = true);
|
||||
|
||||
$this->setOpenApp();
|
||||
$this->setSuperVars();
|
||||
$this->setDebug();
|
||||
$this->setErrorHandler();
|
||||
$this->setTimezone();
|
||||
$this->startSession();
|
||||
$this->setProject();
|
||||
$this->setOpenApp();
|
||||
|
||||
if($this->config->framework->multiSite) $this->setSiteCode() && $this->loadExtraConfig();
|
||||
if($this->config->framework->autoConnectDB) $this->connectDB();
|
||||
@@ -600,7 +600,7 @@ class baseRouter
|
||||
$this->get = new super('get');
|
||||
$this->server = new super('server');
|
||||
$this->cookie = new super('cookie');
|
||||
$this->session = new super('session');
|
||||
$this->session = new super('session', $this->openApp);
|
||||
|
||||
unset($GLOBALS);
|
||||
unset($_REQUEST);
|
||||
@@ -2477,9 +2477,10 @@ class super
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function __construct($scope)
|
||||
public function __construct($scope, $openApp = '')
|
||||
{
|
||||
$this->scope = $scope;
|
||||
$this->scope = $scope;
|
||||
$this->openApp = $openApp;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2511,6 +2512,8 @@ class super
|
||||
}
|
||||
elseif($this->scope == 'session')
|
||||
{
|
||||
$openApp = $this->openApp;
|
||||
empty($openApp) ? $_SESSION[$key] = $value : $_SESSION['app-' . $openApp][$key] = $value;
|
||||
$_SESSION[$key] = $value;
|
||||
}
|
||||
elseif($this->scope == 'env')
|
||||
@@ -2558,7 +2561,10 @@ class super
|
||||
}
|
||||
elseif($this->scope == 'session')
|
||||
{
|
||||
$openApp = $this->openApp;
|
||||
if(!empty($openApp) and isset($_SESSION['app-' . $openApp][$key])) return $_SESSION['app-' . $openApp][$key];
|
||||
if(isset($_SESSION[$key])) return $_SESSION[$key];
|
||||
|
||||
return false;
|
||||
}
|
||||
elseif($this->scope == 'env')
|
||||
|
||||
@@ -285,6 +285,9 @@ class bug extends control
|
||||
/* Whether there is a object to transfer bug, for example feedback. */
|
||||
$extras = str_replace(array(',', ' '), array('&', ''), $extras);
|
||||
parse_str($extras, $output);
|
||||
|
||||
if(isset($output['executionID'])) commonModel::setAppObjectID('execution', $output['executionID']);
|
||||
|
||||
foreach($output as $paramKey => $paramValue)
|
||||
{
|
||||
if(isset($this->config->bug->fromObjects[$paramKey]))
|
||||
|
||||
@@ -356,7 +356,7 @@ $lang->execution->subMenu->view->tree = 'Baumansicht|execution|tree|executi
|
||||
$lang->execution->subMenu->qa = new stdclass();
|
||||
$lang->execution->subMenu->qa->bug = 'Bug|execution|bug|executionID=%s';
|
||||
$lang->execution->subMenu->qa->build = array('link' => 'Build|execution|build|executionID=%s', 'subModule' => 'build');
|
||||
$lang->execution->subMenu->qa->testtask = array('link' => 'Test Aufgabe|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask');
|
||||
$lang->execution->subMenu->qa->testtask = array('link' => 'Test Aufgabe|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask', 'alias' => 'create');
|
||||
|
||||
$lang->execution->subMenu->more = new stdclass();
|
||||
$lang->execution->subMenu->more->whitelist = array('link' => 'Whitelist|execution|whitelist|executionID=%s', 'subModule' => 'personnel', 'alias' => 'addwhitelist');
|
||||
@@ -626,6 +626,7 @@ $lang->navGroup->measrecord = 'project';
|
||||
$lang->navGroup->execution = 'execution';
|
||||
$lang->navGroup->task = 'execution';
|
||||
$lang->navGroup->build = 'execution';
|
||||
$lang->navGroup->repo = 'execution';
|
||||
|
||||
$lang->navGroup->sqlbuilder = 'system';
|
||||
$lang->navGroup->auditcl = 'system';
|
||||
|
||||
@@ -344,13 +344,13 @@ $lang->execution->menu->kanban = array('link' => 'Kanban|execution|kanban|exec
|
||||
$lang->execution->menu->burn = array('link' => 'Burndown|execution|burn|executionID=%s');
|
||||
$lang->execution->menu->view = array('link' => 'View|execution|grouptask|executionID=%s', 'alias' => 'grouptask,tree', 'class' => 'dropdown dropdown-hover');
|
||||
$lang->execution->menu->story = array('link' => 'Story|execution|story|executionID=%s', 'subModule' => 'story', 'alias' => 'linkstory,storykanban');
|
||||
$lang->execution->menu->bug = array('link' => 'Bug|execution|bug|executionID=%s');
|
||||
$lang->execution->menu->build = array('link' => 'Build|execution|build|executionID=%s', 'subModule' => 'build');
|
||||
$lang->execution->menu->testtask = array('link' => 'Request|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask');
|
||||
$lang->execution->menu->qa = array('link' => 'Bug|execution|qa|executionID=%s', 'subModule' => 'bug', 'alias' => 'qa,bug,testcase,testtask,testreport');
|
||||
$lang->execution->menu->repo = array('link' => 'Repo|repo|browse|projectID=%s');
|
||||
$lang->execution->menu->doc = array('link' => 'Doc|doc|objectLibs|type=execution&objectID=%s&from=execution', 'subModule' => 'doc');
|
||||
$lang->execution->menu->product = $lang->productCommon . '|execution|manageproducts|executionID=%s';
|
||||
$lang->execution->menu->team = array('link' => 'Team|execution|team|executionID=%s', 'alias' => 'managemembers');
|
||||
$lang->execution->menu->more = array('link' => 'More|execution|whitelist|executionID=%s', 'subModule' => 'personnel', 'alias' => 'edit', 'class' => 'dropdown dropdown-hover');
|
||||
$lang->execution->menu->build = array('link' => 'Build|execution|build|executionID=%s', 'subModule' => 'build');
|
||||
$lang->execution->menu->release = array('link' => 'Release|projectrelease|browse|project=%s');
|
||||
$lang->execution->menu->action = array('link' => 'Dynamics|execution|dynamic|executionID=%s');
|
||||
$lang->execution->menu->setting = array('link' => 'Settings|execution|view|executionID=%s', 'subModule' => 'personnel', 'alias' => 'edit,manageproducts,team,whitelist,addwhitelist,managemembers', 'class' => 'dropdown dropdown-hover');
|
||||
|
||||
$lang->execution->subMenu = new stdclass();
|
||||
$lang->execution->subMenu->view = new stdclass();
|
||||
@@ -360,7 +360,7 @@ $lang->execution->subMenu->view->tree = 'Tree View|execution|tree|execution
|
||||
$lang->execution->subMenu->qa = new stdclass();
|
||||
$lang->execution->subMenu->qa->bug = 'Bug|execution|bug|executionID=%s';
|
||||
$lang->execution->subMenu->qa->build = array('link' => 'Build|execution|build|executionID=%s', 'subModule' => 'build');
|
||||
$lang->execution->subMenu->qa->testtask = array('link' => 'Request|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask');
|
||||
$lang->execution->subMenu->qa->testtask = array('link' => 'Request|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask', 'alias' => 'create');
|
||||
|
||||
$lang->execution->subMenu->more = new stdclass();
|
||||
$lang->execution->subMenu->more->whitelist = array('link' => 'Whitelist|execution|whitelist|executionID=%s', 'subModule' => 'personnel', 'alias' => 'addwhitelist');
|
||||
@@ -623,9 +623,12 @@ $lang->navGroup->measrecord = 'project';
|
||||
$lang->navGroup->execution = 'execution';
|
||||
$lang->navGroup->task = 'execution';
|
||||
$lang->navGroup->build = 'execution';
|
||||
$lang->navGroup->repo = 'execution';
|
||||
|
||||
$lang->navGroup->doc = 'doc';
|
||||
|
||||
$lang->navGroup->qa = 'qa';
|
||||
|
||||
$lang->navGroup->sqlbuilder = 'system';
|
||||
$lang->navGroup->auditcl = 'system';
|
||||
$lang->navGroup->cmcl = 'system';
|
||||
@@ -857,7 +860,7 @@ $lang->menu = new stdclass();
|
||||
$lang->menu->scrum = new stdclass();
|
||||
$lang->menu->scrum->index = 'Index|project|index|project={PROJECT}';
|
||||
$lang->menu->scrum->project = "$lang->executionCommon|project|index|locate=no";
|
||||
$lang->menu->scrum->projectstory = array('link' => $lang->SRCommon . '|projectstory|story', 'subModule' => 'story', 'alias' => 'story,track');
|
||||
$lang->menu->scrum->projectstory = array('link' => $lang->SRCommon . '|projectstory|story|project={PROJECT}', 'subModule' => 'story', 'alias' => 'story,track');
|
||||
$lang->menu->scrum->doc = 'Doc|doc|index|';
|
||||
$lang->menu->scrum->qa = 'QA|qa|index';
|
||||
$lang->menu->scrum->ci = 'Code|repo|browse';
|
||||
@@ -882,7 +885,7 @@ $lang->menu->waterfall->programplan = array('link' => 'Plan|programplan|brows
|
||||
$lang->menu->waterfall->project = array('link' => $lang->executionCommon . '|project|task|executionID={EXECUTION}', 'subModule' => ',project,task,');
|
||||
$lang->menu->waterfall->doc = array('link' => 'Doc|doc|index|project={PROJECT}');
|
||||
$lang->menu->waterfall->weekly = array('link' => 'Weekly|weekly|index|project={PROJECT}', 'subModule' => ',milestone,');
|
||||
$lang->menu->waterfall->projectstory = array('link' => $lang->SRCommon . '|projectstory|story');
|
||||
$lang->menu->waterfall->projectstory = array('link' => $lang->SRCommon . '|projectstory|story|project={PROJECT}');
|
||||
$lang->menu->waterfall->design = 'Design|design|browse|product={PRODUCT}';
|
||||
$lang->menu->waterfall->ci = 'Repo|repo|browse|';
|
||||
$lang->menu->waterfall->track = array('link' => 'Track|projectstory|track', 'alias' => 'track');
|
||||
|
||||
@@ -356,7 +356,7 @@ $lang->execution->subMenu->view->tree = 'Arborescence|execution|tree|execut
|
||||
$lang->execution->subMenu->qa = new stdclass();
|
||||
$lang->execution->subMenu->qa->bug = 'Bug|execution|bug|executionID=%s';
|
||||
$lang->execution->subMenu->qa->build = array('link' => 'Build|execution|build|executionID=%s', 'subModule' => 'build');
|
||||
$lang->execution->subMenu->qa->testtask = array('link' => 'Recette|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask');
|
||||
$lang->execution->subMenu->qa->testtask = array('link' => 'Recette|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask', 'alias' => 'create');
|
||||
|
||||
$lang->execution->subMenu->more = new stdclass();
|
||||
$lang->execution->subMenu->more->whitelist = array('link' => 'Whitelist|execution|whitelist|executionID=%s', 'subModule' => 'personnel', 'alias' => 'addwhitelist');
|
||||
@@ -618,6 +618,7 @@ $lang->navGroup->measrecord = 'project';
|
||||
$lang->navGroup->execution = 'execution';
|
||||
$lang->navGroup->task = 'execution';
|
||||
$lang->navGroup->build = 'execution';
|
||||
$lang->navGroup->repo = 'execution';
|
||||
|
||||
$lang->navGroup->sqlbuilder = 'system';
|
||||
$lang->navGroup->auditcl = 'system';
|
||||
|
||||
@@ -356,7 +356,7 @@ $lang->execution->subMenu->view->tree = 'Xem theo cây|execution|tree|execu
|
||||
$lang->execution->subMenu->qa = new stdclass();
|
||||
$lang->execution->subMenu->qa->bug = 'Bug|execution|bug|executionID=%s';
|
||||
$lang->execution->subMenu->qa->build = array('link' => 'Bản dựng|execution|build|executionID=%s', 'subModule' => 'build');
|
||||
$lang->execution->subMenu->qa->testtask = array('link' => 'Yêu cầu|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask');
|
||||
$lang->execution->subMenu->qa->testtask = array('link' => 'Yêu cầu|execution|testtask|executionID=%s', 'subModule' => 'testreport,testtask', 'alias' => 'create');
|
||||
|
||||
$lang->execution->subMenu->more = new stdclass();
|
||||
$lang->execution->subMenu->more->whitelist = array('link' => 'Whitelist|execution|whitelist|executionID=%s', 'subModule' => 'personnel', 'alias' => 'addwhitelist');
|
||||
@@ -624,6 +624,7 @@ $lang->navGroup->measrecord = 'project';
|
||||
$lang->navGroup->execution = 'execution';
|
||||
$lang->navGroup->task = 'execution';
|
||||
$lang->navGroup->build = 'execution';
|
||||
$lang->navGroup->repo = 'execution';
|
||||
|
||||
$lang->navGroup->sqlbuilder = 'system';
|
||||
$lang->navGroup->auditcl = 'system';
|
||||
|
||||
@@ -160,14 +160,14 @@ $lang->program->homeMenu = new stdclass();
|
||||
$lang->program->homeMenu->browse = array('link' => '项目集|program|browse|');
|
||||
|
||||
$lang->project = new stdclass();
|
||||
$lang->project->menu = new stdclass();
|
||||
$lang->project->homeMenu = new stdclass();
|
||||
if($config->systemMode == 'new')
|
||||
{
|
||||
$lang->project->menu->browse = array('link' => '项目|project|browse|');
|
||||
$lang->project->homeMenu->browse = array('link' => '项目|project|browse|');
|
||||
}
|
||||
else
|
||||
{
|
||||
$lang->project->menu->browse = array('link' => "$lang->executionCommon|project|browse|");
|
||||
$lang->project->homeMenu->browse = array('link' => "$lang->executionCommon|project|browse|");
|
||||
}
|
||||
|
||||
$lang->project->dividerMenu = ',execution,programplan,doc,dynamic,';
|
||||
@@ -344,9 +344,9 @@ $lang->execution->menu->kanban = array('link' => '看板|execution|kanban|exec
|
||||
$lang->execution->menu->burn = array('link' => '燃尽图|execution|burn|executionID=%s');
|
||||
$lang->execution->menu->view = array('link' => '视图|execution|grouptask|executionID=%s', 'alias' => 'grouptask,tree', 'class' => 'dropdown dropdown-hover');
|
||||
$lang->execution->menu->story = array('link' => "{$lang->SRCommon}|execution|story|executionID=%s", 'subModule' => 'story', 'alias' => 'linkstory,storykanban');
|
||||
$lang->execution->menu->qa = array('link' => '测试|execution|qa|', 'alias' => 'qa,bug,testcase,testtask,testreport');
|
||||
$lang->execution->menu->qa = array('link' => '测试|execution|qa|executionID=%s', 'subModule' => 'bug', 'alias' => 'qa,bug,testcase,testtask,testreport');
|
||||
$lang->execution->menu->repo = array('link' => '代码|repo|browse|projectID=%s');
|
||||
$lang->execution->menu->doc = array('link' => '文档|doc|objectLibs|type=execution&objectID=%s&from=execution', 'subModule' => 'doc');
|
||||
$lang->execution->menu->doc = array('link' => '文档|doc|objectLibs|type=execution&objectID=%s', 'subModule' => 'doc');
|
||||
$lang->execution->menu->build = array('link' => '版本|execution|build|executionID=%s', 'subModule' => 'build');
|
||||
$lang->execution->menu->release = array('link' => '发布|projectrelease|browse|project=%s');
|
||||
$lang->execution->menu->action = array('link' => '动态|execution|dynamic|executionID=%s');
|
||||
@@ -359,11 +359,10 @@ $lang->execution->viewMenu->tree = '树状图|execution|tree|executionID=%s
|
||||
$lang->execution->qaMenu = new stdclass();
|
||||
$lang->execution->qaMenu->qa = array('link' => '仪表盘|execution|qa|executionID=%s');
|
||||
$lang->execution->qaMenu->bug = array('link' => 'Bug|execution|bug|executionID=%s');
|
||||
$lang->execution->qaMenu->testcase = array('link' => '用例|execution|testcase|executionID=%s');
|
||||
$lang->execution->qaMenu->testcase = array('link' => '用例|execution|testcase|executionID=%s', 'alias' => 'create');
|
||||
$lang->execution->qaMenu->testtask = array('link' => '测试单|execution|testtask|executionID=%s');
|
||||
//$lang->execution->qaMenu->testreport = array('link' => '报告|testreport|browse|exeutionID=%s&type=execution');
|
||||
|
||||
$lang->execution->settingMenu = new stdclass();
|
||||
$lang->execution->settingMenu = new stdclass();
|
||||
$lang->execution->settingMenu->view = array('link' => '概况|execution|view|executionID={EXECUTION}', 'subModule' => 'view', 'alias' => 'edit,start,suspend,putoff,close');
|
||||
$lang->execution->settingMenu->products = $lang->productCommon . '|execution|manageproducts|executionID={EXECUTION}';
|
||||
@@ -630,9 +629,12 @@ $lang->navGroup->measrecord = 'project';
|
||||
$lang->navGroup->execution = 'execution';
|
||||
$lang->navGroup->task = 'execution';
|
||||
$lang->navGroup->build = 'execution';
|
||||
$lang->navGroup->repo = 'execution';
|
||||
|
||||
$lang->navGroup->doc = 'doc';
|
||||
|
||||
$lang->navGroup->qa = 'qa';
|
||||
|
||||
$lang->navGroup->company = 'system';
|
||||
$lang->navGroup->sqlbuilder = 'system';
|
||||
$lang->navGroup->auditcl = 'system';
|
||||
@@ -863,8 +865,8 @@ $lang->icons['score'] = 'tint';
|
||||
$lang->menu = new stdclass();
|
||||
$lang->menu->scrum = new stdclass();
|
||||
$lang->menu->scrum->index = '仪表盘|project|index|project={PROJECT}';
|
||||
$lang->menu->scrum->execution = "$lang->executionCommon|execution|all|status=all&projectID={PROJECT}&from=project";
|
||||
$lang->menu->scrum->projectstory = array('link' => $lang->SRCommon . '|projectstory|story', 'alias' => 'story,track');
|
||||
$lang->menu->scrum->execution = "$lang->executionCommon|execution|all|status=all&projectID={PROJECT}";
|
||||
$lang->menu->scrum->projectstory = array('link' => $lang->SRCommon . '|projectstory|story|projectID={PROJECT}', 'alias' => 'story,track');
|
||||
$lang->menu->scrum->doc = array('link' => '文档|doc|objectLibs|type=project&objectID={PROJECT}', 'subModule' => 'doc');
|
||||
$lang->menu->scrum->qa = array('link' => '测试|qa|index', 'subModule' => 'testcase,testtask');
|
||||
$lang->menu->scrum->ci = '代码|repo|browse';
|
||||
@@ -901,7 +903,7 @@ $lang->menu->waterfall->programplan = array('link' => '计划|programplan|bro
|
||||
$lang->menu->waterfall->project = array('link' => $lang->executionCommon . '|project|task|executionID={EXECUTION}', 'subModule' => ',project,task,');
|
||||
$lang->menu->waterfall->doc = array('link' => '文档|doc|index|project={PROJECT}');
|
||||
$lang->menu->waterfall->weekly = array('link' => '报告|weekly|index|project={PROJECT}', 'subModule' => ',milestone,');
|
||||
$lang->menu->waterfall->projectstory = array('link' => $lang->SRCommon . '|projectstory|story');
|
||||
$lang->menu->waterfall->projectstory = array('link' => $lang->SRCommon . '|projectstory|story|project={PROJECT}');
|
||||
$lang->menu->waterfall->design = '设计|design|browse|product={PRODUCT}';
|
||||
$lang->menu->waterfall->ci = '代码|repo|browse|';
|
||||
$lang->menu->waterfall->track = array('link' => '矩阵|projectstory|track', 'alias' => 'track');
|
||||
|
||||
+16
-15
@@ -2289,19 +2289,6 @@ EOD;
|
||||
{
|
||||
global $lang, $config;
|
||||
|
||||
if($openApp == 'project')
|
||||
{
|
||||
if($config->systemMode == 'classic' or ($moduleName == 'project' and $methodName == 'browse'))
|
||||
{
|
||||
$lang->menu = $lang->project->menu;
|
||||
}
|
||||
else
|
||||
{
|
||||
$lang->menu = self::getProjectMainMenu($moduleName);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if(!isset($lang->$openApp->homeMenu))
|
||||
{
|
||||
$lang->menu = $lang->$openApp->menu;
|
||||
@@ -2327,8 +2314,22 @@ EOD;
|
||||
}
|
||||
}
|
||||
|
||||
$lang->menu = $lang->$openApp->menu;
|
||||
$lang->menuOrder = $lang->$openApp->menuOrder;
|
||||
if($openApp == 'project')
|
||||
{
|
||||
if($config->systemMode == 'classic' or ($moduleName == 'project' and $methodName == 'browse'))
|
||||
{
|
||||
$lang->menu = $lang->project->homeMenu;
|
||||
}
|
||||
else
|
||||
{
|
||||
$lang->menu = self::getProjectMainMenu($moduleName);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$lang->menu = $lang->$openApp->menu;
|
||||
$lang->menuOrder = $lang->$openApp->menuOrder;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -919,7 +919,7 @@ class doc extends control
|
||||
$this->lang->product->switcherMenu = $this->product->getSwitcher($objectID);
|
||||
$this->lang->noMenuModule[] = 'doc';
|
||||
}
|
||||
elseif($from == 'project')
|
||||
elseif($from == 'project' or $from == 'execution')
|
||||
{
|
||||
if($this->config->systemMode == 'classic') $this->lang->noMenuModule[] = 'doc';
|
||||
}
|
||||
@@ -947,7 +947,7 @@ class doc extends control
|
||||
|
||||
$this->view->type = $type;
|
||||
$this->view->object = $object;
|
||||
$this->view->from = $$from;
|
||||
$this->view->from = $from;
|
||||
$this->view->libs = $this->doc->getLibsByObject($type, $objectID);
|
||||
$this->view->canBeChanged = common::canModify($type, $object); // Determines whether an object is editable.
|
||||
$this->display();
|
||||
|
||||
@@ -1840,13 +1840,12 @@ class docModel extends model
|
||||
public function appendNavCSS()
|
||||
{
|
||||
$navCSS = '';
|
||||
if($this->lang->navGroup->doc == 'doc')
|
||||
if($this->app->openApp == 'doc')
|
||||
{
|
||||
$navCSS .= <<<EOF
|
||||
#subHeader {margin-top: -50px; background: rgba(0,0,0,0);}
|
||||
#pageActions .btn-link {color: #fff; font-size: 14px; line-height: 18px; border: #84a2e2 1px solid;}
|
||||
.header-btn {padding: 0;}
|
||||
.header-btn .btn{padding: 6px 12px;}
|
||||
EOF;
|
||||
if($this->app->rawMethod != 'index') $navCSS .= '.header-btn+.header-btn::after, .header-btn+.header-btn::before {top: -50px;}';
|
||||
}
|
||||
|
||||
@@ -1511,8 +1511,6 @@ class execution extends control
|
||||
$rdUsers = $this->user->getPairs('noclosed|nodeleted|devfirst', $appendRdUsers, $this->config->maxCount);
|
||||
if(!empty($this->config->user->moreLink)) $this->config->moreLinks["RD"] = $this->config->user->moreLink;
|
||||
|
||||
$project = $this->project->getById($this->session->PRJ);
|
||||
|
||||
$this->view->title = $this->lang->execution->batchEdit;
|
||||
$this->view->position[] = $this->lang->execution->batchEdit;
|
||||
$this->view->executionIDList = $executionIDList;
|
||||
@@ -1521,7 +1519,6 @@ class execution extends control
|
||||
$this->view->poUsers = $poUsers;
|
||||
$this->view->qdUsers = $qdUsers;
|
||||
$this->view->rdUsers = $rdUsers;
|
||||
$this->view->isStage = $project->model == 'waterfall' ? true : false;
|
||||
$this->display();
|
||||
}
|
||||
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
<td class='text-left<?php echo zget($visibleFields, 'RD', ' hidden')?>' style='overflow:visible'><?php echo html::select("RDs[$executionID]", $rdUsers, $executions[$executionID]->RD, "class='form-control chosen'");?></td>
|
||||
<td class='<?php echo zget($visibleFields, 'type', 'hidden')?>'>
|
||||
<?php
|
||||
if($isStage)
|
||||
if($executions[$executionID]->type == 'stage')
|
||||
{
|
||||
echo html::select("attributes[$executionID]", $lang->stage->typeList, $executions[$executionID]->attribute, 'class=form-control');
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
</div>
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php common::printLink('bug', 'export', "productID=$productID&orderBy=$orderBy&browseType=&executionID=$execution->id", "<i class='icon icon-export muted'> </i>" . $lang->bug->export, '', "class='btn btn-link export'");?>
|
||||
<?php if(common::canModify('execution', $execution)) common::printLink('bug', 'create', "productID=$productID&branch=$branchID&extra=executionID=$execution->id", "<i class='icon icon-plus'></i> " . $lang->bug->create, '', "class='btn btn-primary'");?>
|
||||
<?php if(common::canModify('execution', $execution)) common::printLink('bug', 'create', "productID=$productID&branch=$branchID&extras=executionID=$execution->id", "<i class='icon icon-plus'></i> " . $lang->bug->create, '', "class='btn btn-primary'");?>
|
||||
</div>
|
||||
</div>
|
||||
<div id="mainContent">
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<?php echo html::a(inlink('testcase', "executionID=$executionID&type=$type&orderBy=$orderBy"), "<span class='text'>{$lang->execution->all}</span>", '', "class='btn btn-link btn-active-text'");?>
|
||||
</div>
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php if(common::canModify('execution', $execution)) echo html::a(helper::createLink('testcase', 'create', "productID=$productID&branch=0&moduleID=0&from=execution¶m=$execution->id", '', '', '', true), "<i class='icon icon-plus'></i> " . $lang->testcase->create, '', "class='btn btn-primary'");?>
|
||||
<?php if(common::canModify('execution', $execution)) echo html::a(helper::createLink('testcase', 'create', "productID=$productID&branch=0&moduleID=0&from=execution¶m=$execution->id", '', '', '', true), "<i class='icon icon-plus'></i> " . $lang->testcase->create, '', "class='btn btn-primary' data-app='execution'");?>
|
||||
</div>
|
||||
</div>
|
||||
<div id="mainContent">
|
||||
@@ -13,7 +13,7 @@
|
||||
<p>
|
||||
<span class="text-muted"><?php echo $lang->testcase->noCase;?></span>
|
||||
<?php if(common::canModify('execution', $execution) and common::hasPriv('testcase', 'create')):?>
|
||||
<?php echo html::a(helper::createLink('testcase', 'create', "productID=$productID&branch=0&moduleID=0&from=execution¶m=$execution->id", '', '', '', true), "<i class='icon icon-plus'></i> " . $lang->testcase->create, '', "class='btn btn-info'");?>
|
||||
<?php echo html::a(helper::createLink('testcase', 'create', "productID=$productID&branch=0&moduleID=0&from=execution¶m=$execution->id", '', '', '', true), "<i class='icon icon-plus'></i> " . $lang->testcase->create, '', "class='btn btn-info' data-app='execution'");?>
|
||||
<?php endif;?>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
@@ -551,7 +551,7 @@ $lang->resource->execution->qa = 'qa';
|
||||
$lang->resource->execution->testtask = 'testtaskAction';
|
||||
$lang->resource->execution->testcase = 'testcase';
|
||||
$lang->resource->execution->bug = 'bug';
|
||||
$lang->resource->execution->testreport = 'testreport';
|
||||
//$lang->resource->execution->testreport = 'testreport';
|
||||
$lang->resource->execution->burn = 'burn';
|
||||
$lang->resource->execution->computeBurn = 'computeBurnAction';
|
||||
$lang->resource->execution->fixFirst = 'fixFirst';
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
<?php foreach($projectStats as $project):?>
|
||||
<tr>
|
||||
<td><?php printf('%03d', $project->id);?></td>
|
||||
<td class='text-left'><?php echo html::a($this->createLink('project', 'task', 'project=' . $project->id, '', false, $project->id), $project->name, '_parent');?></td>
|
||||
<td class='text-left'><?php echo html::a($this->createLink('project', explode('-', $config->projectLink)[1], 'project=' . $project->id, '', false, $project->id), $project->name, '_parent');?></td>
|
||||
<td><?php echo isset($project->programName) ? $project->programName : '';?></td>
|
||||
<td>
|
||||
<?php $userID = isset($PMList[$project->PM]) ? $PMList[$project->PM]->id : ''?>
|
||||
|
||||
@@ -30,9 +30,9 @@ js::set('browseType', $browseType);
|
||||
</div>
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php if(isset($this->config->maxVersion)):?>
|
||||
<?php common::printLink('project', 'createGuide', "programID=$programID&from=program", '<i class="icon icon-plus"></i>' . $lang->program->PRJCreate, '', 'class="btn btn-primary" data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i>' . $lang->program->PRJCreate, '', 'class="btn btn-primary" data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php elseif($this->config->systemMode == 'new'):?>
|
||||
<?php common::printLink('project', 'create', "mode=scrum&programID=$programID&from=program", '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-primary"');?>
|
||||
<?php common::printLink('project', 'create', "mode=scrum&programID=$programID", '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-primary"');?>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -119,12 +119,12 @@ class projectModel extends model
|
||||
*/
|
||||
public function saveState($projectID = 0, $projects = array())
|
||||
{
|
||||
if($projectID > 0) $this->session->set('project', (int)$projectID);
|
||||
if($projectID == 0 and $this->cookie->lastProject) $this->session->set('project', (int)$this->cookie->lastProject);
|
||||
if($projectID == 0 and $this->session->PRJ == '') $this->session->set('project', key($projects));
|
||||
if($projectID > 0) $this->session->set('PRJ', (int)$projectID);
|
||||
if($projectID == 0 and $this->cookie->lastProject) $this->session->set('PRJ', (int)$this->cookie->lastProject);
|
||||
if($projectID == 0 and $this->session->PRJ == '') $this->session->set('PRJ', key($projects));
|
||||
if(!isset($projects[$this->session->PRJ]))
|
||||
{
|
||||
$this->session->set('project', key($projects));
|
||||
$this->session->set('PRJ', key($projects));
|
||||
if($projectID && strpos(",{$this->app->user->view->projects},", ",{$this->session->PRJ},") === false) $this->accessDenied();
|
||||
}
|
||||
|
||||
@@ -553,11 +553,11 @@ class projectModel extends model
|
||||
* @param array $products
|
||||
* @param int $queryID
|
||||
* @param string $actionURL
|
||||
* @param string $type execution|execution
|
||||
* @param string $type project|execution
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function buildProjectBuildSearchForm($products, $queryID, $actionURL, $type = 'execution')
|
||||
public function buildProjectBuildSearchForm($products, $queryID, $actionURL, $type = 'project')
|
||||
{
|
||||
$this->loadModel('build');
|
||||
|
||||
|
||||
@@ -11,38 +11,6 @@
|
||||
*/
|
||||
class qa extends control
|
||||
{
|
||||
/**
|
||||
* Project id.
|
||||
*
|
||||
* @var int
|
||||
* @access public
|
||||
*/
|
||||
public $projectID;
|
||||
|
||||
/**
|
||||
* Construct.
|
||||
*
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
|
||||
/* Set qa menu group. */
|
||||
$this->projectID = isset($_GET['PRJ']) ? $_GET['PRJ'] : 0;
|
||||
if(!$this->projectID)
|
||||
{
|
||||
foreach($this->config->qa->menuList as $module) $this->lang->navGroup->$module = 'qa';
|
||||
$this->lang->noMenuModule[] = $this->app->rawModule;
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->lang->qa->menu = $this->lang->projectQa->menu;
|
||||
$this->lang->qa->subMenu = $this->lang->projectQa->subMenu;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* The index of qa, go to bug's browse page.
|
||||
*
|
||||
|
||||
@@ -39,6 +39,8 @@ class task extends control
|
||||
*/
|
||||
public function create($executionID = 0, $storyID = 0, $moduleID = 0, $taskID = 0, $todoID = 0)
|
||||
{
|
||||
commonModel::setAppObjectID('execution', $executionID);
|
||||
|
||||
$executions = $this->execution->getPairs($this->session->PRJ);
|
||||
$executionID = $this->execution->saveState($executionID, $executions);
|
||||
|
||||
|
||||
@@ -42,17 +42,22 @@ class testcase extends control
|
||||
|
||||
/* Set test case menu group. */
|
||||
$this->projectID = isset($_GET['PRJ']) ? $_GET['PRJ'] : 0;
|
||||
if(!$this->projectID)
|
||||
if($this->app->openApp == 'qa')
|
||||
{
|
||||
$this->app->loadConfig('qa');
|
||||
foreach($this->config->qa->menuList as $module) $this->lang->navGroup->$module = 'qa';
|
||||
//$this->lang->noMenuModule[] = $this->app->rawModule;
|
||||
}
|
||||
else
|
||||
elseif($this->app->openApp == 'project')
|
||||
{
|
||||
$this->lang->testcase->menu = $this->lang->projectQa->menu;
|
||||
$this->lang->testcase->subMenu = $this->lang->projectQa->subMenu;
|
||||
}
|
||||
elseif($this->app->openApp == 'execution')
|
||||
{
|
||||
$this->lang->testcase->menu = $this->lang->execution->qaMenu;
|
||||
$this->lang->testcase->subMenu = '';
|
||||
}
|
||||
|
||||
$this->view->products = $this->products = $this->product->getProductPairsByProject($this->projectID);
|
||||
if(empty($this->products)) die($this->locate($this->createLink('product', 'showErrorNone', "fromModule=testcase")));
|
||||
@@ -247,6 +252,8 @@ class testcase extends control
|
||||
*/
|
||||
public function create($productID, $branch = '', $moduleID = 0, $from = '', $param = 0, $storyID = 0, $extras = '')
|
||||
{
|
||||
if($this->app->openApp == 'execution') commonModel::setAppObjectID('execution', $this->session->execution);
|
||||
|
||||
$testcaseID = $from == 'testcase' ? $param : 0;
|
||||
$bugID = $from == 'bug' ? $param : 0;
|
||||
|
||||
@@ -283,6 +290,7 @@ class testcase extends control
|
||||
|
||||
setcookie('caseModule', 0, 0, $this->config->webRoot, '', false, false);
|
||||
$response['locate'] = $this->createLink('testcase', 'browse', "productID={$this->post->product}&branch={$this->post->branch}&browseType=all¶m=0&orderBy=id_desc");
|
||||
if($this->app->openApp == 'execution') $response['locate'] = $this->createLink('execution', 'testcase', "executionID={$this->session->execution}&type=all");
|
||||
$this->send($response);
|
||||
}
|
||||
if(empty($this->products)) $this->locate($this->createLink('product', 'create'));
|
||||
|
||||
@@ -80,7 +80,7 @@ class testcaseModel extends model
|
||||
->add('fromBug', $bugID)
|
||||
->setDefault('openedBy', $this->app->user->account)
|
||||
->setDefault('openedDate', $now)
|
||||
->setIF($this->config->systemMode == 'new' && $this->lang->navGroup->testcase != 'qa', 'project', $this->session->PRJ)
|
||||
->setIF($this->config->systemMode == 'new' && $this->app->openApp == 'project', 'project', $this->session->PRJ)
|
||||
->setIF($this->post->story != false, 'storyVersion', $this->loadModel('story')->getVersion((int)$this->post->story))
|
||||
->remove('steps,expects,files,labels,stepType,forceNotReview')
|
||||
->setDefault('story', 0)
|
||||
@@ -176,7 +176,7 @@ class testcaseModel extends model
|
||||
|
||||
$data[$i] = new stdclass();
|
||||
$data[$i]->product = $productID;
|
||||
if($this->config->systemMode == 'new' && $this->lang->navGroup->testcase != 'qa') $data[$i]->project = $this->session->PRJ;
|
||||
if($this->config->systemMode == 'new' && $this->lang->navGroup->testcase == 'project') $data[$i]->project = $this->session->PRJ;
|
||||
$data[$i]->branch = $cases->branch[$i];
|
||||
$data[$i]->module = $cases->module[$i];
|
||||
$data[$i]->type = $cases->type[$i];
|
||||
@@ -1664,10 +1664,14 @@ class testcaseModel extends model
|
||||
$projects = $this->dao->select('project')->from(TABLE_PROJECTSTORY)->where('story')->eq($case->story)->fetchAll('project');
|
||||
$projects = array_keys($projects);
|
||||
}
|
||||
elseif($this->lang->navGroup->testcase == 'project' and empty($case->story))
|
||||
elseif($this->app->openApp == 'project' and empty($case->story))
|
||||
{
|
||||
$projects = array($this->session->PRJ);
|
||||
}
|
||||
elseif($this->app->openApp == 'execution' and empty($case->story))
|
||||
{
|
||||
$projects = array($this->session->execution);
|
||||
}
|
||||
|
||||
if(!empty($projects))
|
||||
{
|
||||
|
||||
@@ -40,9 +40,9 @@ $status = $this->session->testTaskVersionStatus;
|
||||
<?php $condition = "productID=$productID&branch=$branch&type=$scope,$status&orderBy=$orderBy&recTotal=0&recPerPage={$pager->recPerPage}&pageID=1"?>
|
||||
<div class='input-group w-300px input-group-sm'>
|
||||
<span class='input-group-addon'><?php echo $lang->testtask->beginAndEnd;?></span>
|
||||
<div class='datepicker-wrapper datepicker-date'><?php echo html::input('date', $beginTime, "class='form-control form-date' onchange='changeDate(this.value, \"$endTime\", \"$condition\")'");?></div>
|
||||
<div class='datepicker-wrapper datepicker-date'><?php echo html::input('date', $beginTime, "class='form-control form-date' onchange='changeDate(this.value, \"$endTime\", \"$condition\")' placeholder='" . $lang->testtask->begin . "'");?></div>
|
||||
<span class='input-group-addon'><?php echo $lang->testtask->to;?></span>
|
||||
<div class='datepicker-wrapper datepicker-date'><?php echo html::input('date', $endTime, "class='form-control form-date' onchange='changeDate(\"$beginTime\", this.value, \"$condition\")'");?></div>
|
||||
<div class='datepicker-wrapper datepicker-date'><?php echo html::input('date', $endTime, "class='form-control form-date' onchange='changeDate(\"$beginTime\", this.value, \"$condition\")' placeholder='" . $lang->testtask->end . "'");?></div>
|
||||
</div>
|
||||
</div>
|
||||
<?php if(common::canModify('product', $product)):?>
|
||||
|
||||
Reference in New Issue
Block a user