* fix bug and delete test code.

This commit is contained in:
wangyidong
2017-12-26 16:40:18 +08:00
parent dc8ee0995e
commit d09eabbad8
12 changed files with 35 additions and 35 deletions
+4 -4
View File
@@ -111,6 +111,10 @@ $config->file->allowed = 'txt,doc,docx,dot,wps,wri,pdf,ppt,pptx,xls,xlsx,ett,xlt
$filterConfig = dirname(__FILE__) . DIRECTORY_SEPARATOR . 'filter.php';
if(file_exists($filterConfig)) include $filterConfig;
/* 引用自定义的配置。 Include the custom config file. */
$myConfig = dirname(__FILE__) . DIRECTORY_SEPARATOR . 'my.php';
if(file_exists($myConfig)) include $myConfig;
/* 禅道配置文件。zentaopms settings. */
$zentaopmsConfig = dirname(__FILE__) . DIRECTORY_SEPARATOR . 'zentaopms.php';
if(file_exists($zentaopmsConfig)) include $zentaopmsConfig;
@@ -118,7 +122,3 @@ if(file_exists($zentaopmsConfig)) include $zentaopmsConfig;
/* Include extension config files. */
$extConfigFiles = glob(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'ext/*.php');
if($extConfigFiles) foreach($extConfigFiles as $extConfigFile) include $extConfigFile;
/* 引用自定义的配置。 Include the custom config file. */
$myConfig = dirname(__FILE__) . DIRECTORY_SEPARATOR . 'my.php';
if(file_exists($myConfig)) include $myConfig;
+10 -10
View File
@@ -91,15 +91,15 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
<?php $param = strpos($menuItem->name, 'QUERY' === 0) ? (int)substr($menuItem->name, 5) : 0;?>
<?php if($menuItem->name == 'my'):?>
<?php
echo "<li id='statusTab' class='dropdown " . (!empty($currentBrowseType) ? 'active' : '') . "'>";
echo html::a('javascript:;', $menuItem->text . " <span class='caret'></span>", '', "data-toggle='dropdown'");
echo "<ul class='dropdown-menu'>";
foreach ($lang->bug->mySelects as $key => $value)
{
echo '<li' . ($key == $currentBrowseType ? " class='active'" : '') . '>';
echo html::a($this->createLink('bug', 'browse', "productid=$productID&branch=$branch&browseType=$key&param=$param"), $value);
}
echo '</ul></li>';
echo "<li id='statusTab' class='dropdown " . (!empty($currentBrowseType) ? 'active' : '') . "'>";
echo html::a('javascript:;', $menuItem->text . " <span class='caret'></span>", '', "data-toggle='dropdown'");
echo "<ul class='dropdown-menu'>";
foreach ($lang->bug->mySelects as $key => $value)
{
echo '<li' . ($key == $currentBrowseType ? " class='active'" : '') . '>';
echo html::a($this->createLink('bug', 'browse', "productid=$productID&branch=$branch&browseType=$key&param=$param"), $value);
}
echo '</ul></li>';
?>
<?php else:?>
<li id='<?php echo $menuItem->name?>Tab'><?php echo html::a($this->createLink('bug', 'browse', "productid=$productID&branch=$branch&browseType=$browseType&param=$param"), $menuItem->text)?></li>
@@ -137,7 +137,7 @@ $currentBrowseType = isset($lang->bug->mySelects[$browseType]) && in_array($brow
else
{
$misc = common::hasPriv('bug', 'create') ? "class='btn btn-primary'" : "class='btn btn-primary disabled'";
$link = common::hasPriv('bug', 'create') ? $this->createLink('bug', 'create', "productID=$productID&branch=$branch&extra=moduleID=$moduleID") : '#';
$link = common::hasPriv('bug', 'create') ? $this->createLink('bug', 'create', "productID=$productID&branch=$branch&extra=moduleID=$moduleID") : '#';
echo html::a($link, "<i class='icon icon-plus'></i>" . $lang->bug->create, '', $misc);
}
+1 -1
View File
@@ -43,7 +43,7 @@
<h5><?php echo $lang->install->promotion?></h5>
<div class='row'>
<?php foreach($lang->install->product as $product):?>
<div class='col-md-<?php echo 12/count($lang->install->product);?>'>
<div class='col-md-<?php echo 12 / count($lang->install->product);?>'>
<a class="card ad" href="<?php echo $lang->install->{$product}->url;?>" target="_blank">
<div class="img-wrapper" style="background-image:url(<?php echo $defaultTheme . $lang->install->{$product}->logo;?>)"><img src="<?php echo $defaultTheme . $lang->install->{$product}->logo;?>" alt=""></div>
<div class="card-reveal">
-1
View File
@@ -46,7 +46,6 @@ $(function()
{
var list = '';
for(i = 0; i < data.list.length; i++) list += $(data.list[i]).attr('data-id') + ',';
console.log(list);
$.post(createLink('productplan', 'ajaxStorySort', 'planID=' + planID), {'storys' : list, 'orderBy' : orderBy}, function()
{
var $target = $(data.element[0]);
+1 -1
View File
@@ -17,7 +17,7 @@ $lang->productplan->edit = "Edit";
$lang->productplan->delete = "Delete";
$lang->productplan->view = "Details";
$lang->productplan->bugSummary = "<strong>%s</strong> Bugs in total on this page.";
$lang->productplan->info = 'Info';
$lang->productplan->info = 'Info';
$lang->productplan->batchEdit = 'Batch Edit';
$lang->productplan->batchUnlink = "Batch Unlink";
+1 -1
View File
@@ -17,7 +17,7 @@ $lang->productplan->edit = "编辑计划";
$lang->productplan->delete = "删除计划";
$lang->productplan->view = "计划详情";
$lang->productplan->bugSummary = "本页共 <strong>%s</strong> 个Bug";
$lang->productplan->info = '信息';
$lang->productplan->info = '信息';
$lang->productplan->batchEdit = '批量编辑';
$lang->productplan->batchUnlink = "批量移除";
+7 -7
View File
@@ -401,12 +401,12 @@
<th class='w-80px strong'><?php echo $lang->productplan->title;?></th>
<td><?php echo $plan->title;?></td>
</tr>
<?php if($product->type != 'normal'):?>
<tr>
<th><?php echo $lang->product->branch;?></th>
<td><?php echo $branches[$plan->branch];?></td>
</tr>
<?php endif;?>
<?php if($product->type != 'normal'):?>
<tr>
<th><?php echo $lang->product->branch;?></th>
<td><?php echo $branches[$plan->branch];?></td>
</tr>
<?php endif;?>
<tr>
<th><?php echo $lang->productplan->begin;?></th>
<td><?php echo $plan->begin;?></td>
@@ -423,7 +423,7 @@
</fieldset>
</div>
<div class="col-side">
<?php include '../../common/view/action.html.php';?>
<?php include '../../common/view/action.html.php';?>
</div>
</div>
</div>
+2 -1
View File
@@ -1846,7 +1846,8 @@ class projectModel extends model
$totalLeft += (($task->status == 'cancel' or $task->closedReason == 'cancel') ? 0 : $task->left);
$statusVar = 'status' . ucfirst($task->status);
$$statusVar ++;
if(!empty($task->children)){
if(!empty($task->children))
{
$taskSum += count($task->children);
foreach($task->children as $child)
{
+1 -1
View File
@@ -76,7 +76,7 @@ js::set('browseType', $browseType);
</thead>
<tbody>
<?php foreach($tasks as $task):?>
<tr class='text-center' data-id='<?php echo $task->id;?>' data-status='<?php echo $task->status?>' data-estimate='<?php echo $task->estimate?>' data-consumed='<?php echo $task->consumed?>' data-left='<?php echo $task->left?>'>
<tr class='text-center' data-id='<?php echo $task->id;?>' data-status='<?php echo $task->status?>' data-estimate='<?php echo $task->estimate?>' data-consumed='<?php echo $task->consumed?>' data-left='<?php echo $task->left?>'>
<?php foreach($customFields as $field) $this->task->printCell($field, $task, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table');?>
</tr>
<?php if(!empty($task->children)):?>
+5 -5
View File
@@ -243,11 +243,11 @@ class story extends control
$this->product->setMenu($products, $product->id, $branch);
/* Init vars. */
$planID = $plan;
$pri = 0;
$estimate = '';
$title = '';
$spec = '';
$planID = $plan;
$pri = 0;
$estimate = '';
$title = '';
$spec = '';
/* Process upload images. */
if($this->session->storyImagesFile)
+2 -2
View File
@@ -2039,7 +2039,7 @@ class taskModel extends model
$class = '';
if($id == 'status') $class .= ' task-' . $task->status;
if($id == 'id') $class .= ' cell-id';
if($id == 'name') $class .= ' text-left';
if($id == 'name') $class .= ' text-left';
if($id == 'deadline' and isset($task->delay)) $class .= ' delayed';
if($id == 'assignedTo' && $task->assignedTo == $account) $class .= ' red';
@@ -2138,7 +2138,7 @@ class taskModel extends model
}
else
{
echo $task->storyTitle;
echo "<i class='icon icon-{$this->lang->icons['story']}' title='{$task->storyTitle}'></i>";
}
}
break;
+1 -1
View File
@@ -36,7 +36,7 @@
<tr class='text-center'>
<td><?php echo $caseID . html::hidden("version[$caseID]", $cases[$caseID]->version)?></td>
<td class='text-left'><?php echo "<span title='" . $moduleOptionMenu[$cases[$caseID]->module] . "'>" . $moduleOptionMenu[$cases[$caseID]->module] . "</span>"?></td>
<td class='text-left wordwrap'><?php echo "<span title='{$cases[$caseID]->title}'>{$cases[$caseID]->title}</span>"?>我是测试的测试的测试我是测试的测试的测试我是测试的测试的测试我是测试的测试的测试我是测试的测试的测试</td>
<td class='text-left wordwrap'><?php echo "<span title='{$cases[$caseID]->title}'>{$cases[$caseID]->title}</span>"?></td>
<td class='text-left precondition wordwrap'><?php echo "<span title='{$cases[$caseID]->precondition}'>{$cases[$caseID]->precondition}</span>"?></td>
<td><?php echo html::radio("results[$caseID]", $this->lang->testcase->resultList, 'pass', "onclick='showAction(this.value,\".action$caseID\")'", 'block')?></td>
<td>