Merge branch 'master' of https://gitlab.zcorp.cc/easycorp/zentaopms into importExport
This commit is contained in:
@@ -372,6 +372,7 @@ $config->objectTables['kanbanorder'] = TABLE_KANBANORDER;
|
||||
$config->objectTables['kanbangroup'] = TABLE_KANBANGROUP;
|
||||
$config->objectTables['kanbancard'] = TABLE_KANBANCARD;
|
||||
$config->objectTables['sonarqube'] = TABLE_PIPELINE;
|
||||
$config->objectTables['gitea'] = TABLE_PIPELINE;
|
||||
$config->objectTables['gitlab'] = TABLE_PIPELINE;
|
||||
$config->objectTables['jebkins'] = TABLE_PIPELINE;
|
||||
$config->objectTables['stage'] = TABLE_STAGE;
|
||||
@@ -379,7 +380,7 @@ $config->objectTables['apistruct'] = TABLE_APISTRUCT;
|
||||
|
||||
$config->newFeatures = array('introduction', 'tutorial', 'youngBlueTheme', 'visions');
|
||||
|
||||
$config->pipelineTypeList = array('gitlab', 'sonarqube', 'jenkins');
|
||||
$config->pipelineTypeList = array('gitlab', 'sonarqube', 'jenkins', 'gitea');
|
||||
|
||||
/* Program privs.*/
|
||||
$config->programPriv = new stdclass();
|
||||
|
||||
@@ -1025,6 +1025,8 @@ EOT;
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Can not locate the url that has '#app', so remove it. */
|
||||
if(strpos($url, '#app=') !== false) $url = substr($url, 0, strpos($url, '#app='));
|
||||
$js .= "$target.location='$url';\n";
|
||||
}
|
||||
return $js . self::end();
|
||||
|
||||
@@ -43,6 +43,7 @@ $config->action->objectNameFields['kanban'] = 'name';
|
||||
$config->action->objectNameFields['kanbancard'] = 'name';
|
||||
$config->action->objectNameFields['sonarqube'] = 'name';
|
||||
$config->action->objectNameFields['gitlab'] = 'name';
|
||||
$config->action->objectNameFields['gitea'] = 'name';
|
||||
$config->action->objectNameFields['stage'] = 'name';
|
||||
$config->action->objectNameFields['apistruct'] = 'name';
|
||||
|
||||
@@ -60,7 +61,7 @@ $config->action->majorList['execution'] = array('opened', 'edited');
|
||||
|
||||
$config->action->needGetProjectType = 'build,task,bug,case,testcase,caselib,testtask,testsuite,testreport,doc,issue,release,risk,design,opportunity,trainplan,gapanalysis,researchplan,researchreport,';
|
||||
$config->action->needGetRelateField = ',story,productplan,release,task,build,bug,testcase,case,testtask,testreport,doc,doclib,issue,risk,opportunity,trainplan,gapanalysis,team,whitelist,researchplan,researchreport,meeting,kanbanlane,kanbancolumn,module,';
|
||||
$config->action->noLinkModules = ',doclib,module,webhook,gitlab,sonarqube,pipeline,jenkins,kanban,kanbanspace,kanbancolumn,kanbanlane,kanbanregion,kanbancard,execution,project,traincategory,apistruct,program,product,user,entry,';
|
||||
$config->action->noLinkModules = ',doclib,module,webhook,gitlab,gitea,sonarqube,pipeline,jenkins,kanban,kanbanspace,kanbancolumn,kanbanlane,kanbanregion,kanbancard,execution,project,traincategory,apistruct,program,product,user,entry,';
|
||||
|
||||
$config->action->preferredTypeNum = 10;
|
||||
|
||||
|
||||
@@ -123,6 +123,7 @@ $lang->action->objectTypes['team'] = 'Team';
|
||||
$lang->action->objectTypes['whitelist'] = 'Whitelist';
|
||||
$lang->action->objectTypes['pipeline'] = 'GitLib';
|
||||
$lang->action->objectTypes['gitlab'] = 'GitLab Server';
|
||||
$lang->action->objectTypes['gitea'] = 'Gitea Server';
|
||||
$lang->action->objectTypes['jenkins'] = 'Jenkins';
|
||||
$lang->action->objectTypes['mr'] = 'Merge Request';
|
||||
$lang->action->objectTypes['gitlabproject'] = 'GitLab Project';
|
||||
@@ -635,6 +636,10 @@ $lang->action->dynamicAction->gitlab['created'] = 'Create GitLab Server';
|
||||
$lang->action->dynamicAction->gitlab['edited'] = 'Edit GitLab Server';
|
||||
$lang->action->dynamicAction->gitlab['deleted'] = 'Delete GitLab Server';
|
||||
|
||||
$lang->action->dynamicAction->gitea['created'] = 'Create Gitea Server';
|
||||
$lang->action->dynamicAction->gitea['edited'] = 'Edit Gitea Server';
|
||||
$lang->action->dynamicAction->gitea['deleted'] = 'Delete Gitea Server';
|
||||
|
||||
/* Generate the corresponding object link. */
|
||||
$lang->action->label->product = $lang->productCommon . '|product|view|productID=%s';
|
||||
$lang->action->label->productplan = 'Plan|productplan|view|productID=%s';
|
||||
|
||||
@@ -123,6 +123,7 @@ $lang->action->objectTypes['team'] = 'Team';
|
||||
$lang->action->objectTypes['whitelist'] = 'Whitelist';
|
||||
$lang->action->objectTypes['pipeline'] = 'GitLab Server';
|
||||
$lang->action->objectTypes['gitlab'] = 'GitLab Server';
|
||||
$lang->action->objectTypes['gitea'] = 'Gitea Server';
|
||||
$lang->action->objectTypes['jenkins'] = 'Jenkins';
|
||||
$lang->action->objectTypes['mr'] = 'Merge Request';
|
||||
$lang->action->objectTypes['gitlabproject'] = 'GitLab Project';
|
||||
@@ -635,6 +636,10 @@ $lang->action->dynamicAction->gitlab['created'] = 'Create GitLab Server';
|
||||
$lang->action->dynamicAction->gitlab['edited'] = 'Edit GitLab Server';
|
||||
$lang->action->dynamicAction->gitlab['deleted'] = 'Delete GitLab Server';
|
||||
|
||||
$lang->action->dynamicAction->gitea['created'] = 'Create Gitea Server';
|
||||
$lang->action->dynamicAction->gitea['edited'] = 'Edit Gitea Server';
|
||||
$lang->action->dynamicAction->gitea['deleted'] = 'Delete Gitea Server';
|
||||
|
||||
/* Generate the corresponding object link. */
|
||||
$lang->action->label->product = $lang->productCommon . '|product|view|productID=%s';
|
||||
$lang->action->label->productplan = 'Plan|productplan|view|productID=%s';
|
||||
|
||||
@@ -123,6 +123,7 @@ $lang->action->objectTypes['team'] = 'Team';
|
||||
$lang->action->objectTypes['whitelist'] = 'Whitelist';
|
||||
$lang->action->objectTypes['pipeline'] = 'GitLib';
|
||||
$lang->action->objectTypes['gitlab'] = 'GitLab Server';
|
||||
$lang->action->objectTypes['gitea'] = 'Gitea Server';
|
||||
$lang->action->objectTypes['jenkins'] = 'Jenkins';
|
||||
$lang->action->objectTypes['mr'] = 'Merge Request';
|
||||
$lang->action->objectTypes['gitlabproject'] = 'GitLab Project';
|
||||
@@ -635,6 +636,10 @@ $lang->action->dynamicAction->gitlab['created'] = 'Create GitLab Server';
|
||||
$lang->action->dynamicAction->gitlab['edited'] = 'Edit GitLab Server';
|
||||
$lang->action->dynamicAction->gitlab['deleted'] = 'Delete GitLab Server';
|
||||
|
||||
$lang->action->dynamicAction->gitea['created'] = 'Create Gitea Server';
|
||||
$lang->action->dynamicAction->gitea['edited'] = 'Edit Gitea Server';
|
||||
$lang->action->dynamicAction->gitea['deleted'] = 'Delete Gitea Server';
|
||||
|
||||
/* Generate the corresponding object link. */
|
||||
$lang->action->label->product = $lang->productCommon . '|product|view|productID=%s';
|
||||
$lang->action->label->productplan = 'Plan|productplan|view|productID=%s';
|
||||
|
||||
+76
-35
@@ -65,41 +65,62 @@ $lang->action->periods['lastweek'] = $lang->action->dynamic->lastWeek;
|
||||
$lang->action->periods['thismonth'] = $lang->action->dynamic->thisMonth;
|
||||
$lang->action->periods['lastmonth'] = $lang->action->dynamic->lastMonth;
|
||||
|
||||
$lang->action->objectTypes['product'] = $lang->productCommon;
|
||||
$lang->action->objectTypes['branch'] = 'Nhánh';
|
||||
$lang->action->objectTypes['story'] = $lang->SRCommon;
|
||||
$lang->action->objectTypes['design'] = 'Design';
|
||||
$lang->action->objectTypes['productplan'] = 'Plan';
|
||||
$lang->action->objectTypes['release'] = 'Phát hành';
|
||||
$lang->action->objectTypes['program'] = 'Program';
|
||||
$lang->action->objectTypes['project'] = 'Project';
|
||||
$lang->action->objectTypes['execution'] = $lang->executionCommon;
|
||||
$lang->action->objectTypes['task'] = 'Nhiệm vụ';
|
||||
$lang->action->objectTypes['build'] = 'Bản dựng';
|
||||
$lang->action->objectTypes['job'] = 'Job';
|
||||
$lang->action->objectTypes['bug'] = 'Bug';
|
||||
$lang->action->objectTypes['case'] = 'Tình huống';
|
||||
$lang->action->objectTypes['caseresult'] = 'Kết quả tình huống';
|
||||
$lang->action->objectTypes['stepresult'] = 'Các bước tình huống';
|
||||
$lang->action->objectTypes['caselib'] = 'Thư viện';
|
||||
$lang->action->objectTypes['testsuite'] = 'Suite';
|
||||
$lang->action->objectTypes['testtask'] = 'Test bản dựng';
|
||||
$lang->action->objectTypes['testreport'] = 'Báo cáo';
|
||||
$lang->action->objectTypes['doc'] = 'Tài liệu';
|
||||
$lang->action->objectTypes['doclib'] = 'Thư viện tài liệu';
|
||||
$lang->action->objectTypes['todo'] = 'Việc làm';
|
||||
$lang->action->objectTypes['risk'] = 'Risk';
|
||||
$lang->action->objectTypes['issue'] = 'Issue';
|
||||
$lang->action->objectTypes['module'] = 'Module';
|
||||
$lang->action->objectTypes['user'] = 'Người dùng';
|
||||
$lang->action->objectTypes['stakeholder'] = 'Stakeholder';
|
||||
$lang->action->objectTypes['budget'] = 'Cost Estimate';
|
||||
$lang->action->objectTypes['entry'] = 'Entry';
|
||||
$lang->action->objectTypes['webhook'] = 'Webhook';
|
||||
$lang->action->objectTypes['job'] = 'Job';
|
||||
$lang->action->objectTypes['team'] = 'Team';
|
||||
$lang->action->objectTypes['whitelist'] = 'Whitelist';
|
||||
$lang->action->objectTypes['pipeline'] = 'GitLib';
|
||||
$lang->action->objectTypes['product'] = $lang->productCommon;
|
||||
$lang->action->objectTypes['branch'] = 'Nhánh';
|
||||
$lang->action->objectTypes['story'] = $lang->SRCommon;
|
||||
$lang->action->objectTypes['design'] = 'Design';
|
||||
$lang->action->objectTypes['productplan'] = 'Plan';
|
||||
$lang->action->objectTypes['release'] = 'Phát hành';
|
||||
$lang->action->objectTypes['program'] = 'Program';
|
||||
$lang->action->objectTypes['project'] = 'Project';
|
||||
$lang->action->objectTypes['execution'] = $lang->executionCommon;
|
||||
$lang->action->objectTypes['task'] = 'Nhiệm vụ';
|
||||
$lang->action->objectTypes['build'] = 'Bản dựng';
|
||||
$lang->action->objectTypes['job'] = 'Job';
|
||||
$lang->action->objectTypes['bug'] = 'Bug';
|
||||
$lang->action->objectTypes['case'] = 'Tình huống';
|
||||
$lang->action->objectTypes['caseresult'] = 'Kết quả tình huống';
|
||||
$lang->action->objectTypes['stepresult'] = 'Các bước tình huống';
|
||||
$lang->action->objectTypes['caselib'] = 'Thư viện';
|
||||
$lang->action->objectTypes['testsuite'] = 'Suite';
|
||||
$lang->action->objectTypes['testtask'] = 'Test bản dựng';
|
||||
$lang->action->objectTypes['testreport'] = 'Báo cáo';
|
||||
$lang->action->objectTypes['doc'] = 'Tài liệu';
|
||||
$lang->action->objectTypes['doclib'] = 'Thư viện tài liệu';
|
||||
$lang->action->objectTypes['todo'] = 'Việc làm';
|
||||
$lang->action->objectTypes['risk'] = 'Risk';
|
||||
$lang->action->objectTypes['issue'] = 'Issue';
|
||||
$lang->action->objectTypes['module'] = 'Module';
|
||||
$lang->action->objectTypes['user'] = 'Người dùng';
|
||||
$lang->action->objectTypes['stakeholder'] = 'Stakeholder';
|
||||
$lang->action->objectTypes['budget'] = 'Cost Estimate';
|
||||
$lang->action->objectTypes['entry'] = 'Entry';
|
||||
$lang->action->objectTypes['webhook'] = 'Webhook';
|
||||
$lang->action->objectTypes['job'] = 'Job';
|
||||
$lang->action->objectTypes['team'] = 'Team';
|
||||
$lang->action->objectTypes['whitelist'] = 'Whitelist';
|
||||
$lang->action->objectTypes['pipeline'] = 'GitLib';
|
||||
$lang->action->objectTypes['gitlab'] = 'GitLab Server';
|
||||
$lang->action->objectTypes['gitea'] = 'Gitea Server';
|
||||
$lang->action->objectTypes['jenkins'] = 'Jenkins';
|
||||
$lang->action->objectTypes['mr'] = 'Merge Request';
|
||||
$lang->action->objectTypes['gitlabproject'] = 'GitLab Project';
|
||||
$lang->action->objectTypes['gitlabuser'] = 'GitLab User';
|
||||
$lang->action->objectTypes['gitlabgroup'] = 'GitLab Group';
|
||||
$lang->action->objectTypes['gitlabbranch'] = 'GitLab Branch';
|
||||
$lang->action->objectTypes['gitlabbranchpriv'] = 'GitLab Protected Branches';
|
||||
$lang->action->objectTypes['gitlabtag'] = 'GitLab Tag';
|
||||
$lang->action->objectTypes['gitlabtagpriv'] = 'GitLab Tag Protected';
|
||||
$lang->action->objectTypes['kanbanspace'] = 'Kanban Space';
|
||||
$lang->action->objectTypes['kanban'] = 'Kanban';
|
||||
$lang->action->objectTypes['kanbanregion'] = 'Kanban Region';
|
||||
$lang->action->objectTypes['kanbanlane'] = 'Kanban Lane';
|
||||
$lang->action->objectTypes['kanbancolumn'] = 'Kanban Column';
|
||||
$lang->action->objectTypes['kanbancard'] = 'Kanban Card';
|
||||
$lang->action->objectTypes['sonarqube'] = 'SonarQube Server';
|
||||
$lang->action->objectTypes['sonarqubeproject'] = 'SonarQube Project';
|
||||
$lang->action->objectTypes['stage'] = 'Stage';
|
||||
$lang->action->objectTypes['patch'] = 'Patch';
|
||||
|
||||
/* Used to describe operation history. */
|
||||
$lang->action->desc = new stdclass();
|
||||
@@ -462,6 +483,26 @@ $lang->action->dynamicAction->user['loginxuanxuan'] = 'Login Desktop';
|
||||
$lang->action->dynamicAction->entry['created'] = 'Thêm ứng dụng';
|
||||
$lang->action->dynamicAction->entry['edited'] = 'Sửa ứng dụng';
|
||||
|
||||
$lang->action->dynamicAction->job['created'] = 'Create Job';
|
||||
$lang->action->dynamicAction->job['edited'] = 'Edit Job';
|
||||
$lang->action->dynamicAction->job['executed'] = 'Execute Job';
|
||||
$lang->action->dynamicAction->job['deleted'] = 'Delete Job';
|
||||
$lang->action->dynamicAction->job['undeleted'] = 'Undelete Job';
|
||||
|
||||
$lang->action->dynamicAction->sonarqube['created'] = 'Create SonarQube Server';
|
||||
$lang->action->dynamicAction->sonarqube['edited'] = 'Edit SonarQube Server';
|
||||
$lang->action->dynamicAction->sonarqube['deleted'] = 'Delete SonarQube Server';
|
||||
|
||||
$lang->action->dynamicAction->sonarqubeproject['deleted'] = 'Delete SonarQube Project';
|
||||
|
||||
$lang->action->dynamicAction->gitlab['created'] = 'Create GitLab Server';
|
||||
$lang->action->dynamicAction->gitlab['edited'] = 'Edit GitLab Server';
|
||||
$lang->action->dynamicAction->gitlab['deleted'] = 'Delete GitLab Server';
|
||||
|
||||
$lang->action->dynamicAction->gitea['created'] = 'Create Gitea Server';
|
||||
$lang->action->dynamicAction->gitea['edited'] = 'Edit Gitea Server';
|
||||
$lang->action->dynamicAction->gitea['deleted'] = 'Delete Gitea Server';
|
||||
|
||||
/* Generate the corresponding object link. */
|
||||
global $config;
|
||||
$lang->action->label->product = $lang->productCommon . '|product|view|productID=%s';
|
||||
|
||||
@@ -123,6 +123,7 @@ $lang->action->objectTypes['team'] = '团队';
|
||||
$lang->action->objectTypes['whitelist'] = '白名单';
|
||||
$lang->action->objectTypes['pipeline'] = 'GitLab服务器';
|
||||
$lang->action->objectTypes['gitlab'] = 'GitLab服务器';
|
||||
$lang->action->objectTypes['gitea'] = 'Gitea服务器';
|
||||
$lang->action->objectTypes['jenkins'] = 'Jenkins';
|
||||
$lang->action->objectTypes['mr'] = '合并请求';
|
||||
$lang->action->objectTypes['gitlabproject'] = 'GitLab项目';
|
||||
@@ -632,9 +633,13 @@ $lang->action->dynamicAction->sonarqube['deleted'] = '删除SonarQube服务器';
|
||||
$lang->action->dynamicAction->sonarqubeproject['deleted'] = '删除SonarQube项目';
|
||||
|
||||
$lang->action->dynamicAction->gitlab['created'] = '创建GitLab服务器';
|
||||
$lang->action->dynamicAction->gitlab['edited'] = '设置GitLab服务器';
|
||||
$lang->action->dynamicAction->gitlab['edited'] = '编辑GitLab服务器';
|
||||
$lang->action->dynamicAction->gitlab['deleted'] = '删除GitLab服务器';
|
||||
|
||||
$lang->action->dynamicAction->gitea['created'] = '创建Gitea服务器';
|
||||
$lang->action->dynamicAction->gitea['edited'] = '编辑Gitea服务器';
|
||||
$lang->action->dynamicAction->gitea['deleted'] = '删除Gitea服务器';
|
||||
|
||||
/* 用来生成相应对象的链接。*/
|
||||
$lang->action->label->product = $lang->productCommon . '|product|view|productID=%s';
|
||||
$lang->action->label->productplan = "计划|productplan|view|productID=%s";
|
||||
|
||||
@@ -1756,10 +1756,7 @@ class block extends control
|
||||
->beginIF($objectType == 'story' or $objectType == 'requirement')->andWhere('t2.deleted')->eq('0')->fi()
|
||||
->beginIF($objectType == 'todo')->andWhere('t1.cycle')->eq(0)->andWhere('t1.status')->eq('wait')->andWhere('t1.vision')->eq($this->config->vision)->fi()
|
||||
->beginIF($objectType != 'todo')->andWhere('t1.status')->ne('closed')->fi()
|
||||
->beginIF($objectType == 'feedback')
|
||||
->andWhere('t1.status')->in('wait, noreview')
|
||||
->andWhere('t1.assignedTo')->eq($this->app->user->account)
|
||||
->fi()
|
||||
->beginIF($objectType == 'feedback')->andWhere('t1.status')->in('wait, noreview')->fi()
|
||||
->orderBy($orderBy)
|
||||
->beginIF($limitCount)->limit($limitCount)->fi()
|
||||
->fetchAll();
|
||||
|
||||
@@ -211,7 +211,10 @@ class branch extends control
|
||||
public function ajaxGetDropMenu($productID, $branch, $module, $method, $extra = '')
|
||||
{
|
||||
parse_str($extra, $output);
|
||||
$branches = $this->branch->getPairs($productID, 'all', isset($output['projectID']) ? $output['projectID'] : 0);
|
||||
$isQaModule = (strpos(',project,execution,', ",{$this->app->tab},") !== false and strpos(',bug,', ",$method,") !== false and !empty($productID)) ? true : false;
|
||||
$param = $isQaModule ? $extra : 0;
|
||||
$param = isset($output['projectID']) ? $output['projectID'] : $param;
|
||||
$branches = $this->branch->getPairs($productID, 'all', $param);
|
||||
$statusList = $this->dao->select('id,status')->from(TABLE_BRANCH)->where('product')->eq($productID)->fetchPairs();
|
||||
|
||||
$this->view->link = $this->loadModel('product')->getProductLink($module, $method, $extra, true);
|
||||
|
||||
+33
-9
@@ -1416,13 +1416,26 @@ class bug extends control
|
||||
{
|
||||
$bug = $this->bug->getById($bugID);
|
||||
$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
|
||||
{
|
||||
@@ -1853,16 +1866,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
|
||||
{
|
||||
|
||||
@@ -1737,6 +1737,7 @@ class bugModel extends model
|
||||
*
|
||||
* @param int $projectID
|
||||
* @param int $productID
|
||||
* @param int $branchID
|
||||
* @param int $build
|
||||
* @param string $type
|
||||
* @param int $param
|
||||
@@ -1746,7 +1747,7 @@ class bugModel extends model
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getProjectBugs($projectID, $productID = 0, $build = 0, $type = '', $param = 0, $orderBy = 'id_desc', $excludeBugs = '', $pager = null)
|
||||
public function getProjectBugs($projectID, $productID = 0, $branchID = 0, $build = 0, $type = '', $param = 0, $orderBy = 'id_desc', $excludeBugs = '', $pager = null)
|
||||
{
|
||||
$type = strtolower($type);
|
||||
if($type == 'bysearch')
|
||||
@@ -1781,6 +1782,7 @@ class bugModel extends model
|
||||
->where('t1.deleted')->eq(0)
|
||||
->beginIF(empty($build))->andWhere('t1.project')->eq($projectID)->fi()
|
||||
->beginIF(!empty($productID))->andWhere('t1.product')->eq($productID)->fi()
|
||||
->andWhere('t1.branch')->eq($branchID)
|
||||
->beginIF($type == 'unresolved')->andWhere('t1.status')->eq('active')->fi()
|
||||
->beginIF($type == 'noclosed')->andWhere('t1.status')->ne('closed')->fi()
|
||||
->beginIF($type == 'assignedtome')->andWhere('t1.assignedTo')->eq($this->app->user->account)->fi()
|
||||
@@ -1801,6 +1803,7 @@ class bugModel extends model
|
||||
*
|
||||
* @param int $executionID
|
||||
* @param int $productID
|
||||
* @param int $branchID
|
||||
* @param int $build
|
||||
* @param string $type
|
||||
* @param int $param
|
||||
@@ -1810,7 +1813,7 @@ class bugModel extends model
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getExecutionBugs($executionID, $productID = 0, $build = 0, $type = '', $param = 0, $orderBy = 'id_desc', $excludeBugs = '', $pager = null)
|
||||
public function getExecutionBugs($executionID, $productID = 0, $branchID = 'all', $build = 0, $type = '', $param = 0, $orderBy = 'id_desc', $excludeBugs = '', $pager = null)
|
||||
{
|
||||
$type = strtolower($type);
|
||||
if($type == 'bysearch')
|
||||
@@ -1843,6 +1846,7 @@ class bugModel extends model
|
||||
$bugs = $this->dao->select('t1.*')->from(TABLE_BUG)->alias('t1')
|
||||
->leftJoin(TABLE_MODULE)->alias('t2')->on('t1.module=t2.id')
|
||||
->where('t1.deleted')->eq(0)
|
||||
->beginIF($branchID != 'all')->andWhere('t1.branch')->eq($branchID)->fi()
|
||||
->beginIF(empty($build))->andWhere('t1.execution')->eq($executionID)->fi()
|
||||
->beginIF(!empty($productID))->andWhere('t1.product')->eq($productID)->fi()
|
||||
->beginIF($type == 'unresolved')->andWhere('t1.status')->eq('active')->fi()
|
||||
|
||||
@@ -288,7 +288,7 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
|
||||
<div class='btn-group dropup'>
|
||||
<?php
|
||||
$actionLink = $this->createLink('bug', 'batchEdit', "productID=$productID&branch=$branch");
|
||||
$misc = $canBatchEdit ? "onclick=\"setFormAction('$actionLink')\"" : "disabled='disabled'";
|
||||
$misc = $canBatchEdit ? "onclick=\"setFormAction('$actionLink', '', '#bugList')\"" : "disabled='disabled'";
|
||||
echo html::commonButton($lang->edit, $misc);
|
||||
?>
|
||||
<button type='button' class='btn dropdown-toggle' data-toggle='dropdown'><span class='caret'></span></button>
|
||||
@@ -296,17 +296,17 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
|
||||
<?php
|
||||
$class = $canBatchConfirm ? '' : "class='disabled'";
|
||||
$actionLink = $this->createLink('bug', 'batchConfirm');
|
||||
$misc = $canBatchConfirm ? "onclick=\"setFormAction('$actionLink', 'hiddenwin')\"" : '';
|
||||
$misc = $canBatchConfirm ? "onclick=\"setFormAction('$actionLink', 'hiddenwin', '#bugList')\"" : '';
|
||||
echo "<li $class>" . html::a('javascript:;', $lang->bug->confirmBug, '', $misc) . "</li>";
|
||||
|
||||
$class = $canBatchClose ? '' : "class='disabled'";
|
||||
$actionLink = $this->createLink('bug', 'batchClose');
|
||||
$misc = $canBatchClose ? "onclick=\"setFormAction('$actionLink', 'hiddenwin')\"" : '';
|
||||
$misc = $canBatchClose ? "onclick=\"setFormAction('$actionLink', 'hiddenwin', '#bugList')\"" : '';
|
||||
echo "<li $class>" . html::a('javascript:;', $lang->bug->close, '', $misc) . "</li>";
|
||||
|
||||
$class = $canBatchActivate ? '' : "class='disabled'";
|
||||
$actionLink = $this->createLink('bug', 'batchActivate', "productID=$productID&branch=$branch");
|
||||
$misc = $canBatchActivate ? "onclick=\"setFormAction('$actionLink')\"" : '';
|
||||
$misc = $canBatchActivate ? "onclick=\"setFormAction('$actionLink', '', '#bugList')\"" : '';
|
||||
echo "<li $class>" . html::a('javascript:;', $lang->bug->activate, '', $misc) . "</li>";
|
||||
|
||||
$misc = $canBatchResolve ? "id='resolveItem'" : '';
|
||||
@@ -332,7 +332,7 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
|
||||
{
|
||||
$actionLink = $this->createLink('bug', 'batchResolve', "resolution=fixed&resolvedBuild=$key");
|
||||
echo "<li class='option' data-key='$key'>";
|
||||
echo html::a('javascript:;', $build, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin')\"");
|
||||
echo html::a('javascript:;', $build, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin', '#bugList')\"");
|
||||
echo "</li>";
|
||||
}
|
||||
echo "</ul>";
|
||||
@@ -341,7 +341,7 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
|
||||
}
|
||||
else
|
||||
{
|
||||
echo '<li>' . html::a('javascript:;', $resolution, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin')\"") . '</li>';
|
||||
echo '<li>' . html::a('javascript:;', $resolution, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin', '#bugList')\"") . '</li>';
|
||||
}
|
||||
}
|
||||
echo '</ul></li>';
|
||||
@@ -370,7 +370,7 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
|
||||
{
|
||||
$searchKey = $withSearch ? ('data-key="' . zget($branchsPinYin, $branchName, '') . '"') : '';
|
||||
$actionLink = $this->createLink('bug', 'batchChangeBranch', "branchID=$branchID");
|
||||
echo html::a('#', $branchName, '', "$searchKey onclick=\"setFormAction('$actionLink', 'hiddenwin')\" data-key='$branchID'");
|
||||
echo html::a('#', $branchName, '', "$searchKey onclick=\"setFormAction('$actionLink', 'hiddenwin', '#bugList')\" data-key='$branchID'");
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
@@ -398,7 +398,7 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
|
||||
{
|
||||
$searchKey = $withSearch ? ('data-key="' . zget($modulesPinYin, $module, '') . '"') : '';
|
||||
$actionLink = $this->createLink('bug', 'batchChangeModule', "moduleID=$moduleId");
|
||||
echo html::a('#', $module, '', "$searchKey onclick=\"setFormAction('$actionLink', 'hiddenwin')\" data-key='$moduleID'");
|
||||
echo html::a('#', $module, '', "$searchKey onclick=\"setFormAction('$actionLink', 'hiddenwin', '#bugList')\" data-key='$moduleID'");
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
@@ -428,7 +428,7 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
|
||||
{
|
||||
if(empty($key)) continue;
|
||||
$searchKey = $withSearch ? ('data-key="' . zget($membersPinYin, $value, '') . " @$key\"") : "data-key='@$key'";
|
||||
echo html::a("javascript:$(\"#assignedTo\").val(\"$key\");setFormAction(\"$actionLink\", \"hiddenwin\")", $value, '', $searchKey);
|
||||
echo html::a("javascript:$(\"#assignedTo\").val(\"$key\");setFormAction(\"$actionLink\", \"hiddenwin\", \"#bugList\")", $value, '', $searchKey);
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
@@ -270,7 +270,7 @@ class build extends control
|
||||
$this->view->storyPager = $storyPager;
|
||||
|
||||
$generatedBugPager = new pager($type == 'generatedBug' ? $recTotal : 0, $recPerPage, $type == 'generatedBug' ? $pageID : 1);
|
||||
$this->view->generatedBugs = $this->bug->getExecutionBugs($build->execution, $build->product, $build->id, $type, $param, $type == 'generatedBug' ? $orderBy : 'status_desc,id_desc', '', $generatedBugPager);
|
||||
$this->view->generatedBugs = $this->bug->getExecutionBugs($build->execution, $build->product, 'all', $build->id, $type, $param, $type == 'generatedBug' ? $orderBy : 'status_desc,id_desc', '', $generatedBugPager);
|
||||
$this->view->generatedBugPager = $generatedBugPager;
|
||||
|
||||
$this->executeHooks($buildID);
|
||||
@@ -682,7 +682,7 @@ class build extends control
|
||||
}
|
||||
else
|
||||
{
|
||||
$allBugs = $this->bug->getExecutionBugs($build->execution, 0, $buildID, 'noclosed', 0, 'status_desc,id_desc', $build->bugs, $pager);
|
||||
$allBugs = $this->bug->getExecutionBugs($build->execution, 0, 'all', $buildID, 'noclosed', 0, 'status_desc,id_desc', $build->bugs, $pager);
|
||||
}
|
||||
|
||||
$this->view->allBugs = $allBugs;
|
||||
|
||||
@@ -176,7 +176,6 @@ $lang->createIcons['program'] = 'program';
|
||||
$lang->createIcons['kanbanspace'] = 'cube';
|
||||
$lang->createIcons['kanban'] = 'kanban';
|
||||
|
||||
$lang->refreshIcon = "<i class='icon icon-refresh'></i>";
|
||||
$lang->noMenuModule = array('report', 'my', 'todo', 'effort', 'program', 'product', 'execution', 'task', 'build', 'productplan', 'project', 'projectrelease', 'projectstory', 'story', 'branch', 'release', 'attend', 'leave', 'makeup', 'overtime', 'lieu', 'custom', 'admin', 'mail', 'extension', 'dev', 'backup', 'action', 'cron', 'pssp', 'sms', 'message', 'webhook', 'search', 'score', 'stage', 'entry', 'jenkins', 'gitlab', 'gitea');
|
||||
|
||||
if(isset($_SESSION['tutorialMode']) and $_SESSION['tutorialMode'] and !defined('TUTORIAL')) define('TUTORIAL', true);
|
||||
|
||||
@@ -52,6 +52,7 @@ $lang->designedByAIUX = "<a href='https://api.zentao.net/goto.php?item=aiux' cla
|
||||
$lang->reset = 'Zurücksetzen';
|
||||
$lang->cancel = 'Abbrechen';
|
||||
$lang->refresh = 'Aktualisieren';
|
||||
$lang->refreshIcon = "<i title='$lang->refresh' class='icon icon-refresh'></i>";
|
||||
$lang->create = 'Create';
|
||||
$lang->edit = 'Bearbeiten';
|
||||
$lang->delete = 'Löschen';
|
||||
|
||||
@@ -52,6 +52,7 @@ $lang->designedByAIUX = "<a href='https://api.zentao.net/goto.php?item=aiux' cla
|
||||
$lang->reset = 'Reset';
|
||||
$lang->cancel = 'Cancel';
|
||||
$lang->refresh = 'Refresh';
|
||||
$lang->refreshIcon = "<i title='$lang->refresh' class='icon icon-refresh'></i>";
|
||||
$lang->create = 'Create';
|
||||
$lang->edit = 'Edit';
|
||||
$lang->delete = 'Delete';
|
||||
@@ -186,10 +187,10 @@ $lang->upgrade->common = 'Update';
|
||||
$lang->program->list = 'Program List';
|
||||
$lang->program->kanban = 'Program Kanban';
|
||||
$lang->design->common = 'Design';
|
||||
$lang->design->HLDS = 'HLDS';
|
||||
$lang->design->DDS = 'DDS';
|
||||
$lang->design->DBDS = 'DBDS';
|
||||
$lang->design->ADS = 'ADS';
|
||||
$lang->design->HLDS = 'Preliminary Design';
|
||||
$lang->design->DDS = 'Detailed Design';
|
||||
$lang->design->DBDS = 'Database Design';
|
||||
$lang->design->ADS = 'Interface Design';
|
||||
$lang->stage->common = 'Stage';
|
||||
$lang->stage->list = 'Stage List';
|
||||
$lang->execution->list = "{$lang->executionCommon} List";
|
||||
|
||||
@@ -52,6 +52,7 @@ $lang->designedByAIUX = "<a href='https://api.zentao.net/goto.php?item=aiux' cla
|
||||
$lang->reset = 'Réinitialiser';
|
||||
$lang->cancel = 'Annuler';
|
||||
$lang->refresh = 'Rafraichir';
|
||||
$lang->refreshIcon = "<i title='$lang->refresh' class='icon icon-refresh'></i>";
|
||||
$lang->create = 'Create';
|
||||
$lang->edit = 'Editer';
|
||||
$lang->delete = 'Supprimer';
|
||||
|
||||
@@ -52,6 +52,7 @@ $lang->designedByAIUX = "<a href='https://api.zentao.net/goto.php?item=aiux' cla
|
||||
$lang->reset = '重填';
|
||||
$lang->cancel = '取消';
|
||||
$lang->refresh = '刷新';
|
||||
$lang->refreshIcon = "<i title='$lang->refresh' class='icon icon-refresh'></i>";
|
||||
$lang->create = '新建';
|
||||
$lang->edit = '编辑';
|
||||
$lang->delete = '删除';
|
||||
|
||||
@@ -1601,7 +1601,7 @@ EOD;
|
||||
* @param string $extraClass
|
||||
* @param bool $onlyBody
|
||||
* @param string $misc
|
||||
* @Param bool $extraEnabled
|
||||
* @param bool $extraEnabled
|
||||
* @static
|
||||
* @access public
|
||||
* @return void
|
||||
@@ -1802,13 +1802,14 @@ EOD;
|
||||
* @param string $extraClass
|
||||
* @param bool $onlyBody
|
||||
* @param string $misc
|
||||
* @param string $extraEnabled
|
||||
* @static
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public static function printIcon($module, $method, $vars = '', $object = '', $type = 'button', $icon = '', $target = '', $extraClass = '', $onlyBody = false, $misc = '', $title = '', $programID = 0)
|
||||
public static function printIcon($module, $method, $vars = '', $object = '', $type = 'button', $icon = '', $target = '', $extraClass = '', $onlyBody = false, $misc = '', $title = '', $programID = 0, $extraEnabled = '')
|
||||
{
|
||||
echo common::buildIconButton($module, $method, $vars, $object, $type, $icon, $target, $extraClass, $onlyBody, $misc, $title, $programID);
|
||||
echo common::buildIconButton($module, $method, $vars, $object, $type, $icon, $target, $extraClass, $onlyBody, $misc, $title, $programID, $extraEnabled);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2417,6 +2418,7 @@ EOD;
|
||||
($module == 'file' and strpos('|read|download|uploadimages|ajaxwopifiles|', "|{$method}|") !== false) or
|
||||
($module == 'sso' and $method == 'login') or
|
||||
($module == 'report' && $method == 'annualdata') or
|
||||
($module == 'misc' && $method == 'captcha') or
|
||||
($module == 'traincourse' and $method == 'ajaxuploadlargefile') or
|
||||
($module == 'traincourse' and $method == 'playvideo'))
|
||||
{
|
||||
|
||||
@@ -42,7 +42,7 @@ $lang->design->comment = 'Comment';
|
||||
$lang->design->common = 'Design';
|
||||
$lang->design->create = 'Create Design';
|
||||
$lang->design->batchCreate = 'Batch Create';
|
||||
$lang->design->edit = 'Edit';
|
||||
$lang->design->edit = 'Change';
|
||||
$lang->design->delete = 'Delete';
|
||||
$lang->design->view = 'View';
|
||||
$lang->design->browse = 'List';
|
||||
|
||||
@@ -916,6 +916,7 @@ class execution extends control
|
||||
*
|
||||
* @param int $executionID
|
||||
* @param int $productID
|
||||
* @param int $branchID
|
||||
* @param string $orderBy
|
||||
* @param int $build
|
||||
* @param string $type
|
||||
@@ -926,7 +927,7 @@ class execution extends control
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function bug($executionID = 0, $productID = 0, $orderBy = 'status,id_desc', $build = 0, $type = 'all', $param = 0, $recTotal = 0, $recPerPage = 20, $pageID = 1)
|
||||
public function bug($executionID = 0, $productID = 0, $branch = 0, $orderBy = 'status,id_desc', $build = 0, $type = 'all', $param = 0, $recTotal = 0, $recPerPage = 20, $pageID = 1)
|
||||
{
|
||||
/* Load these two models. */
|
||||
$this->loadModel('bug');
|
||||
@@ -943,11 +944,10 @@ class execution extends control
|
||||
$execution = $this->commonAction($executionID);
|
||||
$executionID = $execution->id;
|
||||
$products = $this->product->getProducts($execution->id);
|
||||
$branchID = isset($products[$productID]) ? current($products[$productID]->branches) : 0;
|
||||
|
||||
$productPairs = array('0' => $this->lang->product->all);
|
||||
foreach($products as $productData) $productPairs[$productData->id] = $productData->name;
|
||||
$this->lang->modulePageNav = $this->product->select($productPairs, $productID, 'execution', 'bug', $executionID, 0, 0, '', false);
|
||||
$this->lang->modulePageNav = $this->product->select($productPairs, $productID, 'execution', 'bug', $executionID, $branch);
|
||||
|
||||
/* Header and position. */
|
||||
$title = $execution->name . $this->lang->colon . $this->lang->execution->bug;
|
||||
@@ -959,7 +959,7 @@ class execution extends control
|
||||
if($this->app->getViewType() == 'xhtml') $recPerPage = 10;
|
||||
$pager = new pager($recTotal, $recPerPage, $pageID);
|
||||
$sort = common::appendOrder($orderBy);
|
||||
$bugs = $this->bug->getExecutionBugs($executionID, $productID, $build, $type, $param, $sort, '', $pager);
|
||||
$bugs = $this->bug->getExecutionBugs($executionID, $productID, $branch, $build, $type, $param, $sort, '', $pager);
|
||||
$bugs = $this->bug->checkDelayedBugs($bugs);
|
||||
$users = $this->user->getPairs('noletter');
|
||||
|
||||
@@ -986,7 +986,7 @@ class execution extends control
|
||||
$showBranch = $this->loadModel('branch')->showBranch($productID);
|
||||
|
||||
/* Display status of branch. */
|
||||
$branches = $this->branch->getList($productID, 0, 'all');
|
||||
$branches = $this->branch->getList($productID, $executionID, 'all');
|
||||
foreach($branches as $branchInfo)
|
||||
{
|
||||
$branchOption[$branchInfo->id] = $branchInfo->name;
|
||||
@@ -1014,7 +1014,7 @@ class execution extends control
|
||||
$modules = $this->tree->getAllModulePairs('bug');
|
||||
|
||||
/* Get module tree.*/
|
||||
$extra = array('executionID' => $executionID, 'orderBy' => $orderBy, 'type' => $type, 'build' => $build);
|
||||
$extra = array('executionID' => $executionID, 'orderBy' => $orderBy, 'type' => $type, 'build' => $build, 'branchID' => $branch);
|
||||
if($executionID and empty($productID) and count($products) > 1)
|
||||
{
|
||||
$moduleTree = $this->tree->getBugTreeMenu($executionID, $productID, 0, array('treeModel', 'createBugLink'), $extra);
|
||||
@@ -1022,7 +1022,7 @@ class execution extends control
|
||||
elseif(!empty($products))
|
||||
{
|
||||
$productID = empty($productID) ? reset($products)->id : $productID;
|
||||
$moduleTree = $this->tree->getTreeMenu($productID, 'bug', 0, array('treeModel', 'createBugLink'), $extra + array('productID' => $productID), 'all');
|
||||
$moduleTree = $this->tree->getTreeMenu($productID, 'bug', 0, array('treeModel', 'createBugLink'), $extra + array('branchID' => $branch, 'productID' => $productID), $branch);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -1030,7 +1030,7 @@ class execution extends control
|
||||
}
|
||||
$tree = $moduleID ? $this->tree->getByID($moduleID) : '';
|
||||
|
||||
$showModule = !empty($this->config->datatable->projectBug->showModule) ? $this->config->datatable->executionBug->showModule : '';
|
||||
$showModule = !empty($this->config->datatable->executionBug->showModule) ? $this->config->datatable->executionBug->showModule : '';
|
||||
|
||||
/* Assign. */
|
||||
$this->view->title = $title;
|
||||
@@ -1043,7 +1043,7 @@ class execution extends control
|
||||
$this->view->orderBy = $orderBy;
|
||||
$this->view->users = $users;
|
||||
$this->view->productID = $productID;
|
||||
$this->view->branchID = empty($this->view->build->branch) ? $branchID : $this->view->build->branch;
|
||||
$this->view->branchID = empty($this->view->build->branch) ? $branch : $this->view->build->branch;
|
||||
$this->view->memberPairs = $memberPairs;
|
||||
$this->view->type = $type;
|
||||
$this->view->summary = $this->bug->summary($bugs);
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
<style>
|
||||
#subHeader #dropMenu .col-left .list-group {margin-bottom: 0px; padding-top: 10px;}
|
||||
#subHeader #dropMenu .col-left {padding-bottom: 0px;}
|
||||
#currentBranch + #dropMenu .col-left {padding-bottom: 30px;}
|
||||
</style>
|
||||
<div id="mainMenu" class="clearfix main-row fade in">
|
||||
<div id="sidebarHeader">
|
||||
@@ -23,7 +24,7 @@
|
||||
echo $moduleName;
|
||||
if(!empty($moduleID))
|
||||
{
|
||||
$removeLink = $this->createLink('execution', 'bug', "executionID={$execution->id}&productID={$productID}&orderBy=$orderBy&build=$buildID&type=$type¶m=0&recTotal=$pager->recTotal&recPerPage=$pager->recPerPage");
|
||||
$removeLink = $this->createLink('execution', 'bug', "executionID={$execution->id}&productID={$productID}&branch={$branchID}&orderBy=$orderBy&build=$buildID&type=$type¶m=0&recTotal=$pager->recTotal&recPerPage=$pager->recPerPage");
|
||||
echo html::a($removeLink, "<i class='icon icon-sm icon-close'></i>", '', "class='text-muted' data-app='{$this->app->tab}'");
|
||||
}
|
||||
?>
|
||||
@@ -32,8 +33,8 @@
|
||||
<div class="btn-toolbar pull-left">
|
||||
<?php
|
||||
$buildName = $build ? " <span class='label label-danger'>Build:{$build->name}</span>" : '';
|
||||
echo html::a($this->inlink('bug', "executionID={$execution->id}&productID={$productID}&orderBy=status,id_desc&build=$buildID&type=all"), "<span class='text'>{$lang->bug->allBugs}</span>" . ($type == 'all' ? " <span class='label label-light label-badge'>{$pager->recTotal}</span>$buildName" : ''), '', "id='allTab' class='btn btn-link" . ('all' == $type ? ' btn-active-text' : '') . "'");
|
||||
echo html::a($this->inlink('bug', "executionID={$execution->id}&productID={$productID}&orderBy=status,id_desc&build=$buildID&type=unresolved"), "<span class='text'>{$lang->bug->unResolved}</span>" . ($type == 'unresolved' ? " <span class='label label-light label-badge'>{$pager->recTotal}</span>$buildName" : ''), '', "id='unresolvedTab' class='btn btn-link" . ('unresolved' == $type ? ' btn-active-text' : '') . "'");
|
||||
echo html::a($this->inlink('bug', "executionID={$execution->id}&productID={$productID}&branch={$branchID}&orderBy=status,id_desc&build=$buildID&type=all"), "<span class='text'>{$lang->bug->allBugs}</span>" . ($type == 'all' ? " <span class='label label-light label-badge'>{$pager->recTotal}</span>$buildName" : ''), '', "id='allTab' class='btn btn-link" . ('all' == $type ? ' btn-active-text' : '') . "'");
|
||||
echo html::a($this->inlink('bug', "executionID={$execution->id}&productID={$productID}&branch={$branchID}&orderBy=status,id_desc&build=$buildID&type=unresolved"), "<span class='text'>{$lang->bug->unResolved}</span>" . ($type == 'unresolved' ? " <span class='label label-light label-badge'>{$pager->recTotal}</span>$buildName" : ''), '', "id='unresolvedTab' class='btn btn-link" . ('unresolved' == $type ? ' btn-active-text' : '') . "'");
|
||||
?>
|
||||
<a class="btn btn-link querybox-toggle" id="bysearchTab"><i class="icon icon-search muted"></i> <?php echo $lang->bug->search;?></a>
|
||||
</div>
|
||||
@@ -93,7 +94,7 @@
|
||||
<nav class="btn-toolbar pull-right setting"></nav>
|
||||
</div>
|
||||
<?php
|
||||
$vars = "executionID={$execution->id}&productID={$productID}&orderBy=%s&build=$buildID&type=$type¶m=$param&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}";
|
||||
$vars = "executionID={$execution->id}&productID={$productID}&branch={$branchID}&orderBy=%s&build=$buildID&type=$type¶m=$param&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}";
|
||||
|
||||
$useDatatable ? include '../../common/view/datatable.html.php' : include '../../common/view/tablesorter.html.php';
|
||||
|
||||
|
||||
@@ -135,12 +135,12 @@ class gitea extends control
|
||||
{
|
||||
if($confirm != 'yes') return print(js::confirm($this->lang->gitea->confirmDelete, inlink('delete', "id=$giteaID&confirm=yes")));
|
||||
|
||||
$oldGitea = $this->gitea->getByID($giteaID);
|
||||
$this->gitea->delete(TABLE_PIPELINE, $giteaID);
|
||||
|
||||
$actionID = $this->dao->lastInsertID();
|
||||
$gitea = $this->gitea->getByID($giteaID);
|
||||
$changes = common::createChanges($oldGitea, $gitea);
|
||||
$oldGitea = $this->loadModel('pipeline')->getByID($giteaID);
|
||||
$actionID = $this->pipeline->delete($giteaID, 'gitea');
|
||||
|
||||
$gitea = $this->pipeline->getByID($giteaID);
|
||||
$changes = common::createChanges($oldGitea, $gitea);
|
||||
$this->loadModel('action')->logHistory($actionID, $changes);
|
||||
return print(js::reload('parent'));
|
||||
}
|
||||
|
||||
@@ -1753,7 +1753,7 @@ function resetRegionHeight(fold)
|
||||
var regionPadding = $('.kanban').css('padding-bottom');
|
||||
var columnHeight = $('.kanban-header').outerHeight();
|
||||
|
||||
$('.region').css('height', height);
|
||||
$('.region').css('min-height', height);
|
||||
$('.kanban-lane').css('height', height - regionHeaderHeight - parseInt(regionPadding) - columnHeight);
|
||||
}
|
||||
else
|
||||
|
||||
@@ -2740,7 +2740,7 @@ class kanbanModel extends model
|
||||
}
|
||||
elseif($laneType == 'bug')
|
||||
{
|
||||
$bugs = $this->loadModel('bug')->getExecutionBugs($executionID, 0, 0, '', 0, 'id_desc', $otherCardList);
|
||||
$bugs = $this->loadModel('bug')->getExecutionBugs($executionID, 0, 'all', 0, '', 0, 'id_desc', $otherCardList);
|
||||
foreach($bugs as $bugID => $bug)
|
||||
{
|
||||
foreach($this->config->kanban->bugColumnStatusList as $colType => $status)
|
||||
|
||||
@@ -111,7 +111,8 @@ class productModel extends model
|
||||
}
|
||||
$this->session->set('currentProductType', $currentProduct->type);
|
||||
|
||||
$output = '';
|
||||
$executionID = ($isQaModule and $this->app->tab == 'execution') ? $extra : 0;
|
||||
$output = '';
|
||||
if(!empty($products))
|
||||
{
|
||||
$dropMenuLink = helper::createLink($isQaModule ? 'bug' : 'product', 'ajaxGetDropMenu', "objectID=$productID&module=$currentModule&method=$currentMethod&extra=$extra");
|
||||
@@ -126,7 +127,7 @@ class productModel extends model
|
||||
$this->lang->product->branch = sprintf($this->lang->product->branch, $this->lang->product->branchName[$currentProduct->type]);
|
||||
$this->lang->product->menu->settings['subMenu']->branch = str_replace('@branch@', $this->lang->product->branch, $this->lang->product->menu->settings['subMenu']->branch);
|
||||
|
||||
$branches = $this->loadModel('branch')->getPairs($productID, 'all');
|
||||
$branches = $this->loadModel('branch')->getPairs($productID, 'all', $executionID);
|
||||
$branchName = isset($branches[$branch]) ? $branches[$branch] : $branches[0];
|
||||
if(!$isMobile)
|
||||
{
|
||||
@@ -2263,6 +2264,11 @@ class productModel extends model
|
||||
{
|
||||
return helper::createLink('design', 'browse', "productID=%s");
|
||||
}
|
||||
elseif(strpos(',project,execution,', ",$module,") !== false and $method == 'bug')
|
||||
{
|
||||
$params = explode(',', $extra);
|
||||
return helper::createLink($module, $method, "projectID={$params[0]}&productID=%s" . ($branch ? "&branch=%s" : ''));
|
||||
}
|
||||
elseif($module == 'project' and $method == 'testcase')
|
||||
{
|
||||
$params = explode(',', $extra);
|
||||
|
||||
@@ -26,7 +26,7 @@ js::set('browseType', $browseType);
|
||||
<?php echo html::checkbox('involved ', array('1' => $lang->project->mine), '', $this->cookie->involved ? 'checked=checked' : '');?>
|
||||
</div>
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php if(common::hasPriv('project', 'create')) common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i> ' . $lang->project->create, '', 'class="btn btn-primary" data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php if(common::hasPriv('project', 'create')) common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i> ' . $lang->project->create, '', 'class="btn btn-primary" data-toggle="modal"');?>
|
||||
</div>
|
||||
</div>
|
||||
<div id='mainContent' class="main-row fade">
|
||||
@@ -35,7 +35,7 @@ js::set('browseType', $browseType);
|
||||
<div class="table-empty-tip">
|
||||
<p>
|
||||
<span class="text-muted"><?php echo $lang->project->empty;?></span>
|
||||
<?php if($browseType == 'all') common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i> ' . $lang->project->create, '', 'class="btn btn-info btn-wide " data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php if($browseType == 'all') common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i> ' . $lang->project->create, '', 'class="btn btn-info btn-wide " data-toggle="modal"');?>
|
||||
</p>
|
||||
</div>
|
||||
<?php else:?>
|
||||
|
||||
@@ -981,6 +981,7 @@ class project extends control
|
||||
*
|
||||
* @param int $projectID
|
||||
* @param int $productID
|
||||
* @param int $branchID
|
||||
* @param string $orderBy
|
||||
* @param int $build
|
||||
* @param string $type
|
||||
@@ -991,7 +992,7 @@ class project extends control
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function bug($projectID = 0, $productID = 0, $orderBy = 'status,id_desc', $build = 0, $type = 'all', $param = 0, $recTotal = 0, $recPerPage = 20, $pageID = 1)
|
||||
public function bug($projectID = 0, $productID = 0, $branchID = 0, $orderBy = 'status,id_desc', $build = 0, $type = 'all', $param = 0, $recTotal = 0, $recPerPage = 20, $pageID = 1)
|
||||
{
|
||||
/* Load these two models. */
|
||||
$this->loadModel('bug');
|
||||
@@ -1009,11 +1010,10 @@ class project extends control
|
||||
$type = strtolower($type);
|
||||
$queryID = ($type == 'bysearch') ? (int)$param : 0;
|
||||
$products = $this->product->getProducts($projectID);
|
||||
$branchID = isset($products[$productID]) ? current($products[$productID]->branches) : 0;
|
||||
|
||||
$productPairs = array('0' => $this->lang->product->all);
|
||||
foreach($products as $productData) $productPairs[$productData->id] = $productData->name;
|
||||
$this->lang->modulePageNav = $this->product->select($productPairs, $productID, 'project', 'bug', '', $branchID, 0, '', false);
|
||||
$this->lang->modulePageNav = $this->product->select($productPairs, $productID, 'project', 'bug', $projectID, $branchID);
|
||||
|
||||
/* Header and position. */
|
||||
$title = $project->name . $this->lang->colon . $this->lang->bug->common;
|
||||
@@ -1026,7 +1026,7 @@ class project extends control
|
||||
$this->app->loadClass('pager', $static = true);
|
||||
$pager = new pager($recTotal, $recPerPage, $pageID);
|
||||
$sort = common::appendOrder($orderBy);
|
||||
$bugs = $this->bug->getProjectBugs($projectID, $productID, $build, $type, $param, $sort, '', $pager);
|
||||
$bugs = $this->bug->getProjectBugs($projectID, $productID, $branchID, $build, $type, $param, $sort, '', $pager);
|
||||
|
||||
/* team member pairs. */
|
||||
$memberPairs = array();
|
||||
@@ -1047,7 +1047,7 @@ class project extends control
|
||||
$showBranch = $this->loadModel('branch')->showBranch($productID);
|
||||
|
||||
/* Display status of branch. */
|
||||
$branches = $this->loadModel('branch')->getList($productID, 0, 'all');
|
||||
$branches = $this->loadModel('branch')->getList($productID, $projectID, 'all');
|
||||
foreach($branches as $branchInfo)
|
||||
{
|
||||
$branchOption[$branchInfo->id] = $branchInfo->name;
|
||||
@@ -1055,8 +1055,6 @@ class project extends control
|
||||
}
|
||||
}
|
||||
|
||||
$showModule = !empty($this->config->datatable->bugBrowse->showModule) ? $this->config->datatable->bugBrowse->showModule : '';
|
||||
|
||||
$storyIdList = $taskIdList = array();
|
||||
foreach($bugs as $bug)
|
||||
{
|
||||
@@ -1071,7 +1069,7 @@ class project extends control
|
||||
$modules = $this->tree->getAllModulePairs('bug');
|
||||
|
||||
/* Get module tree.*/
|
||||
$extra = array('projectID' => $projectID, 'orderBy' => $orderBy, 'type' => $type, 'build' => $build);
|
||||
$extra = array('projectID' => $projectID, 'orderBy' => $orderBy, 'type' => $type, 'build' => $build, 'branchID' => $branchID);
|
||||
if($projectID and empty($productID) and count($products) > 1)
|
||||
{
|
||||
$moduleTree = $this->tree->getBugTreeMenu($projectID, $productID, 0, array('treeModel', 'createBugLink'), $extra);
|
||||
@@ -1079,7 +1077,7 @@ class project extends control
|
||||
elseif(!empty($products))
|
||||
{
|
||||
$productID = empty($productID) ? reset($products)->id : $productID;
|
||||
$moduleTree = $this->tree->getTreeMenu($productID, 'bug', 0, array('treeModel', 'createBugLink'), $extra + array('productID' => $productID), 'all');
|
||||
$moduleTree = $this->tree->getTreeMenu($productID, 'bug', 0, array('treeModel', 'createBugLink'), $extra + array('productID' => $productID, 'branchID' => $branchID), $branchID);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
<style>
|
||||
#subHeader #dropMenu .col-left .list-group {margin-bottom: 0px; padding-top: 10px;}
|
||||
#subHeader #dropMenu .col-left {padding-bottom: 0px;}
|
||||
#currentBranch + #dropMenu .col-left {padding-bottom: 30px;}
|
||||
</style>
|
||||
<div id="mainMenu" class="clearfix main-row fade in">
|
||||
<div id="sidebarHeader">
|
||||
@@ -23,7 +24,7 @@
|
||||
echo $moduleName;
|
||||
if(!empty($moduleID))
|
||||
{
|
||||
$removeLink = $this->createLink('project', 'bug', "project={$project->id}&productID={$productID}&orderBy=$orderBy&build=$buildID&type=$type¶m=0&recTotal=$pager->recTotal&recPerPage=$pager->recPerPage");
|
||||
$removeLink = $this->createLink('project', 'bug', "project={$project->id}&productID={$productID}&branch=$branchID&orderBy=$orderBy&build=$buildID&type=$type¶m=0&recTotal=$pager->recTotal&recPerPage=$pager->recPerPage");
|
||||
echo html::a($removeLink, "<i class='icon icon-sm icon-close'></i>", '', "class='text-muted' data-app='{$this->app->tab}'");
|
||||
}
|
||||
?>
|
||||
@@ -32,8 +33,8 @@
|
||||
<div class="btn-toolbar pull-left">
|
||||
<?php
|
||||
$buildName = $build ? " <span class='label label-danger'>Build:{$build->name}</span>" : '';
|
||||
echo html::a($this->inlink('bug', "projectID={$project->id}&productID={$productID}&orderBy=status,id_desc&build=$buildID&type=all"), "<span class='text'>{$lang->bug->allBugs}</span>" . ($type == 'all' ? " <span class='label label-light label-badge'>{$pager->recTotal}</span>$buildName" : ''), '', "id='allTab' class='btn btn-link" . ('all' == $type ? ' btn-active-text' : '') . "'");
|
||||
echo html::a($this->inlink('bug', "projectID={$project->id}&productID={$productID}&orderBy=status,id_desc&build=$buildID&type=unresolved"), "<span class='text'>{$lang->bug->unResolved}</span>" . ($type == 'unresolved' ? " <span class='label label-light label-badge'>{$pager->recTotal}</span>$buildName" : ''), '', "id='unresolvedTab' class='btn btn-link" . ('unresolved' == $type ? ' btn-active-text' : '') . "'");
|
||||
echo html::a($this->inlink('bug', "projectID={$project->id}&productID={$productID}&branch=$branchID&orderBy=status,id_desc&build=$buildID&type=all"), "<span class='text'>{$lang->bug->allBugs}</span>" . ($type == 'all' ? " <span class='label label-light label-badge'>{$pager->recTotal}</span>$buildName" : ''), '', "id='allTab' class='btn btn-link" . ('all' == $type ? ' btn-active-text' : '') . "'");
|
||||
echo html::a($this->inlink('bug', "projectID={$project->id}&productID={$productID}&branch=$branchID&orderBy=status,id_desc&build=$buildID&type=unresolved"), "<span class='text'>{$lang->bug->unResolved}</span>" . ($type == 'unresolved' ? " <span class='label label-light label-badge'>{$pager->recTotal}</span>$buildName" : ''), '', "id='unresolvedTab' class='btn btn-link" . ('unresolved' == $type ? ' btn-active-text' : '') . "'");
|
||||
?>
|
||||
<a class="btn btn-link querybox-toggle" id="bysearchTab"><i class="icon icon-search muted"></i> <?php echo $lang->bug->search;?></a>
|
||||
</div>
|
||||
@@ -77,7 +78,7 @@
|
||||
<nav class="btn-toolbar pull-right setting"></nav>
|
||||
</div>
|
||||
<?php
|
||||
$vars = "projectID={$project->id}&productID=$productID&orderBy=%s&build=$buildID&type=$type¶m=$param&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}";
|
||||
$vars = "projectID={$project->id}&productID=$productID&branch=$branchID&orderBy=%s&build=$buildID&type=$type¶m=$param&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}";
|
||||
if($useDatatable) include '../../common/view/datatable.html.php';
|
||||
else include '../../common/view/tablesorter.html.php';
|
||||
|
||||
|
||||
@@ -1332,7 +1332,7 @@ class repo extends control
|
||||
$zip = new pclzip($fileName);
|
||||
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';
|
||||
$url = $this->config->webRoot . $this->app->getAppName() . 'data' . DS . 'repo' . DS . $repo->name . '.zip';
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -1350,7 +1350,7 @@ class repo extends control
|
||||
$zip = new pclzip($fileName);
|
||||
if($zip->create($repoDir, PCLZIP_OPT_REMOVE_PATH, $repoDir) === 0) return print(js::alert($zip->errorInfo()) . js::close());
|
||||
|
||||
$url = DS . 'data' . DS . 'repo' . DS . $repo->name . '.zip';
|
||||
$url = $this->config->webRoot . $this->app->getAppName() . 'data' . DS . 'repo' . DS . $repo->name . '.zip';
|
||||
}
|
||||
|
||||
$this->locate($url);
|
||||
|
||||
@@ -1873,14 +1873,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';
|
||||
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
|
||||
$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)"));
|
||||
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
|
||||
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
|
||||
{
|
||||
|
||||
@@ -113,7 +113,7 @@
|
||||
<td class='<?php echo zget($visibleFields, 'estimate', 'hidden')?> estimateBox'><?php echo html::input('estimate[$id]', $estimate, "class='form-control'");?></td>
|
||||
<td class='<?php echo zget($visibleFields, 'review', 'hidden')?> reviewBox'>
|
||||
<div class='input-group'>
|
||||
<?php echo html::select('reviewer[$id][]', $reviewers, '', "class='form-control picker-select' multiple");?>
|
||||
<?php echo html::select('reviewer[$id][]', $reviewers, '', "class='form-control chosen' multiple");?>
|
||||
<span class='input-group-addon reviewerDitto'><input type='checkbox' name='reviewDitto[$id]' value='ditto' checked='checked' id='dittocheck$id'/> <?php echo $lang->story->ditto;?></span>
|
||||
</div>
|
||||
</td>
|
||||
@@ -177,7 +177,7 @@
|
||||
<td class='<?php echo zget($visibleFields, 'estimate', 'hidden')?> estimateBox'><?php echo html::input("estimate[$i]", $estimate, "class='form-control'");?></td>
|
||||
<td class='<?php echo zget($visibleFields, 'review', 'hidden')?> reviewBox'>
|
||||
<div class='input-group'>
|
||||
<?php echo html::select("reviewer[$i][]", $reviewers, '', "class='form-control picker-select' multiple");?>
|
||||
<?php echo html::select("reviewer[$i][]", $reviewers, '', "class='form-control chosen' multiple");?>
|
||||
<span class='input-group-addon reviewerDitto'><input type='checkbox' name="reviewDitto[<?php echo $i?>]" value='ditto' checked='checked' id="dittocheck<?php echo $i?>"/> <?php echo $lang->story->ditto;?></span>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
@@ -858,7 +858,7 @@ class task extends control
|
||||
}
|
||||
if(!dao::isError()) $this->loadModel('score')->create('ajax', 'batchOther');
|
||||
}
|
||||
echo js::reload('parent');
|
||||
return print(js::reload('parent'));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1612,7 +1612,7 @@ class task extends control
|
||||
}
|
||||
}
|
||||
|
||||
echo js::reload('parent');
|
||||
return print(js::reload('parent'));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1676,7 +1676,7 @@ class task extends control
|
||||
if(!dao::isError()) $this->loadModel('score')->create('ajax', 'batchOther');
|
||||
}
|
||||
|
||||
echo js::reload('parent');
|
||||
return print(js::reload('parent'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -126,11 +126,11 @@ js::set('suiteID', $suiteID);
|
||||
<div class='btn-group dropup'>
|
||||
<?php
|
||||
$actionLink = $this->createLink('testtask', 'batchRun', "productID=$productID&orderBy=$orderBy");
|
||||
$misc = $canBatchRun ? "onclick=\"setFormAction('$actionLink')\"" : "disabled='disabled'";
|
||||
$misc = $canBatchRun ? "onclick=\"setFormAction('$actionLink', '', '#caseList')\"" : "disabled='disabled'";
|
||||
echo html::commonButton($lang->testtask->runCase, $misc);
|
||||
|
||||
$actionLink = $this->createLink('testcase', 'batchEdit', "productID=$productID&branch=$branch");
|
||||
$misc = $canBatchEdit ? "onclick=\"setFormAction('$actionLink')\"" : "disabled='disabled'";
|
||||
$misc = $canBatchEdit ? "onclick=\"setFormAction('$actionLink', '', '#caseList')\"" : "disabled='disabled'";
|
||||
echo html::commonButton($lang->edit, $misc);
|
||||
?>
|
||||
<button type='button' class='btn dropdown-toggle' data-toggle='dropdown'><span class='caret'></span></button>
|
||||
@@ -145,7 +145,7 @@ js::set('suiteID', $suiteID);
|
||||
foreach($lang->testcase->reviewResultList as $key => $result)
|
||||
{
|
||||
$actionLink = $this->createLink('testcase', 'batchReview', "result=$key");
|
||||
echo '<li>' . html::a('#', $result, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin')\"") . '</li>';
|
||||
echo '<li>' . html::a('#', $result, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin', '#caseList')\"") . '</li>';
|
||||
}
|
||||
echo '</ul></li>';
|
||||
}
|
||||
@@ -166,7 +166,7 @@ js::set('suiteID', $suiteID);
|
||||
foreach($lang->testcase->typeList as $key => $result)
|
||||
{
|
||||
$actionLink = $this->createLink('testcase', 'batchCaseTypeChange', "result=$key");
|
||||
echo '<li>' . html::a('#', $result, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin')\"") . '</li>';
|
||||
echo '<li>' . html::a('#', $result, '', "onclick=\"setFormAction('$actionLink', 'hiddenwin', '#caseList')\"") . '</li>';
|
||||
}
|
||||
echo '</ul></li>';
|
||||
}
|
||||
@@ -174,7 +174,7 @@ js::set('suiteID', $suiteID);
|
||||
if($canBatchConfirmStoryChange)
|
||||
{
|
||||
$actionLink = $this->createLink('testcase', 'batchConfirmStoryChange', "productID=$productID");
|
||||
$misc = "onclick=\"setFormAction('$actionLink')\"";
|
||||
$misc = "onclick=\"setFormAction('$actionLink', '', '#caseList')\"";
|
||||
echo "<li>" . html::a('#', $lang->testcase->confirmStoryChange, '', $misc) . "</li>";
|
||||
}
|
||||
?>
|
||||
@@ -201,7 +201,7 @@ js::set('suiteID', $suiteID);
|
||||
{
|
||||
$searchKey = $withSearch ? ('data-key="' . zget($branchsPinYin, $branchName, '') . '"') : '';
|
||||
$actionLink = $this->createLink('testcase', 'batchChangeBranch', "branchID=$branchID");
|
||||
echo html::a('#', $branchName, '', "$searchKey onclick=\"setFormAction('$actionLink', 'hiddenwin')\"");
|
||||
echo html::a('#', $branchName, '', "$searchKey onclick=\"setFormAction('$actionLink', 'hiddenwin', '#caseList')\"");
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
@@ -230,7 +230,7 @@ js::set('suiteID', $suiteID);
|
||||
{
|
||||
$searchKey = $withSearch ? ('data-key="' . zget($modulesPinYin, $module, '') . '"') : '';
|
||||
$actionLink = $this->createLink('testcase', 'batchChangeModule', "moduleID=$moduleId");
|
||||
echo html::a('#', $module, '', "title='$module' $searchKey onclick=\"setFormAction('$actionLink', 'hiddenwin')\"");
|
||||
echo html::a('#', $module, '', "title='$module' $searchKey onclick=\"setFormAction('$actionLink', 'hiddenwin', '#caseList')\"");
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
@@ -75,7 +75,7 @@ $lang->testreport->buildSummary = 'Tested <strong>%s</strong> builds.';
|
||||
$lang->testreport->confirmDelete = 'Do you want to delete this report?';
|
||||
$lang->testreport->moreNotice = 'More features can be extended with reference to the ZenTao extension manual, or you can contact us at renee@easysoft.ltd for customization.';
|
||||
$lang->testreport->exportNotice = "Exported By <a href='https://www.zentao.net' target='_blank' style='color:grey'>ZenTao</a>";
|
||||
$lang->testreport->noReport = "No report has been generated. Please check it later.";
|
||||
$lang->testreport->noReport = "No report has been generated.Please select one request to generate one test report.";
|
||||
$lang->testreport->foundBugTip = "Bugs found in this build period and the affected build is in this test period.";
|
||||
$lang->testreport->legacyBugTip = "Active bugs, or bugs that are not resolved in the test period.";
|
||||
$lang->testreport->activatedBugTip = "Reactived bugs during the testtask.";
|
||||
|
||||
+13
-10
@@ -425,12 +425,12 @@ class treeModel extends model
|
||||
elseif(strpos(',case,bug,', ",$type,") !== false and $this->app->tab == 'execution')
|
||||
{
|
||||
if($product->type != 'normal' and $executionID) $branches += $this->branch->getPairs($product->id, 'noempty', $executionID);
|
||||
if($onlyGetLinked) $executionModules = $this->getTaskTreeModules($executionID, true, $type);
|
||||
if($onlyGetLinked) $executionModules = $this->getTaskTreeModules($executionID, true, $type, $type == 'bug' ? array('branchID' => $branch) : array());
|
||||
}
|
||||
elseif(($type == 'story' and $this->app->rawModule == 'projectstory') or (strpos(',case,bug,', ",$type,") !== false and $this->app->tab == 'project'))
|
||||
{
|
||||
if($product->type != 'normal' and $projectID) $branches += $this->branch->getPairs($product->id, 'noempty', $projectID);
|
||||
if($onlyGetLinked) $executionModules = $this->getTaskTreeModules($projectID, true, $type);
|
||||
if($onlyGetLinked) $executionModules = $this->getTaskTreeModules($projectID, true, $type, $type == 'bug' ? array('branchID' => $branch) : array());
|
||||
}
|
||||
|
||||
/* Add for task #1945. check the module has case or no. */
|
||||
@@ -447,7 +447,7 @@ class treeModel extends model
|
||||
}
|
||||
elseif(isset($executionModules[$module->id]))
|
||||
{
|
||||
$this->buildTree($treeMenu, $module, $type, $userFunc, $extra);
|
||||
$this->buildTree($treeMenu, $module, $type, $userFunc, $extra, $branch);
|
||||
}
|
||||
}
|
||||
ksort($treeMenu);
|
||||
@@ -689,16 +689,17 @@ class treeModel extends model
|
||||
if(empty($branchGroups[$id])) $branchGroups[$id]['0'] = '';
|
||||
foreach($branchGroups[$id] as $branch => $branchName)
|
||||
{
|
||||
$treeMenu = array();
|
||||
$query = $this->dao->select('*')->from(TABLE_MODULE)->where("((root = $id and type = 'bug') OR (root = $id and type = 'story' and branch ='$branch'))")
|
||||
$query = $this->dao->select('*')->from(TABLE_MODULE)->where("((root = $id and type = 'bug' and branch='$branch') OR (root = $id and type = 'story' and branch ='$branch'))")
|
||||
->beginIF($startModulePath)->andWhere('path')->like($startModulePath)->fi()
|
||||
->andWhere('deleted')->eq(0)
|
||||
->orderBy('grade desc, `order`, type')
|
||||
->get();
|
||||
$stmt = $this->dbh->query($query);
|
||||
$treeMenu = array();
|
||||
$stmt = $this->dbh->query($query);
|
||||
$extra['branchID'] = $branch;
|
||||
while($module = $stmt->fetch())
|
||||
{
|
||||
if(isset($executionModules[$module->id])) $this->buildTree($treeMenu, $module, 'bug', $userFunc, $extra);
|
||||
if(isset($executionModules[$module->id])) $this->buildTree($treeMenu, $module, 'bug', $userFunc, $extra, $branch);
|
||||
}
|
||||
$tree .= isset($treeMenu[0]) ? $treeMenu[0] : '';
|
||||
}
|
||||
@@ -950,10 +951,11 @@ class treeModel extends model
|
||||
* @param int $executionID
|
||||
* @param bool $parent
|
||||
* @param string $linkObject
|
||||
* @param array $extra
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getTaskTreeModules($executionID, $parent = false, $linkObject = 'story')
|
||||
public function getTaskTreeModules($executionID, $parent = false, $linkObject = 'story', $extra = array())
|
||||
{
|
||||
$executionModules = array();
|
||||
$field = $parent ? 'path' : 'id';
|
||||
@@ -987,6 +989,7 @@ class treeModel extends model
|
||||
->leftJoin(TABLE_MODULE)->alias('t2')->on('t1.module = t2.id')
|
||||
->where('t1.deleted')->eq(0)
|
||||
->andWhere('t2.deleted')->eq(0)
|
||||
->andWhere('t1.branch')->eq(zget($extra, 'branchID', 0))
|
||||
->andWhere("t1.{$this->app->tab}")->eq($executionID)
|
||||
->fetchPairs();
|
||||
}
|
||||
@@ -1215,8 +1218,8 @@ class treeModel extends model
|
||||
$moduleName = strpos(',project,execution,', ",{$this->app->tab},") !== false ? $this->app->tab : 'bug';
|
||||
$methodName = strpos(',project,execution,', ",{$this->app->tab},") !== false ? 'bug' : 'browse';
|
||||
$param = "root={$module->root}&branch=&type=byModule¶m={$module->id}";
|
||||
if($this->app->tab == 'execution') $param = "execuitonID={$extra['executionID']}&productID={$module->root}&orderBy={$extra['orderBy']}&build={$extra['build']}&type={$extra['type']}¶m={$module->id}";
|
||||
if($this->app->tab == 'project') $param = "projectID={$extra['projectID']}&productID={$module->root}&orderBy={$extra['orderBy']}&build={$extra['build']}&type={$extra['type']}¶m={$module->id}";
|
||||
if($this->app->tab == 'execution') $param = "execuitonID={$extra['executionID']}&productID={$module->root}&branch={$extra['branchID']}&orderBy={$extra['orderBy']}&build={$extra['build']}&type={$extra['type']}¶m={$module->id}";
|
||||
if($this->app->tab == 'project') $param = "projectID={$extra['projectID']}&productID={$module->root}&branch={$extra['branchID']}&orderBy={$extra['orderBy']}&build={$extra['build']}&type={$extra['type']}¶m={$module->id}";
|
||||
return html::a(helper::createLink($moduleName, $methodName, $param), $module->name, '_self', "id='module{$module->id}' title='{$module->name}'");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user