Merge branch 'sprint/187_tianshujie_fixbug' into 'master'
Sprint/187 tianshujie fixbug See merge request easycorp/zentaopms!2175
This commit is contained in:
@@ -163,7 +163,7 @@ class custom extends control
|
||||
foreach($_POST['keys'] as $index => $key)
|
||||
{
|
||||
if(!empty($key)) $key = trim($key);
|
||||
/* Invalid key. It should be numbers. (It includes severityList in bug module and priList in stroy, task, bug, testcasea, testtask and todo module.) */
|
||||
/* Invalid key. It should be numbers. (It includes severityList in bug module and priList in story, task, bug, testcasea, testtask and todo module.) */
|
||||
if($field == 'priList' or $field == 'severityList')
|
||||
{
|
||||
if(!is_numeric($key) or $key > 255) return $this->send(array('result' => 'fail', 'message' => $this->lang->custom->notice->invalidNumberKey));
|
||||
|
||||
@@ -799,7 +799,7 @@ function createColumnCreateMenu(options)
|
||||
if(col.laneType == 'story')
|
||||
{
|
||||
if(priv.canCreateStory) items.push({label: storyLang.create, url: $.createLink('story', 'create', 'productID=' + productID, '', true), className: 'iframe'});
|
||||
if(priv.canBatchCreateStory) items.push({label: executionLang.batchCreateStroy, url: $.createLink('story', 'batchcreate', 'productID=' + productID + '&branch=0&moduleID=0&storyID=0&executionID=' + executionID, '', true), className: 'iframe', attrs: {'data-width': '90%'}});
|
||||
if(priv.canBatchCreateStory) items.push({label: executionLang.batchCreateStory, url: $.createLink('story', 'batchcreate', 'productID=' + productID + '&branch=0&moduleID=0&storyID=0&executionID=' + executionID, '', true), className: 'iframe', attrs: {'data-width': '90%'}});
|
||||
if(priv.canLinkStory) items.push({label: executionLang.linkStory, url: $.createLink('execution', 'linkStory', 'executionID=' + executionID, '', true), className: 'iframe', attrs: {'data-width': '90%'}});
|
||||
if(priv.canLinkStoryByPlan) items.push({label: executionLang.linkStoryByPlan, url: '#linkStoryByPlan', 'attrs' : {'data-toggle': 'modal'}});
|
||||
}
|
||||
|
||||
@@ -1184,7 +1184,7 @@ function createColumnCreateMenu(options)
|
||||
var laneID = col.$kanbanData.lanes[0].id ? col.$kanbanData.lanes[0].id : 0;
|
||||
var columnID = col.id;
|
||||
|
||||
if(privs.includes('createCard')) items.push({label: kanbanLang.createCard, url: $.createLink('kanban', 'createCard', 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID), className: 'iframe', attrs: {'data-toggle': 'modal'}});
|
||||
if(privs.includes('createCard')) items.push({label: kanbanLang.createCard, url: $.createLink('kanban', 'createCard', 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID, '', true), className: 'iframe', attrs: {'data-toggle': 'modal'}});
|
||||
if(privs.includes('batchCreateCard')) items.push({label: kanbanLang.batchCreateCard, url: $.createLink('kanban', 'batchCreateCard', 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&laneID=' + laneID + '&columnID=' + columnID), attrs: {'data-width': '80%'}});
|
||||
if(privs.includes('import') && kanban.object.indexOf('cards') != -1) items.push({label: kanbanLang.importCard, url: $.createLink('kanban', 'importCard', 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID), className: 'iframe', attrs: {'data-toggle': 'modal'}});
|
||||
if(privs.includes('import') && kanban.object && kanban.object != 'cards') items.push({className: 'parentDivider'});
|
||||
|
||||
@@ -110,7 +110,7 @@ class projectStory extends control
|
||||
* Batch unlink story.
|
||||
*
|
||||
* @param int $projectID
|
||||
* @param string $stroyIdList
|
||||
* @param string $storyIdList
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
|
||||
@@ -1101,8 +1101,6 @@ class story extends control
|
||||
|
||||
/* Set the menu. */
|
||||
$from = $this->app->tab;
|
||||
$this->product->setMenu($story->product, $story->branch);
|
||||
|
||||
if($from == 'execution')
|
||||
{
|
||||
$this->execution->setMenu($param);
|
||||
@@ -1116,6 +1114,10 @@ class story extends control
|
||||
$products = $this->product->getProductPairsByProject(0, 'noclosed');
|
||||
$this->loadModel('qa')->setMenu($products, $story->product);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->product->setMenu($story->product, $story->branch);
|
||||
}
|
||||
|
||||
$reviewers = $this->story->getReviewerPairs($storyID, $story->version);
|
||||
$checkSuperReviewed = strpos(',' . trim(zget($this->config->story, 'superReviewers', ''), ',') . ',', ',' . trim($story->reviewedBy, ',') . ',');
|
||||
|
||||
@@ -647,9 +647,9 @@ class storyModel extends model
|
||||
|
||||
$story = fixer::input('post')->stripTags($this->config->story->editor->change['id'], $this->config->allowedTags)->get();
|
||||
|
||||
$oldStroyReviewers = $this->getReviewerPairs($storyID, $oldStory->version);
|
||||
$oldStoryReviewers = $this->getReviewerPairs($storyID, $oldStory->version);
|
||||
$_POST['reviewer'] = isset($_POST['reviewer']) ? $_POST['reviewer'] : array();
|
||||
$reviewerHasChanged = (array_diff(array_keys($oldStroyReviewers), $_POST['reviewer']) or array_diff($_POST['reviewer'], array_keys($oldStroyReviewers)));
|
||||
$reviewerHasChanged = (array_diff(array_keys($oldStoryReviewers), $_POST['reviewer']) or array_diff($_POST['reviewer'], array_keys($oldStoryReviewers)));
|
||||
if($story->spec != $oldStory->spec or $story->verify != $oldStory->verify or $story->title != $oldStory->title or $this->loadModel('file')->getCount() or $reviewerHasChanged) $specChanged = true;
|
||||
|
||||
$now = helper::now();
|
||||
|
||||
Reference in New Issue
Block a user