Merge branch 'devops18'

This commit is contained in:
liyuchun
2021-12-31 10:38:04 +08:00
58 changed files with 1243 additions and 241 deletions
+10 -9
View File
@@ -760,15 +760,16 @@ class task extends control
$position[] = $this->lang->task->common;
$position[] = $this->lang->task->view;
$this->view->title = $title;
$this->view->position = $position;
$this->view->execution = $execution;
$this->view->task = $task;
$this->view->actions = $this->loadModel('action')->getList('task', $taskID);
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->preAndNext = $this->loadModel('common')->getPreAndNextObject('task', $taskID);
$this->view->product = $this->tree->getProduct($task->module);
$this->view->modulePath = $this->tree->getParents($task->module);
$this->view->title = $title;
$this->view->position = $position;
$this->view->execution = $execution;
$this->view->task = $task;
$this->view->actions = $this->loadModel('action')->getList('task', $taskID);
$this->view->users = $this->loadModel('user')->getPairs('noletter');
$this->view->preAndNext = $this->loadModel('common')->getPreAndNextObject('task', $taskID);
$this->view->product = $this->tree->getProduct($task->module);
$this->view->modulePath = $this->tree->getParents($task->module);
$this->view->linkMRTitles = $this->loadModel('mr')->getLinkedMRPairs($taskID, 'task');
$this->display();
}
+2 -1
View File
@@ -2,4 +2,5 @@
.side-col #legendProjectAndTask .list-unstyled {padding: 10px; border: 1px solid #ddd; border-top: 0px; margin: 0px;}
.tab-pane table {border: 1px solid #ddd; border-top: none;}
.page-title{max-width: 80%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;}
.pull-left{max-width: 80%;}
.pull-left{max-width: 80%;}
.MRThWidth {width: 90px !important;}
+2
View File
@@ -160,6 +160,7 @@ $lang->task->noFinished = 'Unfinished';
$lang->task->noClosed = 'Unclosed';
$lang->task->yesterdayFinished = 'Task Finished Yesterday';
$lang->task->allTasks = 'Task';
$lang->task->linkMR = 'Related MRs';
$lang->task->statusList[''] = '';
$lang->task->statusList['wait'] = 'Waiting';
@@ -199,6 +200,7 @@ $lang->task->legendEffort = 'Effort';
$lang->task->legendLife = 'Task Life';
$lang->task->legendDesc = 'Task Description';
$lang->task->legendDetail = 'Task Detail';
$lang->task->legendMisc = 'Misc.';
$lang->task->confirmDelete = "Do you want to delete this task?";
$lang->task->confirmDeleteEstimate = "Do you want to delete it?";
+2
View File
@@ -160,6 +160,7 @@ $lang->task->noFinished = '未完成';
$lang->task->noClosed = '未关闭';
$lang->task->yesterdayFinished = '昨日完成任务数';
$lang->task->allTasks = '总任务';
$lang->task->linkMR = '相关合并请求';
$lang->task->statusList[''] = '';
$lang->task->statusList['wait'] = '未开始';
@@ -199,6 +200,7 @@ $lang->task->legendEffort = '工时信息';
$lang->task->legendLife = '任务的一生';
$lang->task->legendDesc = '任务描述';
$lang->task->legendDetail = '任务详情';
$lang->task->legendMisc = '其他相关';
$lang->task->confirmDelete = "您确定要删除这个任务吗?";
$lang->task->confirmDeleteEstimate = "您确定要删除这个记录吗?";
+2
View File
@@ -160,6 +160,7 @@ $lang->task->noFinished = '未完成';
$lang->task->noClosed = '未關閉';
$lang->task->yesterdayFinished = '昨日完成任務數';
$lang->task->allTasks = '總任務';
$lang->task->linkMR = '相關合并請求';
$lang->task->statusList[''] = '';
$lang->task->statusList['wait'] = '未開始';
@@ -199,6 +200,7 @@ $lang->task->legendEffort = '工時信息';
$lang->task->legendLife = '任務的一生';
$lang->task->legendDesc = '任務描述';
$lang->task->legendDetail = '任務詳情';
$lang->task->legendMisc = '其他相關';
$lang->task->confirmDelete = "您確定要刪除這個任務嗎?";
$lang->task->confirmDeleteEstimate = "您確定要刪除這個記錄嗎?";
+57 -36
View File
@@ -359,43 +359,64 @@
</div>
</div>
</div>
<div class='cell'>
<details class="detail" open>
<summary class="detail-title"><?php echo $lang->task->legendEffort;?></summary>
<div class="detail-content">
<table class='table table-data'>
<tr>
<th class='effortThWidth'><?php echo $lang->task->estimate;?></th>
<td><?php echo $task->estimate . $lang->workingHour;?></td>
</tr>
<tr>
<th><?php echo $lang->task->consumed;?></th>
<td><?php echo round($task->consumed, 2) . $lang->workingHour;?></td>
</tr>
<tr>
<th><?php echo $lang->task->left;?></th>
<td><?php echo $task->left . $lang->workingHour;?></td>
</tr>
<tr>
<th><?php echo $lang->task->estStarted;?></th>
<td><?php echo $task->estStarted;?></td>
</tr>
<tr>
<th><?php echo $lang->task->realStarted;?></th>
<td><?php echo helper::isZeroDate($task->realStarted) ? '' : $task->realStarted; ?> </td>
</tr>
<tr>
<th><?php echo $lang->task->deadline;?></th>
<td>
<?php
echo $task->deadline;
if(isset($task->delay)) printf($lang->task->delayWarning, $task->delay);
?>
</td>
</tr>
</table>
<div class="cell">
<div class='tabs'>
<ul class='nav nav-tabs'>
<li class='active'><a href='#legendEffort' data-toggle='tab'><?php echo $lang->task->legendEffort;?></a></li>
<li><a href='#legendMisc' data-toggle='tab'><?php echo $lang->task->legendMisc;?></a></li>
</ul>
<div class='tab-content'>
<div class='tab-pane active' id='legendEffort'>
<table class="table table-data">
<tr>
<th class='effortThWidth'><?php echo $lang->task->estimate;?></th>
<td><?php echo $task->estimate . $lang->workingHour;?></td>
</tr>
<tr>
<th><?php echo $lang->task->consumed;?></th>
<td><?php echo round($task->consumed, 2) . $lang->workingHour;?></td>
</tr>
<tr>
<th><?php echo $lang->task->left;?></th>
<td><?php echo $task->left . $lang->workingHour;?></td>
</tr>
<tr>
<th><?php echo $lang->task->estStarted;?></th>
<td><?php echo $task->estStarted;?></td>
</tr>
<tr>
<th><?php echo $lang->task->realStarted;?></th>
<td><?php echo helper::isZeroDate($task->realStarted) ? '' : $task->realStarted; ?> </td>
</tr>
<tr>
<th><?php echo $lang->task->deadline;?></th>
<td>
<?php
echo $task->deadline;
if(isset($task->delay)) printf($lang->task->delayWarning, $task->delay);
?>
</td>
</tr>
</table>
</div>
<div class='tab-pane' id='legendMisc'>
<table class="table table-data">
<tr>
<th class='MRThWidth'><?php echo $lang->task->linkMR;?></th>
<td>
<?php
$canViewMR = common::hasPriv('mr', 'view');
foreach($linkMRTitles as $MRID => $linkMRTitle)
{
echo ($canViewMR ? html::a($this->createLink('mr', 'view', "MRID=$MRID"), "#$MRID $linkMRTitle") : "#$MRID $linkMRTitle") . '<br />';
}
?>
</td>
</tr>
</table>
</div>
</div>
</details>
</div>
</div>
<?php $this->printExtendFields($task, 'div', "position=right&inForm=0&inCell=1");?>
</div>