Merge branch '15.0.beta3' of https://gitlab.zcorp.cc/easycorp/zentaopms into 15.0.beta3

This commit is contained in:
hufangzhou
2021-03-31 11:35:18 +08:00
25 changed files with 113 additions and 63 deletions
+9 -5
View File
@@ -9,6 +9,7 @@
* @version $Id$
* @link http://www.zentao.net
*/
global $config;
$lang->block = new stdclass();
$lang->block->common = '区块';
$lang->block->name = '区块名称';
@@ -307,10 +308,13 @@ $lang->block->default['full']['my']['7']['params']['riskNum'] = '20';
$lang->block->default['full']['my']['7']['params']['issueNum'] = '20';
$lang->block->default['full']['my']['7']['params']['storyNum'] = '20';
$lang->block->default['full']['my']['8']['title'] = '项目人力投入';
$lang->block->default['full']['my']['8']['block'] = 'projectteam';
$lang->block->default['full']['my']['8']['source'] = 'project';
$lang->block->default['full']['my']['8']['grid'] = 8;
if($config->systemMode == 'new')
{
$lang->block->default['full']['my']['8']['title'] = '项目人力投入';
$lang->block->default['full']['my']['8']['block'] = 'projectteam';
$lang->block->default['full']['my']['8']['source'] = 'project';
$lang->block->default['full']['my']['8']['grid'] = 8;
}
$lang->block->default['full']['my']['9']['title'] = '项目列表';
$lang->block->default['full']['my']['9']['block'] = 'project';
@@ -351,7 +355,7 @@ $lang->block->modules['project']->availableBlocks = new stdclass();
$lang->block->modules['project']->availableBlocks->project = '项目列表';
$lang->block->modules['project']->availableBlocks->recentproject = '近期项目';
$lang->block->modules['project']->availableBlocks->statistic = '项目统计';
$lang->block->modules['project']->availableBlocks->projectteam = '项目人力投入';
if($config->systemMode == 'new') $lang->block->modules['project']->availableBlocks->projectteam = '项目人力投入';
$lang->block->modules['scrum']['index'] = new stdclass();
$lang->block->modules['scrum']['index']->availableBlocks = new stdclass();
@@ -41,11 +41,13 @@
<div class='panel-content'>
<div class='panel-heading not-move-handler'>
<strong class='project-name' title='<?php echo $project->name;?>'> <?php echo html::a($viewLink, $project->name);?> </strong>
<?php if($config->systemMode == 'new'):?>
<?php if($project->model === 'waterfall'): ?>
<span class='project-type-label label label-warning label-outline'><?php echo $lang->project->waterfall; ?></span>
<?php else: ?>
<span class='project-type-label label label-info label-outline'><?php echo $lang->project->scrum; ?></span>
<?php endif; ?>
<?php endif; ?>
<nav class='panel-actions nav nav-default'>
<li class='dropdown'>
<a href='javascript:;' data-toggle='context-dropdown' class='panel-action'><i class='icon icon-ellipsis-v'></i></a>
@@ -67,6 +69,7 @@
<span><i class='icon icon-group'></i> <?php printf($lang->project->membersUnit, $project->teamCount); ?></span>
<span><i class='icon icon-clock'></i> <?php printf($lang->project->hoursUnit, $project->estimate); ?></span>
</div>
<?php if($config->systemMode == 'new'):?>
<?php if($project->model === 'waterfall'): ?>
<div class='project-detail project-stages'>
<p class='text-muted'><?php echo $lang->project->ongoingStage;?></p>
@@ -109,6 +112,7 @@
<?php endif; ?>
</div>
<?php endif; ?>
<?php endif; ?>
</div>
</div>
</div>
+1 -1
View File
@@ -60,7 +60,7 @@ js::set('flow', $config->global->flow);
<?php common::printLink('caselib', 'exportTemplet', "libID=$libID", "<i class='icon icon-export muted'> </i>" . $lang->caselib->exportTemplet, '', "class='btn btn-link export' data-width='35%'");?>
<?php common::printLink('caselib', 'import', "libID=$libID", "<i class='icon muted icon-import'> </i>" . $lang->testcase->fileImport, '', "class='btn btn-link export'");?>
</div>
<?php echo html::a($this->createLink('caselib', 'create'), $lang->caselib->create, '', 'class="btn btn-secondary"');?>
<?php echo html::a($this->createLink('caselib', 'create'), "<i class='icon icon-plus'> </i>" . $lang->caselib->create, '', 'class="btn btn-secondary"');?>
<div class='btn-group dropdown'>
<?php
$params = "libID=$libID&moduleID=" . (isset($moduleID) ? $moduleID : 0);
+1
View File
@@ -119,6 +119,7 @@ $lang->statusAB = 'Status';
$lang->openedByAB = 'Ersteller';
$lang->assignedToAB = 'Bearbeiter';
$lang->typeAB = 'Typ';
$lang->nameAB = 'Name';
$lang->common = new stdclass();
$lang->common->common = 'Standard Module';
+1
View File
@@ -124,6 +124,7 @@ $lang->statusAB = 'Status';
$lang->openedByAB = 'CreatedBy';
$lang->assignedToAB = 'AssignedTo';
$lang->typeAB = 'Type';
$lang->nameAB = 'Name';
$lang->common->common = 'Common Module';
$lang->my->common = 'Dashboard';
+1
View File
@@ -119,6 +119,7 @@ $lang->statusAB = 'Statut';
$lang->openedByAB = 'Créé par';
$lang->assignedToAB = 'Affecté à';
$lang->typeAB = 'Type';
$lang->nameAB = 'Name';
$lang->common = new stdclass();
$lang->common->common = 'Module Commun';
+1 -1
View File
@@ -221,7 +221,7 @@ $lang->execution->menu = new stdclass();
$lang->execution->menu->task = array('link' => "{$lang->task->common}|execution|task|executionID=%s", 'subModule' => 'task,tree', 'alias' => 'importtask,importbug');
$lang->execution->menu->kanban = array('link' => "$lang->kanban|execution|kanban|executionID=%s");
$lang->execution->menu->burn = array('link' => "$lang->burn|execution|burn|executionID=%s");
$lang->execution->menu->view = array('link' => "$lang->view|execution|grouptask|executionID=%s", 'alias' => 'grouptask,tree', 'class' => 'dropdown dropdown-hover');
$lang->execution->menu->view = array('link' => "$lang->view|execution|grouptask|executionID=%s", 'alias' => 'grouptask,tree,taskeffort,gantt,calendar');
$lang->execution->menu->story = array('link' => "$lang->SRCommon|execution|story|executionID=%s", 'subModule' => 'story', 'alias' => 'batchcreate,linkstory,storykanban');
$lang->execution->menu->qa = array('link' => "{$lang->qa->common}|execution|bug|executionID=%s", 'subModule' => 'bug,testcase,testtask,testreport', 'alias' => 'qa,bug,testcase,testtask,testreport');
$lang->execution->menu->devops = array('link' => "{$lang->repo->common}|repo|browse|repoID=0&branchID=&objectID=%s", 'subModule' => 'repo');
+1
View File
@@ -119,6 +119,7 @@ $lang->statusAB = 'Tình trạng';
$lang->openedByAB = 'Người tạo';
$lang->assignedToAB = 'Giao cho';
$lang->typeAB = 'Loại';
$lang->nameAB = 'Name';
$lang->common = new stdclass();
$lang->common->common = 'Module chung';
+1
View File
@@ -124,6 +124,7 @@ $lang->statusAB = '状态';
$lang->openedByAB = '创建';
$lang->assignedToAB = '指派';
$lang->typeAB = '类型';
$lang->nameAB = '名称';
$lang->common->common = '公有模块';
$lang->my->common = '地盘';
+1
View File
@@ -126,6 +126,7 @@ $lang->statusAB = '狀態';
$lang->openedByAB = '創建';
$lang->assignedToAB = '指派';
$lang->typeAB = '類型';
$lang->nameAB = '名稱';
$lang->common = new stdclass();
$lang->common->common = '公有模組';
@@ -15,7 +15,7 @@
</style>
<div id='mainMenu' class='clearfix'>
<div class='pull-right'>
<?php if(common::hasPriv('custom', 'setstoryconcept')) echo html::a($this->createLink('custom', 'setstoryconcept', '', '', true), $lang->custom->setStoryConcept, '', "class='btn btn-primary iframe'");?>
<?php if(common::hasPriv('custom', 'setstoryconcept')) echo html::a($this->createLink('custom', 'setstoryconcept', '', '', true), $lang->custom->setStoryConcept, '', "class='btn btn-primary iframe' data-width=50%");?>
</div>
</div>
<div id='mainContent' class='main-row'>
-2
View File
@@ -10,8 +10,6 @@
* @link http://www.zentao.net
*/
/* Fields. */
$lang->executionCommon = $lang->executionCommon;
$lang->execution->common = $lang->executionCommon;
$lang->execution->allExecutions = 'Alle';
$lang->execution->allExecutionAB = 'All Executions';
$lang->execution->id = $lang->executionCommon . ' ID';
-2
View File
@@ -10,8 +10,6 @@
* @link http://www.zentao.net
*/
/* Fields. */
$lang->executionCommon = $lang->executionCommon;
$lang->execution->common = 'Execution';
$lang->execution->allExecutions = 'All ' . $lang->executionCommon . 's';
$lang->execution->allExecutionAB = 'All Executions';
$lang->execution->id = $lang->executionCommon . ' ID';
-2
View File
@@ -10,8 +10,6 @@
* @link https://www.zentao.pm
*/
/* Fields. */
$lang->executionCommon = $lang->executionCommon;
$lang->execution->common = $lang->executionCommon;
$lang->execution->allExecutions = 'Tous les ' . $lang->executionCommon . 's';
$lang->execution->allExecutionAB = 'All Executions';
$lang->execution->id = $lang->executionCommon . ' ID';
-2
View File
@@ -10,8 +10,6 @@
* @link http://www.zentao.net
*/
/* Fields. */
$lang->executionCommon = $lang->executionCommon;
$lang->execution->common = $lang->executionCommon;
$lang->execution->allExecutions = 'Tất cả ' . $lang->executionCommon;
$lang->execution->allExecutionAB = 'All Executions';
$lang->execution->id = 'ID '.$lang->executionCommon;
-2
View File
@@ -10,8 +10,6 @@
* @link http://www.zentao.net
*/
/* 字段列表。*/
$lang->executionCommon = $lang->executionCommon;
$lang->execution->common = '执行';
$lang->execution->allExecutions = '所有' . $lang->executionCommon;
$lang->execution->allExecutionAB = '所有执行';
$lang->execution->id = $lang->executionCommon . '编号';
+36 -36
View File
@@ -322,6 +322,42 @@ if($config->systemMode == 'new')
$lang->projectrelease->methodOrder[60] = 'unlinkBug';
$lang->projectrelease->methodOrder[65] = 'batchUnlinkBug';
$lang->projectrelease->methodOrder[70] = 'changeStatus';
/* Stakeholer. */
$lang->resource->stakeholder = new stdclass();
$lang->resource->stakeholder->browse = 'browse';
$lang->resource->stakeholder->create = 'create';
$lang->resource->stakeholder->batchCreate = 'batchCreate';
$lang->resource->stakeholder->edit = 'edit';
$lang->resource->stakeholder->delete = 'delete';
$lang->resource->stakeholder->view = 'viewAction';
$lang->resource->stakeholder->issue = 'issue';
$lang->resource->stakeholder->viewIssue = 'viewIssueAction';
$lang->resource->stakeholder->communicate = 'communicate';
$lang->resource->stakeholder->expect = 'expect';
$lang->resource->stakeholder->expectation = 'expectation';
$lang->resource->stakeholder->deleteExpect = 'deleteExpect';
$lang->resource->stakeholder->createExpect = 'createExpect';
$lang->resource->stakeholder->editExpect = 'editExpect';
$lang->resource->stakeholder->viewExpect = 'viewExpect';
$lang->resource->stakeholder->userIssue = 'userIssue';
$lang->stakeholder->methodOrder[5] = 'browse';
$lang->stakeholder->methodOrder[10] = 'create';
$lang->stakeholder->methodOrder[13] = 'batchCreate';
$lang->stakeholder->methodOrder[15] = 'edit';
$lang->stakeholder->methodOrder[25] = 'delete';
$lang->stakeholder->methodOrder[30] = 'view';
$lang->stakeholder->methodOrder[35] = 'issue';
$lang->stakeholder->methodOrder[40] = 'viewIssue';
$lang->stakeholder->methodOrder[45] = 'communicate';
$lang->stakeholder->methodOrder[50] = 'expect';
$lang->stakeholder->methodOrder[55] = 'expectation';
$lang->stakeholder->methodOrder[60] = 'deleteExpect';
$lang->stakeholder->methodOrder[65] = 'createExpect';
$lang->stakeholder->methodOrder[70] = 'editExpect';
$lang->stakeholder->methodOrder[75] = 'viewExpect';
$lang->stakeholder->methodOrder[80] = 'userIssue';
}
/* Product. */
@@ -378,42 +414,6 @@ $lang->branch->methodOrder[0] = 'manage';
$lang->branch->methodOrder[5] = 'sort';
$lang->branch->methodOrder[10] = 'delete';
/* Stakeholer. */
$lang->resource->stakeholder = new stdclass();
$lang->resource->stakeholder->browse = 'browse';
$lang->resource->stakeholder->create = 'create';
$lang->resource->stakeholder->batchCreate = 'batchCreate';
$lang->resource->stakeholder->edit = 'edit';
$lang->resource->stakeholder->delete = 'delete';
$lang->resource->stakeholder->view = 'viewAction';
$lang->resource->stakeholder->issue = 'issue';
$lang->resource->stakeholder->viewIssue = 'viewIssueAction';
$lang->resource->stakeholder->communicate = 'communicate';
$lang->resource->stakeholder->expect = 'expect';
$lang->resource->stakeholder->expectation = 'expectation';
$lang->resource->stakeholder->deleteExpect = 'deleteExpect';
$lang->resource->stakeholder->createExpect = 'createExpect';
$lang->resource->stakeholder->editExpect = 'editExpect';
$lang->resource->stakeholder->viewExpect = 'viewExpect';
$lang->resource->stakeholder->userIssue = 'userIssue';
$lang->stakeholder->methodOrder[5] = 'browse';
$lang->stakeholder->methodOrder[10] = 'create';
$lang->stakeholder->methodOrder[13] = 'batchCreate';
$lang->stakeholder->methodOrder[15] = 'edit';
$lang->stakeholder->methodOrder[25] = 'delete';
$lang->stakeholder->methodOrder[30] = 'view';
$lang->stakeholder->methodOrder[35] = 'issue';
$lang->stakeholder->methodOrder[40] = 'viewIssue';
$lang->stakeholder->methodOrder[45] = 'communicate';
$lang->stakeholder->methodOrder[50] = 'expect';
$lang->stakeholder->methodOrder[55] = 'expectation';
$lang->stakeholder->methodOrder[60] = 'deleteExpect';
$lang->stakeholder->methodOrder[65] = 'createExpect';
$lang->stakeholder->methodOrder[70] = 'editExpect';
$lang->stakeholder->methodOrder[75] = 'viewExpect';
$lang->stakeholder->methodOrder[80] = 'userIssue';
/* Story. */
$lang->resource->story = new stdclass();
$lang->resource->story->create = 'create';
+2
View File
@@ -475,6 +475,8 @@ class groupModel extends model
ksort($this->lang->moduleOrder, SORT_ASC);
foreach($this->lang->moduleOrder as $moduleName)
{
if(!isset($resources->$moduleName)) continue;
$resource = $resources->$moduleName;
unset($resources->$moduleName);
$this->lang->resource->$moduleName = $resource;
+1 -1
View File
@@ -6,7 +6,7 @@
<tr>
<th class='table-nest-title'>
<a class='table-nest-toggle table-nest-toggle-global' data-expand-text='<?php echo $lang->expand; ?>' data-collapse-text='<?php echo $lang->collapse;?>'></a>
<?php echo $lang->program->name;?>
<?php echo $lang->nameAB;?>
</th>
<th class='w-100px'><?php common::printOrderLink('PM', $orderBy, $vars, $lang->program->PM);?></th>
<th class='text-right w-100px'><?php common::printOrderLink('budget', $orderBy, $vars, $lang->project->budget);?></th>
+1 -3
View File
@@ -22,9 +22,7 @@
?>
</div>
<div class="btn-toolbar pull-right">
<?php if(common::canModify('execution', $execution)):?>
<?php common::printLink('projectrelease', 'create', "projectID=$projectID", "<i class='icon icon-plus'></i> {$lang->release->create}", '', "class='btn btn-primary'");?>
<?php endif;?>
</div>
</div>
<div id="mainContent" class='main-table'>
@@ -32,7 +30,7 @@
<div class="table-empty-tip">
<p>
<span class="text-muted"><?php echo $lang->release->noRelease;?></span>
<?php if(common::canModify('execution', $execution) and common::hasPriv('projectrelease', 'create')):?>
<?php if(common::hasPriv('projectrelease', 'create')):?>
<?php echo html::a($this->createLink('projectrelease', 'create', "projectID=$projectID"), "<i class='icon icon-plus'></i> " . $lang->release->create, '', "class='btn btn-info'");?>
<?php endif;?>
</p>
+2 -1
View File
@@ -1 +1,2 @@
.c-desc {overflow-x: scroll;}
.table td.c-desc div {height: 25px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; float: left; max-width: calc(100% - 20px);}
.table td.c-desc .more {height: 25px; float: left;}
+28
View File
@@ -7,4 +7,32 @@ $(function()
$(this).parent().toggleClass('active');
});
}
$('#suiteList tbody tr').each(function()
{
var $content = $(this).find('td.c-desc');
var content = $content.find('div').html();
if(content.indexOf('<br') >= 0)
{
$content.append("<a href='###' class='more'><i class='icon icon-chevron-double-down'></i></a>");
}
});
})
$(document).on('click', 'td.c-desc .more', function(e)
{
var $toggle = $(this);
if($toggle.hasClass('open'))
{
$toggle.removeClass('open');
$toggle.closest('.c-desc').find('div').css('height', '25px');
$toggle.css('padding-top', 0);
$toggle.find('i').removeClass('icon-chevron-double-up').addClass('icon-chevron-double-down');
}
else
{
$toggle.addClass('open');
$toggle.closest('.c-desc').find('div').css('height', 'auto');
$toggle.css('padding-top', ($toggle.closest('.c-desc').find('div').height() - $toggle.height()) / 2);
$toggle.find('i').removeClass('icon-chevron-double-down').addClass('icon-chevron-double-up');
}
});
+4 -1
View File
@@ -62,7 +62,10 @@
<?php if($suite->type == 'private') echo "<span class='label label-info label-badge'>{$lang->testsuite->authorList['private']}</span> ";?>
<?php echo html::a(inlink('view', "suiteID=$suite->id"), $suite->name);?>
</td>
<td class='c-desc'><?php echo $suite->desc;?></td>
<td class='c-desc'>
<?php $desc = trim(strip_tags(str_replace(array('</p>', '<br />', '<br>', '<br/>'), "\n", str_replace(array("\n", "\r"), '', $suite->desc)), '<img>'));?>
<div title='<?php echo $desc;?>'><?php echo nl2br($desc);?></div>
</td>
<td><?php echo zget($users, $suite->addedBy);?></td>
<td><?php echo $suite->addedDate;?></td>
<?php foreach($extendFields as $extendField) echo "<td>" . $this->loadModel('flow')->getFieldValue($extendField, $suite) . "</td>";?>
+15 -1
View File
@@ -3973,7 +3973,21 @@ class upgradeModel extends model
*/
public function adjustPriv15_0()
{
$this->dao->update(TABLE_GROUPPRIV)->set('module')->eq('execution')->where('module')->eq('project')->exec();
$executionPriv = $this->dao->select('*')->from(TABLE_GROUPPRIV)->where('module')->eq('execution')->limit(1)->fetch();
if(empty($executionPriv)) $this->dao->update(TABLE_GROUPPRIV)->set('module')->eq('execution')->where('module')->eq('project')->exec();
$groups = $this->dao->select('id')->from(TABLE_GROUP)->fetchPairs('id', 'id');
foreach($groups as $groupID)
{
$groupPriv = new stdclass();
$groupPriv->group = $groupID;
$groupPriv->module = 'my';
$groupPriv->method = 'work';
$this->dao->replace(TABLE_GROUPPRIV)->data($groupPriv)->exec();
$groupPriv->method = 'contribute';
$this->dao->replace(TABLE_GROUPPRIV)->data($groupPriv)->exec();
}
$stmt = $this->dao->select('*')->from(TABLE_GROUPPRIV)->where('module')->eq('program')->andWhere('method')->like('PGM%')->query();
while($grouppriv = $stmt->fetch())
File diff suppressed because one or more lines are too long