* [bug#60761,done,1h] remove product block under the lite interface.

This commit is contained in:
tianshujie
2025-03-31 09:56:36 +08:00
committed by 刘刚
parent dc5b2a6f8a
commit 4c7f7fa443
6 changed files with 21 additions and 18 deletions
+3
View File
@@ -46,3 +46,6 @@ UPDATE `zt_workflowfield` SET `control` = 'select' WHERE `module` = 'proje
UPDATE `zt_workflowfield` SET `control` = 'select', `options` = "{\"extend\":\"\\u7ee7\\u627f\",\"reset\":\"\\u91cd\\u65b0\\u5b9a\\u4e49\"}" WHERE `module` = 'project' AND `field` = 'auth';
UPDATE `zt_workflowaction` SET `layout` = 'side' WHERE `module` = 'ticket' AND `action` = 'edit';
DELETE FROM `zt_block` WHERE `dashboard` = 'my' AND `module` = 'product' AND `code` IN ('overview', 'statistic') AND `vision` = 'lite';
DELETE FROM `zt_block` WHERE `dashboard` = 'my' AND `module` = 'qa' AND `code` = 'statistic' AND `vision` = 'lite';
+3 -3
View File
@@ -197,12 +197,12 @@ $lang->block->default['full']['my'][] = array('title' => "Recent {$lang->project
$lang->block->default['full']['my'][] = array('title' => "Undone {$lang->projectCommon} list", 'module' => 'project', 'code' => 'project', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20', 'orderBy' => 'id_desc'));
$lang->block->default['full']['my'][] = array('title' => "{$lang->projectCommon} Statistic", 'module' => 'project', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Undone {$lang->execution->common} Statistic", 'module' => 'execution', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} Statistic", 'module' => 'product', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} test statistics", 'module' => 'qa', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} Statistic", 'module' => 'product', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} test statistics", 'module' => 'qa', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Zentao Dynamic", 'module' => 'zentaodynamic', 'code' => 'zentaodynamic', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => 'Dynamic', 'module' => 'dynamic', 'code' => 'dynamic', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "Team", 'module' => 'teamachievement', 'code' => 'teamachievement', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->productCommon} Overview", 'module' => 'product', 'code' => 'overview', 'width' => '1');
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "{$lang->productCommon} Overview", 'module' => 'product', 'code' => 'overview', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->projectCommon} Overview", 'module' => 'project', 'code' => 'overview', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->execution->common} Overview", 'module' => 'execution', 'code' => 'overview', 'width' => '1');
+3 -3
View File
@@ -197,12 +197,12 @@ $lang->block->default['full']['my'][] = array('title' => "Recent {$lang->project
$lang->block->default['full']['my'][] = array('title' => "Undone {$lang->projectCommon} list", 'module' => 'project', 'code' => 'project', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20', 'orderBy' => 'id_desc'));
$lang->block->default['full']['my'][] = array('title' => "{$lang->projectCommon} Statistic", 'module' => 'project', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Undone {$lang->execution->common} Statistic", 'module' => 'execution', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} Statistic", 'module' => 'product', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} test statistics", 'module' => 'qa', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} Statistic", 'module' => 'product', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} test statistics", 'module' => 'qa', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Zentao Dynamic", 'module' => 'zentaodynamic', 'code' => 'zentaodynamic', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => 'Dynamic', 'module' => 'dynamic', 'code' => 'dynamic', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "Team", 'module' => 'teamachievement', 'code' => 'teamachievement', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->productCommon} Overview", 'module' => 'product', 'code' => 'overview', 'width' => '1');
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "{$lang->productCommon} Overview", 'module' => 'product', 'code' => 'overview', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->projectCommon} Overview", 'module' => 'project', 'code' => 'overview', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->execution->common} Overview", 'module' => 'execution', 'code' => 'overview', 'width' => '1');
+3 -3
View File
@@ -197,12 +197,12 @@ $lang->block->default['full']['my'][] = array('title' => "Recent {$lang->project
$lang->block->default['full']['my'][] = array('title' => "Undone {$lang->projectCommon} list", 'module' => 'project', 'code' => 'project', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20', 'orderBy' => 'id_desc'));
$lang->block->default['full']['my'][] = array('title' => "{$lang->projectCommon} Statistic", 'module' => 'project', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Undone {$lang->execution->common} Statistic", 'module' => 'execution', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} Statistic", 'module' => 'product', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} test statistics", 'module' => 'qa', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} Statistic", 'module' => 'product', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "Unclosed {$lang->productCommon} test statistics", 'module' => 'qa', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "Zentao Dynamic", 'module' => 'zentaodynamic', 'code' => 'zentaodynamic', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => 'Dynamic', 'module' => 'dynamic', 'code' => 'dynamic', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "Team", 'module' => 'teamachievement', 'code' => 'teamachievement', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->productCommon} Overview", 'module' => 'product', 'code' => 'overview', 'width' => '1');
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "{$lang->productCommon} Overview", 'module' => 'product', 'code' => 'overview', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->projectCommon} Overview", 'module' => 'project', 'code' => 'overview', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->execution->common} Overview", 'module' => 'execution', 'code' => 'overview', 'width' => '1');
+3 -3
View File
@@ -197,12 +197,12 @@ $lang->block->default['full']['my'][] = array('title' => "我近期参与的{$la
$lang->block->default['full']['my'][] = array('title' => "未完成的{$lang->projectCommon}列表", 'module' => 'project', 'code' => 'project', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20', 'orderBy' => 'id_desc'));
$lang->block->default['full']['my'][] = array('title' => "未完成的{$lang->execution->common}统计", 'module' => 'execution', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "未完成的{$lang->projectCommon}统计", 'module' => 'project', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'undone', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "未关闭的{$lang->productCommon}统计", 'module' => 'product', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "未关闭{$lang->productCommon}的测试统计", 'module' => 'qa', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "未关闭的{$lang->productCommon}统计", 'module' => 'product', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "未关闭{$lang->productCommon}的测试统计", 'module' => 'qa', 'code' => 'statistic', 'width' => '2', 'params' => array('type' => 'noclosed', 'count' => '20'));
$lang->block->default['full']['my'][] = array('title' => "禅道动态", 'module' => 'zentaodynamic', 'code' => 'zentaodynamic', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "最新动态", 'module' => 'dynamic', 'code' => 'dynamic', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "团队成就", 'module' => 'teamachievement', 'code' => 'teamachievement', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->productCommon}总览", 'module' => 'product', 'code' => 'overview', 'width' => '1');
if($config->vision != 'lite') $lang->block->default['full']['my'][] = array('title' => "{$lang->productCommon}总览", 'module' => 'product', 'code' => 'overview', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->projectCommon}总览", 'module' => 'project', 'code' => 'overview', 'width' => '1');
$lang->block->default['full']['my'][] = array('title' => "{$lang->execution->common}总览", 'module' => 'execution', 'code' => 'overview', 'width' => '1');
+6 -6
View File
@@ -1893,7 +1893,7 @@ class blockZen extends block
/* 通过度量项获取迭代总量。 */
$executionCount = 0;
$executionCountGroup = $project ? $this->metric->getResultByCodeWithArray('count_of_execution_in_project', array('project' => $project)) : $this->metric->getResultByCodeWithArray('count_of_execution', array(), 'cron');
$executionCountGroup = $project ? $this->metric->getResultByCodeWithArray('count_of_execution_in_project', array('project' => $project)) : $this->metric->getResultByCodeWithArray('count_of_execution', array(), 'cron', null, $this->config->vision);
if(!empty($executionCountGroup))
{
$executionCountGroup = reset($executionCountGroup);
@@ -1902,7 +1902,7 @@ class blockZen extends block
/* 通过度量项获取今年完成的迭代数量。 */
$finishedExecution = 0;
$finishedExecutionGroup = $project ? $this->metric->getResultByCodeWithArray('count_of_annual_finished_execution_in_project', array('project' => $project, 'year' => date('Y')), 'cron') : $this->metric->getResultByCodeWithArray('count_of_annual_finished_execution', array('year' => date('Y')), 'cron');
$finishedExecutionGroup = $project ? $this->metric->getResultByCodeWithArray('count_of_annual_finished_execution_in_project', array('project' => $project, 'year' => date('Y')), 'cron') : $this->metric->getResultByCodeWithArray('count_of_annual_finished_execution', array('year' => date('Y')), 'cron', null, $this->config->vision);
if(!empty($finishedExecutionGroup))
{
$finishedExecutionGroup = reset($finishedExecutionGroup);
@@ -1911,7 +1911,7 @@ class blockZen extends block
/* 通过度量项获取未开始的迭代数量。 */
$waitExecution = 0;
$waitExecutionGroup = $project ? $this->metric->getResultByCodeWithArray('count_wait_execution_in_project', array('project' => $project), 'cron') : $this->metric->getResultByCodeWithArray('count_of_wait_execution', array(), 'cron');
$waitExecutionGroup = $project ? $this->metric->getResultByCodeWithArray('count_wait_execution_in_project', array('project' => $project), 'cron') : $this->metric->getResultByCodeWithArray('count_of_wait_execution', array(), 'cron', null, $this->config->vision);
if(!empty($waitExecutionGroup))
{
$waitExecutionGroup = reset($waitExecutionGroup);
@@ -1920,7 +1920,7 @@ class blockZen extends block
/* 通过度量项获取进行中的迭代数量。 */
$doingExecution = 0;
$doingExecutionGroup = $project ? $this->metric->getResultByCodeWithArray('count_of_doing_execution_in_project', array('project' => $project), 'cron') : $this->metric->getResultByCodeWithArray('count_of_doing_execution', array(), 'cron');
$doingExecutionGroup = $project ? $this->metric->getResultByCodeWithArray('count_of_doing_execution_in_project', array('project' => $project), 'cron') : $this->metric->getResultByCodeWithArray('count_of_doing_execution', array(), 'cron', null, $this->config->vision);
if(!empty($doingExecutionGroup))
{
$doingExecutionGroup = reset($doingExecutionGroup);
@@ -1929,7 +1929,7 @@ class blockZen extends block
/* 通过度量项获取已挂起的迭代数量。 */
$suspendedExecution = 0;
$suspendedExecutionGroup = $project ? $this->metric->getResultByCodeWithArray('count_of_suspended_execution_in_project', array('project' => $project), 'cron') : $this->metric->getResultByCodeWithArray('count_of_suspended_execution', array(), 'cron');
$suspendedExecutionGroup = $project ? $this->metric->getResultByCodeWithArray('count_of_suspended_execution_in_project', array('project' => $project), 'cron') : $this->metric->getResultByCodeWithArray('count_of_suspended_execution', array(), 'cron', null, $this->config->vision);
if(!empty($suspendedExecutionGroup))
{
$suspendedExecutionGroup = reset($suspendedExecutionGroup);
@@ -1937,7 +1937,7 @@ class blockZen extends block
}
/* 如果是地盘下的区块跳转到执行列表,如果是单项目下的区块跳转到项目的迭代列表。 */
$url = common::hasPriv('execution', 'all') ? helper::createLink('execution', 'all', 'status=all') : null;
$url = common::hasPriv('execution', 'all') && $this->config->vision != 'lite' ? helper::createLink('execution', 'all', 'status=all') : null;
if($project) $url = common::hasPriv('project', 'execution') ? helper::createLink('project', 'execution', "status=all&projectID=$project") : null;
/* 组装区块左侧的数据。 */