This commit is contained in:
Yagami
2018-09-07 10:19:31 +08:00
49 changed files with 309 additions and 227 deletions
+20 -48
View File
@@ -741,29 +741,20 @@ class block extends control
if(!empty($this->params->type) and preg_match('/[^a-zA-Z0-9_]/', $this->params->type)) die();
$status = isset($this->params->type) ? $this->params->type : '';
$orderBy = isset($this->params->orderBy) ? $this->params->orderBy : 'id_asc';
/* Get products. */
$products = $this->loadModel('product')->getList($status);
foreach($products as $productID => $product)
{
if(!$this->product->checkPriv($product)) unset($products[$productID]);
}
$productIDList = array_keys($products);
if(!$productIDList)
$products = $this->block->getProductsLikeDropMenu($status);
$productIdList = array_keys($products);
if(empty($products))
{
$this->view->products = $products;
return false;
}
$products = $this->dao->select('*')->from(TABLE_PRODUCT)
->where('id')->in($productIDList)
->orderBy($orderBy)
->fetchAll('id');
/* Get stories. */
$stories = $this->dao->select('product, stage, COUNT(status) AS count')->from(TABLE_STORY)
->where('deleted')->eq(0)
->andWhere('product')->in($productIDList)
->andWhere('product')->in($productIdList)
->groupBy('product, stage')
->fetchGroup('product', 'stage');
/* Padding the stories to sure all status have records. */
@@ -779,7 +770,7 @@ class block extends control
/* Get plans. */
$plans = $this->dao->select('product, end')->from(TABLE_PRODUCTPLAN)
->where('deleted')->eq(0)
->andWhere('product')->in($productIDList)
->andWhere('product')->in($productIdList)
->fetchGroup('product');
foreach($plans as $product => $productPlans)
{
@@ -802,7 +793,7 @@ class block extends control
/* Get projects. */
$projects = $this->dao->select('t1.product, t2.status, t2.end')->from(TABLE_PROJECTPRODUCT)->alias('t1')
->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project=t2.id')
->where('t1.product')->in($productIDList)
->where('t1.product')->in($productIdList)
->andWhere('t2.deleted')->eq(0)
->fetchGroup('product');
foreach($projects as $product => $productProjects)
@@ -829,7 +820,7 @@ class block extends control
/* Get releases. */
$releases = $this->dao->select('product, status, COUNT(*) AS count')->from(TABLE_RELEASE)
->where('deleted')->eq(0)
->andWhere('product')->in($productIDList)
->andWhere('product')->in($productIdList)
->groupBy('product, status')
->fetchGroup('product', 'status');
foreach($releases as $product => $release)
@@ -843,7 +834,7 @@ class block extends control
/* Get last releases. */
$lastReleases = $this->dao->select('product, COUNT(*) AS count')->from(TABLE_RELEASE)
->where('date')->eq(date('Y-m-d', strtotime('-1 day')))
->andWhere('product')->in($productIDList)
->andWhere('product')->in($productIdList)
->groupBy('product')
->fetchPairs();
@@ -879,33 +870,23 @@ class block extends control
$this->app->loadLang('bug');
$status = isset($this->params->type) ? $this->params->type : '';
$orderBy = isset($this->params->orderBy) ? $this->params->orderBy : 'id_asc';
$num = isset($this->params->num) ? (int)$this->params->num : 0;
/* Get projects. */
$projects = $this->loadModel('project')->getList($status);
foreach($projects as $projectID => $project)
{
if(!$this->project->checkPriv($project)) unset($projects[$projectID]);
}
$projectIDList = array_keys($projects);
if(!$projectIDList)
$projects = $this->block->getProjectsLikeDropMenu($status);
if(empty($projects))
{
$this->view->projects = $projects;
return false;
}
$projects = $this->dao->select('*')->from(TABLE_PROJECT)
->where('id')->in($projectIDList)
->orderBy($orderBy)
->beginIF($this->viewType != 'json')->limit($num)->fi()
->fetchAll('id');
$projectIDList = array_keys($projects);
$projectIdList = array_keys($projects);
/* Get tasks. */
$yesterday = date('Y-m-d', strtotime('-1 day'));
$tasks = $this->dao->select("project, count(id) as totalTasks, count(status in ('wait','doing','pause') or null) as undoneTasks, count(finishedDate like '{$yesterday}%' or null) as yesterdayFinished, sum(if(status != 'cancel', estimate, 0)) as totalEstimate, sum(consumed) as totalConsumed, sum(if(status != 'cancel', `left`, 0)) as totalLeft")->from(TABLE_TASK)
->where('project')->in($projectIDList)
->where('project')->in($projectIdList)
->andWhere('deleted')->eq(0)
->andWhere('parent')->eq(0)
->groupBy('project')
@@ -923,7 +904,7 @@ class block extends control
/* Get stories. */
$stories = $this->dao->select("t1.project, count(t2.status) as totalStories, count(t2.status != 'closed' or null) as unclosedStories, count(t2.stage = 'released' or null) as releasedStories")->from(TABLE_PROJECTSTORY)->alias('t1')
->leftJoin(TABLE_STORY)->alias('t2')->on('t1.story = t2.id')
->where('t1.project')->in($projectIDList)
->where('t1.project')->in($projectIdList)
->andWhere('t2.deleted')->eq(0)
->groupBy('project')
->fetchAll('project');
@@ -939,7 +920,7 @@ class block extends control
/* Get bugs. */
$bugs = $this->dao->select("project, status, count(status) as totalBugs, count(status = 'active' or null) as activeBugs, count(resolvedDate like '{$yesterday}%' or null) as yesterdayResolved")->from(TABLE_BUG)
->where('project')->in($projectIDList)
->where('project')->in($projectIdList)
->andWhere('deleted')->eq(0)
->groupBy('project')
->fetchAll('project');
@@ -997,24 +978,15 @@ class block extends control
if(!empty($this->params->type) and preg_match('/[^a-zA-Z0-9_]/', $this->params->type)) die();
$status = isset($this->params->type) ? $this->params->type : '';
$orderBy = isset($this->params->orderBy) ? $this->params->orderBy : 'id_asc';
/* Get products. */
$products = $this->loadModel('product')->getList($status);
foreach($products as $productID => $product)
{
if(!$this->product->checkPriv($product)) unset($products[$productID]);
}
$productIDList = array_keys($products);
if(!$productIDList)
$products = $this->block->getProductsLikeDropMenu($status);
$productIdList = array_keys($products);
if(empty($products))
{
$this->view->products = $products;
return false;
}
$products = $this->dao->select('*')->from(TABLE_PRODUCT)
->where('id')->in($productIDList)
->orderBy($orderBy)
->fetchAll('id');
$testedBuilds = $this->dao->select('build')->from(TABLE_TESTTASK)->where('product')->in(array_keys($products))->andWhere('project')->ne(0)->andWhere('deleted')->eq(0)->fetchPairs();
$builds = $this->dao->select('id, product, name, bugs')->from(TABLE_BUILD)->where('id')->in($testedBuilds)->andWhere('deleted')->eq(0)->fetchGroup('product', 'id');
+84 -15
View File
@@ -471,11 +471,6 @@ class blockModel extends model
$params->type['options'] = $this->lang->block->typeList->product;
$params->type['control'] = 'select';
$params->orderBy['name'] = $this->lang->block->orderBy;
$params->orderBy['default'] = 'id_desc';
$params->orderBy['options'] = $this->lang->block->orderByList->product;
$params->orderBy['control'] = 'select';
return json_encode($params);
}
@@ -492,11 +487,6 @@ class blockModel extends model
$params->type['options'] = $this->lang->block->typeList->project;
$params->type['control'] = 'select';
$params->orderBy['name'] = $this->lang->block->orderBy;
$params->orderBy['default'] = 'id_desc';
$params->orderBy['options'] = $this->lang->block->orderByList->project;
$params->orderBy['control'] = 'select';
return json_encode($params);
}
@@ -513,11 +503,6 @@ class blockModel extends model
$params->type['options'] = $this->lang->block->typeList->product;
$params->type['control'] = 'select';
$params->orderBy['name'] = $this->lang->block->orderBy;
$params->orderBy['default'] = 'id_desc';
$params->orderBy['options'] = $this->lang->block->orderByList->product;
$params->orderBy['control'] = 'select';
return json_encode($params);
}
@@ -645,4 +630,88 @@ class blockModel extends model
return $key == $hash;
}
/**
* Get products like drop menu order
*
* @param strint $status
* @access public
* @return array
*/
public function getProductsLikeDropMenu($status)
{
$products = $this->loadModel('product')->getList($status);
if(empty($products)) return $products;
$lines = $this->loadModel('tree')->getLinePairs();
$productList = array();
foreach($lines as $id => $name)
{
foreach($products as $key => $product)
{
if($product->line == $id)
{
$product->name = $name . '/' . $product->name;
$productList[] = $product;
unset($products[$key]);
}
}
}
$productList = array_merge($productList, $products);
$products = $mineProducts = $otherProducts = $closedProducts = array();
foreach($productList as $product)
{
if(!$this->app->user->admin and !$this->product->checkPriv($product)) continue;
if($product->status == 'normal' and $product->PO == $this->app->user->account)
{
$mineProducts[$product->id] = $product;
}
elseif($product->status == 'normal' and $product->PO != $this->app->user->account)
{
$otherProducts[$product->id] = $product;
}
elseif($product->status == 'closed')
{
$closedProducts[$product->id] = $product;
}
}
$products = $mineProducts + $otherProducts + $closedProducts;
return $products;
}
/**
* Get projects like drop menu order
*
* @param string $status
* @access public
* @return array
*/
public function getProjectsLikeDropMenu($status)
{
$projectList = $this->loadModel('project')->getList($status);
if(empty($projectList)) return $projectList;
$projects = $mineProjects = $otherProjects = $closedProjects = array();
foreach($projectList as $project)
{
if(!$this->app->user->admin and !$this->project->checkPriv($project->id)) continue;
if($project->status != 'done' and $project->status != 'closed' and $project->PM == $this->app->user->account)
{
$mineProjects[$project->id] = $project;
}
elseif($project->status != 'done' and $project->status != 'closed' and !($project->PM == $this->app->user->account))
{
$otherProjects[$project->id] = $project;
}
elseif($project->status == 'done' or $project->status == 'closed')
{
$closedProjects[$project->id] = $project;
}
}
$projects = $mineProjects + $otherProjects + $closedProjects;
return $projects;
}
}
+3 -3
View File
@@ -165,7 +165,7 @@ $config->bug->search['params']['lastEditedDate']= array('operator' => '=',
$config->bug->search['params']['deadline'] = array('operator' => '=', 'control' => 'input', 'values' => '', 'class' => 'date');
$config->bug->datatable = new stdclass();
$config->bug->datatable->defaultField = array('id', 'pri', 'title', 'severity', 'status', 'openedBy', 'openedDate', 'assignedTo', 'resolvedBy', 'resolution', 'actions');
$config->bug->datatable->defaultField = array('id', 'pri', 'title', 'severity', 'status', 'openedBy', 'openedDate', 'assignedTo', 'resolution', 'actions');
$config->bug->datatable->fieldList['id']['title'] = 'idAB';
$config->bug->datatable->fieldList['id']['fixed'] = 'left';
@@ -284,12 +284,12 @@ $config->bug->datatable->fieldList['deadline']['required'] = 'no';
$config->bug->datatable->fieldList['resolvedBy']['title'] = 'resolvedByAB';
$config->bug->datatable->fieldList['resolvedBy']['fixed'] = 'no';
$config->bug->datatable->fieldList['resolvedBy']['width'] = '80';
$config->bug->datatable->fieldList['resolvedBy']['width'] = '70';
$config->bug->datatable->fieldList['resolvedBy']['required'] = 'no';
$config->bug->datatable->fieldList['resolution']['title'] = 'resolutionAB';
$config->bug->datatable->fieldList['resolution']['fixed'] = 'no';
$config->bug->datatable->fieldList['resolution']['width'] = '80';
$config->bug->datatable->fieldList['resolution']['width'] = '70';
$config->bug->datatable->fieldList['resolution']['required'] = 'no';
$config->bug->datatable->fieldList['resolvedDate']['title'] = 'resolvedDateAB';
-1
View File
@@ -1,2 +1 @@
#batchCreateForm{overflow-x:auto;}
#batchCreateForm .chosen-container .chosen-drop{min-width:200px;}
-1
View File
@@ -1,4 +1,3 @@
.chosen-container[id^="plan"] .chosen-drop {min-width: 300px; border-top: 1px solid #ddd!important}
.duplicate-input {border-left-width: 0; border-radius: 0 2px 2px 0; padding-left: 9px}
.duplicate-input:focus {border-left-width: 1px; padding-left: 8px}
#batchEditForm{overflow-x:auto;}
+2 -2
View File
@@ -18,8 +18,8 @@
<?php if($this->session->currentProductType !== 'normal') echo '<span class="label label-info">' . $branches[$branch] . '</span>';?>
</h2>
<div class="pull-right btn-toolbar">
<?php if(common::hasPriv('file', 'uploadImages')) echo html::a($this->createLink('file', 'uploadImages', 'module=bug&params=' . helper::safe64Encode("productID=$productID&projectID=$projectID&moduleID=$moduleID")), $lang->uploadImages, '', "data-toggle='modal' data-type='iframe' class='btn btn-info' data-width='70%'")?>
<button type='button' data-toggle='modal' data-target="#importLinesModal" class="btn btn-info"><?php echo $lang->pasteText;?></button>
<?php if(common::hasPriv('file', 'uploadImages')) echo html::a($this->createLink('file', 'uploadImages', 'module=bug&params=' . helper::safe64Encode("productID=$productID&projectID=$projectID&moduleID=$moduleID")), $lang->uploadImages, '', "data-toggle='modal' data-type='iframe' class='btn btn-primary' data-width='70%'")?>
<button type='button' data-toggle='modal' data-target="#importLinesModal" class="btn btn-primary"><?php echo $lang->pasteText;?></button>
<?php $customLink = $this->createLink('custom', 'ajaxSaveCustomFields', 'module=bug&section=custom&key=batchCreateFields')?>
<?php include '../../common/view/customfield.html.php';?>
</div>
+1 -1
View File
@@ -143,7 +143,7 @@ js::set('confirmDeleteTemplate', $lang->bug->confirmDeleteTemplate);
<?php if($hasCustomPri):?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control chosen'");?>
<?php else: ?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector'");?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector' data-label-class='label-pri'");?>
<?php endif; ?>
</td>
</tr>
+2 -1
View File
@@ -11,6 +11,7 @@
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<div id='mainContent' class='main-content'>
<div class='main-header'>
<h2>
@@ -22,7 +23,7 @@
<div id='queryBox' class='show divider'></div>
<?php if($bugs2Link):?>
<form class='main-table' method='post' data-ride='table' target='hiddenwin' id='linkBugsForm'>
<table class='table' id='bugList'>
<table class='table tablesorter' id='bugList'>
<thead>
<tr>
<th class="c-id">
+5 -2
View File
@@ -16,7 +16,7 @@
<div class='table-header hl-primary text-primary strong'>
<?php echo html::icon('unlink');?> <?php echo $lang->productplan->unlinkedBugs;?>
</div>
<table class='table'>
<table class='table tablesorter'>
<thead>
<tr class='text-center'>
<th class='c-id text-left'>
@@ -71,4 +71,7 @@
</div>
<?php endif;?>
</form>
</div>
</div>
<script>
$(function(){$('#unlinkBugList .tablesorter').sortTable();});
</script>
+4 -1
View File
@@ -16,7 +16,7 @@
<div class='table-header hl-primary text-primary strong'>
<?php echo html::icon('unlink');?> <?php echo $lang->productplan->unlinkedStories;?>
</div>
<table class='table'>
<table class='table tablesorter'>
<thead>
<tr class='text-center'>
<th class='c-id text-left'>
@@ -76,3 +76,6 @@
<?php endif;?>
</form>
</div>
<script>
$(function(){$('#unlinkStoryList .tablesorter').sortTable();});
</script>
+1
View File
@@ -11,6 +11,7 @@
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<?php js::set('confirmUnlinkStory', $lang->build->confirmUnlinkStory)?>
<?php js::set('confirmUnlinkBug', $lang->build->confirmUnlinkBug)?>
<?php js::set('flow', $config->global->flow)?>
+2 -2
View File
@@ -1224,14 +1224,14 @@ class docModel extends model
*/
public function statLibCounts($idList)
{
$moduleCounts = $this->dao->select("root, count(id) as moduleCount")->from(TABLE_MODULE)
$moduleCounts = $this->dao->select("`root`, count(id) as moduleCount")->from(TABLE_MODULE)
->where('type')->eq('doc')
->andWhere('root')->in($idList)
->andWhere('deleted')->eq(0)
->groupBy('root')
->fetchPairs();
$docs = $this->dao->select("id,lib,acl,users,groups")->from(TABLE_DOC)
$docs = $this->dao->select("`id`,`lib`,`acl`,`users`,`groups`")->from(TABLE_DOC)
->where('lib')->in($idList)
->andWhere('deleted')->eq(0)
->andWhere('module')->eq(0)
+1 -1
View File
@@ -68,7 +68,7 @@
<div id="mainContent" class="main-row">
<div class="main-col col-8">
<div class="cell">
<div class="detail no-margin no-padding">
<div class="detail no-padding">
<div class="detail-content article-content no-margin no-padding">
<?php
$content = $doc->content;
+7 -1
View File
@@ -138,9 +138,15 @@ class file extends control
$file = $this->file->getById($fileID);
/* Judge the mode, down or open. */
$mode = 'down';
$mode = 'down';
$fileTypes = 'txt|jpg|jpeg|gif|png|bmp|xml|html';
if(stripos($fileTypes, $file->extension) !== false && $mouse == 'left') $mode = 'open';
if($file->extension == 'txt')
{
$extension = end(explode('.', $file->title));
if($extension != 'txt') $mode = 'down';
$file->extension = $extension;
}
if(file_exists($file->realPath))
{
+63 -63
View File
@@ -19,7 +19,7 @@ class fileModel extends model
/**
* Construct function.
*
*
* @access public
* @return void
*/
@@ -33,9 +33,9 @@ class fileModel extends model
/**
* Get files of an object.
*
* @param string $objectType
* @param string $objectID
*
* @param string $objectType
* @param string $objectID
* @param string $extra
* @access public
* @return array
@@ -60,8 +60,8 @@ class fileModel extends model
/**
* Get info of a file.
*
* @param int $fileID
*
* @param int $fileID
* @access public
* @return object
*/
@@ -77,10 +77,10 @@ class fileModel extends model
/**
* Save upload.
*
* @param string $objectType
* @param string $objectID
* @param string $extra
*
* @param string $objectType
* @param string $objectID
* @param string $extra
* @param string $filesName
* @param string $labelsName
* @access public
@@ -113,7 +113,7 @@ class fileModel extends model
/**
* Get counts of uploaded files.
*
*
* @access public
* @return int
*/
@@ -124,8 +124,8 @@ class fileModel extends model
/**
* Get info of uploaded files.
*
* @param string $htmlTagName
*
* @param string $htmlTagName
* @param string $labelsName
* @access public
* @return array
@@ -152,7 +152,7 @@ class fileModel extends model
$title = isset($_POST[$labelsName][$id]) ? $_POST[$labelsName][$id] : '';
$file['extension'] = $this->getExtension($filename);
$file['pathname'] = $this->setPathName($id, $file['extension']);
$file['title'] = (!empty($title) and $title != $filename) ? htmlspecialchars($title) : str_replace('.' . $file['extension'], '', $filename);
$file['title'] = (!empty($title) and $title != $filename) ? htmlspecialchars($title) : $filename;
$file['title'] = $purifier->purify($file['title']);
$file['size'] = $size[$id];
$file['tmpname'] = $tmp_name[$id];
@@ -167,7 +167,7 @@ class fileModel extends model
$title = isset($_POST[$labelsName][0]) ? $_POST[$labelsName][0] : '';
$file['extension'] = $this->getExtension($name);
$file['pathname'] = $this->setPathName(0, $file['extension']);
$file['title'] = (!empty($title) and $title != $name) ? htmlspecialchars($title) : substr($name, 0, strpos($name, $file['extension']) - 1);
$file['title'] = (!empty($title) and $title != $name) ? htmlspecialchars($title) : $name;
$file['title'] = $purifier->purify($file['title']);
$file['size'] = $size;
$file['tmpname'] = $tmp_name;
@@ -287,8 +287,8 @@ class fileModel extends model
/**
* Get extension of a file.
*
* @param string $filename
*
* @param string $filename
* @access public
* @return string
*/
@@ -303,8 +303,8 @@ class fileModel extends model
/**
* Get save name.
*
* @param string $pathName
*
* @param string $pathName
* @access public
* @return string
*/
@@ -316,8 +316,8 @@ class fileModel extends model
/**
* Get real path name.
*
* @param string $pathName
*
* @param string $pathName
* @access public
* @return string
*/
@@ -331,8 +331,8 @@ class fileModel extends model
/**
* Get export tpl.
*
* @param string $module
*
* @param string $module
* @access public
* @return object
*/
@@ -349,8 +349,8 @@ class fileModel extends model
/**
* Save export template.
*
* @param string $module
*
* @param string $module
* @access public
* @return int
*/
@@ -369,9 +369,9 @@ class fileModel extends model
/**
* Set path name of the uploaded file to be saved.
*
* @param int $fileID
* @param string $extension
*
* @param int $fileID
* @param string $extension
* @access public
* @return string
*/
@@ -384,7 +384,7 @@ class fileModel extends model
/**
* Set save path.
*
*
* @access public
* @return void
*/
@@ -398,10 +398,10 @@ class fileModel extends model
}
$this->savePath = dirname($savePath) . '/';
}
/**
* Set the web path of upload files.
*
*
* @access public
* @return void
*/
@@ -412,9 +412,9 @@ class fileModel extends model
/**
* Insert the set image size code.
*
* @param string $content
* @param int $maxSize
*
* @param string $content
* @param int $maxSize
* @access public
* @return string
*/
@@ -463,9 +463,9 @@ class fileModel extends model
}
/**
* Paste image in kindeditor at firefox and chrome.
*
* @param string $data
* Paste image in kindeditor at firefox and chrome.
*
* @param string $data
* @access public
* @return string
*/
@@ -503,8 +503,8 @@ class fileModel extends model
/**
* Parse CSV.
*
* @param string $fileName
*
* @param string $fileName
* @access public
* @return array
*/
@@ -606,8 +606,8 @@ class fileModel extends model
/**
* Remove interference for parse csv.
*
* @param array $matchs
*
* @param array $matchs
* @access private
* @return string
*/
@@ -619,9 +619,9 @@ class fileModel extends model
/**
* Process editor.
*
* @param object $data
* @param string $editorList
*
* @param object $data
* @param string $editorList
* @access public
* @return object
*/
@@ -662,9 +662,9 @@ class fileModel extends model
}
/**
* Compress image
*
* @param array $file
* Compress image
*
* @param array $file
* @access public
* @return array
*/
@@ -699,15 +699,15 @@ class fileModel extends model
* Webpage: de77.com
* Version: 07.02.2010
* Source : https://github.com/acustodioo/pic/blob/master/imagecreatefrombmp.function.php
*
* @param string $filename
*
* @param string $filename
* @access public
* @return resource
*/
public function imagecreatefrombmp($filename) {
$f = fopen($filename, "rb");
//read header
//read header
$header = fread($f, 54);
$header = unpack('c2identifier/Vfile_size/Vreserved/Vbitmap_data/Vheader_size/'.
'Vwidth/Vheight/vplanes/vbits_per_pixel/Vcompression/Vdata_size/'.
@@ -740,9 +740,9 @@ class fileModel extends model
}
/**
* Dwordize for imagecreatefrombmp
*
* @param streing $str
* Dwordize for imagecreatefrombmp
*
* @param streing $str
* @access private
* @return int
*/
@@ -756,10 +756,10 @@ class fileModel extends model
/**
* Update objectID.
*
* @param int $uid
* @param int $objectID
* @param string $objectType
*
* @param int $uid
* @param int $objectID
* @param string $objectType
* @access public
* @return bool
*/
@@ -779,10 +779,10 @@ class fileModel extends model
}
/**
* Revert real src.
*
* @param object $data
* @param string $fields
* Revert real src.
*
* @param object $data
* @param string $fields
* @access public
* @return object
*/
@@ -800,8 +800,8 @@ class fileModel extends model
/**
* Auto delete useless image.
*
* @param int $uid
*
* @param int $uid
* @access public
* @return void
*/
+1 -1
View File
@@ -47,7 +47,7 @@ $sessionString .= session_name() . '=' . session_id();
{
$uploadDate = $lang->file->uploadDate . substr($file->addedDate, 0, 10);
$fileTitle = "<li title='{$uploadDate}'><i class='icon icon-file-text'></i> &nbsp;" . $file->title;
if(strpos($file->title, ".{$file->extension}") === false) $fileTitle .= ".{$file->extension}";
if(strpos($file->title, ".{$file->extension}") === false && $file->extension != 'txt') $fileTitle .= ".{$file->extension}";
$imageWidth = 0;
if(stripos('jpg|jpeg|gif|png|bmp', $file->extension) !== false)
{
+31 -24
View File
@@ -283,11 +283,11 @@ class gitModel extends model
exec("{$this->client} config core.quotepath false");
if($fromRevision)
{
$cmd = "$this->client log --stat=1024 $fromRevision..HEAD --pretty=format:%an*_*%cd*_*%H*_*%s";
$cmd = "$this->client log --stat=1024 --name-status $fromRevision..HEAD";
}
else
{
$cmd = "$this->client log --stat=1024 --pretty=format:%an*_*%cd*_*%H*_*%s";
$cmd = "$this->client log --stat=1024 --name-status";
}
exec($cmd, $list, $return);
@@ -304,17 +304,11 @@ class gitModel extends model
foreach($list as $line)
{
if(!$line)
{
$i++;
continue;
}
if(strpos($line, 'commit ') === 0) $i++;
$logs[$i][] = $line;
}
foreach($logs as $log)
{
$parsedLogs[] = $this->convertLog($log);
}
foreach($logs as $log) $parsedLogs[] = $this->convertLog($log);
return $parsedLogs;
}
@@ -328,22 +322,35 @@ class gitModel extends model
public function convertLog($log)
{
list($account, $date, $hash, $comment) = explode('*_*', $log[0]);
list($hash, $account, $date) = $log;
$account = preg_replace('/^Author:/', '', $account);
$account = trim(preg_replace('/<\w+@\w+\.\w+>/', '', $account));
$date = trim(preg_replace('/^Date:/', '', $date));
$count = count($log);
$comment = '';
$files = array();
for($i = 3; $i < $count; $i++)
{
$line = $log[$i];
if(preg_match('/^\s{2,}/', $line))
{
$comment .= $line;
}
elseif(strpos($line, "\t") !== false)
{
list($action, $entry) = explode("\t", $line);
$entry = '/' . trim($entry);
$files[$action][] = $entry;
}
}
$parsedLog = new stdClass();
$parsedLog->author = $account;
$parsedLog->revision = $hash;
$parsedLog->msg = $comment;
$parsedLog->revision = trim(preg_replace('/^commit/', '', $hash));
$parsedLog->msg = trim($comment);
$parsedLog->date = date('Y-m-d H:i:s', strtotime($date));
$parsedLog->files = array();
unset($log[0]);
foreach($log as $change)
{
if(strpos($change, '|') === false) continue;
list($entry, $modify) = explode('|', $change);
$entry = '/' . trim($entry);
$parsedLog->files['M'][] = $entry;
}
$parsedLog->files = $files;
return $parsedLog;
}
+6 -6
View File
@@ -12,8 +12,8 @@
class message extends control
{
/**
* Index
*
* Index
*
* @access public
* @return void
*/
@@ -32,8 +32,8 @@ class message extends control
}
/**
* Setting
*
* Setting
*
* @access public
* @return void
*/
@@ -65,7 +65,7 @@ class message extends control
/**
* Ajax get message.
*
*
* @access public
* @return void
*/
@@ -96,7 +96,7 @@ class message extends control
{
echo <<<EOT
<div class='alert alert-info with-icon alert-dismissable' style='width:380px; position:fixed; bottom:25px; right:15px; z-index: 9999;'>
<i class='icon icon-envelope-alt'> </i>
<i class='icon icon-envelope-o'> </i>
<div class='content'>{$messages}</div>
<button type="button" class="close" data-dismiss="alert">×</button>
</div>
+5 -2
View File
@@ -10,13 +10,13 @@
* @link http://www.zentao.net
*/
?>
<div id='queryBox' class='show'></div>
<div id='queryBox' class='show no-margin'></div>
<div id='unlinkBugList'>
<form class='main-table table-bug' data-ride='table' method='post' id='unlinkedBugsForm' target='hiddenwin' action='<?php echo $this->createLink('productplan', 'linkBug', "planID=$plan->id&browseType=$browseType&param=$param&orderBy=$orderBy")?>'>
<div class='table-header hl-primary text-primary strong'>
<?php echo html::icon('unlink');?> <?php echo $lang->productplan->unlinkedBugs;?>
</div>
<table class='table'>
<table class='table tablesorter'>
<thead>
<tr class='text-center'>
<th class='c-id text-left'>
@@ -71,3 +71,6 @@
</div>
</form>
</div>
<script>
$(function(){$('#unlinkBugList .tablesorter').sortTable();});
</script>
+5 -2
View File
@@ -10,13 +10,13 @@
* @link http://www.zentao.net
*/
?>
<div id='queryBox' class='show'></div>
<div id='queryBox' class='show no-margin'></div>
<div id='unlinkStoryList'>
<form class="main-table table-story" data-ride="table" method="post" target='hiddenwin' id='unlinkedStoriesForm' action="<?php echo $this->createLink('productplan', 'linkStory', "planID=$plan->id&browseType=$browseType&param=$param&orderBy=$orderBy")?>">
<div class='table-header hl-primary text-primary strong'>
<?php echo html::icon('unlink');?> <?php echo $lang->productplan->unlinkedStories;?>
</div>
<table class='table'>
<table class='table tablesorter'>
<thead>
<tr class='text-center'>
<th class='c-id text-left'>
@@ -79,3 +79,6 @@
</div>
</form>
</div>
<script>
$(function(){$('#unlinkStoryList .tablesorter').sortTable();});
</script>
+1
View File
@@ -12,6 +12,7 @@
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/sortable.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<?php js::set('confirmUnlinkStory', $lang->productplan->confirmUnlinkStory)?>
<?php js::set('confirmUnlinkBug', $lang->productplan->confirmUnlinkBug)?>
<?php js::set('planID', $plan->id);?>
+1
View File
@@ -28,6 +28,7 @@ $(function()
parent.location.href = createLink('project', 'importPlanStories', 'projectID=' + projectID + '&planID=' + planID);
}
})
$('.sorter-false a').unwrap();
});
function showCheckedSummary()
+1 -1
View File
@@ -51,7 +51,7 @@ var browseType = '<?php echo $browseType;?>';
<tr>
<td class='c-id'>
<div class="checkbox-primary">
<input type='checkbox' name='import[<?php echo $bug->id;?>]' value='<?php echo $bug->id;?>' />
<input type='checkbox' name='import[<?php echo $bug->id;?>]' value='<?php echo $bug->id;?>' />
<label></label>
</div>
<?php echo sprintf('%03d', $bug->id) . html::hidden("id[$bug->id]", $bug->id);?>
+2 -1
View File
@@ -11,6 +11,7 @@
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<style>
.search-form .form-actions {padding-bottom: 10px!important;}
</style>
@@ -27,7 +28,7 @@
<div id='queryBox' class='show no-margin'></div>
</div>
<form class='main-table table-story' method='post' data-ride='table' id='linkStoryForm'>
<table class='table table-fixed' id='linkStoryList'>
<table class='table table-fixed tablesorter' id='linkStoryList'>
<thead>
<tr>
<th class='c-id'>
+12 -11
View File
@@ -12,6 +12,7 @@
?>
<?php $canOrder = common::hasPriv('project', 'storySort');?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<?php if($canOrder) include '../../common/view/sortable.html.php';?>
<?php js::set('moduleID', ($type == 'byModule' ? $param : 0));?>
<?php js::set('productID', ($type == 'byProduct' ? $param : 0));?>
@@ -97,7 +98,7 @@
<div class="table-header fixed-right">
<nav class="btn-toolbar pull-right"></nav>
</div>
<table class='table has-sort-head' id='storyList'>
<table class='table tablesorter has-sort-head' id='storyList'>
<thead>
<tr>
<?php
@@ -106,7 +107,7 @@
$canBatchClose = common::hasPriv('story', 'batchClose');
?>
<?php $vars = "projectID={$project->id}&orderBy=%s&type=$type&param=$param&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}"; ?>
<th class='c-id'>
<th class='c-id {sorter:false}'>
<?php if($canBatchEdit or $canBatchClose):?>
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
<label></label>
@@ -115,19 +116,19 @@
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
</th>
<?php if($canOrder):?>
<th class='w-80px c-sort'> <?php common::printOrderLink('order', $orderBy, $vars, $lang->project->updateOrder);?></th>
<th class='w-80px c-sort {sorter:false}'> <?php common::printOrderLink('order', $orderBy, $vars, $lang->project->updateOrder);?></th>
<?php endif;?>
<th class='c-pri'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th class='c-name'> <?php common::printOrderLink('title', $orderBy, $vars, $lang->story->title);?></th>
<th class='c-user'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='c-user'> <?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->assignedToAB);?></th>
<th class='c-estimate w-80px'> <?php common::printOrderLink('estimate', $orderBy, $vars, $lang->story->estimateAB);?></th>
<th class='c-status'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->statusAB);?></th>
<th class='c-stage w-70px'> <?php common::printOrderLink('stage', $orderBy, $vars, $lang->story->stageAB);?></th>
<th class='c-pri {sorter:false}'> <?php common::printOrderLink('pri', $orderBy, $vars, $lang->priAB);?></th>
<th class='c-name {sorter:false}'> <?php common::printOrderLink('title', $orderBy, $vars, $lang->story->title);?></th>
<th class='c-user {sorter:false}'> <?php common::printOrderLink('openedBy', $orderBy, $vars, $lang->openedByAB);?></th>
<th class='c-user {sorter:false}'> <?php common::printOrderLink('assignedTo', $orderBy, $vars, $lang->assignedToAB);?></th>
<th class='c-estimate w-80px {sorter:false}'> <?php common::printOrderLink('estimate', $orderBy, $vars, $lang->story->estimateAB);?></th>
<th class='c-status {sorter:false}'> <?php common::printOrderLink('status', $orderBy, $vars, $lang->statusAB);?></th>
<th class='c-stage w-70px {sorter:false}'> <?php common::printOrderLink('stage', $orderBy, $vars, $lang->story->stageAB);?></th>
<th title='<?php echo $lang->story->taskCount?>' class='w-30px'><?php echo $lang->story->taskCountAB;?></th>
<th title='<?php echo $lang->story->bugCount?>' class='w-30px'><?php echo $lang->story->bugCountAB;?></th>
<th title='<?php echo $lang->story->caseCount?>' class='w-30px'><?php echo $lang->story->caseCountAB;?></th>
<th class='c-actions-4 text-center'><?php echo $lang->actions;?></th>
<th class='c-actions-4 text-center {sorter:false}'><?php echo $lang->actions;?></th>
</tr>
</thead>
<tbody id='storyTableList' class='sortable'>
+4 -1
View File
@@ -20,7 +20,7 @@ $formID = $type == 'leftBug' ? 'unlinkedLeftBugsForm' : 'unlinkedBugsForm';
<div class='table-header hl-primary text-primary strong'>
<?php echo html::icon('unlink');?> <?php echo $lang->productplan->unlinkedBugs;?>
</div>
<table class='table'>
<table class='table tablesorter'>
<thead>
<tr class='text-center'>
<th class='c-id text-left'>
@@ -75,3 +75,6 @@ $formID = $type == 'leftBug' ? 'unlinkedLeftBugsForm' : 'unlinkedBugsForm';
</div>
</form>
</div>
<script>
$(function(){$('#<?php echo $formID;?> .tablesorter').sortTable();});
</script>
+5 -2
View File
@@ -16,7 +16,7 @@
<div class='table-header hl-primary text-primary strong'>
<?php echo html::icon('unlink');?> <?php echo $lang->productplan->unlinkedStories;?>
</div>
<table class='table'>
<table class='table tablesorter'>
<thead>
<tr class='text-center'>
<th class='c-id text-left'>
@@ -74,4 +74,7 @@
<div class='table-statistic'></div>
</div>
</form>
</div>
</div>
<script>
$(function(){$('#unlinkStoryList .tablesorter').sortTable();});
</script>
+1
View File
@@ -11,6 +11,7 @@
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<?php js::set('confirmUnlinkStory', $lang->release->confirmUnlinkStory)?>
<?php js::set('confirmUnlinkBug', $lang->release->confirmUnlinkBug)?>
<div id='mainMenu' class='clearfix'>
+8 -4
View File
@@ -36,15 +36,19 @@ $formId = 'searchForm-' . uniqid('');
#userQueries {border-left: 1px solid #eee; vertical-align: top;}
#userQueries > h4 {margin: 0 0 6px;}
#userQueries ul {list-style: none; padding-left: 0; margin: 0;max-height:244px; overflow:auto;}
#userQueries ul {list-style: none; padding-left: 0; margin: 0; max-height:170px; overflow:auto;}
#userQueries ul li + li {margin-top: 5px;}
#userQueries .label {line-height: 24px; padding: 0 20px 0 8px; display: inline-block; background-color: #EEEEEE; color: #A6AAB8; border-radius: 12px; max-width: 100%; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; position: relative;}
#userQueries .label:hover {background-color: #aaa; color: #fff;}
#userQueries .label > .icon-close {position: absolute; top: 2px; right: 2px; border-radius: 9px; font-size: 12px; line-height: 18px; width: 18px; display: inline-block;}
#userQueries .label > .icon-close:hover {background-color: #ff5d5d; color: #fff;}
@media (max-width: 1150px) {#userQueries {display: none}}
@media (max-width: 1150px) {#userQueries {display: none}}
<?php if($style == 'simple'):?>
#<?php echo $formId;?> .form-actions {text-align: left; padding: 0!important; max-width: 200px; vertical-align: middle; width: 200px;}
#queryBox.show {min-height: 66px;}
<?php endif;?>
</style>
<form method='post' action='<?php echo $this->createLink('search', 'buildQuery');?>' target='hiddenwin' id='<?php echo $formId;?>' class='search-form'>
<form method='post' action='<?php echo $this->createLink('search', 'buildQuery');?>' target='hiddenwin' id='<?php echo $formId;?>' class='search-form<?php if($style == 'simple') echo ' search-form-simple';?>'>
<div class='hidden'>
<?php
/* Print every field as an html object, select or input. Thus when setFiled is called, copy it's html to build the search form. */
@@ -195,9 +199,9 @@ foreach($fieldParams as $fieldName => $param)
<?php endforeach;?>
</ul>
</td>
<?php endif;?>
</tr>
<tr>
<?php endif;?>
<td colspan='3' class='text-center form-actions'>
<?php
echo html::hidden('module', $module);
-1
View File
@@ -1,3 +1,2 @@
#suhosinInfo {margin-bottom: 0;}
.chosen-container .chosen-drop {min-width: 400px; border-top: 1px solid #ddd!important}
#batchEditForm{overflow-x:auto}
+2 -2
View File
@@ -15,8 +15,8 @@
<div class="main-header">
<h2><?php echo $lang->story->batchCreate;?></h2>
<div class="pull-right btn-toolbar">
<?php if(common::hasPriv('file', 'uploadImages')) echo html::a($this->createLink('file', 'uploadImages', 'module=story&params=' . helper::safe64Encode("productID=$productID&branch=$branch&moduleID=$moduleID")), $lang->uploadImages, '', "data-toggle='modal' data-type='iframe' class='btn btn-info' data-width='70%'")?>
<button type='button' data-toggle='modal' data-target="#importLinesModal" class="btn btn-info"><?php echo $lang->pasteText;?></button>
<?php if(common::hasPriv('file', 'uploadImages')) echo html::a($this->createLink('file', 'uploadImages', 'module=story&params=' . helper::safe64Encode("productID=$productID&branch=$branch&moduleID=$moduleID")), $lang->uploadImages, '', "data-toggle='modal' data-type='iframe' class='btn btn-primary' data-width='70%'")?>
<button type='button' data-toggle='modal' data-target="#importLinesModal" class="btn btn-primary"><?php echo $lang->pasteText;?></button>
<?php $customLink = $this->createLink('custom', 'ajaxSaveCustomFields', 'module=story&section=custom&key=batchCreateFields')?>
<?php include '../../common/view/customfield.html.php';?>
</div>
+1 -1
View File
@@ -26,7 +26,7 @@
<th class='w-80px'><?php echo $lang->story->reviewedBy;?></th>
<td>
<div class="input-group w-p35-f">
<?php echo html::select('assignedTo', $users, $story->assignedTo, 'class="form-control chosen"');?>
<?php echo html::select('assignedTo', $users, $story->reviewedBy, 'class="form-control chosen"');?>
<?php if(!$this->story->checkForceReview()):?>
<span class="input-group-addon">
<?php echo html::checkbox('needNotReview', $lang->story->needNotReview, '', "id='needNotReview' {$needReview}");?>
+4 -4
View File
@@ -122,9 +122,9 @@
<th><?php echo $lang->story->pri;?></th>
<td colspan="<?php echo $hasCustomPri ? 1 : 4;?>">
<?php if($hasCustomPri):?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control chosen'");?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control chosen'");?>
<?php else: ?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector'");?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector' data-label-class='label-pri'");?>
<?php endif; ?>
</td>
</tr>
@@ -147,7 +147,7 @@
</div>
</td>
<?php endif;?>
</tr>
</tr>
<tr>
<th><?php echo $lang->story->spec;?></th>
<td colspan="4"><?php echo html::textarea('spec', $spec, "rows='9' class='form-control kindeditor disabled-ie-placeholder' hidefocus='true' placeholder='" . htmlspecialchars($lang->story->specTemplate) . "'");?></td>
@@ -161,7 +161,7 @@
<tr>
<th><?php echo $lang->story->legendAttatch;?></th>
<td colspan='4'><?php echo $this->fetch('file', 'buildform');?></td>
</tr>
</tr>
<?php if(strpos(",$showFields,", ',mailto,') !== false):?>
<tr>
<th><?php echo $lang->story->mailto;?></th>
+2 -1
View File
@@ -11,6 +11,7 @@
*/
?>
<?php include './header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<?php js::set('linkType', $type);?>
<div class='main-content' id='mainContent'>
<div class='main-header'>
@@ -25,7 +26,7 @@
<div id='queryBox' class='show divider'></div>
<form method='post' target='hiddenwin' id='linkStoryForm' class='main-table table-story'>
<?php if($stories2Link):?>
<table class='table' id='storyList'>
<table class='table tablesorter' id='storyList'>
<thead>
<tr>
<th class='c-id'>
-1
View File
@@ -7,7 +7,6 @@
#batchCreateForm .input-group .form-control {position: static;}
#batchCreateForm .input-group .colorpicker {z-index: 2;}
#batchCreateForm .input-group .colorpicker.open {z-index: 5;}
#batchCreateForm{overflow-x:auto;}
.main-header .pull-left {max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;}
-1
View File
@@ -1,2 +1 @@
.chosen-container[id^="module"] .chosen-drop {min-width: 400px;!important}
#batchEditForm{overflow-x:auto;}
+2 -2
View File
@@ -1468,7 +1468,7 @@ class taskModel extends model
public function getProjectTasks($projectID, $productID = 0, $type = 'all', $modules = 0, $orderBy = 'status_asc, id_desc', $pager = null)
{
if(is_string($type)) $type = strtolower($type);
$tasks = $this->dao->select('t1.*, t2.id AS storyID, t2.title AS storyTitle, t2.product, t2.branch, t2.version AS latestStoryVersion, t2.status AS storyStatus, t3.realname AS assignedToRealName')
$tasks = $this->dao->select('DISTINCT t1.*, t2.id AS storyID, t2.title AS storyTitle, t2.product, t2.branch, t2.version AS latestStoryVersion, t2.status AS storyStatus, t3.realname AS assignedToRealName')
->from(TABLE_TASK)->alias('t1')
->leftJoin(TABLE_STORY)->alias('t2')->on('t1.story = t2.id')
->leftJoin(TABLE_USER)->alias('t3')->on('t1.assignedTo = t3.account')
@@ -1504,7 +1504,7 @@ class taskModel extends model
}
/* Select children task. */
$children = $this->dao->select('t1.*, t2.id AS storyID, t2.title AS storyTitle, t2.product, t2.branch, t2.version AS latestStoryVersion, t2.status AS storyStatus, t3.realname AS assignedToRealName')
$children = $this->dao->select('DISTINCT t1.*, t2.id AS storyID, t2.title AS storyTitle, t2.product, t2.branch, t2.version AS latestStoryVersion, t2.status AS storyStatus, t3.realname AS assignedToRealName')
->from(TABLE_TASK)->alias('t1')
->leftJoin(TABLE_STORY)->alias('t2')->on('t1.story = t2.id')
->leftJoin(TABLE_USER)->alias('t3')->on('t1.assignedTo = t3.account')
+1 -1
View File
@@ -28,7 +28,7 @@
</a>
<?php endif;?>
<div class="pull-right btn-toolbar">
<button type='button' data-toggle='modal' data-target="#importLinesModal" class="btn btn-info"><?php echo $lang->pasteText;?></button>
<button type='button' data-toggle='modal' data-target="#importLinesModal" class="btn btn-primary"><?php echo $lang->pasteText;?></button>
<?php $customLink = $this->createLink('custom', 'ajaxSaveCustomFields', 'module=task&section=custom&key=batchCreateFields')?>
<?php include '../../common/view/customfield.html.php';?>
</div>
+1 -1
View File
@@ -107,7 +107,7 @@
<?php if($hasCustomPri):?>
<?php echo html::select('pri', (array)$priList, $task->pri, "class='form-control chosen'");?>
<?php else: ?>
<?php echo html::select('pri', (array)$priList, $task->pri, "class='form-control' data-provide='labelSelector'");?>
<?php echo html::select('pri', (array)$priList, $task->pri, "class='form-control' data-provide='labelSelector' data-label-class='label-pri'");?>
<?php endif; ?>
</td>
</tr>
-1
View File
@@ -9,4 +9,3 @@
#batchCreateForm .input-group .form-control {position: static;}
#batchCreateForm .input-group .colorpicker {z-index: 2;}
#batchCreateForm .input-group .colorpicker.open {z-index: 5;}
#batchCreateForm {overflow-x: auto;}
+1 -1
View File
@@ -24,7 +24,7 @@
<?php endif;?>
</h2>
<div class="pull-right btn-toolbar">
<button type='button' data-toggle='modal' data-target="#importLinesModal" class="btn btn-info"><?php echo $lang->pasteText;?></button>
<button type='button' data-toggle='modal' data-target="#importLinesModal" class="btn btn-primary"><?php echo $lang->pasteText;?></button>
<?php $customLink = $this->createLink('custom', 'ajaxSaveCustomFields', 'module=testcase&section=custom&key=batchCreateFields')?>
<?php include '../../common/view/customfield.html.php';?>
</div>
+2 -2
View File
@@ -125,7 +125,7 @@
<?php if($hasCustomPri):?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control chosen'");?>
<?php else: ?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector'");?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector' data-label-class='label-pri'");?>
<?php endif; ?>
</td>
</tr>
@@ -182,7 +182,7 @@
<?php if(!isset($step->type)) $step->type = 'step';?>
<input type='hidden' name='stepType[]' value='<?php echo $step->type;?>' class='step-type'>
<div class='checkbox-primary'>
<input tabindex='-1' type="checkbox" class='step-group-toggle'<?php if($step->type === 'group') echo ' checked' ?>>
<input tabindex='-1' type="checkbox" class='step-group-toggle'<?php if($step->type === 'group') echo ' checked' ?>>
<label><?php echo $lang->testcase->group ?></label>
</div>
</span>
+2 -1
View File
@@ -11,6 +11,7 @@
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<div id="mainContent" class="main-content">
<div class='main-header'>
<h2>
@@ -22,7 +23,7 @@
<div id='queryBox' class='show divider'></div>
<?php if($cases2Link):?>
<form class='main-table' method='post' target='hiddenwin' id='linkCasesForm' data-ride='table'>
<table class='table' id='caseList'>
<table class='table tablesorter' id='caseList'>
<thead>
<tr>
<th class='c-id'>
+1 -1
View File
@@ -95,7 +95,7 @@
<?php if($hasCustomPri):?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control chosen'");?>
<?php else: ?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector'");?>
<?php echo html::select('pri', (array)$priList, $pri, "class='form-control' data-provide='labelSelector' data-label-class='label-pri'");?>
<?php endif; ?>
</td>
</tr>
+1 -1
View File
@@ -30,7 +30,7 @@
<div class="table-header">
<i class="icon-unlink"></i> &nbsp;<strong><?php echo $lang->testsuite->unlinkedCases;?></strong> (<?php echo $pager->recTotal;?>)
</div>
<table class='table' id='testcaseList'>
<table class='table tablesorter' id='testcaseList'>
<thead>
<tr>
<th class='w-id'>
+2 -1
View File
@@ -11,6 +11,7 @@
*/
?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/tablesorter.html.php';?>
<div id='mainMenu' class='clearfix'>
<div class='btn-toolbar pull-left'>
<?php common::printBack($this->session->testtaskList, 'btn btn-link');?>
@@ -68,7 +69,7 @@
<div class="cell show" id="queryBox"></div>
<div id='mainContent'>
<form class='main-table table-case' data-ride='table' method='post'>
<table class='table'>
<table class='table tablesorter'>
<div class="table-header">
<i class="icon-unlink"></i> &nbsp;<strong><?php echo $lang->testtask->unlinkedCases;?></strong> (<?php echo $pager->recTotal;?>)
</div>