Merge branch 'master' into 'sprint/231_zg_65782'

# Conflicts:
#   module/story/control.php
This commit is contained in:
王怡栋
2022-08-25 00:51:00 +00:00
62 changed files with 632 additions and 286 deletions
+4 -5
View File
@@ -20,9 +20,8 @@ class executionEntry extends Entry
*/
public function get($executionID)
{
$fields = $this->param('fields');
$productID = $this->param('productID');
$status = $this->param('status', 'all');
$fields = $this->param('fields');
$status = $this->param('status', 'all');
$control = $this->loadController('execution', 'view');
$control->view($executionID);
@@ -47,8 +46,8 @@ class executionEntry extends Entry
foreach($executionProduct->plans as $planID)
{
$plan = new stdclass();
$plan->id = $planID;
$plan->name = $data->data->planGroups->{$productID}->{$planID};
$plan->id = trim($planID, ',');
$plan->name = $data->data->planGroups->{$productID}->{$plan->id};
$product->plans[] = $plan;
}
$execution->products[] = $product;
-1
View File
@@ -74,5 +74,4 @@ else
}
$app->parseRequest();
$app->setParams();
$app->loadModule();
@@ -85,7 +85,8 @@
<tfoot>
<tr>
<td colspan="7" class="text-center form-actions">
<?php echo html::submitButton($lang->save);?>
<?php echo html::commonButton($lang->save, "id='saveButton'", 'btn btn-primary btn-wide');?>
<?php echo html::commonButton($lang->story->saveDraft, "id='saveDraftButton'", 'btn btn-secondary btn-wide');?>
<?php echo html::backButton();?>
</td>
</tr>
+18 -20
View File
@@ -24,13 +24,21 @@
<div class="center-block">
<div class="main-header">
<h2><?php echo $lang->story->create;?></h2>
<?php if(!$this->story->checkForceReview()):?>
<div class="needNotReviewBox">
<div class='checkbox-primary'>
<input id='needNotReview' name='needNotReview' value='1' type='checkbox' class='no-margin' <?php echo $needReview;?>/>
<label for='needNotReview'><?php echo $lang->story->needNotReview;?></label>
</div>
</div>
<?php endif;?>
</div>
<form class="load-indicator main-form form-ajax" method='post' enctype='multipart/form-data' id='dataform'>
<table class="table table-form">
<tbody>
<tr>
<th><?php echo $lang->story->module;?></th>
<td>
<td colspan='2'>
<div class='input-group' id='moduleIdBox'>
<?php
echo html::select('module', $moduleOptionMenu, $moduleID, "class='form-control chosen'");
@@ -39,7 +47,7 @@
echo "<div class='input-group-addon'>";
echo html::a($this->createLink('tree', 'browse', "rootID=$productID&view=story&currentModuleID=0&branch=$branch", '', true), $lang->tree->manage, '', "class='text-primary' data-toggle='modal' data-type='iframe' data-width='90%'");
echo '&nbsp; ';
echo html::a("javascript:void(0)", $lang->refresh, '', "class='refresh' onclick='loadProductModules($productID)'");
echo html::a("javascript:void(0)", $lang->refreshIcon, '', "class='refresh' title='refresh' onclick='loadProductModules($productID)'");
echo '</div>';
}
?>
@@ -48,21 +56,13 @@
</tr>
<tr>
<th><?php echo $lang->story->reviewedBy;?></th>
<td colspan='<?php echo $type == 'story' ? 4 : 2;?>' id='reviewerBox'>
<td colspan='2' id='reviewerBox'>
<div class="table-row">
<?php $required = $this->story->checkForceReview() ? 'required' : '';?>
<?php echo $this->story->checkForceReview() ? '' : html::hidden('needNotReview', 1);?>
<div class="table-col">
<?php echo html::select('reviewer[]', $reviewers, empty($needReview) ? $product->PO : '', "class='form-control chosen' multiple");?>
<?php echo html::select('reviewer[]', $reviewers, empty($needReview) ? $product->PO : '', "class='form-control picker-select' multiple $required");?>
</div>
<?php if(!$this->story->checkForceReview()):?>
<div class="table-col w-130px">
<span class="input-group-addon" style="border: 1px solid #dcdcdc; border-left-width: 0px;">
<div class='checkbox-primary'>
<input id='needNotReview' name='needNotReview' value='1' type='checkbox' class='no-margin' <?php echo $needReview;?>/>
<label for='needNotReview'><?php echo $lang->story->needNotReview;?></label>
</div>
</span>
</div>
<?php endif;?>
</div>
</td>
</tr>
@@ -134,10 +134,6 @@
<?php echo html::textarea('spec', $spec, "rows='9' class='form-control kindeditor disabled-ie-placeholder' hidefocus='true' placeholder='" . htmlSpecialString($lang->noticePasteImg) . "'");?>
</td>
</tr>
<tr class='hide'>
<th><?php echo $lang->story->status;?></th>
<td><?php echo html::hidden('status', 'draft');?></td>
</tr>
<?php $this->printExtendFields('', 'table', 'columns=4');?>
<tr>
<th><?php echo $lang->story->legendAttatch;?></th>
@@ -147,7 +143,7 @@
<th><?php echo $lang->story->mailto;?></th>
<td colspan="4">
<div class="input-group">
<?php echo html::select('mailto[]', $users, str_replace(' ' , '', $mailto), "class='form-control chosen' data-placeholder='{$lang->chooseUsersToMail}' multiple");?>
<?php echo html::select('mailto[]', $users, str_replace(' ' , '', $mailto), "class='form-control picker-select' data-placeholder='{$lang->chooseUsersToMail}' multiple");?>
<?php echo $this->fetch('my', 'buildContactLists');?>
</div>
</td>
@@ -162,10 +158,12 @@
<tfoot>
<tr>
<td colspan="5" class="text-center form-actions">
<?php echo html::hidden('type', $type) . html::submitButton();?>
<?php echo html::hidden('type', $type);?>
<?php echo html::hidden('product', $productID);?>
<?php echo html::hidden('plan', $planID);?>
<?php echo html::hidden('vision', 'lite');?>
<?php echo html::commonButton($lang->save, "id='saveButton'", 'btn btn-primary btn-wide');?>
<?php echo html::commonButton($lang->story->saveDraft, "id='saveDraftButton'", 'btn btn-secondary btn-wide');?>
<?php echo html::backButton();?>
</td>
</tr>
+49 -10
View File
@@ -14,14 +14,16 @@
<?php include $this->app->getModuleRoot() . 'common/view/kindeditor.html.php';?>
<?php js::set('page', 'edit')?>
<?php js::set('oldProductID', $story->product);?>
<?php js::set('storyID', $story->id);?>
<?php js::set('parentStory', !empty($story->children));?>
<?php js::set('moveChildrenTips', $lang->story->moveChildrenTips);?>
<?php js::set('rawModule', $this->app->rawModule);?>
<?php js::set('reviewedReviewer', $reviewedReviewer);?>
<?php js::set('storyModule', $lang->story->module);?>
<?php js::set('reviewers', explode(',', $reviewers));?>
<?php js::set('reviewers', $reviewers);?>
<?php js::set('reviewerNotEmpty', $lang->story->notice->reviewerNotEmpty);?>
<?php js::set('feedbackSource', $config->story->feedbackSource); ?>
<?php js::set('storyStatus', $story->status);?>
<div class='main-content' id='mainContent'>
<form method='post' enctype='multipart/form-data' target='hiddenwin' id='dataform'>
<div class='main-header'>
@@ -34,7 +36,7 @@
<div class='main-row'>
<div class='main-col col-8'>
<div class='cell'>
<div class='form-group'>
<div class='form-group titleBox'>
<div class="input-control has-icon-right">
<div class="colorpicker">
<button type="button" class="btn btn-link dropdown-toggle" data-toggle="dropdown" title="<?php echo $lang->task->colorTag ?>"><span class="cp-title"></span><span class="color-bar"></span><i class="ic"></i></button>
@@ -43,12 +45,40 @@
</ul>
<input type="hidden" class="colorpicker" id="color" name="color" value="<?php echo $story->color ?>" data-icon="color" data-wrapper="input-control-icon-right" data-update-color=".story-title" data-provide="colorpicker">
</div>
<?php echo html::input('title', $story->title, 'class="form-control disabled story-title" disabled="disabled"');?>
<?php echo html::input('title', $story->title, 'class="form-control disabled story-title"' . (strpos('draft,changing', $story->status) !== false ? '' : ' disabled="disabled"'));?>
</div>
</div>
<?php if(strpos('draft,changing', $story->status) !== false):?>
<div class='detail'>
<div class='detail-title'><?php echo $lang->story->reviewers;?></div>
<div class='detail-content'>
<div class="table-row">
<?php if(!$this->story->checkForceReview()):?>
<div class="table-col">
<?php echo html::select('reviewer[]', $productReviewers, $reviewers, 'class="form-control picker-select" multiple')?>
</div>
<div class="table-col needNotReviewBox">
<span class="input-group-addon" style="border: 1px solid #dcdcdc; border-left-width: 0px;">
<div class='checkbox-primary'>
<input id='needNotReview' name='needNotReview' value='1' type='checkbox' class='no-margin' <?php echo empty($reviewers) ? 'checked' : '';?>/>
<label for='needNotReview'><?php echo $lang->story->needNotReview;?></label>
</div>
</span>
</div>
<?php else:?>
<div class="table-col">
<?php echo html::select('reviewer[]', $productReviewers, $reviewers, 'class="form-control picker-select" multiple required')?>
</div>
<?php endif;?>
</div>
</div>
</div>
<?php endif;?>
<div class='detail'>
<div class='detail-title'><?php echo $lang->story->legendSpec;?></div>
<div class='detail-content article-content'><?php echo $story->spec;?></div>
<div class='detail-content article-content'>
<?php echo strpos('draft,changing', $story->status) !== false ? html::textarea('spec', htmlSpecialString($story->spec), "rows='5' class='form-control'") : $story->spec;?>
</div>
</div>
<?php $this->printExtendFields($story, 'div', 'position=left');?>
<div class='detail'>
@@ -61,7 +91,15 @@
<?php
echo html::hidden('lastEditedDate', $story->lastEditedDate);
echo html::hidden('product', $story->product);
echo html::submitButton($lang->save);
if(strpos('draft,changing', $story->status) !== false)
{
echo html::commonButton($lang->save, "id='saveButton'", 'btn btn-primary btn-wide');
echo html::commonButton($story->status == 'changing' ? $lang->story->doNotSubmit : $lang->story->saveDraft, "id='saveDraftButton'", 'btn btn-secondary btn-wide');
}
else
{
echo html::submitButton($lang->save);
}
if(!isonlybody()) echo html::backButton();
?>
</div>
@@ -85,7 +123,7 @@
echo "<span class='input-group-addon'>";
echo html::a($this->createLink('tree', 'browse', "rootID=$story->product&view=story&currentModuleID=0&branch=$story->branch", '', true), $lang->tree->manage, '', "class='text-primary' data-toggle='modal' data-type='iframe' data-width='95%'");
echo '&nbsp; ';
echo html::a("javascript:void(0)", $lang->refresh, '', "class='refresh' onclick='loadProductModules($story->product)'");
echo html::a("javascript:void(0)", $lang->refreshIcon, '', "class='refresh' title='$lang->refresh' onclick='loadProductModules($story->product)'");
echo '</span>';
}
?>
@@ -129,7 +167,7 @@
<th><?php echo $lang->story->mailto;?></th>
<td>
<div class='input-group'>
<?php echo html::select('mailto[]', $users, str_replace(' ' , '', $story->mailto), "class='form-control chosen' multiple");?>
<?php echo html::select('mailto[]', $users, str_replace(' ' , '', $story->mailto), "class='form-control picker-select' multiple");?>
<?php echo $this->fetch('my', 'buildContactLists');?>
</div>
</td>
@@ -145,12 +183,13 @@
</tr>
<tr>
<th><?php echo $lang->story->assignedTo;?></th>
<td><?php echo html::select('assignedTo', $users, $story->assignedTo, 'class="form-control chosen"');?></td>
<?php $assignedToList = $story->status == 'closed' ? $users + array('closed' => 'Closed') : $users;?>
<td><?php echo html::select('assignedTo', $assignedToList, $story->assignedTo, 'class="form-control chosen"');?></td>
</tr>
<?php if($isShowReviewer):?>
<?php if($story->status == 'reviewing'):?>
<tr>
<th><?php echo $lang->story->reviewers;?></th>
<td><?php echo html::select('reviewer[]', $productReviewers, $reviewers, 'class="form-control chosen" multiple')?></td>
<td><?php echo html::select('reviewer[]', $productReviewers, $reviewers, 'class="form-control picker-select" multiple')?></td>
</tr>
<?php endif;?>
<?php if($story->status == 'closed'):?>
+16 -2
View File
@@ -108,7 +108,14 @@
<td class='c-actions'>
<?php
common::printIcon('story', 'change', "storyID=$child->id", $child, 'list', 'alter');
common::printIcon('story', 'review', "storyID=$child->id", $child, 'list', 'search', '', 'iframe showinonlybody', true);
if(strpos('draft,changing', $child->status) !== false)
{
common::printIcon('story', 'submitReview', "storyID=$child->id", $child, 'list', 'sub-review', '', 'iframe showinonlybody', true);
}
else
{
common::printIcon('story', 'review', "storyID=$child->id", $child, 'list', 'search', '', 'iframe showinonlybody', true);
}
common::printIcon('story', 'assignTo', "storyID=$child->id", $child, 'list', '', '', 'iframe showinonlybody', true);
common::printIcon('story', 'close', "storyID=$child->id", $child, 'list', '', '', 'iframe showinonlybody', true);
common::printIcon('story', 'activate', "storyID=$child->id", $child, 'list', '', '', 'iframe showinonlybody', true);
@@ -134,7 +141,14 @@
<?php if(!$story->deleted):?>
<?php
common::printIcon('story', 'change', "storyID=$story->id", $story, 'button', 'alter', '', 'showinonlybody');
common::printIcon('story', 'review', "storyID=$story->id", $story, 'button', 'search', '', 'showinonlybody');
if(strpos('draft,changing', $story->status) !== false)
{
common::printIcon('story', 'submitReview', "storyID=$story->id", $story, 'button', 'sub-review', '', 'iframe showinonlybody', true);
}
else
{
common::printIcon('story', 'review', "storyID=$story->id", $story, 'button', 'search', '', 'iframe showinonlybody', true);
}
if($story->status == 'active' and $story->stage == 'wait' and $story->parent <= 0 and !isonlybody())
{
$divideLang = $lang->story->subdivide;
+1 -5
View File
@@ -191,11 +191,7 @@ class api extends router
public function loadModule()
{
/* If the version of api don't exists, call parent method. */
if(!$this->version)
{
parent::setParams();
return parent::loadModule();
}
if(!$this->version) return parent::loadModule();
$entry = strtolower($this->entry);
include($this->appRoot . "api/$this->version/entries/$entry.php");
+4 -1
View File
@@ -1540,11 +1540,12 @@ class baseRouter
$_COOKIE = validater::filterParam($_COOKIE, 'cookie');
}
}
return true;
}
catch(EndResponseException $endResponseException)
{
echo $endResponseException->getContent();
return false;
}
}
@@ -2146,6 +2147,8 @@ class baseRouter
public function loadModule()
{
try {
if(is_null($this->params) and !$this->setParams()) return false;
/* 调用该方法 Call the method. */
$module = $this->control;
+5 -1
View File
@@ -1540,7 +1540,11 @@ class actionModel extends model
if($action->objectType == 'story')
{
$story = $this->loadModel('story')->getByID($action->objectID);
if(!empty($story)) $moduleName = $story->type;
if(!empty($story))
{
$moduleName = $story->type;
$action->objectLink = helper::createLink('story', 'view', "id=$story->id&version=0&param=0&storyType=$story->type");
}
}
if($action->objectType == 'doclib')
-1
View File
@@ -1569,7 +1569,6 @@ class bugModel extends model
$bugCount = $this->dao->select("count(id) as num, date_format($field, '%m/%d') as date")->from(TABLE_BUG)
->where('product')->eq($productID)
->andWhere($field)->ne('0000-00-00 00:00:00')
->andWhere($field)->ne('')
->andWhere('deleted')->eq(0)
->andWhere($field)->between($startDate, $endDate . ' 23:50:59')
->groupBy('date')
+11 -7
View File
@@ -1335,28 +1335,31 @@ class commonModel extends model
$label = $menuItem->text;
$dropMenu = '';
/* Print sub menus. */
if(isset($menuItem->dropMenu))
{
foreach($menuItem->dropMenu as $dropMenuItem)
foreach($menuItem->dropMenu as $dropMenuKey => $dropMenuItem)
{
if($dropMenuItem->hidden) continue;
if(isset($dropMenuItem->hidden) and $dropMenuItem->hidden) continue;
$subActive = '';
$subModule = '';
$subMethod = '';
$subParams = '';
$subLabel = $dropMenuItem->text;
if(isset($dropMenuItem->link['module'])) $subModule = $dropMenuItem->link['module'];
if(isset($dropMenuItem->link['method'])) $subMethod = $dropMenuItem->link['method'];
if(isset($dropMenuItem->link['vars'])) $subParams = $dropMenuItem->link['vars'];
$subLabel = '';
list($dropMenuName, $dropMenuModule, $dropMenuMethod, $dropMenuParams) = explode('|', $dropMenuItem['link']);
if(isset($dropMenuModule)) $subModule = $dropMenuModule;
if(isset($dropMenuMethod)) $subMethod = $dropMenuMethod;
if(isset($dropMenuParams)) $subParams = $dropMenuParams;
if(isset($dropMenuName)) $subLabel = $dropMenuName;
$subLink = helper::createLink($subModule, $subMethod, $subParams);
if($currentModule == strtolower($subModule) and $currentMethod == strtolower($subMethod)) $subActive = 'active';
$misc = (isset($lang->navGroup->$subModule) and $tab != $lang->navGroup->$subModule) ? "data-app='$tab'" : '';
$dropMenu .= "<li class='$subActive' data-id='$dropMenuItem->name'>" . html::a($subLink, $subLabel, '', $misc) . '</li>';
$dropMenu .= "<li class='$subActive' data-id='$dropMenuKey'>" . html::a($subLink, $subLabel, '', $misc) . '</li>';
}
if(empty($dropMenu)) continue;
@@ -2498,6 +2501,7 @@ EOD;
if($module == 'story' and !empty($params['storyType']) and strpos(",story,requirement,", ",{$params['storyType']},") !== false) $module = $params['storyType'];
if($module == 'product' and $method == 'browse' and !empty($app->params['storyType']) and $app->params['storyType'] == 'requirement') $method = 'requirement';
if($module == 'product' and $method == 'browse' and !empty($params['storyType']) and $params['storyType'] == 'requirement') $method = 'requirement';
if($module == 'story' and $method == 'linkrequirements') $module = 'requirement';
/* If the user is doing a tutorial, have all tutorial privs. */
if(defined('TUTORIAL'))
+13
View File
@@ -7,9 +7,22 @@ $(function()
{
var type = $(this).parent().attr('data-id');
if(type == 'bysearch') return;
if(type == 'more')
{
$(this).attr('href', '###');
return;
}
type = type == 'all' ? type : type.toLowerCase();
var href = createLink('design', 'browse', 'projectID=' + projectID + '&productID=' + productID + '&type=' + type);
$(this).attr('href', href);
});
if($('#subNavbar .dropdown-menu li[data-id=' + type +']').hasClass('active'))
{
var typeName = $('#subNavbar li[data-id=' + type +'] > a').html();
$('#subNavbar').find(".dropdown-hover > a").html(typeName + "<span class='caret'></span>");
$("#subNavbar li[data-id='more']").addClass('active');
}
})
+1
View File
@@ -37,6 +37,7 @@ $lang->design->createdDate = 'CreatedDate';
$lang->design->basicInfo = 'Basic Information';
$lang->design->noAssigned = 'Unassigned';
$lang->design->comment = 'Comment';
$lang->design->more = 'Mehr';
/* 动作列表. */
$lang->design->common = 'Design';
+1
View File
@@ -37,6 +37,7 @@ $lang->design->createdDate = 'CreatedDate';
$lang->design->basicInfo = 'Basic Information';
$lang->design->noAssigned = 'Unassigned';
$lang->design->comment = 'Comment';
$lang->design->more = 'More';
/* 动作列表. */
$lang->design->common = 'Design';
+1
View File
@@ -37,6 +37,7 @@ $lang->design->createdDate = 'CreatedDate';
$lang->design->basicInfo = 'Basic Information';
$lang->design->noAssigned = 'Unassigned';
$lang->design->comment = 'Comment';
$lang->design->more = 'Suite';
/* 动作列表. */
$lang->design->common = 'Design';
+1
View File
@@ -37,6 +37,7 @@ $lang->design->createdDate = '创建时间';
$lang->design->basicInfo = '基本信息';
$lang->design->noAssigned = '未指派';
$lang->design->comment = '注释';
$lang->design->more = '更多';
/* 动作列表. */
$lang->design->common = '设计';
+11 -1
View File
@@ -406,10 +406,20 @@ class designModel extends model
/* Show custom design types. */
$this->lang->waterfall->menu->design['subMenu'] = new stdclass();
$this->lang->waterfall->menu->design['subMenu']->all = array('link' => "{$this->lang->all}|design|browse|projectID=%s&productID=0&browseType=all");
$count = 1;
foreach(array_filter($this->lang->design->typeList) as $key => $value)
{
$key = strtolower($key);
$this->lang->waterfall->menu->design['subMenu']->$key = array('link' => "{$value}|design|browse|projectID=%s&productID=0&browseType={$key}");
if($count <= 4) $this->lang->waterfall->menu->design['subMenu']->$key = array('link' => "{$value}|design|browse|projectID=%s&productID=0&browseType={$key}");
if($count == 5)
{
$this->lang->waterfall->menu->design['subMenu']->more = array('link' => "{$this->lang->design->more}|design|browse|projectID=%s&productID=0&browseType={$key}", 'class' => 'dropdown dropdown-hover');
$this->lang->waterfall->menu->design['subMenu']->more['dropMenu'] = new stdclass();
}
if($count >= 5) $this->lang->waterfall->menu->design['subMenu']->more['dropMenu']->$key = array('link' => "{$value}|design|browse|projectID=%s&productID=0&browseType={$key}");
$count ++;
}
if($this->app->rawMethod == 'browse') $this->lang->waterfall->menu->design['subMenu']->bysearch = array('link' => '<a href="javascript:;" class="querybox-toggle"><i class="icon-search icon"></i> ' . $this->lang->searchAB . '</a>');
+1 -1
View File
@@ -19,4 +19,4 @@ th.c-pri{width:50px;}
.panel-actions {position: relative; padding: 0;}
.switchBtn {background-color: #fff !important;}
.switchBtn > i {padding-left: 7px;}
#main>.container {padding: 23px 20px;}
#main>.container {padding: 0 20px 20px 23px;}
+5 -3
View File
@@ -336,12 +336,13 @@ class myModel extends model
if($objectType == 'task')
{
$objectList = $this->dao->select('t1.*, t2.name as executionName, t2.type as executionType')->from($this->config->objectTables[$module])->alias('t1')
$orderBy = strpos($orderBy, 'pri_') !== false ? str_replace('pri_', 'priOrder_', $orderBy) : 't1.' . $orderBy;
$objectList = $this->dao->select("t1.*, t2.name as executionName, t2.type as executionType, IF(t1.`pri` = 0, {$this->config->maxPriValue}, t1.`pri`) as priOrder")->from($this->config->objectTables[$module])->alias('t1')
->leftJoin(TABLE_EXECUTION)->alias('t2')->on("t1.execution = t2.id")
->where('t1.deleted')->eq(0)
->andWhere('t2.deleted')->eq(0)
->andWhere('t1.id')->in(array_keys($objectIDList))
->orderBy('t1.' . $orderBy)
->orderBy($orderBy)
->page($pager)
->fetchAll('id');
}
@@ -582,7 +583,8 @@ class myModel extends model
$query = preg_replace('/`(\w+)`/', 't1.`$1`', $query);
$query = str_replace('t1.`project`', 't2.`project`', $query);
$tasks = $this->dao->select('t1.*, t2.id as executionID, t2.name as executionName, t2.type as executionType, t3.id as storyID, t3.title as storyTitle, t3.status AS storyStatus, t3.version AS latestStoryVersion')
$orderBy = str_replace('pri_', 'priOrder_', $orderBy);
$tasks = $this->dao->select("t1.*, t2.id as executionID, t2.name as executionName, t2.type as executionType, t3.id as storyID, t3.title as storyTitle, t3.status AS storyStatus, t3.version AS latestStoryVersion, IF(t1.`pri` = 0, {$this->config->maxPriValue}, t1.`pri`) as priOrder")
->from(TABLE_TASK)->alias('t1')
->leftJoin(TABLE_EXECUTION)->alias('t2')->on("t1.execution = t2.id")
->leftJoin(TABLE_STORY)->alias('t3')->on('t1.story = t3.id')
+23 -6
View File
@@ -103,7 +103,15 @@
{
$vars = "story={$story->id}";
echo common::buildIconButton('story', 'change', "$vars&from=&storyType=requirement", $story, 'list', 'alter', '', 'iframe', true);
echo common::buildIconButton('story', 'review', "$vars&from=product&storyType=requirement", $story, 'list', 'search', '', 'iframe', true);
if(strpos('draft,changing', $story->status) !== false)
{
echo common::buildIconButton('story', 'submitReview', "$vars&storyType=requirement", $story, 'list', 'sub-review', '', 'iframe', true);
}
else
{
echo common::buildIconButton('story', 'review', "$vars&from=product&storyType=requirement", $story, 'list', 'search', '', 'iframe', true);
}
echo common::buildIconButton('story', 'recall', "$vars&from=list&storyType=requirement", $story, 'list', 'undo', 'hiddenwin', '', '', '', $lang->story->recall);
echo common::buildIconButton('story', 'close', "$vars&from=&storyType=requirement", $story, 'list', '', '', 'iframe', true);
echo common::buildIconButton('story', 'edit', "$vars&from=default&storyType=requirement", $story, 'list', '', '', 'iframe', true, "data-width='95%'");
@@ -147,11 +155,20 @@
}
else
{
common::printIcon('story', 'change', $vars, $child, 'list', 'alter');
common::printIcon('story', 'review', $vars, $child, 'list', 'search');
common::printIcon('story', 'close', $vars, $child, 'list', '', '', 'iframe', true);
common::printIcon('story', 'edit', $vars, $child, 'list');
common::printIcon('story', 'createCase', "productID=$child->product&branch=$child->branch&module=0&from=&param=0&$vars", $child, 'list', 'sitemap');
common::printIcon('story', 'change', "$vars&from=&storyType=requirement", $child, 'list', 'alter', '', 'iframe', true);
if(strpos('draft,changing', $child->status) !== false)
{
common::printIcon('story', 'submitReview', "$vars&storyType=requirement", $child, 'list', 'sub-review', '', 'iframe', true);
}
else
{
common::printIcon('story', 'review', "$vars&from=product&storyType=requirement", $child, 'list', 'search', '', 'iframe', true);
}
common::printIcon('story', 'recall', "$vars&from=list&storyType=requirement", $child, 'list', 'undo', 'hiddenwin', '', '', '', $lang->story->recall);
common::printIcon('story', 'close', "$vars&from=&storyType=requirement", $child, 'list', '', '', 'iframe', true);
common::printIcon('story', 'edit', "$vars&from=default&storyType=requirement", $child, 'list');
}
}
?>
+21 -3
View File
@@ -105,7 +105,16 @@
{
$vars = "story={$story->id}";
echo common::buildIconButton('story', 'change', $vars, $story, 'list', 'alter', '', 'iframe', true);
echo common::buildIconButton('story', 'review', $vars, $story, 'list', 'search', '', 'iframe', true);
if(strpos('draft,changing', $story->status) !== false)
{
echo common::buildIconButton('story', 'submitReview', $vars, $story, 'list', 'sub-review', '', 'iframe', true);
}
else
{
echo common::buildIconButton('story', 'review', $vars, $story, 'list', 'search', '', 'iframe', true);
}
echo common::buildIconButton('story', 'recall', $vars, $story, 'list', 'undo', 'hiddenwin', '', '', '', $lang->story->recall);
echo common::buildIconButton('story', 'close', $vars, $story, 'list', '', '', 'iframe', true);
echo common::buildIconButton('story', 'edit', $vars, $story, 'list', '', '', 'iframe', true, "data-width='95%'");
@@ -145,8 +154,17 @@
if($canBeChanged)
{
$vars = "story={$child->id}";
common::printIcon('story', 'change', $vars, $child, 'list', 'alter', '', 'iframe', true);
common::printIcon('story', 'review', $vars, $child, 'list', 'search', '', 'iframe', true);
common::printIcon('story', 'change', $vars, $child, 'list', 'alter', '', 'iframe', true);
if(strpos('draft,changing', $child->status) !== false)
{
common::printIcon('story', 'submitReview', $vars, $child, 'list', 'sub-review', '', 'iframe', true);
}
else
{
common::printIcon('story', 'review', $vars, $child, 'list', 'search', '', 'iframe', true);
}
common::printIcon('story', 'recall', $vars, $child, 'list', 'undo', 'hiddenwin', '', '', '', $lang->story->recall);
common::printIcon('story', 'close', $vars, $child, 'list', '', '', 'iframe', true);
common::printIcon('story', 'edit', $vars, $child, 'list', '', '', 'iframe', true, "data-width='95%'");
common::printIcon('story', 'createCase', "productID=$child->product&branch=$child->branch&module=0&from=&param=0&$vars", $child, 'list', 'sitemap', '', 'iframe', true, "data-width='95%'");
+15 -15
View File
@@ -207,23 +207,23 @@ $lang->product->noModule = '<div>Kein Modul</div><div>Jetzt verwalten</div
$lang->product->noProduct = 'Kein Produkt. ';
$lang->product->noMatched = '"%s" kann nicht gefunden werden.' . $lang->productCommon;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['reviewbyme'] = $lang->product->reviewByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['reviewbyme'] = $lang->product->reviewByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['all']['all'] = $lang->product->allProduct;
$lang->product->featureBar['all']['noclosed'] = $lang->product->unclosed;
$lang->product->featureBar['all']['closed'] = $lang->product->statusList['closed'];
$lang->product->moreSelects['assignedbyme'] = $lang->product->assignedByMe;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
$lang->product->moreSelects['assignedbyme'] = $lang->product->assignedByMe;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
+15 -15
View File
@@ -207,23 +207,23 @@ $lang->product->noModule = '<div>You have no modules. </div><div>Manage No
$lang->product->noProduct = "No {$lang->productCommon} yet. ";
$lang->product->noMatched = '"%s" cannot be found.' . $lang->productCommon;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['reviewbyme'] = $lang->product->reviewByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['reviewbyme'] = $lang->product->reviewByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['all']['all'] = $lang->product->allProduct;
$lang->product->featureBar['all']['noclosed'] = $lang->product->unclosed;
$lang->product->featureBar['all']['closed'] = $lang->product->statusList['closed'];
$lang->product->moreSelects['assignedbyme'] = $lang->product->assignedByMe;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
$lang->product->moreSelects['assignedbyme'] = $lang->product->assignedByMe;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
+15 -15
View File
@@ -207,23 +207,23 @@ $lang->product->noModule = "<div>Vous n'avez aucun modules. </div><div>Gé
$lang->product->noProduct = "No {$lang->productCommon} à ce jour. ";
$lang->product->noMatched = '"%s" cannot be found.' . $lang->productCommon;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['reviewbyme'] = $lang->product->reviewByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['reviewbyme'] = $lang->product->reviewByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['all']['all'] = $lang->product->allProduct;
$lang->product->featureBar['all']['noclosed'] = $lang->product->unclosed;
$lang->product->featureBar['all']['closed'] = $lang->product->statusList['closed'];
$lang->product->moreSelects['assignedbyme'] = $lang->product->assignedByMe;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
$lang->product->moreSelects['assignedbyme'] = $lang->product->assignedByMe;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
+13 -13
View File
@@ -166,21 +166,21 @@ $lang->product->noModule = '<div>Chưa có Module. </div><div>Quản lý n
$lang->product->noProduct = "Không có {$lang->productCommon} nào.";
$lang->product->noMatched = '"%s" không thể tìm thấy ' . $lang->productCommon;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['all']['all'] = $lang->product->allProduct;
$lang->product->featureBar['all']['noclosed'] = $lang->product->unclosed;
$lang->product->featureBar['all']['closed'] = $lang->product->statusList['closed'];
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
+15 -15
View File
@@ -207,23 +207,23 @@ $lang->product->noModule = "<div>您现在还没有模块信息</div><div>
$lang->product->noProduct = "暂时没有{$lang->productCommon}。";
$lang->product->noMatched = '找不到包含"%s"的' . $lang->productCommon;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['reviewbyme'] = $lang->product->reviewByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['browse']['allstory'] = $lang->product->allStory;
$lang->product->featureBar['browse']['unclosed'] = $lang->product->unclosed;
$lang->product->featureBar['browse']['assignedtome'] = $lang->product->assignedToMe;
$lang->product->featureBar['browse']['openedbyme'] = $lang->product->openedByMe;
$lang->product->featureBar['browse']['reviewedbyme'] = $lang->product->reviewedByMe;
$lang->product->featureBar['browse']['reviewbyme'] = $lang->product->reviewByMe;
$lang->product->featureBar['browse']['draftstory'] = $lang->product->draftStory;
$lang->product->featureBar['browse']['more'] = $lang->more;
$lang->product->featureBar['all']['all'] = '所有' . $lang->productCommon;
$lang->product->featureBar['all']['noclosed'] = $lang->product->unclosed;
$lang->product->featureBar['all']['closed'] = $lang->product->statusList['closed'];
$lang->product->moreSelects['assignedbyme'] = $lang->product->assignedByMe;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
$lang->product->moreSelects['assignedbyme'] = $lang->product->assignedByMe;
$lang->product->moreSelects['closedbyme'] = $lang->product->closedByMe;
$lang->product->moreSelects['activestory'] = $lang->product->activeStory;
$lang->product->moreSelects['changingstory'] = $lang->product->changingStory;
$lang->product->moreSelects['reviewingstory'] = $lang->product->reviewingStory;
$lang->product->moreSelects['willclose'] = $lang->product->willClose;
$lang->product->moreSelects['closedstory'] = $lang->product->closedStory;
+1 -1
View File
@@ -43,7 +43,7 @@ $config->story->list->customCreateFields = 'source,verify,pri,estimate,mail
$config->story->list->customBatchCreateFields = 'plan,spec,source,verify,pri,estimate,review,keywords';
$config->story->list->customBatchEditFields = 'branch,plan,estimate,pri,assignedTo,source,stage,closedBy,closedReason,keywords';
$config->story->list->actionsOpratedParentStory = ',edit,batchcreate,change,review,recall,';
$config->story->list->actionsOpratedParentStory = ',edit,batchcreate,change,review,recall,submitreview,';
$config->story->custom = new stdclass();
$config->story->custom->createFields = $config->story->list->customCreateFields;
+20 -15
View File
@@ -137,7 +137,7 @@ class story extends control
$response['message'] = sprintf($this->lang->duplicate, $this->lang->story->common);
if($objectID == 0)
{
$response['locate'] = $this->createLink('story', 'view', "storyID={$storyID}");
$response['locate'] = $this->createLink('story', 'view', "storyID={$storyID}&version=0&param=0&storyType=$storyType");
}
else
{
@@ -563,7 +563,7 @@ class story extends control
if($storyID)
{
return print(js::locate(inlink('view', "storyID=$storyID"), 'parent'));
return print(js::locate(inlink('view', "storyID=$storyID&version=0&param=0&storyType=$storyType"), 'parent'));
}
elseif($executionID)
{
@@ -796,7 +796,8 @@ class story extends control
}
}
if(defined('RUN_MODE') && RUN_MODE == 'api') return $this->send(array('status' => 'success', 'data' => $storyID));
return print(js::locate($this->createLink($this->app->rawModule, 'view', "storyID=$storyID"), 'parent'));
$params = $this->app->rawModule == 'story' ? "storyID=$storyID&version=0&param=0&storyType=$storyType" : "storyID=$storyID";
return print(js::locate($this->createLink($this->app->rawModule, 'view', $params), 'parent'));
}
$this->commonAction($storyID);
@@ -1136,7 +1137,8 @@ class story extends control
}
if(defined('RUN_MODE') && RUN_MODE == 'api') return $this->send(array('status' => 'success'));
return print(js::locate($this->createLink($module, 'view', "storyID=$storyID"), 'parent'));
$params = $module == 'story' ? "storyID=$storyID&version=0&param=0&storyType=$storyType" : "storyID=$storyID";
return print(js::locate($this->createLink($module, 'view', $params), 'parent'));
}
$this->commonAction($storyID);
@@ -1207,7 +1209,7 @@ class story extends control
return print(js::closeModal('parent.parent', 'this'));
}
}
return print(js::locate($this->createLink('story', 'view', "storyID=$storyID"), 'parent'));
return print(js::locate($this->createLink('story', 'view', "storyID=$storyID&version=0&param=0&storyType=$storyType"), 'parent'));
}
$this->commonAction($storyID);
@@ -1339,7 +1341,7 @@ class story extends control
if($confirm == 'no')
{
return print(js::confirm($this->lang->story->confirmDelete, $this->createLink('story', 'delete', "story=$storyID&confirm=yes&from=$from"), ''));
return print(js::confirm($this->lang->story->confirmDelete, $this->createLink('story', 'delete', "story=$storyID&confirm=yes&from=$from&storyType=$storyType"), ''));
}
else
{
@@ -1434,7 +1436,8 @@ class story extends control
$module = $from == 'project' ? 'projectstory' : 'story';
if(defined('RUN_MODE') and RUN_MODE == 'api') return $this->send(array('status' => 'success', 'data' => $storyID));
return print(js::locate($this->createLink($module, 'view', "storyID=$storyID"), 'parent'));
$params = $module == 'story' ? "storyID=$storyID&version=0&param=0&storyType=$storyType" : "storyID=$storyID";
return print(js::locate($this->createLink($module, 'view', $params), 'parent'));
}
/* Get story and product. */
@@ -1537,7 +1540,7 @@ class story extends control
$action = $story->status == 'changing' ? 'recalledChange' : 'Recalled';
$this->loadModel('action')->create('story', $storyID, $action);
if($from == 'view') return print(js::locate($this->createLink('story', 'view', "storyID=$storyID"), 'parent'));
if($from == 'view') return print(js::locate($this->createLink('story', 'view', "storyID=$storyID&version=0&param=0&storyType=$storyType"), 'parent'));
$locateLink = $this->session->storyList ? $this->session->storyList : $this->createLink('product', 'browse', "productID={$story->product}");
return print(js::locate($locateLink, 'parent'));
@@ -1566,7 +1569,7 @@ class story extends control
}
if(isonlybody()) return print(js::closeModal('parent.parent', 'this'));
return print(js::locate($this->createLink('story', 'view', "storyID=$storyID"), 'parent'));
return print(js::locate($this->createLink('story', 'view', "storyID=$storyID&version=0&param=0&storyType=$storyType"), 'parent'));
}
/* Get story and product. */
@@ -1659,7 +1662,7 @@ class story extends control
}
else
{
return print(js::locate(inlink('view', "storyID=$storyID"), 'parent'));
return print(js::locate(inlink('view', "storyID=$storyID&version=0&param=0&storyType=$storyType"), 'parent'));
}
}
@@ -1672,8 +1675,9 @@ class story extends control
$this->product->setMenu($product->id, $story->branch);
/* Set the closed reason options and remove subdivided options. */
if($story->status == 'draft') unset($this->lang->story->reasonList['cancel']);
unset($this->lang->story->reasonList['subdivided']);
$reasonList = $this->lang->story->reasonList;
if($story->status == 'draft') unset($reasonList['cancel']);
unset($reasonList['subdivided']);
$branch = $product->type == 'branch' ? ($story->branch > 0 ? $story->branch : '0') : 'all';
$productStories = $this->story->getProductStoryPairs($story->product, $branch, 0, 'all', 'id_desc', 0, '');
@@ -1688,7 +1692,7 @@ class story extends control
$this->view->productStories = $productStories;
$this->view->actions = $this->action->getList('story', $storyID);
$this->view->users = $this->loadModel('user')->getPairs();
$this->view->reasonList = $this->lang->story->reasonList;
$this->view->reasonList = $reasonList;
$this->display();
}
@@ -2050,7 +2054,7 @@ class story extends control
return print(js::closeModal('parent.parent', 'this', 'function(){parent.parent.$(\'[data-ride="searchList"]\').searchList();}'));
}
}
return print(js::locate($this->createLink('story', 'view', "storyID=$storyID"), 'parent'));
return print(js::locate($this->createLink('story', 'view', "storyID=$storyID&version=0&param=0&storyType=$storyType"), 'parent'));
}
/* Get story and product. */
@@ -2227,9 +2231,10 @@ class story extends control
$products = $this->product->getPairs();
$queryID = ($browseType == 'bySearch') ? (int)$param : 0;
$type = $story->type == 'story' ? 'linkRelateSR' : 'linkRelateUR';
$method = $story->type == 'story' ? 'linkStories' : 'linkRequirements';
/* Build search form. */
$actionURL = $this->createLink('story', 'linkStories', "storyID=$storyID&browseType=bySearch&excludeStories=$excludeStories&queryID=myQueryID", '', true);
$actionURL = $this->createLink('story', $method, "storyID=$storyID&browseType=bySearch&excludeStories=$excludeStories&queryID=myQueryID", '', true);
$this->product->buildSearchForm($story->product, $products, $queryID, $actionURL);
$this->view->story = $story;
+1
View File
@@ -12,6 +12,7 @@ $(function()
$('.input-group-addon').addClass('required');
}
});
if(!$('#reviewer').val()) $('#needNotReview').change();
if($('.tabs .tab-content .tab-pane.active').children().length == 0) $('.tabs .nav-tabs li.active').css('border-bottom', '1px solid #ccc');
});
+9 -17
View File
@@ -608,7 +608,6 @@ class storyModel extends model
$this->dao->insert(TABLE_STORYSPEC)->data($specData)->exec();
/* Save the story reviewer to storyreview table. */
$assignedTo = '';
foreach($_POST['reviewer'][$i] as $reviewer)
{
if(empty($reviewer)) continue;
@@ -618,10 +617,7 @@ class storyModel extends model
$reviewData->version = 1;
$reviewData->reviewer = $reviewer;
$this->dao->insert(TABLE_STORYREVIEW)->data($reviewData)->exec();
if(empty($assignedTo)) $assignedTo = $reviewer;
}
if($assignedTo) $this->dao->update(TABLE_STORY)->set('assignedTo')->eq($assignedTo)->set('assignedDate')->eq($now)->where('id')->eq($storyID)->exec();
$this->executeHooks($storyID);
@@ -1511,10 +1507,11 @@ class storyModel extends model
foreach($storyIdList as $storyID)
{
if(!$storyID) continue;
$oldStory = $oldStories[$storyID];
$isSuperReviewer = strpos(',' . trim(zget($this->config->story, 'superReviewers', ''), ',') . ',', ',' . $this->app->user->account . ',');
if($oldStory->status != 'draft' and $oldStory->status != 'changing') continue;
$isSuperReviewer = strpos(',' . trim(zget($this->config->story, 'superReviewers', ''), ',') . ',', ',' . $this->app->user->account . ',');
$oldStory = $oldStories[$storyID];
if($oldStory->status != 'reviewing') continue;
if(!in_array($this->app->user->account, array_keys($reviewerList[$storyID])) and $isSuperReviewer === false) continue;
if(isset($hasResult[$storyID]) and $hasResult[$storyID]->version == $oldStories[$storyID]->version) continue;
@@ -1633,7 +1630,6 @@ class storyModel extends model
if(isset($_POST['reviewer']))
{
$assignedTo = '';
foreach($this->post->reviewer as $reviewer)
{
if(empty($reviewer)) continue;
@@ -1643,10 +1639,7 @@ class storyModel extends model
$reviewData->version = $oldStory->version;
$reviewData->reviewer = $reviewer;
$this->dao->insert(TABLE_STORYREVIEW)->data($reviewData)->exec();
if(empty($assignedTo)) $assignedTo = $reviewer;
}
if($assignedTo) $this->dao->update(TABLE_STORY)->set('assignedTo')->eq($assignedTo)->set('assignedDate')->eq(helper::now())->where('id')->eq($storyID)->exec();
$story->status = 'reviewing';
}
@@ -2355,8 +2348,6 @@ class storyModel extends model
->add('closedDate', '0000-00-00')
->add('reviewedBy', '')
->add('reviewedDate', '0000-00-00')
->add('changedBy', '')
->add('changedDate', '0000-00-00')
->add('duplicateStory', 0)
->add('childStories', '')
->setDefault('lastEditedBy', $this->app->user->account)
@@ -4182,7 +4173,7 @@ class storyModel extends model
$isSuperReviewer = strpos(',' . trim(zget($config->story, 'superReviewers', ''), ',') . ',', ',' . $app->user->account . ',');
if($action == 'change') return ($isSuperReviewer !== false or $story->status == 'active');
if($action == 'change') return (($isSuperReviewer !== false or count($story->reviewer) == 0 or count($story->notReview) == 0) and $story->status == 'active');
if($action == 'review') return (($isSuperReviewer !== false or in_array($app->user->account, $story->notReview)) and $story->status == 'reviewing');
if($action == 'recall') return strpos('reviewing,changing', $story->status) !== false;
if($action == 'close') return $story->status != 'closed';
@@ -4300,7 +4291,7 @@ class storyModel extends model
if($type == 'view')
{
$menu .= $this->buildMenu('story', 'change', $params . "&from=&storyType=$story->type", $story, $type, 'alter', '', 'showinonlybody');
if($story->status == 'draft') $menu .= $this->buildMenu('story', 'submitReview', $params . "&storyType=$story->type", $story, $type, 'sub-review', '', 'showinonlybody iframe', true, "data-width='50%'");
if(strpos('draft,changing', $story->status) !== false) $menu .= $this->buildMenu('story', 'submitReview', $params . "&storyType=$story->type", $story, $type, 'sub-review', '', 'showinonlybody iframe', true, "data-width='50%'");
$title = $story->status == 'changing' ? $this->lang->story->recallChange : $this->lang->story->recall;
$menu .= $this->buildMenu('story', 'recall', $params . "&from=view&confirm=no&storyType=$story->type", $story, $type, 'undo', 'hiddenwin', 'showinonlybody', false, '', $title);
@@ -4578,7 +4569,7 @@ class storyModel extends model
$executionID = empty($execution) ? $this->session->execution : $execution->id;
$account = $this->app->user->account;
$storyLink = helper::createLink('story', 'view', "storyID=$story->id&version=0&param=0&storyType=$story->type");
$canView = common::hasPriv('story', 'view');
$canView = common::hasPriv($story->type, 'view', null, "storyType=$story->type");
if($tab == 'project')
{
@@ -5572,7 +5563,8 @@ class storyModel extends model
if($reviewRule == 'halfpass')
{
if($rejectCount == floor(count($revireList) / 2)) return 'closed';
/* When the number of reviewers is even, half of them reject to close. */
if(count($reviewerList) > 1 and count($reviewerList) % 2 == 0 and $rejectCount == floor(count($reviewerList) / 2)) return 'closed';
if($passCount >= floor(count($reviewerList) / 2) + 1) $status = 'active';
if($rejectCount >= floor(count($reviewerList) / 2) + 1) $status = 'closed';
+1 -1
View File
@@ -131,8 +131,8 @@
<tfoot>
<tr>
<td colspan="<?php echo count($visibleFields) + 3?>" class="text-center form-actions">
<?php echo html::commonButton($lang->story->saveDraft, "id='saveDraftButton'", 'btn btn-secondary btn-wide');?>
<?php echo html::commonButton($lang->save, "id='saveButton'", 'btn btn-primary btn-wide');?>
<?php echo html::commonButton($lang->story->saveDraft, "id='saveDraftButton'", 'btn btn-secondary btn-wide');?>
<?php echo html::backButton();?>
</td>
</tr>
+3 -8
View File
@@ -147,16 +147,11 @@ foreach(explode(',', $config->story->create->requiredFields) as $field)
<th><?php echo $lang->story->reviewedBy;?></th>
<td colspan='2' id='reviewerBox'>
<div class="table-row">
<?php if(!$this->story->checkForceReview()):?>
<?php $required = $this->story->checkForceReview() ? 'required' : '';?>
<?php echo $this->story->checkForceReview() ? '' : html::hidden('needNotReview', 1);?>
<div class="table-col">
<?php echo html::select('reviewer[]', $reviewers, empty($needReview) ? $product->PO : '', "class='form-control picker-select' multiple");?>
<?php echo html::select('reviewer[]', $reviewers, empty($needReview) ? $product->PO : '', "class='form-control picker-select' multiple $required");?>
</div>
<?php echo html::hidden('needNotReview', 1);?>
<?php else:?>
<div class="table-col">
<?php echo html::select('reviewer[]', $reviewers, empty($needReview) ? $product->PO : '', "class='form-control picker-select' multiple required");?>
</div>
<?php endif;?>
</div>
</td>
</tr>
+1 -1
View File
@@ -18,7 +18,7 @@
<span class='label label-id'><?php echo $story->id;?></span>
<?php echo html::a($this->createLink('story', 'view', "storyID=$story->id"), $story->title, '_blank', "title='$story->title'");?>
<?php $title = $story->type == 'story' ? $lang->story->linkStoriesAB : $lang->story->linkRequirementsAB?>
<small class='text-muted'> <?php echo $lang->arrow . $lang->story->linkStoriesAB;?></small>
<small class='text-muted'> <?php echo $lang->arrow . $title;?></small>
</h2>
</div>
<div id='queryBox' data-module='story' class='show divider'></div>
+4 -2
View File
@@ -2367,7 +2367,8 @@ class taskModel extends model
public function getExecutionTasks($executionID, $productID = 0, $type = 'all', $modules = 0, $orderBy = 'status_asc, id_desc', $pager = null)
{
if(is_string($type)) $type = strtolower($type);
$fields = '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';
$orderBy = str_replace('pri_', 'priOrder_', $orderBy);
$fields = "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, IF(t1.`pri` = 0, {$this->config->maxPriValue}, t1.`pri`) as priOrder";
$this->config->edition == 'max' && $fields .= ', t6.name as designName, t6.version as latestDesignVersion';
$actionIDList = array();
@@ -2510,7 +2511,8 @@ class taskModel extends model
public function getUserTasks($account, $type = 'assignedTo', $limit = 0, $pager = null, $orderBy = "id_desc", $projectID = 0)
{
if(!$this->loadModel('common')->checkField(TABLE_TASK, $type)) return array();
$tasks = $this->dao->select('t1.*, t2.id as executionID, t2.name as executionName, t2.type as executionType, t3.id as storyID, t3.title as storyTitle, t3.status AS storyStatus, t3.version AS latestStoryVersion')
$orderBy = str_replace('pri_', 'priOrder_', $orderBy);
$tasks = $this->dao->select("t1.*, t2.id as executionID, t2.name as executionName, t2.type as executionType, t3.id as storyID, t3.title as storyTitle, t3.status AS storyStatus, t3.version AS latestStoryVersion, IF(t1.`pri` = 0, {$this->config->maxPriValue}, t1.`pri`) as priOrder")
->from(TABLE_TASK)->alias('t1')
->leftJoin(TABLE_EXECUTION)->alias('t2')->on("t1.execution = t2.id")
->leftJoin(TABLE_STORY)->alias('t3')->on('t1.story = t3.id')
+45
View File
@@ -547,6 +547,7 @@ class upgradeModel extends model
$this->updateOSAndBrowserOfBug();
$this->addURPriv();
$this->updateStoryStatus();
if(strpos($fromVersion, 'max') !== false) $this->syncCase2Project();
break;
}
@@ -7157,4 +7158,48 @@ class upgradeModel extends model
$this->dbh->exec($sql);
return true;
}
/**
* Sync case to project|execution if case create from import.
*
* @access public
* @return void
*/
public function syncCase2Project()
{
$linkStoryCases = $this->dao->select('id, story, version, product')->from(TABLE_CASE)->where('story')->ne('0')->fetchAll('id');
$linkProjectCases = $this->dao->select('`case`, project')->from(TABLE_PROJECTCASE)->where('`case`')->ne('0')->andWhere('project')->ne('0')->fetchGroup('case', 'project');
if(empty($linkStoryCases)) return true;
$projectList = $this->dao->select('t1.project, t1.story, t1.product')->from(TABLE_PROJECTSTORY)->alias('t1')
->leftjoin(TABLE_PROJECT)->alias('t2')->on('t1.project=t2.id')
->where('t2.status')->ne('closed')
->fetchGroup('story', 'project');
if(empty($projectList)) return true;
foreach($linkStoryCases as $caseID => $case)
{
/* If story unlink project continue. */
if(!isset($projectList[$case->story])) continue;
$storyProjects = $projectList[$case->story];
$lastOrder = 1;
foreach($storyProjects as $projectID => $value)
{
/* If case linked project continue.*/
if(isset($linkProjectCases[$caseID][$projectID])) continue;
$data = new stdclass();
$data->project = $projectID;
$data->product = $case->product;
$data->case = $caseID;
$data->version = $case->version;
$data->order = $lastOrder ++;
$this->dao->insert(TABLE_PROJECTCASE)->data($data)->exec();
}
}
}
}
-1
View File
@@ -32,5 +32,4 @@ $common = $app->loadCommon();
$app->moduleName = 'cron';
$app->methodName = 'ajaxExec';
$app->setControlFile();
$app->setParams();
$app->loadModule();
+89
View File
@@ -2080,4 +2080,93 @@ class bugTest
return $title;
}
}
/**
* Test get statistic.
*
* @param int $productID
* @access public
* @return string
*/
public function getStatisticTest($productID = 0)
{
$dates = $this->objectModel->getStatistic($productID);
$returns = array();
$today = date('m/d', time());
foreach($dates as $dateType => $dateList)
{
$returns[$dateType] = $dateList[$today];
}
if(dao::isError())
{
return dao::getError();
}
else
{
return $returns;
}
}
/**
* Test get bugs to review.
*
* @param array $productIDList
* @param int|string $branch
* @param array $modules
* @param array $executions
* @param string $orderBy
* @access public
* @return string
*/
public function getReviewBugsTest($productIDList, $branch, $modules, $executions, $orderBy)
{
$bugs = $this->objectModel->getReviewBugs($productIDList, $branch, $modules, $executions, $orderBy);
$ids = '';
foreach($bugs as $bug)
{
$ids .= ",$bug->id";
}
$ids = trim($ids, ',');
if(dao::isError())
{
return dao::getError();
}
else
{
return $ids;
}
}
/**
* Test get related objects id lists.
*
* @param array $productIDList
* @param int|string $branch
* @param array $modules
* @param array $executions
* @param string $orderBy
* @access public
* @return string
*/
public function getRelatedObjectsTest($object, $pairs)
{
$objects = $this->objectModel->getRelatedObjects($object, $pairs);
$ids = '';
foreach($objects as $objectID => $object)
{
$ids .= ",$objectID:$object";
}
$ids = trim($ids, ',');
if(dao::isError())
{
return dao::getError();
}
else
{
return $ids;
}
}
}
+9 -11
View File
@@ -1604,33 +1604,31 @@ class executionTest
}
/**
* function getBurnDataFlot test by execution
* Function getBurnDataFlot test by execution.
*
* @param int $executionID
* @param string $count
* @param int $executionID
* @access public
* @return array
* @return int
*/
public function getBurnDataFlotTest($executionID = 0, $count)
public function getBurnDataFlotTest($executionID = 0)
{
$date = date("Y-m-d");
$object = $this->objectModel->getBurnDataFlot($executionID, $burnBy = 'left');
$todayData = array();
foreach ($object[$date] as $key => $value) $todayData[$key] = $value;
if(isset($object[$date]))
{
foreach($object[$date] as $key => $value) $todayData[$key] = $value;
}
if(dao::isError())
{
$error = dao::getError();
return $error;
}
elseif($count == "1")
{
return sizeof($todayData);
}
else
{
return $object;
return sizeof($todayData);
}
}
+1 -3
View File
@@ -16,7 +16,6 @@ pid=1
指派bugID为3的bug >> assignedTo,admin,user94
指派bugID为4的bug >> assignedTo,admin,user95
指派bugID为51的bug >> assignedTo,dev1,user96
指派bugID为81的bug >> assignedTo,test1,user97
指派人不发生变化的bug >> 0
*/
@@ -36,6 +35,5 @@ r($bug->assignTest($bugIDlist[1],$bug2)) && p('0:field,old,new') && e('assigned
r($bug->assignTest($bugIDlist[2],$bug3)) && p('0:field,old,new') && e('assignedTo,admin,user94'); // 指派bugID为3的bug
r($bug->assignTest($bugIDlist[3],$bug4)) && p('0:field,old,new') && e('assignedTo,admin,user95'); // 指派bugID为4的bug
r($bug->assignTest($bugIDlist[4],$bug51)) && p('0:field,old,new') && e('assignedTo,dev1,user96'); // 指派bugID为51的bug
r($bug->assignTest($bugIDlist[5],$bug81)) && p('0:field,old,new') && e('assignedTo,test1,user97'); // 指派bugID为81的bug
r($bug->assignTest($bugIDlist[5],$bug81)) && p() && e('0'); // 指派人不发生变化的bug
$db->restoreDB();
$db->restoreDB();
+3 -3
View File
@@ -10,7 +10,7 @@ title=bugModel->getBugQuery();
cid=1
pid=1
查询 `product` = 'all' 的bugQuery >> 1 AND `product` IN ('1','2','3','4','5','6','7','8','9','10','11','12','13','14','15','16','17','18','19','20','21','22','23','24','25','26','27','28','29','30','31','32','33','34','35','36','37','38','39','40','41','42','43','44','45','46','47','48','49','50','51','52','53','54','55','56','57','58','59','60','61','62','63','64','65','66','67','68','69','70','71','72','73','74','75','76','77','78','79','80','81','82','83','84','85','86','87','88','89','90','91','92','93','94','95','96','97','98','99','100','101','102','103','104','105','106','107','108','109','110','111','112','113','114','115','116','117','118','119','120','1','2','3','4','5','6','7','8','9','10','21','22','23','24','25','26','27','28','29','30','41','42','43','44','45','46','47','48','49','50','61','62','63','64','65','66','67','68','69','70','81','82','83','84','85','86','87','88','89','90','101','102','103','104','105','106','107','108','109','110
查询 `product` = 'all' 的bugQuery >> 1 AND `product` IN ('1','2','3','4','5','6','7','8','9','10','21','22','23','24','25','26','27','28','29','30','41','42','43','44','45','46','47','48','49','50','61','62','63','64','65','66','67','68','69','70','81','82','83','84','85','86','87','88','89','90','101','102','103','104','105','106','107','108','109','110','11','12','13','14','15','16','17','18','19','20','31','32','33','34','35','36','37','38','39','40','51','52','53','54','55','56','57','58','59','60','71','72','73','74','75','76','77','78','79','80','91','92','93','94','95','96','97','98','99','100','111','112','113','114','115','116','117','118','119','120','1','2','3','4','5','6','7','8','9','10','21','22','23','24','25','26','27','28','29','30','41','42','43','44','45','46','47','48','49','50','61','62','63','64','65','66','67','68','69','70','81','82','83','84','85','86','87','88','89','90','101','102','103','104','105','106','107','108','109','110')
查询 `project` = 'all' 的bugQuery >> 1 AND `project` in (11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,731,732,733,734,735,736,737,738,739,740,741,742,743,744,745,746,747,748,749,750)
查询 `resolvedDate` = '2022-01-01' 的bugQuery >> `resolvedDate` != '0000-00-00 00:00:00' AND `resolvedDate` > '2022-01-01'
查询 `closedDate` = '2022-01-01' 的bugQuery >> `closedDate` != '0000-00-00 00:00:00' AND `closedDate` <= '2022-01-01'
@@ -31,10 +31,10 @@ $bugQuery[] = " `product` = '1' and `project` = '1' and `story` > 'abc'";
$bug=new bugTest();
r($bug->getBugQueryTest($bugQuery[0])) && p() && e("1 AND `product` IN ('1','2','3','4','5','6','7','8','9','10','11','12','13','14','15','16','17','18','19','20','21','22','23','24','25','26','27','28','29','30','31','32','33','34','35','36','37','38','39','40','41','42','43','44','45','46','47','48','49','50','51','52','53','54','55','56','57','58','59','60','61','62','63','64','65','66','67','68','69','70','71','72','73','74','75','76','77','78','79','80','81','82','83','84','85','86','87','88','89','90','91','92','93','94','95','96','97','98','99','100','101','102','103','104','105','106','107','108','109','110','111','112','113','114','115','116','117','118','119','120','1','2','3','4','5','6','7','8','9','10','21','22','23','24','25','26','27','28','29','30','41','42','43','44','45','46','47','48','49','50','61','62','63','64','65','66','67','68','69','70','81','82','83','84','85','86','87','88','89','90','101','102','103','104','105','106','107','108','109','110')"); // 查询 `product` = 'all' 的bugQuery
r($bug->getBugQueryTest($bugQuery[0])) && p() && e("1 AND `product` IN ('1','2','3','4','5','6','7','8','9','10','21','22','23','24','25','26','27','28','29','30','41','42','43','44','45','46','47','48','49','50','61','62','63','64','65','66','67','68','69','70','81','82','83','84','85','86','87','88','89','90','101','102','103','104','105','106','107','108','109','110','11','12','13','14','15','16','17','18','19','20','31','32','33','34','35','36','37','38','39','40','51','52','53','54','55','56','57','58','59','60','71','72','73','74','75','76','77','78','79','80','91','92','93','94','95','96','97','98','99','100','111','112','113','114','115','116','117','118','119','120','1','2','3','4','5','6','7','8','9','10','21','22','23','24','25','26','27','28','29','30','41','42','43','44','45','46','47','48','49','50','61','62','63','64','65','66','67','68','69','70','81','82','83','84','85','86','87','88','89','90','101','102','103','104','105','106','107','108','109','110')"); // 查询 `product` = 'all' 的bugQuery
r($bug->getBugQueryTest($bugQuery[1])) && p() && e("1 AND `project` in (11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,731,732,733,734,735,736,737,738,739,740,741,742,743,744,745,746,747,748,749,750)"); // 查询 `project` = 'all' 的bugQuery
r($bug->getBugQueryTest($bugQuery[2])) && p() && e(" `resolvedDate` != '0000-00-00 00:00:00' AND `resolvedDate` > '2022-01-01'"); // 查询 `resolvedDate` = '2022-01-01' 的bugQuery
r($bug->getBugQueryTest($bugQuery[3])) && p() && e(" `closedDate` != '0000-00-00 00:00:00' AND `closedDate` <= '2022-01-01'"); // 查询 `closedDate` = '2022-01-01' 的bugQuery
r($bug->getBugQueryTest($bugQuery[4])) && p() && e(" `story` IN (2,12,20,21,22,23,24,25,26,27,28,29,32,42,52,62,70,71,72,73,74,75,76,77,78,79,82,92,102,112,120,121,122,123,124,125,126,127,128,129,132,142,152,162,172,182,192,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,302,312,320,321,322,323,324,325,326,327,328,329,332,342,352,362,372,382,392,402,412,420,421,422,423,424,425,426,427,428,429,432,442) AND `story` != 0"); // 查询 `story` LIKE '%abc%' 的bugQuery
r($bug->getBugQueryTest($bugQuery[5])) && p() && e(" `story` NOT IN (2,12,20,21,22,23,24,25,26,27,28,29,32,42,52,62,70,71,72,73,74,75,76,77,78,79,82,92,102,112,120,121,122,123,124,125,126,127,128,129,132,142,152,162,172,182,192,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,302,312,320,321,322,323,324,325,326,327,328,329,332,342,352,362,372,382,392,402,412,420,421,422,423,424,425,426,427,428,429,432,442) AND `story` != 0"); // 查询 `story` NOT LIKE '%abc%' 的bugQuery
r($bug->getBugQueryTest($bugQuery[6])) && p() && e("`product` = '1' and `project` = '1' and `story` > 'abc' AND `story` != 0"); // 查询 `product` = '1' and `project` = '1' and `story` > 'abc' 的bugQuery
r($bug->getBugQueryTest($bugQuery[6])) && p() && e("`product` = '1' and `project` = '1' and `story` > 'abc' AND `story` != 0"); // 查询 `product` = '1' and `project` = '1' and `story` > 'abc' 的bugQuery
+33
View File
@@ -0,0 +1,33 @@
#!/usr/bin/env php
<?php
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
include dirname(dirname(dirname(__FILE__))) . '/class/bug.class.php';
su('admin');
/**
title=bugModel->getRelatedObjects();
cid=1
pid=1
获取bug关联的 branch 的 id,name >> :,0:
获取bug关联的 task 的 id,name >> :,0:
获取bug关联的 case 的 id,title >> :,0:
获取bug关联的 resolvedBuild 的 id,name >> :,0:,trunk:主干
获取bug关联的 openedBuild 的 id,name >> :,0:,trunk:主干,1:项目版本版本1
获取bug关联的 story 的 id,title >> :,0:,2:软件需求2,6:软件需求6,10:软件需求10,14:软件需求14,18:软件需求18,22:软件需求22,26:软件需求26,30:软件需求30,34:软件需求34
*/
$objects = array('branch', 'task', 'case', 'resolvedBuild', 'openedBuild', 'story');
$pairs = array('id,name', 'id,title');
$bug=new bugTest();
$_SESSION['bugQueryCondition'] = 'id < 10';
r($bug->getRelatedObjectsTest($objects[0], $pairs[0])) && p() && e(':,0:'); // 获取bug关联的 branch 的 id,name
r($bug->getRelatedObjectsTest($objects[1], $pairs[0])) && p() && e(':,0:'); // 获取bug关联的 task 的 id,name
r($bug->getRelatedObjectsTest($objects[2], $pairs[1])) && p() && e(':,0:'); // 获取bug关联的 case 的 id,title
r($bug->getRelatedObjectsTest($objects[3], $pairs[0])) && p() && e(':,0:,trunk:主干'); // 获取bug关联的 resolvedBuild 的 id,name
r($bug->getRelatedObjectsTest($objects[4], $pairs[0])) && p() && e(':,0:,trunk:主干,1:项目版本版本1'); // 获取bug关联的 openedBuild 的 id,name
r($bug->getRelatedObjectsTest($objects[5], $pairs[1])) && p() && e(':,0:,2:软件需求2,6:软件需求6,10:软件需求10,14:软件需求14,18:软件需求18,22:软件需求22,26:软件需求26,30:软件需求30,34:软件需求34'); // 获取bug关联的 story 的 id,title
+41
View File
@@ -0,0 +1,41 @@
#!/usr/bin/env php
<?php
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
include dirname(dirname(dirname(__FILE__))) . '/class/bug.class.php';
su('admin');
/**
title=bugModel->getReviewBugs();
cid=1
pid=1
*/
$productIDList = array('1,2,3,1000001', '1,3');
$branch = array('all', '1');
$moduleIDList = array('1821,1825,1832,1000001', '1821, 1825');
$executions = array(array(101,102), array(101,111));
$orderBy = 'id_asc';
$bug=new bugTest();
r($bug->getReviewBugsTest($productIDList[0], $branch[0], $moduleIDList[0], $executions[0], $orderBy)) && p('') && e(''); // 查询产品1 2 3 不存在的产品10001 与分支all 模块1821, 1825, 1832 不存在的模块1000001 执行101 102下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[0], $branch[1], $moduleIDList[0], $executions[0], $orderBy)) && p('') && e(''); // 查询产品1 2 3 不存在的产品10001 与分支1 模块1821, 1825, 1832 不存在的模块1000001 执行101 102下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[0], $branch[0], $moduleIDList[1], $executions[0], $orderBy)) && p('') && e(''); // 查询产品1 2 3 不存在的产品10001 与分支all 模块1821, 1825 执行101 102下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[0], $branch[1], $moduleIDList[1], $executions[0], $orderBy)) && p('') && e(''); // 查询产品1 2 3 不存在的产品10001 与分支1 模块1821, 1825 执行101 102下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[0], $branch[0], $moduleIDList[0], $executions[1], $orderBy)) && p('') && e(''); // 查询产品1 2 3 不存在的产品10001 与分支all 模块1821, 1825, 1832 不存在的模块1000001 执行101 111下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[0], $branch[1], $moduleIDList[0], $executions[1], $orderBy)) && p('') && e(''); // 查询产品1 2 3 不存在的产品10001 与分支1 模块1821, 1825, 1832 不存在的模块1000001 执行101 111下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[0], $branch[0], $moduleIDList[1], $executions[1], $orderBy)) && p('') && e(''); // 查询产品1 2 3 不存在的产品10001 与分支all 模块1821, 1825 执行101 111下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[0], $branch[1], $moduleIDList[1], $executions[1], $orderBy)) && p('') && e(''); // 查询产品1 2 3 不存在的产品10001 与分支1 模块1821, 1825 执行101 111下审批人为当前用户的bug
//
r($bug->getReviewBugsTest($productIDList[1], $branch[0], $moduleIDList[0], $executions[0], $orderBy)) && p('') && e(''); // 查询产品1 3 与分支all 模块1821, 1825, 1832 不存在的模块1000001 执行101 102下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[1], $branch[1], $moduleIDList[0], $executions[0], $orderBy)) && p('') && e(''); // 查询产品1 3 与分支1 模块1821, 1825, 1832 不存在的模块1000001 执行101 102下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[1], $branch[0], $moduleIDList[1], $executions[0], $orderBy)) && p('') && e(''); // 查询产品1 3 与分支all 模块1821, 1825 执行101 102下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[1], $branch[1], $moduleIDList[1], $executions[0], $orderBy)) && p('') && e(''); // 查询产品1 3 与分支1 模块1821, 1825 执行101 102下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[1], $branch[0], $moduleIDList[0], $executions[1], $orderBy)) && p('') && e(''); // 查询产品1 3 与分支all 模块1821, 1825, 1832 不存在的模块1000001 执行101 111下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[1], $branch[1], $moduleIDList[0], $executions[1], $orderBy)) && p('') && e(''); // 查询产品1 3 与分支1 模块1821, 1825, 1832 不存在的模块1000001 执行101 111下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[1], $branch[0], $moduleIDList[1], $executions[1], $orderBy)) && p('') && e(''); // 查询产品1 3 与分支all 模块1821, 1825 执行101 111下审批人为当前用户的bug
r($bug->getReviewBugsTest($productIDList[1], $branch[1], $moduleIDList[1], $executions[1], $orderBy)) && p('') && e(''); // 查询产品1 3 与分支1 模块1821, 1825 执行101 111下审批人为当前用户的bug
+37
View File
@@ -0,0 +1,37 @@
#!/usr/bin/env php
<?php
include dirname(dirname(dirname(__FILE__))) . '/lib/init.php';
include dirname(dirname(dirname(__FILE__))) . '/class/bug.class.php';
su('admin');
/**
title=bugModel->getStatistic();
cid=1
pid=1
查询product id为0创建日期在今天的统计信息 >> 0
查询product id为1创建日期在今天的统计信息 >> 0
查询product id为1创建日期在今天的统计信息 >> 0
查询product id为1创建日期在今天的统计信息 >> 0
查询product id为11解决日期在今天的统计信息 >> 1
查询product id为31解决日期在今天的统计信息 >> 0
查询product id为61解决日期在今天的统计信息 >> 0
查询product id为91关闭日期在今天的统计信息 >> 0
查询product id为10001关闭日期在今天的统计信息 >> 0
*/
$productIDList = array('1', '11', '31', '61', '91', '10001');
$bug=new bugTest();
r($bug->getStatisticTest()) && p('openedDate:num') && e('0'); // 查询product id为0创建日期在今天的统计信息
r($bug->getStatisticTest($productIDList[0])) && p('openedDate:num') && e('0'); // 查询product id为1创建日期在今天的统计信息
r($bug->getStatisticTest($productIDList[0])) && p('resolvedDate:num') && e('0'); // 查询product id为1创建日期在今天的统计信息
r($bug->getStatisticTest($productIDList[0])) && p('closedDate:num') && e('0'); // 查询product id为1创建日期在今天的统计信息
r($bug->getStatisticTest($productIDList[1])) && p('openedDate:num') && e('1'); // 查询product id为11解决日期在今天的统计信息
r($bug->getStatisticTest($productIDList[2])) && p('openedDate:num') && e('0'); // 查询product id为31解决日期在今天的统计信息
r($bug->getStatisticTest($productIDList[3])) && p('openedDate:num') && e('0'); // 查询product id为61解决日期在今天的统计信息
r($bug->getStatisticTest($productIDList[4])) && p('openedDate:num') && e('0'); // 查询product id为91关闭日期在今天的统计信息
r($bug->getStatisticTest($productIDList[5])) && p('openedDate:num') && e('0'); // 查询product id为10001关闭日期在今天的统计信息
+3 -3
View File
@@ -12,7 +12,7 @@ pid=1
敏捷执行燃尽图数据 >> 7/1
瀑布执行燃尽图数据 >> [0,0,0,0,0,0,0,0,0,0,0]
看板执行燃尽图数据 >> [20,18,16,14,12,10,8,6,4,2,0]
看板执行燃尽图数据 >> [0,0,0,0,0,0,0,0,0,0,0]
结果统计 >> 3
*/
@@ -23,5 +23,5 @@ $count = array('0', '1');
$execution = new executionTest();
r($execution->buildBurnDataTest($executionIDList[0], $count[0])) && p('labels:0') && e('7/1'); // 敏捷执行燃尽图数据
r($execution->buildBurnDataTest($executionIDList[1], $count[0])) && p('burnLine') && e('[0,0,0,0,0,0,0,0,0,0,0]'); // 瀑布执行燃尽图数据
r($execution->buildBurnDataTest($executionIDList[2], $count[0])) && p('baseLine') && e('[20,18,16,14,12,10,8,6,4,2,0]'); // 看板执行燃尽图数据
r($execution->buildBurnDataTest($executionIDList[0], $count[1])) && p() && e('3'); // 结果统计
r($execution->buildBurnDataTest($executionIDList[2], $count[0])) && p('baseLine') && e('[0,0,0,0,0,0,0,0,0,0,0]'); // 看板执行燃尽图数据
r($execution->buildBurnDataTest($executionIDList[0], $count[1])) && p() && e('3'); // 结果统计
+2 -2
View File
@@ -11,7 +11,7 @@ cid=1
pid=1
正常初始化 >> project600
初始化后数据统计 >> 516
初始化后数据统计 >> 361
*/
@@ -19,4 +19,4 @@ $count = array('0','1');
$execution = new executionTest();
r($execution->computeBurnTest($count[0])) && p('700:executionName') && e('project600'); // 正常初始化
r($execution->computeBurnTest($count[1])) && p() && e('516'); // 初始化后数据统计
r($execution->computeBurnTest($count[1])) && p() && e('361'); // 初始化后数据统计
+5 -7
View File
@@ -19,11 +19,10 @@ pid=1
测试创建看板公开执行 >> 新增公开看板执行code,kanban
测试创建迭代团队分配 >> pd58,pd72,dev10,dev10
测试不输入项目 >> 所属项目不能为空。
测试不输入产品 >> 关联产品不能为空!
测试不输入执行名称 >> 『执行名称』不能为空。
测试不输入执行代号 >> 『执行代号』不能为空。
测试一样的执行名称 >> 『执行名称』已经有『新增私有敏捷执行』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。
测试一样的执行代号 >> 『执行代号』已经有『新增私有敏捷执行code』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。
测试一样的执行名称 >> 『执行名称』已经有『新增私有敏捷执行』这条记录了。
测试一样的执行代号 >> 『执行代号』已经有『新增私有敏捷执行code』这条记录了。
*/
@@ -56,10 +55,9 @@ r($task->createObject($prvExecution_kanban, $projectIDList[3], $dayNum, $days))
r($task->createObject($openExecution_kanban, $projectIDList[3], $dayNum, $days)) && p('code,type') && e('新增公开看板执行code,kanban'); // 测试创建看板公开执行
r($task->createObject($teamExecution, $projectIDList[1], $dayNum, $days)) && p('PO,QD,PM,RD') && e('pd58,pd72,dev10,dev10'); // 测试创建迭代团队分配
r($task->createObject($prvExecution, '', $dayNum, $days)) && p('message:0') && e('所属项目不能为空。'); // 测试不输入项目
r($task->createObject($noProductID, $projectIDList[1], $dayNum, $days)) && p('message:0') && e('关联产品不能为空!'); // 测试不输入产品
r($task->createObject($noName, $projectIDList[1], $dayNum, $days)) && p('name:0') && e('『执行名称』不能为空。'); // 测试不输入执行名称
r($task->createObject($noCode, $projectIDList[1], $dayNum, $days)) && p('code:0') && e('『执行代号』不能为空。'); // 测试不输入执行代号
r($task->createObject($equallyName, $projectIDList[1], $dayNum, $days)) && p('name:0') && e('『执行名称』已经有『新增私有敏捷执行』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。'); // 测试一样的执行名称
r($task->createObject($equallyCode, $projectIDList[1], $dayNum, $days)) && p('code:0') && e('『执行代号』已经有『新增私有敏捷执行code』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。'); // 测试一样的执行代号
r($task->createObject($equallyName, $projectIDList[1], $dayNum, $days)) && p('name:0') && e('『执行名称』已经有『新增私有敏捷执行』这条记录了。'); // 测试一样的执行名称
r($task->createObject($equallyCode, $projectIDList[1], $dayNum, $days)) && p('code:0') && e('『执行代号』已经有『新增私有敏捷执行code』这条记录了。'); // 测试一样的执行代号
$db->restoreDB();
$db->restoreDB();
+5 -5
View File
@@ -10,8 +10,8 @@ title=executionModel->getBranchByProduct();
cid=1
pid=1
正常产品分支统计 >> 0
分支产品分支查看 >> 分支2
正常产品分支统计 >> 1
分支产品分支查看 >> 分支1
分支产品分支统计 >> 1
*/
@@ -20,6 +20,6 @@ $productIDList = array('1', '41');
$count = array('0', '1');
$execution = new executionTest();
r($execution->getBranchByProductTest($productIDList[0],$count[1])) && p() && e('0'); //正常产品分支统计
r($execution->getBranchByProductTest($productIDList[1],$count[0])) && p('41:2') && e('分支2'); //分支产品分支查看
r($execution->getBranchByProductTest($productIDList[1],$count[1])) && p() && e('1'); //分支产品分支统计
r($execution->getBranchByProductTest($productIDList[0], $count[1])) && p() && e('1'); //正常产品分支统计
r($execution->getBranchByProductTest($productIDList[1], $count[0])) && p('41:1') && e('分支1'); //分支产品分支查看
r($execution->getBranchByProductTest($productIDList[1], $count[1])) && p() && e('1'); //分支产品分支统计
+4 -5
View File
@@ -12,14 +12,13 @@ pid=1
敏捷执行查询统计 >> 3
瀑布执行查询统计 >> 3
看板执行查询统计 >> 3
看板执行查询统计 >> 0
*/
$executionIDList = array('101', '131', '161');
$count = array('0','1');
$execution = new executionTest();
r($execution->getBurnDataFlotTest($executionIDList[0], $count[1])) && p() && e('3'); // 敏捷执行查询统计
r($execution->getBurnDataFlotTest($executionIDList[1], $count[1])) && p() && e('3'); // 瀑布执行查询统计
r($execution->getBurnDataFlotTest($executionIDList[2], $count[1])) && p() && e('3'); // 看板执行查询统计
r($execution->getBurnDataFlotTest($executionIDList[0])) && p() && e('3'); // 敏捷执行查询统计
r($execution->getBurnDataFlotTest($executionIDList[1])) && p() && e('3'); // 瀑布执行查询统计
r($execution->getBurnDataFlotTest($executionIDList[2])) && p() && e('0'); // 看板执行查询统计
+2 -2
View File
@@ -19,5 +19,5 @@ $executionID = '131';
$count = array('0','1');
$execution = new executionTest();
r($execution->getChildExecutionsTest($executionID,$count[0])) && p('701') && e('子阶段1'); // 查询子阶段
r($execution->getChildExecutionsTest($executionID,$count[1])) && p() && e('1'); // 查询子阶段数量
r($execution->getChildExecutionsTest($executionID, $count[0])) && p('701:name') && e('子阶段1'); // 查询子阶段
r($execution->getChildExecutionsTest($executionID, $count[1])) && p() && e('1'); // 查询子阶段数量
@@ -11,12 +11,12 @@ cid=1
pid=1
查询当前用户访问的产品相关项目集 >> 项目集10
查询当前用户访问的产品相关数量 >> 101
查询当前用户访问的产品相关数量 >> 121
*/
$count = array('0','1');
$execution = new executionTest();
r($execution->getProductGroupListTest($count[0])) && p('9:name') && e('项目集10'); // 查询当前用户访问的产品相关项目集
r($execution->getProductGroupListTest($count[1])) && p() && e('101'); // 查询当前用户访问的产品相关数量
r($execution->getProductGroupListTest($count[0])) && p('9:name') && e('项目集10'); // 查询当前用户访问的产品相关项目集
r($execution->getProductGroupListTest($count[1])) && p() && e('121'); // 查询当前用户访问的产品相关数量
+5 -5
View File
@@ -27,13 +27,13 @@ suspended状态执行close按钮检查 >> 检查通过
suspended状态执行suspend按钮检查 >> 检查不通过
suspended状态执行putoff按钮检查 >> 检查不通过
suspended状态执行activate按钮检查 >> 检查通过
suspended状态执行delete按钮检查 >> 检查不通过
suspended状态执行delete按钮检查 >> 检查通过
closed状态执行start按钮检查 >> 检查不通过
closed状态执行close按钮检查 >> 检查不通过
closed状态执行suspend按钮检查 >> 检查不通过
closed状态执行putoff按钮检查 >> 检查不通过
closed状态执行activate按钮检查 >> 检查通过
closed状态执行delete按钮检查 >> 检查不通过
closed状态执行delete按钮检查 >> 检查通过
*/
@@ -67,10 +67,10 @@ r($execution->isClickableTest($suspendedExecution, $actionList[1])) && p() && e(
r($execution->isClickableTest($suspendedExecution, $actionList[2])) && p() && e('检查不通过'); // suspended状态执行suspend按钮检查
r($execution->isClickableTest($suspendedExecution, $actionList[3])) && p() && e('检查不通过'); // suspended状态执行putoff按钮检查
r($execution->isClickableTest($suspendedExecution, $actionList[4])) && p() && e('检查通过'); // suspended状态执行activate按钮检查
r($execution->isClickableTest($suspendedExecution, $actionList[5])) && p() && e('检查不通过'); // suspended状态执行delete按钮检查
r($execution->isClickableTest($suspendedExecution, $actionList[5])) && p() && e('检查通过'); // suspended状态执行delete按钮检查
r($execution->isClickableTest($closedExecution, $actionList[0])) && p() && e('检查不通过'); // closed状态执行start按钮检查
r($execution->isClickableTest($closedExecution, $actionList[1])) && p() && e('检查不通过'); // closed状态执行close按钮检查
r($execution->isClickableTest($closedExecution, $actionList[2])) && p() && e('检查不通过'); // closed状态执行suspend按钮检查
r($execution->isClickableTest($closedExecution, $actionList[3])) && p() && e('检查不通过'); // closed状态执行putoff按钮检查
r($execution->isClickableTest($closedExecution, $actionList[3])) && p() && e('检查通过'); // closed状态执行putoff按钮检查
r($execution->isClickableTest($closedExecution, $actionList[4])) && p() && e('检查通过'); // closed状态执行activate按钮检查
r($execution->isClickableTest($closedExecution, $actionList[5])) && p() && e('检查不通过'); // closed状态执行delete按钮检查
r($execution->isClickableTest($closedExecution, $actionList[5])) && p() && e('检查不通过'); // closed状态执行delete按钮检查
+3 -3
View File
@@ -14,7 +14,7 @@ pid=1
敏捷执行关联用例 >> 101,1,1
瀑布执行关联用例 >> 131,43,169
看板执行关联用例 >> 161,68,269
敏捷执行关联用例统计 >> 4
敏捷执行关联用例统计 >> 8
瀑布执行关联用例统计 >> 4
看板执行关联用例统计 >> 4
@@ -29,8 +29,8 @@ $execution = new executionTest();
r($execution->linkCasesTest($executionIDList[0], $count[0], $products[0], $stories[0])) && p('0:project,product,case') && e('101,1,1'); // 敏捷执行关联用例
r($execution->linkCasesTest($executionIDList[1], $count[0], $products[1], $stories[1])) && p('0:project,product,case') && e('131,43,169'); // 瀑布执行关联用例
r($execution->linkCasesTest($executionIDList[2], $count[0], $products[2], $stories[2])) && p('0:project,product,case') && e('161,68,269'); // 看板执行关联用例
r($execution->linkCasesTest($executionIDList[0], $count[1], $products[0], $stories[0])) && p() && e('4'); // 敏捷执行关联用例统计
r($execution->linkCasesTest($executionIDList[0], $count[1], $products[0], $stories[0])) && p() && e('8'); // 敏捷执行关联用例统计
r($execution->linkCasesTest($executionIDList[1], $count[1], $products[1], $stories[1])) && p() && e('4'); // 瀑布执行关联用例统计
r($execution->linkCasesTest($executionIDList[2], $count[1], $products[2], $stories[2])) && p() && e('4'); // 看板执行关联用例统计
$db->restoreDB();
$db->restoreDB();
+7 -7
View File
@@ -14,9 +14,9 @@ pid=1
敏捷执行关联需求 >> 101,1,4
瀑布执行关联需求 >> 131,1,4
看板执行关联需求 >> 161,1,4
敏捷执行关联需求统计 >> 3
瀑布执行关联需求统计 >> 3
看板执行关联需求统计 >> 3
敏捷执行关联需求统计 >> 1
瀑布执行关联需求统计 >> 1
看板执行关联需求统计 >> 1
*/
@@ -31,8 +31,8 @@ $execution = new executionTest();
r($execution->linkStoryTest($executionIDList[0], $count[0], $story)) && p('0:project,product,story') && e('101,1,4'); // 敏捷执行关联需求
r($execution->linkStoryTest($executionIDList[1], $count[0], $story)) && p('0:project,product,story') && e('131,1,4'); // 瀑布执行关联需求
r($execution->linkStoryTest($executionIDList[2], $count[0], $story)) && p('0:project,product,story') && e('161,1,4'); // 看板执行关联需求
r($execution->linkStoryTest($executionIDList[0], $count[1], $story)) && p() && e('3'); // 敏捷执行关联需求统计
r($execution->linkStoryTest($executionIDList[1], $count[1], $story)) && p() && e('3'); // 瀑布执行关联需求统计
r($execution->linkStoryTest($executionIDList[2], $count[1], $story)) && p() && e('3'); // 看板执行关联需求统计
r($execution->linkStoryTest($executionIDList[0], $count[1], $story)) && p() && e('1'); // 敏捷执行关联需求统计
r($execution->linkStoryTest($executionIDList[1], $count[1], $story)) && p() && e('1'); // 瀑布执行关联需求统计
r($execution->linkStoryTest($executionIDList[2], $count[1], $story)) && p() && e('1'); // 看板执行关联需求统计
$db->restoreDB();
$db->restoreDB();
+7 -7
View File
@@ -10,9 +10,9 @@ title=测试executionModel->processBurnDataTest();
cid=1
pid=1
敏捷执行查询统计 >> 29
瀑布执行查询统计 >> 59
看板执行查询统计 >> 62
敏捷执行查询统计 >> 30
瀑布执行查询统计 >> 60
看板执行查询统计 >> 67
错误时间查询统计 >> 0
*/
@@ -24,7 +24,7 @@ $end = array('2022-03-22','2022-01-15');
$count = array('0','1');
$execution = new executionTest();
r($execution->processBurnDataTest($executionIDList[0], $itemCounts[0], $begin[0], $end[0], $count[1])) && p() && e('29'); // 敏捷执行查询统计
r($execution->processBurnDataTest($executionIDList[1], $itemCounts[1], $begin[0], $end[0], $count[1])) && p() && e('59'); // 瀑布执行查询统计
r($execution->processBurnDataTest($executionIDList[2], $itemCounts[2], $begin[0], $end[0], $count[1])) && p() && e('62'); // 看板执行查询统计
r($execution->processBurnDataTest($executionIDList[2], $itemCounts[2], $begin[1], $end[1], $count[1])) && p() && e('0'); // 错误时间查询统计
r($execution->processBurnDataTest($executionIDList[0], $itemCounts[0], $begin[0], $end[0], $count[1])) && p() && e('30'); // 敏捷执行查询统计
r($execution->processBurnDataTest($executionIDList[1], $itemCounts[1], $begin[0], $end[0], $count[1])) && p() && e('60'); // 瀑布执行查询统计
r($execution->processBurnDataTest($executionIDList[2], $itemCounts[2], $begin[0], $end[0], $count[1])) && p() && e('67'); // 看板执行查询统计
r($execution->processBurnDataTest($executionIDList[2], $itemCounts[2], $begin[1], $end[1], $count[1])) && p() && e('0'); // 错误时间查询统计
+5 -5
View File
@@ -14,8 +14,8 @@ pid=1
敏捷执行解除团队成员 >> po82,研发
敏捷执行解除团队成员后统计 >> 1
瀑布执行解除团队成员 >> 0
看板执行解除团队成员 >> test52,测试
看板执行解除团队成员后统计 >> 1
看板执行解除团队成员 >> 0
看板执行解除团队成员后统计 >> 0
*/
@@ -27,6 +27,6 @@ $execution = new executionTest();
r($execution->unlinkMemberTest($executionIDList[0], $accountList[0], $count[0])) && p('0:account,role') && e('po82,研发'); // 敏捷执行解除团队成员
r($execution->unlinkMemberTest($executionIDList[0], $accountList[0], $count[1])) && p() && e('1'); // 敏捷执行解除团队成员后统计
r($execution->unlinkMemberTest($executionIDList[1], $accountList[1], $count[0])) && p() && e('0'); // 瀑布执行解除团队成员
r($execution->unlinkMemberTest($executionIDList[2], $accountList[2], $count[0])) && p('0:account,role') && e('test52,测试'); // 看板执行解除团队成员
r($execution->unlinkMemberTest($executionIDList[2], $accountList[2], $count[1])) && p() && e('1'); // 看板执行解除团队成员后统计
$db->restoreDB();
r($execution->unlinkMemberTest($executionIDList[2], $accountList[2], $count[0])) && p('0:account,role') && e('0'); // 看板执行解除团队成员
r($execution->unlinkMemberTest($executionIDList[2], $accountList[2], $count[1])) && p() && e('0'); // 看板执行解除团队成员后统计
$db->restoreDB();
+11 -11
View File
@@ -11,12 +11,12 @@ title=测试executionModel->unlinkStoryTest();
cid=1
pid=1
敏捷执行解除关联需求 >> 101,81,324
敏捷执行解除关联需求 >> 0
瀑布执行解除关联需求 >> 131,1,4
看板执行解除关联需求 >> 161,1,4
敏捷执行关联需求统计 >> 2
瀑布执行关联需求统计 >> 2
看板执行关联需求统计 >> 2
敏捷执行关联需求统计 >> 0
瀑布执行关联需求统计 >> 1
看板执行关联需求统计 >> 1
*/
@@ -28,11 +28,11 @@ $count = array('0', '1');
$story = array('stories' => $stories, 'products' => $products);
$execution = new executionTest();
r($execution->unlinkStoryTest($executionIDList[0], $count[0], $stories[0], $story)) && p('0:project,product,story') && e('101,81,324'); // 敏捷执行解除关联需求
r($execution->unlinkStoryTest($executionIDList[1], $count[0], $stories[1], $story)) && p('0:project,product,story') && e('131,1,4'); // 瀑布执行解除关联需求
r($execution->unlinkStoryTest($executionIDList[2], $count[0], $stories[2], $story)) && p('0:project,product,story') && e('161,1,4'); // 看板执行解除关联需求
r($execution->unlinkStoryTest($executionIDList[0], $count[1], $stories[0], $story)) && p() && e('2'); // 敏捷执行关联需求统计
r($execution->unlinkStoryTest($executionIDList[1], $count[1], $stories[1], $story)) && p() && e('2'); // 瀑布执行关联需求统计
r($execution->unlinkStoryTest($executionIDList[2], $count[1], $stories[2], $story)) && p() && e('2'); // 看板执行关联需求统计
r($execution->unlinkStoryTest($executionIDList[0], $count[0], $stories[0], $story)) && p('0:project,product,story') && e('0'); // 敏捷执行解除关联需求
r($execution->unlinkStoryTest($executionIDList[1], $count[0], $stories[1], $story)) && p('0:project,product,story') && e('131,1,4'); // 瀑布执行解除关联需求
r($execution->unlinkStoryTest($executionIDList[2], $count[0], $stories[2], $story)) && p('0:project,product,story') && e('161,1,4'); // 看板执行解除关联需求
r($execution->unlinkStoryTest($executionIDList[0], $count[1], $stories[0], $story)) && p() && e('0'); // 敏捷执行关联需求统计
r($execution->unlinkStoryTest($executionIDList[1], $count[1], $stories[1], $story)) && p() && e('1'); // 瀑布执行关联需求统计
r($execution->unlinkStoryTest($executionIDList[2], $count[1], $stories[2], $story)) && p() && e('1'); // 看板执行关联需求统计
$db->restoreDB();
$db->restoreDB();
+3 -3
View File
@@ -11,7 +11,7 @@ title=测试executionModel->update();
cid=1
pid=1
测试重复迭代code >> 『迭代代号』已经有『project1』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。
测试重复迭代code >> 『迭代代号』已经有『project1』这条记录了。
测试修改迭代名称 >> name,迭代1,迭代名修改
测试修改迭代项目为瀑布项目 >> project,11,41
测试修改迭代项目为看板项目 >> project,41,71
@@ -44,7 +44,7 @@ $noCode = array('code' => '');
$repeatcode = array('name' => '迭代名修改1');
$execution = new executionTest();
r($execution->updateObject($executionIDList[0], $repeatcode)) && p('code:0') && e('『迭代代号』已经有『project1』这条记录了。如果您确定该记录已删除,请到后台-系统-数据-回收站还原。'); // 测试重复迭代code
r($execution->updateObject($executionIDList[0], $repeatcode)) && p('code:0') && e('『迭代代号』已经有『project1』这条记录了。'); // 测试重复迭代code
r($execution->updateObject($executionIDList[0], $changeName)) && p('0:field,old,new') && e('name,迭代1,迭代名修改'); // 测试修改迭代名称
r($execution->updateObject($executionIDList[0], $changeStage)) && p('0:field,old,new') && e('project,11,41'); // 测试修改迭代项目为瀑布项目
r($execution->updateObject($executionIDList[0], $changeKanban)) && p('0:field,old,new') && e('project,41,71'); // 测试修改迭代项目为看板项目
@@ -57,4 +57,4 @@ r($execution->updateObject($executionIDList[1], $noName)) && p('name:0')
r($execution->updateObject($executionIDList[1], $noCode)) && p('code:0') && e('『迭代代号』不能为空。'); // 测试修改code为空
r($execution->updateObject($executionIDList[1], $noChange)) && p() && e('没有数据更新'); // 测试无修改
$db->restoreDB();
$db->restoreDB();
-1
View File
@@ -46,7 +46,6 @@ $app->parseRequest();
/* Old version need check priv here, new version check priv in entry. */
if(!$app->version) $common->checkPriv();
$app->setParams();
$app->loadModule();
$output = ob_get_clean();
+1 -1
View File
@@ -68,7 +68,7 @@ if($app->clientDevice == 'mobile' and (strpos($config->version, 'pro') === 0 or
if(!empty($_GET['display']) && $_GET['display'] == 'card') $config->default->view = 'xhtml';
$app->parseRequest();
$app->setParams();
if(!$app->setParams()) return;
$common->checkPriv();
$common->checkIframe();
$app->loadModule();
-1
View File
@@ -33,5 +33,4 @@ $app->setDebug();
if(isset($config->installed) and $config->installed) $app->connectDB();
$app->parseRequest();
$app->setParams();
$app->loadModule();
+6 -6
View File
File diff suppressed because one or more lines are too long
+1 -5
View File
@@ -80,8 +80,4 @@ if($app->isContainer())
/* Run it. */
$app->parseRequest();
if($common->checkUpgradeStatus())
{
$app->setParams();
$app->loadModule();
}
if($common->checkUpgradeStatus()) $app->loadModule();