* Finish task #40518,#40519.
This commit is contained in:
@@ -187,6 +187,7 @@ $filter->project->default->cookie['lastProject'] = 'int';
|
||||
$filter->project->default->cookie['lastPRJ'] = 'int';
|
||||
$filter->project->default->cookie['projectMode'] = 'code';
|
||||
$filter->project->browse->cookie['involved'] = 'code';
|
||||
$filter->project->browse->cookie['projectType'] = 'code';
|
||||
$filter->project->story->cookie['storyModuleParam'] = 'int';
|
||||
$filter->project->story->cookie['storyPreProjectID'] = 'int';
|
||||
$filter->project->story->cookie['storyProductParam'] = 'int';
|
||||
|
||||
@@ -891,7 +891,7 @@ class programModel extends model
|
||||
$project->hours = isset($hours[$project->id]) ? $hours[$project->id] : (object)$emptyHour;
|
||||
|
||||
$project->teamCount = isset($teams[$project->id]) ? $teams[$project->id]->teams : 0;
|
||||
$stats[] = $project;
|
||||
$stats[$key] = $project;
|
||||
}
|
||||
return $stats;
|
||||
}
|
||||
|
||||
@@ -216,6 +216,8 @@ class project extends control
|
||||
$this->loadModel('execution');
|
||||
$this->session->set('projectList', $this->app->getURI(true), 'project');
|
||||
|
||||
$projectType = $this->cookie->projectType ? $this->cookie->projectType : 'bylist';
|
||||
|
||||
/* Load pager and get tasks. */
|
||||
$this->app->loadClass('pager', $static = true);
|
||||
$pager = new pager($recTotal, $recPerPage, $pageID);
|
||||
@@ -232,10 +234,15 @@ class project extends control
|
||||
$this->view->programID = $programID;
|
||||
$this->view->program = $this->program->getByID($programID);
|
||||
$this->view->programTree = $this->project->getTreeMenu(0, array('projectmodel', 'createManageLink'), 0, 'list');
|
||||
$this->view->programs = array('0' => '') + $this->program->getParentPairs();
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter|pofirst|nodeleted');
|
||||
$this->view->browseType = $browseType;
|
||||
$this->view->projectType = $projectType;
|
||||
$this->view->param = $param;
|
||||
$this->view->orderBy = $orderBy;
|
||||
$this->view->recTotal = $recTotal;
|
||||
$this->view->recPerPage = $recPerPage;
|
||||
$this->view->pageID = $pageID;
|
||||
|
||||
$this->display();
|
||||
}
|
||||
|
||||
@@ -5,3 +5,4 @@
|
||||
th.c-budget,{text-align:right;}
|
||||
td.c-actions {overflow: visible;}
|
||||
.c-actions .btn {overflow: visible;}
|
||||
#programBox {float: left; margin-right: 10px;}
|
||||
|
||||
@@ -6,6 +6,26 @@ $(function()
|
||||
$.cookie('involved', involved, {expires:config.cookieLife, path:config.webRoot});
|
||||
window.location.reload();
|
||||
});
|
||||
|
||||
$('[id="switchButton"]').click(function()
|
||||
{
|
||||
var projectType = $(this).attr('data-type');
|
||||
$.cookie('projectType', projectType, {expires:config.cookieLife, path:config.webRoot});
|
||||
window.location.reload();
|
||||
});
|
||||
});
|
||||
|
||||
/**
|
||||
* Change program.
|
||||
*
|
||||
* @param int $programID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function changeProgram(programID)
|
||||
{
|
||||
link = createLink('project', 'browse', 'programID=' + programID + '&browseType=' + browseType + '¶m=' + param + '&orderBy=order_asc&recTotal=' + recTotal + '&recPerPage=' + recPerPage + '&pageID=' + pageID);
|
||||
location.href = link;
|
||||
}
|
||||
|
||||
$(".tree #program" + programID).parent('li').addClass('active');
|
||||
|
||||
@@ -48,6 +48,8 @@ $lang->project->copyNoProject = 'There are no items available to copy.';
|
||||
$lang->project->searchByName = 'Enter the project name to search';
|
||||
$lang->project->linkedProducts = "Linked {$lang->productCommon}s";
|
||||
$lang->project->unlinkedProducts = "Unlinked {$lang->productCommon}s";
|
||||
$lang->project->testreport = 'Testreport';
|
||||
$lang->project->selectProgram = 'Select Program';
|
||||
|
||||
/* Fields. */
|
||||
$lang->project->common = 'Program';
|
||||
@@ -74,6 +76,7 @@ $lang->project->realEnd = 'Actual End';
|
||||
$lang->project->realBegan = 'Actual Began';
|
||||
$lang->project->bygrid = 'Kanban';
|
||||
$lang->project->bylist = 'List';
|
||||
$lang->project->bycard = 'Card';
|
||||
$lang->project->mine = 'My';
|
||||
$lang->project->myProject = 'Meine Zuständigkeit';
|
||||
$lang->project->other = 'Andere';
|
||||
|
||||
@@ -50,6 +50,8 @@ $lang->project->deleted = 'Deleted';
|
||||
$lang->project->linkedProducts = "Linked {$lang->productCommon}s";
|
||||
$lang->project->unlinkedProducts = "Unlinked {$lang->productCommon}s";
|
||||
$lang->project->testreport = 'Test Report';
|
||||
$lang->project->testreport = 'Testreport';
|
||||
$lang->project->selectProgram = 'Select Program';
|
||||
|
||||
/* Fields. */
|
||||
$lang->project->common = 'Project';
|
||||
@@ -75,6 +77,7 @@ $lang->project->realEnd = 'Actual End';
|
||||
$lang->project->realBegan = 'Actual Began';
|
||||
$lang->project->bygrid = 'Kanban';
|
||||
$lang->project->bylist = 'List';
|
||||
$lang->project->bycard = 'Card';
|
||||
$lang->project->mine = 'My';
|
||||
$lang->project->myProject = 'Mine';
|
||||
$lang->project->other = 'Others';
|
||||
|
||||
@@ -48,6 +48,8 @@ $lang->project->copyNoProject = 'There are no items available to copy.';
|
||||
$lang->project->searchByName = 'Enter the project name to retrieve';
|
||||
$lang->project->linkedProducts = "Linked {$lang->productCommon}s";
|
||||
$lang->project->unlinkedProducts = "Unlinked {$lang->productCommon}s";
|
||||
$lang->project->testreport = 'Testreport';
|
||||
$lang->project->selectProgram = 'Select Program';
|
||||
|
||||
/* Fields. */
|
||||
$lang->project->common = 'Project';
|
||||
@@ -74,6 +76,7 @@ $lang->project->realEnd = 'Actual End';
|
||||
$lang->project->realBegan = 'Actual Began';
|
||||
$lang->project->bygrid = 'Kanban';
|
||||
$lang->project->bylist = 'List';
|
||||
$lang->project->bycard = 'Card';
|
||||
$lang->project->mine = 'My';
|
||||
$lang->project->myProject = 'Mine';
|
||||
$lang->project->other = 'Others';
|
||||
|
||||
@@ -48,6 +48,8 @@ $lang->project->copyNoProject = 'There are no items available to copy.';
|
||||
$lang->project->searchByName = 'Enter the project name to retrieve';
|
||||
$lang->project->linkedProducts = "Linked {$lang->productCommon}s";
|
||||
$lang->project->unlinkedProducts = "Unlinked {$lang->productCommon}s";
|
||||
$lang->project->testreport = 'Testreport';
|
||||
$lang->project->selectProgram = 'Select Program';
|
||||
|
||||
/* Fields. */
|
||||
$lang->project->common = 'Project';
|
||||
@@ -74,6 +76,7 @@ $lang->project->realEnd = 'Actual End';
|
||||
$lang->project->realBegan = 'Actual Began';
|
||||
$lang->project->bygrid = 'Kanban';
|
||||
$lang->project->bylist = 'List';
|
||||
$lang->project->bycard = 'Card';
|
||||
$lang->project->mine = 'My';
|
||||
$lang->project->myProject = 'Mine';
|
||||
$lang->project->other = 'Others';
|
||||
|
||||
@@ -50,6 +50,7 @@ $lang->project->deleted = '已删除';
|
||||
$lang->project->linkedProducts = '已关联';
|
||||
$lang->project->unlinkedProducts = '未关联';
|
||||
$lang->project->testreport = '测试报告';
|
||||
$lang->project->selectProgram = '筛选项目集';
|
||||
|
||||
/* Fields. */
|
||||
$lang->project->common = '项目';
|
||||
@@ -75,6 +76,7 @@ $lang->project->realEnd = '实际完成日期';
|
||||
$lang->project->realBegan = '实际开始日期';
|
||||
$lang->project->bygrid = '看板';
|
||||
$lang->project->bylist = '列表';
|
||||
$lang->project->bycard = '卡片';
|
||||
$lang->project->mine = '我参与的';
|
||||
$lang->project->myProject = '我负责';
|
||||
$lang->project->other = '其他';
|
||||
|
||||
@@ -15,115 +15,20 @@
|
||||
js::set('orderBy', $orderBy);
|
||||
js::set('programID', $programID);
|
||||
js::set('browseType', $browseType);
|
||||
js::set('param', $param);
|
||||
js::set('orderBy', $orderBy);
|
||||
js::set('recTotal', $recTotal);
|
||||
js::set('recPerPage', $recPerPage);
|
||||
js::set('pageID', $pageID);
|
||||
?>
|
||||
<?php
|
||||
if($projectType == 'bycard')
|
||||
{
|
||||
include 'browsebycard.html.php';
|
||||
}
|
||||
else
|
||||
{
|
||||
include 'browsebylist.html.php';
|
||||
}
|
||||
?>
|
||||
<style>
|
||||
.project-type-label.label-outline {width: 50px; min-width: 50px;}
|
||||
.project-type-label.label {overflow: unset !important; text-overflow: unset !important; white-space: unset !important;}
|
||||
</style>
|
||||
<div id="mainMenu" class="clearfix">
|
||||
<?php if($this->config->systemMode == 'new'):?>
|
||||
<div id="sidebarHeader">
|
||||
<div class="title">
|
||||
<?php echo $programID ? $program->name : $lang->project->parent;?>
|
||||
<?php if($programID) echo html::a(inLink('browse', 'programID=0'), "<i class='icon icon-sm icon-close'></i>", '', 'class="text-muted"');?>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
<div class="btn-toolBar pull-left">
|
||||
<?php foreach($lang->project->featureBar as $key => $label):?>
|
||||
<?php $active = $browseType == $key ? 'btn-active-text' : '';?>
|
||||
<?php $label = "<span class='text'>$label</span>";?>
|
||||
<?php if($browseType == $key) $label .= " <span class='label label-light label-badge'>{$pager->recTotal}</span>";?>
|
||||
<?php echo html::a(inlink('browse', "programID=$programID&browseType=$key"), $label, '', "class='btn btn-link $active'");?>
|
||||
<?php endforeach;?>
|
||||
<?php echo html::checkbox('involved', array('1' => $lang->project->mine), '', $this->cookie->involved ? 'checked=checked' : '');?>
|
||||
</div>
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php if(isset($this->config->maxVersion)):?>
|
||||
<?php common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-primary" data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php elseif($this->config->systemMode == 'new'):?>
|
||||
<?php common::printLink('project', 'create', 'mode=scrum', '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-primary"');?>
|
||||
<?php else:?>
|
||||
<?php common::printLink('execution', 'create', '', '<i class="icon icon-plus"></i>' . $lang->execution->create, '', 'class="btn btn-primary"');?>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
<div id='mainContent' class="main-row fade">
|
||||
<?php if($this->config->systemMode == 'new'):?>
|
||||
<div id="sidebar" class="side-col">
|
||||
<div class="sidebar-toggle"><i class="icon icon-angle-left"></i></div>
|
||||
<div class="cell">
|
||||
<?php echo $programTree;?>
|
||||
<div class="text-center">
|
||||
<?php common::printLink('project', 'programTitle', '', $lang->project->moduleSetting, '', "class='btn btn-info btn-wide iframe'", true, true);?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
<div class="main-col">
|
||||
<?php if(empty($projectStats)):?>
|
||||
<div class="table-empty-tip">
|
||||
<p>
|
||||
<span class="text-muted"><?php echo $lang->project->empty;?></span>
|
||||
<?php if(isset($this->config->maxVersion)):?>
|
||||
<?php common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-info" data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php elseif($this->config->systemMode == 'new'):?>
|
||||
<?php common::printLink('project', 'create', 'mode=scrum', '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-info"');?>
|
||||
<?php else:?>
|
||||
<?php common::printLink('execution', 'create', '', '<i class="icon icon-plus"></i>' . $lang->execution->create, '', 'class="btn btn-info"');?>
|
||||
<?php endif;?>
|
||||
</p>
|
||||
</div>
|
||||
<?php else:?>
|
||||
<form class='main-table' id='projectForm' method='post' data-ride="table">
|
||||
<div class="table-header fixed-right">
|
||||
<nav class="btn-toolbar pull-right"></nav>
|
||||
</div>
|
||||
<?php
|
||||
$vars = "programID=$programID&browseType=$browseType¶m=$param&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}&pageID={$pager->pageID}";
|
||||
$setting = $this->datatable->getSetting('project');
|
||||
?>
|
||||
<table class='table has-sort-head'>
|
||||
<?php $canBatchEdit = $this->config->systemMode == 'new' ? common::hasPriv('project', 'batchEdit') : common::hasPriv('project', 'batchEdit');?>
|
||||
<thead>
|
||||
<tr>
|
||||
<?php
|
||||
foreach($setting as $value)
|
||||
{
|
||||
if($value->id == 'status' and $browseType !== 'all') $value->show = false;
|
||||
if($value->id == 'teamCount' and $browseType == 'all') $value->show = false;
|
||||
if($value->show) $this->datatable->printHead($value, $orderBy, $vars, $canBatchEdit);
|
||||
}
|
||||
?>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="sortable" id='projectTableList'>
|
||||
<?php foreach($projectStats as $project):?>
|
||||
<?php $project->from = 'project';?>
|
||||
<tr data-id="<?php echo $project->id;?>">
|
||||
<?php foreach($setting as $value) $this->project->printCell($value, $project, $users, $programID);?>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class='table-footer'>
|
||||
<?php if($canBatchEdit):?>
|
||||
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
|
||||
<?php endif;?>
|
||||
<div class="table-actions btn-toolbar">
|
||||
<?php
|
||||
if($canBatchEdit)
|
||||
{
|
||||
$actionLink = $this->config->systemMode == 'new' ? $this->createLink('project', 'batchEdit', 'from=prjbrowse') : $this->createLink('project', 'batchEdit');
|
||||
$misc = "data-form-action='$actionLink'";
|
||||
echo html::commonButton($lang->edit, $misc);
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<?php $pager->show('right', 'pagerjs');?>
|
||||
</div>
|
||||
</form>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
@@ -0,0 +1,92 @@
|
||||
<?php
|
||||
/**
|
||||
* The browsebycard view file of project module of ZenTaoPMS.
|
||||
*
|
||||
* @copyright Copyright 2009-2021 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com)
|
||||
* @license ZPL (http://zpl.pub/page/zplv12.html)
|
||||
* @author Shujie Tian <tianshujie@easycorp.ltd>
|
||||
* @package project
|
||||
* @version $Id: browsebycard.html.php 4769 2021-07-23 11:29:21Z $
|
||||
* @link https://www.zentao.net
|
||||
*/
|
||||
?>
|
||||
<div id="mainMenu" class="clearfix table-row">
|
||||
<div class="btn-toolBar pull-left">
|
||||
<?php if($this->config->systemMode == 'new'):?>
|
||||
<div class="input-control space w-150px" id='programBox'><?php echo html::select('programID', $programs, $programID, "onchange=changeProgram(this.value) class='form-control chosen' data-placeholder='{$lang->project->selectProgram}'");?></div>
|
||||
<?php endif;?>
|
||||
<?php foreach($lang->project->featureBar as $key => $label):?>
|
||||
<?php $active = $browseType == $key ? 'btn-active-text' : '';?>
|
||||
<?php $label = "<span class='text'>$label</span>";?>
|
||||
<?php if($browseType == $key) $label .= " <span class='label label-light label-badge'>{$pager->recTotal}</span>";?>
|
||||
<?php echo html::a(inlink('browse', "programID=$programID&browseType=$key"), $label, '', "class='btn btn-link $active'");?>
|
||||
<?php endforeach;?>
|
||||
<?php echo html::checkbox('involved', array('1' => $lang->project->mine), '', $this->cookie->involved ? 'checked=checked' : '');?>
|
||||
</div>
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php echo html::a('#',"<i class='icon-list'></i> ", '', "class='btn btn-link' title='{$lang->project->bylist}' id='switchButton' data-type='bylist'");?>
|
||||
<?php if(isset($this->config->maxVersion)):?>
|
||||
<?php common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-primary" data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php elseif($this->config->systemMode == 'new'):?>
|
||||
<?php common::printLink('project', 'create', 'mode=scrum', '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-primary"');?>
|
||||
<?php else:?>
|
||||
<?php common::printLink('execution', 'create', '', '<i class="icon icon-plus"></i>' . $lang->execution->create, '', 'class="btn btn-primary"');?>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
<div class='row cell' id='cards'>
|
||||
<?php foreach ($projectStats as $projectID => $project):?>
|
||||
<div class='col' data-id='<?php echo $projectID?>'>
|
||||
<div class='panel'>
|
||||
<div class='panel-heading'>
|
||||
<?php if(isset($config->maxVersion) and $project->model === 'waterfall'):?>
|
||||
<span class='project-type-label label label-warning label-outline'><i class='icon icon-waterfall'></i></span>
|
||||
<?php elseif(isset($config->maxVersion)):?>
|
||||
<span class='project-type-label label label-info label-outline'><i class='icon icon-sprint'></i></span>
|
||||
<?php endif;?>
|
||||
<strong class='project-name' title='<?php echo $project->name;?>'><?php echo html::a(helper::createLink('project', 'index', "projectID=$projectID"), $project->name);?></strong>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php endforeach;?>
|
||||
<div class='col-xs-12' id='cardsFooter'>
|
||||
<?php $pager->show('right', 'pagerjs');?>
|
||||
</div>
|
||||
</div>
|
||||
<style>
|
||||
#mainMenu {padding-left: 10px; padding-right: 10px; margin-bottom: -10px;}
|
||||
#cards {margin: 0 0;}
|
||||
#cards > .col {width: 25%;}
|
||||
#cards .panel {margin: 10px 0; border: 1px solid #DCDCDC; border-radius: 2px; box-shadow: none; height: 146px; cursor: pointer;}
|
||||
#cards .pager .btn {padding-top: 4px;}
|
||||
#cards .panel:hover {border-color: #006AF1; box-shadow: 0 0 10px 0 rgba(0,0,100,.25);}
|
||||
#cards .panel-heading {padding: 12px 24px 10px 16px;}
|
||||
#cards .panel-body {padding: 0 16px 16px;}
|
||||
#cards .panel-actions {padding: 7px 0;}
|
||||
#cards .panel-actions .dropdown-menu > li > a {padding-left: 5px; text-align: left;}
|
||||
#cards .panel-actions .dropdown-menu > li > a > i {opacity: .5; display: inline-block; margin-right: 4px; width: 18px; text-align: center;}
|
||||
#cards .panel-actions .dropdown-menu > li > a:hover > i {opacity: 1;}
|
||||
#cards .project-type-label {padding: 1px 2px;}
|
||||
#cards .icon {font-size: 8px;}
|
||||
#cards .project-name {font-size: 14px; display: inline-block; max-width: 80%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle;}
|
||||
#cards .project-infos {font-size: 12px;}
|
||||
#cards .project-infos > span {display: inline-block; line-height: 12px;}
|
||||
#cards .program-infos > span > .icon {font-size: 12px; display: inline-block; position: relative; top: -1px}
|
||||
#cards .program-infos > span + span {margin-left: 15px;}
|
||||
#cards .program-detail {position: absolute; bottom: 16px; left: 16px; right: 16px; font-size: 12px;}
|
||||
#cards .program-detail > p {margin-bottom: 8px;}
|
||||
#cards .program-detail .progress {height: 4px;}
|
||||
#cards .program-detail .progress-text-left .progress-text {width: 50px; left: -50px;}
|
||||
#cards .pager {margin: 0; float: right;}
|
||||
#cards .pager .btn {border: none}
|
||||
#cards .program-stages-container {margin: 0 -16px -16px -16px; padding: 0 4px; height: 46px; overflow-x: auto; position: relative;}
|
||||
#cards .program-stages:after {content: ' '; width: 30px; display: block; right: -16px; top: 16px; bottom: -6px; z-index: 1; background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,1) 100%); position: absolute;}
|
||||
#cards .program-stages-row {position: relative; height: 30px; z-index: 0;}
|
||||
#cards .program-stage-item {white-space: nowrap; position: absolute; top: 0; min-width: 48px; padding-top: 13px; color: #838A9D;}
|
||||
#cards .program-stage-item > div {white-space: nowrap; overflow: visible; text-align: center; text-overflow: ellipsis;}
|
||||
#cards .program-stage-item:before {content: ' '; display: block; width: 8px; height: 8px; border-radius: 50%; background: #D1D1D1; position: absolute; left: 50%; margin-left: -4px; top: 0; z-index: 1;}
|
||||
#cards .program-stage-item + .program-stage-item:after {content: ' '; display: block; left: -50%; right: 50%; height: 2px; background-color: #D1D1D1; top: 3px; position: absolute; z-index: 0;}
|
||||
#cards .program-stage-item.is-going {color: #333;}
|
||||
#cards .program-stage-item.is-going::before {background-color: #0C64EB;}
|
||||
.chosen-drop.chosen-auto-max-width.in {width: 150px !important;}
|
||||
</style>
|
||||
@@ -0,0 +1,123 @@
|
||||
<?php
|
||||
/**
|
||||
* The browsebylist view file of project module of ZenTaoPMS.
|
||||
*
|
||||
* @copyright Copyright 2009-2021 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com)
|
||||
* @license ZPL (http://zpl.pub/page/zplv12.html)
|
||||
* @author Shujie Tian <tianshujie@easycorp.ltd>
|
||||
* @package project
|
||||
* @version $Id: browsebylist.html.php 4769 2021-07-23 11:16:21Z $
|
||||
* @link https://www.zentao.net
|
||||
*/
|
||||
?>
|
||||
<style>
|
||||
.project-type-label.label-outline {width: 50px; min-width: 50px;}
|
||||
.project-type-label.label {overflow: unset !important; text-overflow: unset !important; white-space: unset !important;}
|
||||
</style>
|
||||
<div id="mainMenu" class="clearfix">
|
||||
<?php if($this->config->systemMode == 'new'):?>
|
||||
<div id="sidebarHeader">
|
||||
<div class="title">
|
||||
<?php echo $programID ? $program->name : $lang->project->parent;?>
|
||||
<?php if($programID) echo html::a(inLink('browse', 'programID=0'), "<i class='icon icon-sm icon-close'></i>", '', 'class="text-muted"');?>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
<div class="btn-toolBar pull-left">
|
||||
<?php foreach($lang->project->featureBar as $key => $label):?>
|
||||
<?php $active = $browseType == $key ? 'btn-active-text' : '';?>
|
||||
<?php $label = "<span class='text'>$label</span>";?>
|
||||
<?php if($browseType == $key) $label .= " <span class='label label-light label-badge'>{$pager->recTotal}</span>";?>
|
||||
<?php echo html::a(inlink('browse', "programID=$programID&browseType=$key"), $label, '', "class='btn btn-link $active'");?>
|
||||
<?php endforeach;?>
|
||||
<?php echo html::checkbox('involved', array('1' => $lang->project->mine), '', $this->cookie->involved ? 'checked=checked' : '');?>
|
||||
</div>
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php echo html::a('#',"<i class='icon-cards-view'></i> ", '', "class='btn btn-link' title='{$lang->project->bycard}' id='switchButton' data-type='bycard'");?>
|
||||
<?php if(isset($this->config->maxVersion)):?>
|
||||
<?php common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-primary" data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php elseif($this->config->systemMode == 'new'):?>
|
||||
<?php common::printLink('project', 'create', 'mode=scrum', '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-primary"');?>
|
||||
<?php else:?>
|
||||
<?php common::printLink('execution', 'create', '', '<i class="icon icon-plus"></i>' . $lang->execution->create, '', 'class="btn btn-primary"');?>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
<div id='mainContent' class="main-row fade">
|
||||
<?php if($this->config->systemMode == 'new'):?>
|
||||
<div id="sidebar" class="side-col">
|
||||
<div class="sidebar-toggle"><i class="icon icon-angle-left"></i></div>
|
||||
<div class="cell">
|
||||
<?php echo $programTree;?>
|
||||
<div class="text-center">
|
||||
<?php common::printLink('project', 'programTitle', '', $lang->project->moduleSetting, '', "class='btn btn-info btn-wide iframe'", true, true);?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
<div class="main-col">
|
||||
<?php if(empty($projectStats)):?>
|
||||
<div class="table-empty-tip">
|
||||
<p>
|
||||
<span class="text-muted"><?php echo $lang->project->empty;?></span>
|
||||
<?php if(isset($this->config->maxVersion)):?>
|
||||
<?php common::printLink('project', 'createGuide', "programID=$programID", '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-info" data-toggle="modal" data-target="#guideDialog"');?>
|
||||
<?php elseif($this->config->systemMode == 'new'):?>
|
||||
<?php common::printLink('project', 'create', 'mode=scrum', '<i class="icon icon-plus"></i>' . $lang->project->create, '', 'class="btn btn-info"');?>
|
||||
<?php else:?>
|
||||
<?php common::printLink('execution', 'create', '', '<i class="icon icon-plus"></i>' . $lang->execution->create, '', 'class="btn btn-info"');?>
|
||||
<?php endif;?>
|
||||
</p>
|
||||
</div>
|
||||
<?php else:?>
|
||||
<form class='main-table' id='projectForm' method='post' data-ride="table">
|
||||
<div class="table-header fixed-right">
|
||||
<nav class="btn-toolbar pull-right"></nav>
|
||||
</div>
|
||||
<?php
|
||||
$vars = "programID=$programID&browseType=$browseType¶m=$param&orderBy=%s&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}&pageID={$pager->pageID}";
|
||||
$setting = $this->datatable->getSetting('project');
|
||||
?>
|
||||
<table class='table has-sort-head'>
|
||||
<?php $canBatchEdit = $this->config->systemMode == 'new' ? common::hasPriv('project', 'batchEdit') : common::hasPriv('project', 'batchEdit');?>
|
||||
<thead>
|
||||
<tr>
|
||||
<?php
|
||||
foreach($setting as $value)
|
||||
{
|
||||
if($value->id == 'status' and $browseType !== 'all') $value->show = false;
|
||||
if($value->id == 'teamCount' and $browseType == 'all') $value->show = false;
|
||||
if($value->show) $this->datatable->printHead($value, $orderBy, $vars, $canBatchEdit);
|
||||
}
|
||||
?>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="sortable" id='projectTableList'>
|
||||
<?php foreach($projectStats as $project):?>
|
||||
<?php $project->from = 'project';?>
|
||||
<tr data-id="<?php echo $project->id;?>">
|
||||
<?php foreach($setting as $value) $this->project->printCell($value, $project, $users, $programID);?>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class='table-footer'>
|
||||
<?php if($canBatchEdit):?>
|
||||
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
|
||||
<?php endif;?>
|
||||
<div class="table-actions btn-toolbar">
|
||||
<?php
|
||||
if($canBatchEdit)
|
||||
{
|
||||
$actionLink = $this->config->systemMode == 'new' ? $this->createLink('project', 'batchEdit', 'from=prjbrowse') : $this->createLink('project', 'batchEdit');
|
||||
$misc = "data-form-action='$actionLink'";
|
||||
echo html::commonButton($lang->edit, $misc);
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<?php $pager->show('right', 'pagerjs');?>
|
||||
</div>
|
||||
</form>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user