Merge branch 'cyy_mr' into 'master'
Cyy mr See merge request easycorp/zentaopms!4643
This commit is contained in:
@@ -303,6 +303,8 @@ class mr extends control
|
||||
$this->view->stories = $this->mr->getLinkList($MR->id, $product->id, 'story');
|
||||
$this->view->bugs = $this->mr->getLinkList($MR->id, $product->id, 'bug');
|
||||
$this->view->tasks = $this->mr->getLinkList($MR->id, $product->id, 'task');
|
||||
$this->view->actions = $this->loadModel('action')->getList('mr', $MRID);
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter|noclosed');
|
||||
|
||||
$this->display();
|
||||
}
|
||||
|
||||
@@ -11,3 +11,10 @@
|
||||
#repoList .tree li > a {max-width: 100%;}
|
||||
#repoList .hide-in-search .hidden {display: block !important; visibility: inherit !important;}
|
||||
#repoList .tree li > a {line-height: 20px; border-radius: 2px;}
|
||||
|
||||
.c-id {width: 60px;}
|
||||
.c-title {min-width: 120px;}
|
||||
.c-branch {width: 240px;}
|
||||
.c-status {width: 100px;}
|
||||
.c-author {width: 100px;}
|
||||
.c-date {width: 140px;}
|
||||
|
||||
@@ -1 +1,2 @@
|
||||
#mrForm table tbody th {width: 145px;}
|
||||
.branch-btn {width: 110px; height: 32px; line-height: 22px; float: right;}
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
$(document).ready(function()
|
||||
{
|
||||
{
|
||||
$('#mergeButton,.mergeButton').click(function()
|
||||
{
|
||||
{
|
||||
link = $(this).attr('href');
|
||||
$.getJSON(link, function(response)
|
||||
{
|
||||
{
|
||||
if(response.result == 'success')
|
||||
{
|
||||
$.zui.messager.success(response.message);
|
||||
setTimeout(function(){ location.href=response.locate }, 2500);
|
||||
$.zui.messager.success(response.message);
|
||||
setTimeout(function(){ location.href=response.locate }, 2500);
|
||||
}
|
||||
if(response.result == 'fail') $.zui.messager.danger(response.message);
|
||||
});
|
||||
});
|
||||
return false;
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -30,6 +30,7 @@ $lang->mr->mriid = "raw MR ID";
|
||||
$lang->mr->title = 'Name';
|
||||
$lang->mr->status = 'Status';
|
||||
$lang->mr->author = 'Author';
|
||||
$lang->mr->createdDate = 'Created date';
|
||||
$lang->mr->assignee = 'Assignee';
|
||||
$lang->mr->reviewer = 'Reviewer';
|
||||
$lang->mr->mergeStatus = 'Merge status';
|
||||
|
||||
@@ -30,6 +30,7 @@ $lang->mr->mriid = "raw MR ID";
|
||||
$lang->mr->title = 'Name';
|
||||
$lang->mr->status = 'Status';
|
||||
$lang->mr->author = 'Author';
|
||||
$lang->mr->createdDate = 'Created date';
|
||||
$lang->mr->assignee = 'Assignee';
|
||||
$lang->mr->reviewer = 'Reviewer';
|
||||
$lang->mr->mergeStatus = 'Merge status';
|
||||
|
||||
@@ -30,6 +30,7 @@ $lang->mr->mriid = "raw MR ID";
|
||||
$lang->mr->title = 'Name';
|
||||
$lang->mr->status = 'Status';
|
||||
$lang->mr->author = 'Author';
|
||||
$lang->mr->createdDate = 'Created date';
|
||||
$lang->mr->assignee = 'Assignee';
|
||||
$lang->mr->reviewer = 'Reviewer';
|
||||
$lang->mr->mergeStatus = 'Merge status';
|
||||
|
||||
@@ -30,6 +30,7 @@ $lang->mr->mriid = "raw MR ID";
|
||||
$lang->mr->title = 'Name';
|
||||
$lang->mr->status = 'Status';
|
||||
$lang->mr->author = 'Author';
|
||||
$lang->mr->createdDate = 'Created date';
|
||||
$lang->mr->assignee = 'Assignee';
|
||||
$lang->mr->reviewer = 'Reviewer';
|
||||
$lang->mr->mergeStatus = 'Merge status';
|
||||
|
||||
@@ -30,6 +30,7 @@ $lang->mr->mriid = "MR原始ID";
|
||||
$lang->mr->title = '名称';
|
||||
$lang->mr->status = '状态';
|
||||
$lang->mr->author = '创建人';
|
||||
$lang->mr->createdDate = '创建时间';
|
||||
$lang->mr->assignee = '指派给';
|
||||
$lang->mr->reviewer = '评审人';
|
||||
$lang->mr->mergeStatus = '是否可合并';
|
||||
|
||||
@@ -46,14 +46,15 @@
|
||||
<thead>
|
||||
<tr class='text-left'>
|
||||
<?php $vars = "repoID=$repoID&mode=$mode¶m=$param&objectID=$objectID&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}&pageID={$pager->pageID}";?>
|
||||
<th class='w-60px'><?php common::printOrderLink('id', $orderBy, $vars, $lang->mr->id);?></th>
|
||||
<th class='c-name'><?php common::printOrderLink('title', $orderBy, $vars, $lang->mr->title);?></th>
|
||||
<th class='w-200px'><?php common::printOrderLink('sourceBranch', $orderBy, $vars, $lang->mr->sourceBranch);?></th>
|
||||
<th class='w-200px'><?php common::printOrderLink('targetBranch', $orderBy, $vars, $lang->mr->targetBranch);?></th>
|
||||
<th class='w-120px'><?php common::printOrderLink('mergeStatus', $orderBy, $vars, $lang->mr->mergeStatus);?></th>
|
||||
<th class='w-120px'><?php common::printOrderLink('approvalStatus', $orderBy, $vars, $lang->mr->approvalStatus);?></th>
|
||||
<th class='w-120px'><?php common::printOrderLink('createdBy', $orderBy, $vars, $lang->mr->author);?></th>
|
||||
<th class='c-actions-5'><?php echo $lang->actions;?></th>
|
||||
<th class='c-id'><?php common::printOrderLink('id', $orderBy, $vars, $lang->mr->id);?></th>
|
||||
<th class='c-title'><?php common::printOrderLink('title', $orderBy, $vars, $lang->mr->title);?></th>
|
||||
<th class='c-branch'><?php common::printOrderLink('sourceBranch', $orderBy, $vars, $lang->mr->sourceBranch);?></th>
|
||||
<th class='c-branch'><?php common::printOrderLink('targetBranch', $orderBy, $vars, $lang->mr->targetBranch);?></th>
|
||||
<th class='c-status'><?php common::printOrderLink('mergeStatus', $orderBy, $vars, $lang->mr->mergeStatus);?></th>
|
||||
<th class='c-status'><?php common::printOrderLink('approvalStatus', $orderBy, $vars, $lang->mr->approvalStatus);?></th>
|
||||
<th class='c-author'><?php common::printOrderLink('createdBy', $orderBy, $vars, $lang->mr->author);?></th>
|
||||
<th class='c-date'><?php common::printOrderLink('createdDate', $orderBy, $vars, $lang->mr->createdDate);?></th>
|
||||
<th class='c-actions-5 text-center'><?php echo $lang->actions;?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -87,6 +88,7 @@
|
||||
<td><?php echo empty($MR->approvalStatus) ? $lang->mr->approvalStatusList['notReviewed'] : $lang->mr->approvalStatusList[$MR->approvalStatus];?></td>
|
||||
<?php endif;?>
|
||||
<td class='text' title='<?php echo zget($users, $MR->createdBy);?>'><?php echo zget($users, $MR->createdBy);?></td>
|
||||
<td class='text' title='<?php echo zget($users, $MR->createdDate);?>'><?php echo zget($users, $MR->createdDate);?></td>
|
||||
<td class='c-actions'>
|
||||
<?php
|
||||
$canDelete = ($app->user->admin or (isset($projects[$MR->hostID][$MR->sourceProject]->owner->id) and $projects[$MR->hostID][$MR->sourceProject]->owner->id == $openIDList[$MR->hostID])) ? '' : 'disabled';
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
<td>
|
||||
<div class='input-group required'>
|
||||
<?php echo html::select('sourceProject', array(''), '', "class='form-control chosen'");?>
|
||||
<span class='input-group-addon fix-border'><?php echo $lang->mr->sourceBranch ?></span>
|
||||
<span class='input-group-addon fix-border branch-btn'><?php echo $lang->mr->sourceBranch ?></span>
|
||||
<?php echo html::select('sourceBranch', array(''), '', "class='form-control chosen'");?>
|
||||
</div>
|
||||
</td>
|
||||
@@ -42,7 +42,7 @@
|
||||
<td>
|
||||
<div class='input-group required'>
|
||||
<?php echo html::select('targetProject', array(''), '', "class='form-control chosen'");?>
|
||||
<span class='input-group-addon fix-border'><?php echo $lang->mr->targetBranch ?></span>
|
||||
<span class='input-group-addon fix-border branch-btn'><?php echo $lang->mr->targetBranch ?></span>
|
||||
<?php echo html::select('targetBranch', array(''), '', "class='form-control chosen'");?>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="mainContent" class="main-content">
|
||||
<div class="main-content">
|
||||
<div class='tabs' id='tabsNav'>
|
||||
<ul class='nav nav-tabs'>
|
||||
<li class='active'><?php echo html::a('###', $lang->mr->view);?></li>
|
||||
@@ -46,7 +46,7 @@
|
||||
<li><?php echo html::a(inlink('link', "MRID={$MR->id}&type=bug"), html::icon($lang->icons['bug'], 'text-red') . ' ' . $lang->productplan->linkedBugs);?></a></li>
|
||||
<li><?php echo html::a(inlink('link', "MRID={$MR->id}&type=task"), html::icon('todo', 'text-info') . ' ' . $lang->mr->linkedTasks);?></a></li>
|
||||
</ul>
|
||||
<div class='tab-content main-row'>
|
||||
<div class='tab-content main-row' id="mainContent">
|
||||
<div class="main-col col-8">
|
||||
<div class="cell">
|
||||
<div class="detail">
|
||||
@@ -105,6 +105,10 @@
|
||||
<div class="cell"><?php echo sprintf($lang->mr->commandDocument, $httpRepoURL, $MR->sourceBranch, $branchPath, $MR->targetBranch, $branchPath, $MR->targetBranch); ?></div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if($this->app->getViewType() != 'xhtml'):?>
|
||||
<div class="cell"><?php include '../../common/view/action.html.php';?></div>
|
||||
<?php endif;?>
|
||||
|
||||
<div class='main-actions'>
|
||||
<div class="btn-toolbar">
|
||||
<?php common::printBack(inlink('browse', '')); ?>
|
||||
|
||||
Reference in New Issue
Block a user