* fix bug#494.
This commit is contained in:
@@ -1,52 +1,9 @@
|
||||
<?php
|
||||
$config->custom = new stdClass();
|
||||
|
||||
$config->custom->story = new stdClass();
|
||||
$config->custom->story->fields['priList'] = '优先级';
|
||||
$config->custom->story->fields['sourceList'] = '来源';
|
||||
$config->custom->story->fields['reasonList'] = '关闭原因';
|
||||
$config->custom->story->fields['reviewResultList'] = '评审结果';
|
||||
$config->custom->story->fields['stageList'] = '阶段';
|
||||
$config->custom->story->fields['statusList'] = '状态';
|
||||
$config->custom->story->canAdd = 'reasonList,reviewResultList,sourceList,priList';
|
||||
|
||||
$config->custom->task = new stdClass();
|
||||
$config->custom->task->fields['priList'] = '优先级';
|
||||
$config->custom->task->fields['typeList'] = '类型';
|
||||
$config->custom->task->fields['reasonList'] = '关闭原因';
|
||||
$config->custom->task->fields['statusList'] = '状态';
|
||||
$config->custom->task->canAdd = 'priList,typeList';
|
||||
|
||||
$config->custom->bug = new stdClass();
|
||||
$config->custom->bug->fields['priList'] = '优先级';
|
||||
$config->custom->bug->fields['severityList'] = '严重程度';
|
||||
$config->custom->bug->fields['osList'] = '操作系统';
|
||||
$config->custom->bug->fields['browserList'] = '浏览器';
|
||||
$config->custom->bug->fields['typeList'] = '类型';
|
||||
$config->custom->bug->fields['resolutionList'] = '解决方案';
|
||||
$config->custom->bug->fields['statusList'] = '状态';
|
||||
$config->custom->bug->canAdd = 'priList,severityList,osList,browserList,typeList,resolutionList';
|
||||
|
||||
$config->custom->testcase = new stdClass();
|
||||
$config->custom->testcase->fields['priList'] = '优先级';
|
||||
$config->custom->testcase->fields['typeList'] = '类型';
|
||||
$config->custom->testcase->fields['stageList'] = '阶段';
|
||||
$config->custom->testcase->fields['resultList'] = '执行结果';
|
||||
$config->custom->testcase->fields['statusList'] = '状态';
|
||||
$config->custom->testcase->canAdd = 'priList,typeList,stageList';
|
||||
|
||||
$config->custom->testtask = new stdClass();
|
||||
$config->custom->testtask->fields['priList'] = '优先级';
|
||||
$config->custom->testtask->fields['statusList'] = '状态';
|
||||
$config->custom->testtask->canAdd = 'priList';
|
||||
|
||||
$config->custom->todo = new stdClass();
|
||||
$config->custom->todo->fields['priList'] = '优先级';
|
||||
$config->custom->todo->fields['typeList'] = '类型';
|
||||
$config->custom->todo->fields['statusList'] = '状态';
|
||||
$config->custom->todo->canAdd = 'priList,typeList';
|
||||
|
||||
$config->custom->user = new stdClass();
|
||||
$config->custom->user->fields['roleList'] = '职位';
|
||||
$config->custom->user->fields['statusList'] = '状态';
|
||||
$config->custom->user->canAdd = 'roleList';
|
||||
$config->custom->canAdd['story'] = 'reasonList,reviewResultList,sourceList,priList';
|
||||
$config->custom->canAdd['task'] = 'priList,typeList';
|
||||
$config->custom->canAdd['bug'] = 'priList,severityList,osList,browserList,typeList,resolutionList';
|
||||
$config->custom->canAdd['testcase'] = 'priList,typeList,stageList';
|
||||
$config->custom->canAdd['testtask'] = 'priList';
|
||||
$config->custom->canAdd['todo'] = 'priList,typeList';
|
||||
$config->custom->canAdd['user'] = 'roleList';
|
||||
|
||||
@@ -60,7 +60,7 @@ class custom extends control
|
||||
$this->view->field = $field;
|
||||
$this->view->module = $module;
|
||||
$this->view->currentLang = $currentLang;
|
||||
$this->view->canAdd = strpos($this->config->custom->$module->canAdd, $field) !== false;
|
||||
$this->view->canAdd = strpos($this->config->custom->canAdd[$module], $field) !== false;
|
||||
|
||||
$this->display();
|
||||
}
|
||||
|
||||
@@ -6,13 +6,56 @@ $lang->custom->restore = 'restore';
|
||||
$lang->custom->key = 'Key';
|
||||
$lang->custom->value = 'Value';
|
||||
|
||||
$lang->custom->story = 'Story';
|
||||
$lang->custom->task = 'Task';
|
||||
$lang->custom->bug = 'Bug';
|
||||
$lang->custom->testcase = 'Test case';
|
||||
$lang->custom->testtask = 'Test task';
|
||||
$lang->custom->todo = 'Todo';
|
||||
$lang->custom->user = 'User';
|
||||
$lang->custom->object['story'] = 'Story';
|
||||
$lang->custom->object['task'] = 'Task';
|
||||
$lang->custom->object['bug'] = 'Bug';
|
||||
$lang->custom->object['testcase'] = 'Test case';
|
||||
$lang->custom->object['testtask'] = 'Test task';
|
||||
$lang->custom->object['todo'] = 'Todo';
|
||||
$lang->custom->object['user'] = 'User';
|
||||
|
||||
$lang->custom->story = new stdClass();
|
||||
$lang->custom->story->fields['priList'] = 'Priority';
|
||||
$lang->custom->story->fields['sourceList'] = 'Source';
|
||||
$lang->custom->story->fields['reasonList'] = 'Closed reason';
|
||||
$lang->custom->story->fields['reviewResultList'] = 'Reviewed result';
|
||||
$lang->custom->story->fields['stageList'] = 'Stage';
|
||||
$lang->custom->story->fields['statusList'] = 'Status';
|
||||
|
||||
$lang->custom->task = new stdClass();
|
||||
$lang->custom->task->fields['priList'] = 'Priority';
|
||||
$lang->custom->task->fields['typeList'] = 'Type';
|
||||
$lang->custom->task->fields['reasonList'] = 'Closed reason';
|
||||
$lang->custom->task->fields['statusList'] = 'Status';
|
||||
|
||||
$lang->custom->bug = new stdClass();
|
||||
$lang->custom->bug->fields['priList'] = 'Priority';
|
||||
$lang->custom->bug->fields['severityList'] = 'Severity';
|
||||
$lang->custom->bug->fields['osList'] = 'OS';
|
||||
$lang->custom->bug->fields['browserList'] = 'Browser';
|
||||
$lang->custom->bug->fields['typeList'] = 'Type';
|
||||
$lang->custom->bug->fields['resolutionList'] = 'Resolution';
|
||||
$lang->custom->bug->fields['statusList'] = 'Status';
|
||||
|
||||
$lang->custom->testcase = new stdClass();
|
||||
$lang->custom->testcase->fields['priList'] = 'Priority';
|
||||
$lang->custom->testcase->fields['typeList'] = 'Type';
|
||||
$lang->custom->testcase->fields['stageList'] = 'Stage';
|
||||
$lang->custom->testcase->fields['resultList'] = 'Result';
|
||||
$lang->custom->testcase->fields['statusList'] = 'Status';
|
||||
|
||||
$lang->custom->testtask = new stdClass();
|
||||
$lang->custom->testtask->fields['priList'] = 'Priority';
|
||||
$lang->custom->testtask->fields['statusList'] = 'Status';
|
||||
|
||||
$lang->custom->todo = new stdClass();
|
||||
$lang->custom->todo->fields['priList'] = 'Priority';
|
||||
$lang->custom->todo->fields['typeList'] = 'Type';
|
||||
$lang->custom->todo->fields['statusList'] = 'Status';
|
||||
|
||||
$lang->custom->user = new stdClass();
|
||||
$lang->custom->user->fields['roleList'] = 'Role';
|
||||
$lang->custom->user->fields['statusList'] = 'Status';
|
||||
|
||||
$lang->custom->currentLang = 'For current language';
|
||||
$lang->custom->allLang = 'For all language';
|
||||
|
||||
@@ -6,13 +6,56 @@ $lang->custom->restore = '恢复默认';
|
||||
$lang->custom->key = '键';
|
||||
$lang->custom->value = '值';
|
||||
|
||||
$lang->custom->story = '需求';
|
||||
$lang->custom->task = '任务';
|
||||
$lang->custom->bug = 'Bug';
|
||||
$lang->custom->testcase = '测试用例';
|
||||
$lang->custom->testtask = '测试任务';
|
||||
$lang->custom->todo = '待办';
|
||||
$lang->custom->user = '用户';
|
||||
$lang->custom->object['story'] = '需求';
|
||||
$lang->custom->object['task'] = '任务';
|
||||
$lang->custom->object['bug'] = 'Bug';
|
||||
$lang->custom->object['testcase'] = '测试用例';
|
||||
$lang->custom->object['testtask'] = '测试任务';
|
||||
$lang->custom->object['todo'] = '待办';
|
||||
$lang->custom->object['user'] = '用户';
|
||||
|
||||
$lang->custom->story = new stdClass();
|
||||
$lang->custom->story->fields['priList'] = '优先级';
|
||||
$lang->custom->story->fields['sourceList'] = '来源';
|
||||
$lang->custom->story->fields['reasonList'] = '关闭原因';
|
||||
$lang->custom->story->fields['reviewResultList'] = '评审结果';
|
||||
$lang->custom->story->fields['stageList'] = '阶段';
|
||||
$lang->custom->story->fields['statusList'] = '状态';
|
||||
|
||||
$lang->custom->task = new stdClass();
|
||||
$lang->custom->task->fields['priList'] = '优先级';
|
||||
$lang->custom->task->fields['typeList'] = '类型';
|
||||
$lang->custom->task->fields['reasonList'] = '关闭原因';
|
||||
$lang->custom->task->fields['statusList'] = '状态';
|
||||
|
||||
$lang->custom->bug = new stdClass();
|
||||
$lang->custom->bug->fields['priList'] = '优先级';
|
||||
$lang->custom->bug->fields['severityList'] = '严重程度';
|
||||
$lang->custom->bug->fields['osList'] = '操作系统';
|
||||
$lang->custom->bug->fields['browserList'] = '浏览器';
|
||||
$lang->custom->bug->fields['typeList'] = '类型';
|
||||
$lang->custom->bug->fields['resolutionList'] = '解决方案';
|
||||
$lang->custom->bug->fields['statusList'] = '状态';
|
||||
|
||||
$lang->custom->testcase = new stdClass();
|
||||
$lang->custom->testcase->fields['priList'] = '优先级';
|
||||
$lang->custom->testcase->fields['typeList'] = '类型';
|
||||
$lang->custom->testcase->fields['stageList'] = '阶段';
|
||||
$lang->custom->testcase->fields['resultList'] = '执行结果';
|
||||
$lang->custom->testcase->fields['statusList'] = '状态';
|
||||
|
||||
$lang->custom->testtask = new stdClass();
|
||||
$lang->custom->testtask->fields['priList'] = '优先级';
|
||||
$lang->custom->testtask->fields['statusList'] = '状态';
|
||||
|
||||
$lang->custom->todo = new stdClass();
|
||||
$lang->custom->todo->fields['priList'] = '优先级';
|
||||
$lang->custom->todo->fields['typeList'] = '类型';
|
||||
$lang->custom->todo->fields['statusList'] = '状态';
|
||||
|
||||
$lang->custom->user = new stdClass();
|
||||
$lang->custom->user->fields['roleList'] = '职位';
|
||||
$lang->custom->user->fields['statusList'] = '状态';
|
||||
|
||||
$lang->custom->currentLang = '适用当前语言';
|
||||
$lang->custom->allLang = '适用所有语言';
|
||||
|
||||
@@ -35,24 +35,23 @@ EOT;
|
||||
<div id='featurebar'>
|
||||
<div class='f-left'>
|
||||
<?php
|
||||
echo "<span id='storyTab'>"; common::printLink('custom', 'set', "module=story", $lang->custom->story); echo '</span>';
|
||||
echo "<span id='taskTab'>"; common::printLink('custom', 'set', "module=task", $lang->custom->task); echo '</span>';
|
||||
echo "<span id='bugTab'>"; common::printLink('custom', 'set', "module=bug", $lang->custom->bug); echo '</span>';
|
||||
echo "<span id='testcaseTab'>"; common::printLink('custom', 'set', "module=testcase", $lang->custom->testcase); echo '</span>';
|
||||
echo "<span id='testtaskTab'>"; common::printLink('custom', 'set', "module=testtask", $lang->custom->testtask); echo '</span>';
|
||||
echo "<span id='todoTab'>"; common::printLink('custom', 'set', "module=todo", $lang->custom->todo); echo '</span>' ;
|
||||
echo "<span id='userTab'>"; common::printLink('custom', 'set', "module=user", $lang->custom->user); echo '</span>';
|
||||
foreach($lang->custom->object as $object => $name)
|
||||
{
|
||||
echo "<span id='{$object}Tab'>";
|
||||
common::printLink('custom', 'set', "module=$object", $name);
|
||||
echo '</span>';
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<table class='cont-lt2'>
|
||||
<tr valign='top'>
|
||||
<td class='side'>
|
||||
<div class='box-title'><?php echo $lang->custom->$module?></div>
|
||||
<div class='box-title'><?php echo $lang->custom->object[$module]?></div>
|
||||
<div class='box-content'>
|
||||
<ul class='tree'>
|
||||
<?php
|
||||
foreach($config->custom->{$module}->fields as $key => $value)
|
||||
foreach($lang->custom->{$module}->fields as $key => $value)
|
||||
{
|
||||
echo "<li><span id='{$key}Tab'>" . html::a(inlink('set', "module=$module&field=$key"), $value) . "</span></li>";
|
||||
}
|
||||
@@ -64,7 +63,7 @@ EOT;
|
||||
<td>
|
||||
<form method='post'>
|
||||
<table class='table-1'>
|
||||
<caption><?echo $lang->custom->$module . ' >> ' . $config->custom->$module->fields[$field]?></caption>
|
||||
<caption><?echo $lang->custom->object[$module] . ' >> ' . $lang->custom->$module->fields[$field]?></caption>
|
||||
<tr>
|
||||
<th class='w-100px'><?php echo $lang->custom->key;?></th>
|
||||
<th><?php echo $lang->custom->value;?></th>
|
||||
|
||||
Reference in New Issue
Block a user