This commit is contained in:
Yagami
2018-09-12 16:58:22 +08:00
10 changed files with 22 additions and 19 deletions
+1
View File
@@ -23,3 +23,4 @@
#dashboard.sortable-sorting .panel.drag-shadow {box-shadow: 0 1px 3px rgba(0,0,0,.175), 0 3px 8px 0 rgba(0,0,0,.175)}
#dashboard .block-sm .hide-in-sm {display: none;}
#dashboard .block-dynamic .panel-body{overflow-x:hidden;}
+2 -2
View File
@@ -383,7 +383,7 @@ class product extends control
$this->product->setMenu($this->products, $productID);
$releases = $this->dao->select('*')->from(TABLE_RELEASE)->where('deleted')->eq(0)->andWhere('product')->eq($productID)->orderBy('date')->fetchAll();
$plans = $this->loadModel('productplan')->getList($productID, 0, 'unexpired', null, 'begin');
$this->view->title = $product->name . $this->lang->colon . $this->lang->product->view;
$this->view->position[] = html::a($this->createLink($this->moduleName, 'browse'), $product->name);
@@ -395,7 +395,7 @@ class product extends control
$this->view->lines = array('') + $this->loadModel('tree')->getLinePairs();
$this->view->branches = $this->loadModel('branch')->getPairs($productID);
$this->view->dynamics = $this->loadModel('action')->getDynamic('all', 'all', 'date_desc', $pager = null, $productID);
$this->view->releases = $releases;
$this->view->plans = $plans;
$this->display();
}
+7 -8
View File
@@ -17,21 +17,20 @@
<div class="col-sm-6">
<div class="panel block-release">
<div class="panel-heading">
<div class="panel-title"><?php echo $lang->product->plan;?> <span class="label label-badge label-light"><?php printf($lang->product->iterationInfo, count($releases));?></span></div>
<div class="panel-title"><?php echo $lang->productplan->unexpired;?> <span class="label label-badge label-light"><?php printf($lang->product->iterationInfo, count($plans));?></span></div>
</div>
<div class="panel-body">
<div class="release-path">
<ul class="release-line">
<?php $i = 0;?>
<?php foreach($releases as $release):?>
<?php foreach($plans as $plan):?>
<?php $i++;?>
<?php if($i > 6) break;?>
<li <?php if(date('Y-m-d') < $release->date) echo "class='active'";?>>
<a href="<?php echo $this->createLink('release', 'view', "releaseID={$release->id}");?>">
<?php if(!empty($release->marker)) echo "<i class='icon icon-flag text-primary'></i>";?>
<span class="title"><?php echo $release->name;?></span>
<span class="date"><?php echo $release->date;?></span>
<span class="info text-ellipsis" title="<?php echo strip_tags($release->desc);?>"><?php echo $release->desc;?></span>
<li <?php if(date('Y-m-d') < $plan->begin) echo "class='active'";?>>
<a href="<?php echo $this->createLink('plan', 'view', "planID={$plan->id}");?>">
<span class="title"><?php echo $plan->title;?></span>
<span class="date"><?php echo $plan->begin;?></span>
<span class="info text-ellipsis" title="<?php echo strip_tags($plan->desc);?>"><?php echo $plan->desc;?></span>
</a>
</li>
<?php endforeach;?>
+1
View File
@@ -33,6 +33,7 @@ $lang->productplan->unlinkBug = "Unlink Bug";
$lang->productplan->batchUnlinkBug = "Batch Unlink Bug";
$lang->productplan->linkedBugs = 'Linked Bug';
$lang->productplan->unlinkedBugs = 'Unlinked';
$lang->productplan->unexpired = 'Unexpired Plan';
$lang->productplan->confirmDelete = "Do you want to delete this Plan?";
$lang->productplan->confirmUnlinkStory = "Do you want to unlink this Story?";
+1
View File
@@ -33,6 +33,7 @@ $lang->productplan->unlinkBug = "移除Bug";
$lang->productplan->batchUnlinkBug = "批量移除Bug";
$lang->productplan->linkedBugs = 'Bug';
$lang->productplan->unlinkedBugs = '未关联Bug';
$lang->productplan->unexpired = '未过期计划';
$lang->productplan->confirmDelete = "您确认删除该计划吗?";
$lang->productplan->confirmUnlinkStory = "您确认移除该需求吗?";
+1 -1
View File
@@ -308,7 +308,7 @@ class searchModel extends model
->from(TABLE_USERQUERY)
->where('account')->eq($this->app->user->account)
->andWhere('module')->eq($module)
->orderBy('id_asc')
->orderBy('id_desc')
->fetchPairs();
if(!$queries) return array('' => $this->lang->search->myQuery);
$queries = array('' => $this->lang->search->myQuery) + $queries;
+1 -1
View File
@@ -63,7 +63,7 @@ $lang->testreport->exportNotice = "由<a href='http://www.zentao.net' target='
$lang->testreport->noReport = "报表还没有生成,请稍候查看。";
$lang->testreport->foundBugTip = "影响版本在测试轮次内,并且创建时间在测试时间范围内产生的Bug数。";
$lang->testreport->legacyBugTip = "Bug状态是激活,或Bug的解决时间在测试结束时间之后。";
$lang->testreport->fromCaseBugTip = "测试时间范围内,用例执行失败后创建的Bug";
$lang->testreport->fromCaseBugTip = "测试时间范围内,用例执行失败后创建的Bug。";
$lang->testreport->errorTrunk = "主干版本不能创建测试报告,请修改关联版本!";
$lang->testreport->moreProduct = "只能对同一个产品生成测试报告。";
+3 -2
View File
@@ -900,7 +900,7 @@ class user extends control
* @access public
* @return void
*/
public function dynamic($period = 'today', $account = '', $recTotal = 0, $direction = 'next')
public function dynamic($period = 'today', $account = '', $recTotal = 0, $date = '', $direction = 'next')
{
/* set menus. */
$this->lang->set('menugroup.user', 'company');
@@ -926,8 +926,9 @@ class user extends control
/* Append id for secend sort. */
$orderBy = $direction == 'next' ? 'date_desc' : 'date_asc';
$sort = $this->loadModel('common')->appendOrder($orderBy);
$date = empty($date) ? '' : date('Y-m-d', $date);
$actions = $this->loadModel('action')->getDynamic($account, $period, $orderBy, $pager);
$actions = $this->loadModel('action')->getDynamic($account, $period, $sort, $pager, 'all', 'all', $date, $direction);
$this->view->title = $this->lang->user->common . $this->lang->colon . $this->lang->user->dynamic;
$this->view->position[] = $this->lang->user->dynamic;
+4 -4
View File
@@ -75,14 +75,14 @@ $firstDate = date('Y-m-d', strtotime($firstAction->originalDate) + 24 * 3600);
$lastDate = substr($action->originalDate, 0, 10);
$hasPre = $this->action->hasPreOrNext($firstDate, 'pre');
$hasNext = $this->action->hasPreOrNext($lastDate, 'next');
$preLink = $hasPre ? inlink('dynamic', "type=$type&recTotal={$pager->recTotal}&date=" . strtotime($firstDate) . '&direction=pre') : 'javascript:;';
$nextLink = $hasNext ? inlink('dynamic', "type=$type&recTotal={$pager->recTotal}&date=" . strtotime($lastDate) . '&direction=next') : 'javascript:;';
$preLink = $hasPre ? inlink('dynamic', "type=$type&account=$account&recTotal={$pager->recTotal}&date=" . strtotime($firstDate) . '&direction=pre') : 'javascript:;';
$nextLink = $hasNext ? inlink('dynamic', "type=$type&account=$account&recTotal={$pager->recTotal}&date=" . strtotime($lastDate) . '&direction=next') : 'javascript:;';
?>
<?php if($hasPre or $hasNext):?>
<div id="mainActions">
<nav class="container">
<a id="prevPage" class="btn btn-info<?php if(!$hasPre) echo ' disabled';?>" href="<?php echo $preLink;?>"><i class="icon icon-chevron-left"></i></a>
<a id="nextPage" class="btn btn-info<?php if(!$hasNext) echo ' disabled';?>" href="<?php echo $nextLink;?>"><i class="icon icon-chevron-right"></i></a>
<a id="prevPage" class="btn btn-info<?php if(!$hasNext) echo ' disabled';?>" href="<?php echo $nextLink;?>"><i class="icon icon-chevron-left"></i></a>
<a id="nextPage" class="btn btn-info<?php if(!$hasPre) echo ' disabled';?>" href="<?php echo $preLink;?>"><i class="icon icon-chevron-right"></i></a>
</nav>
</div>
<?php endif;?>
+1 -1
View File
@@ -760,5 +760,5 @@ $(document).ready(function()
checkTutorial();
revertModuleCookie();
$(document).on('click', '#helpMenuItem .close-help-tab', function(){$('#helpMenuItem').remove();});
$(document).on('click', '#helpMenuItem .close-help-tab', function(){$('#helpMenuItem').prev().remove();$('#helpMenuItem').remove();});
});