Merge branch 'sprint/master_lanzongjun_fixbug' into 'master'
* fix bug 20029,19713 See merge request easycorp/zentaopms!2049
This commit is contained in:
@@ -112,7 +112,7 @@ $projectIDParam = $isProjectStory ? "projectID=$projectID&" : '';
|
||||
$tab = $isProjectStory ? 'project' : 'product';
|
||||
$class = common::hasPriv('story', 'export') ? '' : "class=disabled";
|
||||
$misc = common::hasPriv('story', 'export') ? "data-toggle='modal' data-type='iframe' class='export' data-app='$tab'" : "class=disabled";
|
||||
$link = common::hasPriv('story', 'export') ? $this->createLink('story', 'export', "productID=$productID&orderBy=$orderBy&projectID=0&browseType=$browseType&type=$storyType") : '#';
|
||||
$link = common::hasPriv('story', 'export') ? $this->createLink('story', 'export', "productID=$productID&orderBy=$orderBy&executionID=$projectID&browseType=$browseType&type=$storyType") : '#';
|
||||
echo "<li $class>" . html::a($link, $lang->story->export, '', $misc) . "</li>";
|
||||
?>
|
||||
</ul>
|
||||
@@ -191,7 +191,7 @@ $projectIDParam = $isProjectStory ? "projectID=$projectID&" : '';
|
||||
<?php endif;?>
|
||||
<?php echo $moduleTree;?>
|
||||
<div class="text-center">
|
||||
<?php if($productID) common::printLink('tree', 'browse', "rootID=$productID&view=story¤tModuleID=0&branch=$branchID", $lang->tree->manageMenu, '', "class='btn btn-info btn-wide'");?>
|
||||
<?php if($productID) common::printLink('tree', 'browse', "rootID=$productID&view=story¤tModuleID=0&branch=$branchID&from=&projectID=$projectID", $lang->tree->manageMenu, '', "class='btn btn-info btn-wide'");?>
|
||||
<hr class="space-sm" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
helper::importControl('tree');
|
||||
class myTree extends tree
|
||||
{
|
||||
/**
|
||||
* Module browse.
|
||||
*
|
||||
* @param int $rootID
|
||||
* @param string $view story|bug|case|doc
|
||||
* @param int $currentModuleID
|
||||
* @param int $branch
|
||||
* @param string $from
|
||||
* @param int $projectID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function browse($rootID, $view, $currentModuleID = 0, $branch = 0, $from = '', $projectID = 0)
|
||||
{
|
||||
$this->view->projectID = $projectID;
|
||||
$this->view->projectName = $this->dao->findById($projectID)->from(TABLE_PROJECT)->fetch('name');
|
||||
return parent::browse($rootID, $view, $currentModuleID, $branch, $from);
|
||||
}
|
||||
}
|
||||
@@ -3,11 +3,11 @@
|
||||
$lang->tree->all = '所有目录';
|
||||
$lang->tree->allMenu = $lang->tree->all;
|
||||
$lang->tree->manageMenu = '维护目录';
|
||||
$lang->tree->manage = '维护目录';
|
||||
|
||||
global $app;
|
||||
if ($app->rawModule == 'tree' and $app->rawMethod == 'browsetask')
|
||||
{
|
||||
$lang->tree->manage = '维护目录';
|
||||
$lang->tree->common = '目录维护';
|
||||
$lang->tree->manageExecution = "维护{$lang->executionCommon}视图目录";
|
||||
$lang->tree->manageTaskChild = "维护{$lang->executionCommon}子目录";
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
<script>
|
||||
$("#childrenForm a:first").text('<?php echo $projectName; ?>');
|
||||
</script>
|
||||
@@ -1072,6 +1072,7 @@ function createTaskMenu(options)
|
||||
if(priv.canRestartTask && task.$col.type == 'pause') items.push({label: taskLang.restart, icon: 'play', url: createLink('task', 'restart', 'taskID=' + task.id, '', 'true'), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canPauseTask && task.$col.type == 'developing') items.push({label: taskLang.pause, icon: 'pause', url: createLink('task', 'pause', 'taskID=' + task.id, '', 'true'), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canRecordEstimateTask) items.push({label: executionLang.effort, icon: 'time', url: createLink('task', 'recordEstimate', 'taskID=' + task.id, '', 'true'), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canBatchCreateTask && vision == 'lite') items.push({label: taskLang.children, icon:'split', url: $.createLink('task', 'batchcreate', 'executionID=' + executionID + '&storyID=0&moduleID=0&taskID=' + task.id, '', true), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canActivateTask && (task.$col.type == 'developed' || task.$col.type == 'canceled' || task.$col.type == 'closed')) items.push({label: executionLang.activate, icon: 'magic', url: createLink('task', 'activate', 'taskID=' + task.id, '', 'true'), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canCreateTask) items.push({label: taskLang.copy, icon: 'copy', url: createLink('task', 'create', 'executionID=' + executionID + '&storyID=' + '0' + '&moduleID=' + '0' + '&taskID=' + task.id, '', 'true'), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
if(priv.canCancelTask && (task.$col.type == 'wait' || task.$col.type == 'developing' || task.$col.type == 'pause')) items.push({label: taskLang.cancel, icon: 'cancel', url: createLink('task', 'cancel', 'taskID=' + task.id, '', 'true'), className: 'iframe', attrs: {'data-toggle': 'modal', 'data-width': '80%'}});
|
||||
|
||||
@@ -138,7 +138,7 @@ $projectIDParam = $isProjectStory ? "projectID=$projectID&" : '';
|
||||
$tab = $isProjectStory ? 'project' : 'product';
|
||||
$class = common::hasPriv('story', 'export') ? '' : "class=disabled";
|
||||
$misc = common::hasPriv('story', 'export') ? "data-toggle='modal' data-type='iframe' class='export' data-app='$tab'" : "class=disabled";
|
||||
$link = common::hasPriv('story', 'export') ? $this->createLink('story', 'export', "productID=$productID&orderBy=$orderBy&projectID=0&browseType=$browseType&type=$storyType") : '#';
|
||||
$link = common::hasPriv('story', 'export') ? $this->createLink('story', 'export', "productID=$productID&orderBy=$orderBy&projectID=0&executionID=0&browseType=$browseType&type=$storyType") : '#';
|
||||
echo "<li $class>" . html::a($link, $lang->story->export, '', $misc) . "</li>";
|
||||
?>
|
||||
</ul>
|
||||
|
||||
@@ -221,7 +221,7 @@ $(function()
|
||||
},
|
||||
itemCreator: function($li, item)
|
||||
{
|
||||
var link = (item.id !== undefined && item.type != 'line') ? ('<a href="' + createLink('tree', 'browse', 'rootID=<?php echo $rootID ?>&viewType=<?php echo $viewType ?>&moduleID={0}&branch={1}&from=<?php echo $from;?>'.format(item.id, branch)) + '" data-app="' + tab + '">' + item.name + '</a>') : ('<span class="tree-toggle">' + item.name + '</span>');
|
||||
var link = (item.id !== undefined && item.type != 'line') ? ('<a href="' + createLink('tree', 'browse', 'rootID=<?php echo $rootID ?>&viewType=<?php echo $viewType ?>&moduleID={0}&branch={1}&from=<?php echo $from;?>&projectID=<?php echo $projectID; ?>'.format(item.id, branch)) + '" data-app="' + tab + '">' + item.name + '</a>') : ('<span class="tree-toggle">' + item.name + '</span>');
|
||||
var $toggle = $('<span class="module-name" data-id="' + item.id + '">' + link + '</span>');
|
||||
if(item.type === 'bug') $toggle.append(' <span class="text-muted">[B]</span>');
|
||||
if(item.type === 'case') $toggle.append(' <span class="text-muted">[C]</span>');
|
||||
|
||||
Reference in New Issue
Block a user