Merge branch 'sprint/tianshujie_fixbug' into 'master'
Sprint/tianshujie fixbug See merge request easycorp/zentaopms!2588
This commit is contained in:
@@ -240,14 +240,14 @@ class build extends control
|
||||
|
||||
/* Get stories and stages. */
|
||||
$storyPager = new pager($type == 'story' ? $recTotal : 0, $recPerPage, $type == 'story' ? $pageID : 1);
|
||||
$stories = $this->dao->select('*')->from(TABLE_STORY)->where('id')->in($build->stories)->andWhere('deleted')->eq(0)
|
||||
->beginIF($type == 'story')->orderBy($orderBy)->fi()
|
||||
$stories = $this->dao->select('t1.*, t2.stage')->from(TABLE_STORY)->alias('t1')
|
||||
->leftJoin(TABLE_STORYSTAGE)->alias('t2')->on('t1.id = t2.story')
|
||||
->where('t1.id')->in($build->stories)
|
||||
->andWhere('t1.deleted')->eq(0)
|
||||
->beginIF($type == 'story')->orderBy("t1.$orderBy")->fi()
|
||||
->page($storyPager)
|
||||
->fetchAll('id');
|
||||
|
||||
$stages = $this->dao->select('*')->from(TABLE_STORYSTAGE)->where('story')->in($build->stories)->andWhere('branch')->eq($build->branch)->fetchPairs('story', 'stage');
|
||||
foreach($stages as $storyID => $stage) $stories[$storyID]->stage = $stage;
|
||||
|
||||
/* Set menu. */
|
||||
if($this->app->tab == 'project')
|
||||
{
|
||||
|
||||
@@ -3285,9 +3285,11 @@ class execution extends control
|
||||
{
|
||||
$projects = $this->project->getPairsByProgram();
|
||||
$projectID = $this->project->saveState($projectID, $projects);
|
||||
$project = $this->loadModel('project')->getByID($projectID);
|
||||
$project = $this->loadModel('project')->getByID($projectID);
|
||||
$this->view->project = $project;
|
||||
$this->project->setMenu($projectID);
|
||||
|
||||
if(!empty($project->model) and $project->model == 'kanban') return $this->locate($this->createLink('project', 'index', "projectID=$projectID"));
|
||||
}
|
||||
|
||||
if($this->app->viewType == 'mhtml')
|
||||
|
||||
@@ -482,6 +482,12 @@ class project extends control
|
||||
|
||||
$topProgramID = $this->program->getTopByID($programID);
|
||||
|
||||
if($model == 'kanban')
|
||||
{
|
||||
$this->lang->project->aclList = $this->lang->project->kanbanAclList;
|
||||
$this->lang->project->subAclList = $this->lang->project->kanbanSubAclList;
|
||||
}
|
||||
|
||||
$this->view->title = $this->lang->project->create;
|
||||
$this->view->position[] = $this->lang->project->create;
|
||||
|
||||
@@ -534,7 +540,12 @@ class project extends control
|
||||
$project = $this->project->getByID($projectID);
|
||||
$programID = $project->parent;
|
||||
$this->project->setMenu($projectID);
|
||||
if($project->model == 'kanban') unset($this->lang->project->authList['reset']);
|
||||
if($project->model == 'kanban')
|
||||
{
|
||||
unset($this->lang->project->authList['reset']);
|
||||
$this->lang->project->aclList = $this->lang->project->kanbanAclList;
|
||||
$this->lang->project->subAclList = $this->lang->project->kanbanSubAclList;
|
||||
}
|
||||
|
||||
if($_POST)
|
||||
{
|
||||
|
||||
@@ -7,3 +7,4 @@
|
||||
#productsBox .product.has-branch > .chosen-container {position: absolute; width: 40% !important; right: 3px; top: 3px;}
|
||||
#productsBox .product.has-branch > .chosen-container > .chosen-single {background: rgba(0,0,0,.05);}
|
||||
#productsBox .product.has-branch > .chosen-container > .chosen-single:hover {background: #fff;}
|
||||
#productsBox .chosen-container .chosen-results{max-height: 180px;}
|
||||
|
||||
@@ -243,6 +243,13 @@ $lang->project->subAclList['private'] = "Private (Only the project leader, team
|
||||
$lang->project->subAclList['open'] = "Open (accessible with project view permissions)";
|
||||
$lang->project->subAclList['program'] = 'Open in the program (all upper-level program team leaders and stakeholders, the project leader, team members and stakeholders can access)';
|
||||
|
||||
$lang->project->kanbanAclList['private'] = 'Private (For the project leader, team members only)';
|
||||
$lang->project->kanbanAclList['open'] = "Open (accessible with project view permissions)";
|
||||
|
||||
$lang->project->kanbanSubAclList['private'] = "Private (Only the project leader, team members can access)";
|
||||
$lang->project->kanbanSubAclList['open'] = "Open (accessible with project view permissions)";
|
||||
$lang->project->kanbanSubAclList['program'] = 'Open in the program (all upper-level program team leaders and stakeholders, the project leader, team members can access)';
|
||||
|
||||
$lang->project->authList['extend'] = 'Inherit (system privilege and project privilege)';
|
||||
$lang->project->authList['reset'] = 'Reset (project privilege only)';
|
||||
|
||||
|
||||
@@ -243,6 +243,13 @@ $lang->project->subAclList['private'] = "私有 (只有项目负责人、团队
|
||||
$lang->project->subAclList['open'] = "公开 (有项目视图权限即可访问)";
|
||||
$lang->project->subAclList['program'] = '项目集内公开(所有上级项目集负责人和干系人、项目负责人、团队成员和干系人可访问)';
|
||||
|
||||
$lang->project->kanbanAclList['private'] = "私有 (只有项目负责人、团队成员可访问)";
|
||||
$lang->project->kanbanAclList['open'] = "公开 (有项目视图权限即可访问)";
|
||||
|
||||
$lang->project->kanbanSubAclList['private'] = "私有 (只有项目负责人、团队成员可访问)";
|
||||
$lang->project->kanbanSubAclList['open'] = "公开 (有项目视图权限即可访问)";
|
||||
$lang->project->kanbanSubAclList['program'] = '项目集内公开(所有上级项目集负责人和干系人、项目负责人、团队成员可访问)';
|
||||
|
||||
$lang->project->authList['extend'] = '继承 (取系统权限与项目权限的合集)';
|
||||
$lang->project->authList['reset'] = '重新定义 (只取项目权限)';
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
<?php echo "<input type='checkbox' name='products[$i]' value='$productID' $checked id='products{$productID}' $isDisabled>";?>
|
||||
<label class='text-ellipsis checkbox-inline' for='<?php echo 'products' . $productID;?>' title='<?php echo $productName;?>'><?php echo $productName;?></label>
|
||||
</div>
|
||||
<?php if(isset($allBranches[$productID][$branchID])) echo html::select("branch[$i]", $allBranches[$productID], $branchID, "class='form-control chosen' disabled='disabled'");?>
|
||||
<?php if(isset($allBranches[$productID][$branchID])) echo html::select("branch[$i]", $allBranches[$productID], $branchID, "class='form-control chosen' data-drop_direction='down' disabled='disabled'");?>
|
||||
</div>
|
||||
</div>
|
||||
<?php if(!empty($isDisabled)) echo html::hidden("products[$i]", $productID);?>
|
||||
@@ -61,7 +61,7 @@
|
||||
<?php echo "<input type='checkbox' name='products[$i]' value='$productID' id='products{$productID}'>";?>
|
||||
<label class='text-ellipsis checkbox-inline' for='<?php echo 'products' . $productID;?>'><?php echo $productName;?></label>
|
||||
</div>
|
||||
<?php if(isset($branchGroups[$productID])) echo html::select("branch[$i]", $branchGroups[$productID], '', "class='form-control chosen'");?>
|
||||
<?php if(isset($branchGroups[$productID])) echo html::select("branch[$i]", $branchGroups[$productID], '', "class='form-control chosen' data-drop_direction='down'");?>
|
||||
</div>
|
||||
</div>
|
||||
<?php $i++;?>
|
||||
|
||||
@@ -225,14 +225,15 @@ class projectrelease extends control
|
||||
}
|
||||
|
||||
$storyPager = new pager($type == 'story' ? $recTotal : 0, $recPerPage, $type == 'story' ? $pageID : 1);
|
||||
$stories = $this->dao->select('*')->from(TABLE_STORY)->where('id')->in($release->stories)->andWhere('deleted')->eq(0)
|
||||
->beginIF($type == 'story')->orderBy($orderBy)->fi()
|
||||
->page($storyPager)
|
||||
->fetchAll('id');
|
||||
$stories = $this->dao->select('t1.*, t2.stage')->from(TABLE_STORY)->alias('t1')
|
||||
->leftJoin(TABLE_STORYSTAGE)->alias('t2')->on('t1.id = t2.story')
|
||||
->where('t1.id')->in($release->stories)
|
||||
->andWhere('t1.deleted')->eq(0)
|
||||
->beginIF($type == 'story')->orderBy("t1.$orderBy")->fi()
|
||||
->page($storyPager)
|
||||
->fetchAll('id');
|
||||
|
||||
$this->loadModel('common')->saveQueryCondition($this->dao->get(), 'story');
|
||||
$stages = $this->dao->select('*')->from(TABLE_STORYSTAGE)->where('story')->in($release->stories)->andWhere('branch')->eq($release->branch)->fetchPairs('story', 'stage');
|
||||
foreach($stages as $storyID => $stage)$stories[$storyID]->stage = $stage;
|
||||
|
||||
$bugPager = new pager($type == 'bug' ? $recTotal : 0, $recPerPage, $type == 'bug' ? $pageID : 1);
|
||||
$bugs = $this->dao->select('*')->from(TABLE_BUG)->where('id')->in($release->bugs)->andWhere('deleted')->eq(0)
|
||||
|
||||
@@ -1374,7 +1374,8 @@ class story extends control
|
||||
$execution = $this->execution->getByID($this->session->execution);
|
||||
if($this->app->tab == 'execution' and $execution->type == 'kanban' and $this->app->tab == 'execution')
|
||||
{
|
||||
$kanbanData = $this->loadModel('kanban')->getRDKanban($this->session->execution, $this->session->execLaneType ? $this->session->execLaneType : 'all');
|
||||
$this->loadModel('kanban')->updateLane($this->session->execution, 'story', $storyID);
|
||||
$kanbanData = $this->kanban->getRDKanban($this->session->execution, $this->session->execLaneType ? $this->session->execLaneType : 'all');
|
||||
$kanbanData = json_encode($kanbanData);
|
||||
|
||||
return print(js::closeModal('parent.parent', '', "parent.parent.updateKanban($kanbanData)"));
|
||||
|
||||
Reference in New Issue
Block a user