Merge branch 'sprint/175_liyuchun_45152' into 'sprint/168'

* Finish task #45152.

See merge request easycorp/zentaopms!627
This commit is contained in:
孙广明
2021-11-29 00:58:04 +00:00
4 changed files with 20 additions and 4 deletions
+2 -2
View File
@@ -280,5 +280,5 @@ $config->newFeatures = array('introduction', 'tutorial', 'youngBlueTheme');
/* Program privs.*/
$config->programPriv = new stdclass();
$config->programPriv->scrum = array('product', 'story', 'productplan', 'release', 'projectrelease', 'project', 'task', 'build', 'qa', 'bug', 'testcase', 'testsuite', 'testreport', 'caselib', 'doc', 'report', 'repo', 'svn', 'git', 'search', 'tree', 'file', 'jenkins', 'gitlab', 'job', 'ci', 'branch');
$config->programPriv->waterfall = $config->programPriv->scrum + array('workestimation', 'durationestimation', 'budget', 'programplan', 'review', 'reviewissue', 'weekly', 'milestone', 'design', 'issue', 'risk', 'auditplan', 'nc', 'cm', 'pssp');
$config->programPriv->scrum = array('projectstory', 'projectrelease', 'project', 'build', 'bug', 'testcase', 'testreport', 'caselib', 'doc', 'repo', 'meeting');
$config->programPriv->waterfall = array_merge($config->programPriv->scrum, array('workestimation', 'durationestimation', 'budget', 'programplan', 'review', 'reviewissue', 'weekly', 'milestone', 'design', 'issue', 'risk', 'opportunity', 'measrecord', 'auditplan', 'trainplan', 'gapanalysis', 'pssp'));
+3
View File
@@ -110,3 +110,6 @@ $config->project->datatable->fieldList['actions']['fixed'] = 'right';
$config->project->datatable->fieldList['actions']['width'] = '180';
$config->project->datatable->fieldList['actions']['required'] = 'yes';
$config->project->datatable->fieldList['actions']['pri'] = '1';
$config->project->removePriv['project'] = array('browse', 'kanban', 'create', 'batchEdit', 'qa', 'updateOrder', 'createGuide', 'programTitle');
$config->project->removePriv['doc'] = array('catalog', 'index');
+14 -2
View File
@@ -1136,9 +1136,21 @@ class project extends control
/* Unset not project privs. */
$project = $this->project->getByID($group->project);
foreach($this->lang->resource as $method => $label)
foreach($this->lang->resource as $module => $methods)
{
if(!in_array($method, $this->config->programPriv->{$project->model})) unset($this->lang->resource->$method);
if(!in_array($module, $this->config->programPriv->{$project->model}))
{
unset($this->lang->resource->$module);
}
else
{
if($project->model == 'scrum' and $module == 'projectstory') $this->config->project->removePriv[$module][] = 'track';
foreach($methods as $method => $label)
{
if(isset($this->config->project->removePriv[$module]) and in_array($method, $this->config->project->removePriv[$module])) unset($this->lang->resource->$module->$method);
}
}
}
}
+1
View File
@@ -21,6 +21,7 @@
#mainMenu #groupName{line-height:33px; float: left}
.checkbox-right{padding-left:0px !important;}
.thWidth {width: 160px;}
td.menus {border-right: 0;padding-right: 0;width: 220px !important;}
td.menus + td {border-left: 0;}
.menus .checkbox-primary {float: left; width: 220px;}