Merge branch '15.0.beta3' of https://gitlab.zcorp.cc/easycorp/zentaopms into 15.0.beta3
This commit is contained in:
@@ -66,7 +66,7 @@ class bug extends control
|
||||
|
||||
$this->view->products = $this->products = $products;
|
||||
$openApp = ($this->app->openApp == 'project' or $this->app->openApp == 'execution') ? $this->app->openApp : 'qa';
|
||||
if(empty($this->products)) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$openApp&activeMenu=bug&objectID=$objectID")));
|
||||
if(empty($this->products) and !helper::isAjaxRequest()) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$openApp&activeMenu=bug&objectID=$objectID")));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -221,7 +221,12 @@ class doc extends control
|
||||
$objectType = 'project';
|
||||
$objectID = $execution->project;
|
||||
}
|
||||
if($objectType == 'project' and $this->post->project) $objectID = $this->post->project;
|
||||
if($objectType == 'product' and $this->post->product) $objectID = $this->post->product;
|
||||
if($objectType == 'custom' or $objectType == 'book') $objectID = 0;
|
||||
|
||||
$this->action->create('docLib', $libID, 'Created');
|
||||
|
||||
die(js::locate($this->createLink('doc', 'objectLibs', "type=$objectType&objectID=$objectID&libID=$libID"), 'parent.parent'));
|
||||
}
|
||||
else
|
||||
@@ -491,8 +496,22 @@ class doc extends control
|
||||
else
|
||||
{
|
||||
$this->app->rawMethod = $objectType;
|
||||
|
||||
/* High light menu. */
|
||||
if($objectType)
|
||||
{
|
||||
$menu = $this->lang->doc->menu->$objectType;
|
||||
$menu['alias'] .= ',edit';
|
||||
$menu['subModule'] = 'doc';
|
||||
$this->lang->doc->menu->$objectType = $menu;
|
||||
}
|
||||
}
|
||||
|
||||
$objects = $this->doc->getOrderedObjects($objectType);
|
||||
$libs = $this->doc->getLibsByObject($objectType, $objectID);
|
||||
$this->lang->modulePageNav = $this->doc->select($objectType, $objects, $objectID, $libs, $libID);
|
||||
$this->lang->TRActions = common::hasPriv('doc', 'create') ? $this->doc->buildCreateButton4Doc($objectType, $objectID, $libID) : '';
|
||||
|
||||
$this->view->title = $lib->name . $this->lang->colon . $this->lang->doc->edit;
|
||||
$this->view->position[] = html::a($this->createLink('doc', 'browse', "libID=$libID"), $lib->name);
|
||||
$this->view->position[] = $this->lang->doc->edit;
|
||||
|
||||
@@ -9,34 +9,65 @@ $(function()
|
||||
toggleAcl($('form [name=acl]:checked').val(), 'lib');
|
||||
});
|
||||
|
||||
/**
|
||||
* Change form by lib type.
|
||||
*
|
||||
* @param string libType
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function changeByLibType(libType)
|
||||
{
|
||||
if(libType == 'product')
|
||||
{
|
||||
$('table tr.product').removeClass('hidden');
|
||||
$('#product').attr('disabled', false);
|
||||
|
||||
$('table tr.project').addClass('hidden');
|
||||
$('#project').attr('disabled', true);
|
||||
|
||||
$('table tr.execution').addClass('hidden');
|
||||
$('#execution').attr('disabled', true);
|
||||
|
||||
changeDoclibAcl(libType);
|
||||
}
|
||||
else if(libType == 'project')
|
||||
{
|
||||
$('table tr.product').addClass('hidden');
|
||||
$('table tr.project').removeClass('hidden');
|
||||
$('#project').attr('disabled', false);
|
||||
|
||||
$('table tr.product').addClass('hidden');
|
||||
$('#product').attr('disabled', true);
|
||||
|
||||
$('table tr.execution').addClass('hidden');
|
||||
$('#execution').attr('disabled', true);
|
||||
|
||||
changeDoclibAcl(libType);
|
||||
}
|
||||
else if(libType == 'execution')
|
||||
{
|
||||
$('table tr.product').addClass('hidden');
|
||||
$('table tr.project').addClass('hidden');
|
||||
$('table tr.execution').removeClass('hidden');
|
||||
$('#execution').attr('disabled', false);
|
||||
|
||||
$('table tr.product').addClass('hidden');
|
||||
$('#product').attr('disabled', true);
|
||||
|
||||
$('table tr.project').addClass('hidden');
|
||||
$('#project').attr('disabled', true);
|
||||
|
||||
changeDoclibAcl(libType);
|
||||
}
|
||||
else
|
||||
{
|
||||
$('table tr.product').addClass('hidden');
|
||||
$('#product').attr('disabled', true);
|
||||
|
||||
$('table tr.project').addClass('hidden');
|
||||
$('#project').attr('disabled', true);
|
||||
|
||||
$('table tr.execution').addClass('hidden');
|
||||
$('#execution').attr('disabled', true);
|
||||
|
||||
changeDoclibAcl(libType);
|
||||
}
|
||||
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
* @link http://www.zentao.net
|
||||
*/
|
||||
?>
|
||||
<?php $pageCSS .= $this->doc->appendNavCSS();?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<?php if($doc->contentType == 'html') include '../../common/view/kindeditor.html.php';?>
|
||||
<?php if($doc->contentType == 'markdown') include '../../common/view/markdown.html.php';?>
|
||||
|
||||
@@ -33,7 +33,7 @@ $sideWidth = common::checkNotCN() ? '270' : '238';
|
||||
if($type == 'book')
|
||||
{
|
||||
common::printLink('doc', 'editLib', "rootID=$libID", $lang->doc->editBook, '', "class='btn btn-info btn-wide iframe'", '', true);
|
||||
common::printLink('doc', 'manageBook', "bookID=$libID", $lang->doc->manageBook, '', "class='btn btn-info btn-wide iframe'", '', true);
|
||||
common::printLink('doc', 'manageBook', "bookID=$libID", $lang->doc->manageBook, '', "class='btn btn-info btn-wide'");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -68,11 +68,11 @@
|
||||
</th>
|
||||
<th><?php common::printOrderLink('name', $orderBy, $vars, (($from == 'execution') and ($config->systemMode == 'new')) ? $lang->execution->execName : $lang->execution->name);?></th>
|
||||
<th class='thWidth'><?php common::printOrderLink('PM', $orderBy, $vars, $lang->execution->owner);?></th>
|
||||
<th class='w-100px'><?php common::printOrderLink('end', $orderBy, $vars, $lang->execution->end);?></th>
|
||||
<th class='w-100px'><?php common::printOrderLink('status', $orderBy, $vars, $from == 'execution' ? $lang->execution->execStatus : $lang->execution->status);?></th>
|
||||
<th class='w-80px hours text-right'><?php echo $lang->execution->totalEstimate;?></th>
|
||||
<th class='w-80px hours text-right'><?php echo $lang->execution->totalConsumed;?></th>
|
||||
<th class='w-80px hours text-right'><?php echo $lang->execution->totalLeft;?></th>
|
||||
<th class='w-80px'><?php common::printOrderLink('end', $orderBy, $vars, $lang->execution->end);?></th>
|
||||
<th class='w-80px'><?php common::printOrderLink('status', $orderBy, $vars, $from == 'execution' ? $lang->execution->execStatus : $lang->execution->status);?></th>
|
||||
<th class='w-70px text-center'><?php echo $lang->execution->totalEstimate;?></th>
|
||||
<th class='w-70px text-center'><?php echo $lang->execution->totalConsumed;?></th>
|
||||
<th class='w-70px text-center'><?php echo $lang->execution->totalLeft;?></th>
|
||||
<th class='w-60px'><?php echo $lang->execution->progress;?></th>
|
||||
<th class='w-100px'><?php echo $lang->execution->burn;?></th>
|
||||
</tr>
|
||||
@@ -101,7 +101,7 @@
|
||||
<td><?php echo zget($users, $execution->PM);?></td>
|
||||
<td><?php echo $execution->end;?></td>
|
||||
<?php $executionStatus = $this->processStatus('execution', $execution);?>
|
||||
<td class='c-status' title='<?php echo $executionStatus;?>'>
|
||||
<td class='c-status text-center' title='<?php echo $executionStatus;?>'>
|
||||
<span class="status-execution status-<?php echo $execution->status?>"><?php echo $executionStatus;?></span>
|
||||
</td>
|
||||
<td class='hours' title='<?php echo $execution->hours->totalEstimate . ' ' . $this->lang->execution->workHour;?>'><?php echo $execution->hours->totalEstimate . $this->lang->execution->workHourUnit;?></td>
|
||||
|
||||
@@ -994,10 +994,11 @@ class product extends control
|
||||
$this->lang->project->menuOrder = $this->lang->{$project->model}->menuOrder;
|
||||
$this->app->rawModule = $activeMenu;
|
||||
|
||||
if($activeMenu == 'bug') $this->lang->{$project->model}->menu->qa['subMenu']->bug['subModule'] = 'product';
|
||||
if($activeMenu == 'testcase') $this->lang->{$project->model}->menu->qa['subMenu']->testcase['subModule'] = 'product';
|
||||
if($activeMenu == 'testtask') $this->lang->{$project->model}->menu->qa['subMenu']->testtask['subModule'] = 'product';
|
||||
if($activeMenu == 'testreport') $this->lang->{$project->model}->menu->qa['subMenu']->testreport['subModule'] = 'product';
|
||||
if($activeMenu == 'bug') $this->lang->{$project->model}->menu->qa['subMenu']->bug['subModule'] = 'product';
|
||||
if($activeMenu == 'testcase') $this->lang->{$project->model}->menu->qa['subMenu']->testcase['subModule'] = 'product';
|
||||
if($activeMenu == 'testtask') $this->lang->{$project->model}->menu->qa['subMenu']->testtask['subModule'] = 'product';
|
||||
if($activeMenu == 'testreport') $this->lang->{$project->model}->menu->qa['subMenu']->testreport['subModule'] = 'product';
|
||||
if($activeMenu == 'projectrelease') $this->lang->{$project->model}->menu->release['subModule'] = 'projectrelease';
|
||||
}
|
||||
elseif($moduleName == 'qa')
|
||||
{
|
||||
|
||||
@@ -29,7 +29,7 @@ class projectrelease extends control
|
||||
$this->loadModel('release');
|
||||
$this->loadModel('project');
|
||||
$this->view->products = $this->products = $this->product->getProductPairsByProject($this->session->project);
|
||||
if(empty($this->view->products)) $this->locate($this->createLink('product', 'create'));
|
||||
if(empty($this->products) and !helper::isAjaxRequest()) die($this->locate($this->createLink('product', 'showErrorNone', 'moduleName=project&activeMenu=projectrelease&projectID=' . $this->session->project)));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php if(common::canModify('product', $product)): ?>
|
||||
<?php
|
||||
$otherParam = '';
|
||||
$otherParam = 'storyID=&projectID=';
|
||||
$openApp = 'product';
|
||||
if($this->app->rawModule == 'projectstory')
|
||||
{
|
||||
@@ -57,7 +57,7 @@
|
||||
$openGroup = 'project';
|
||||
}
|
||||
?>
|
||||
<?php common::printLink('story', 'create', "productID={$story->product}&branch={$story->branch}&moduleID={$story->module}&$otherParam", "<i class='icon icon-plus'></i>" . $lang->story->create, '', "class='btn btn-primary' data-app='$openApp'"); ?>
|
||||
<?php common::printLink('story', 'create', "productID={$story->product}&branch={$story->branch}&moduleID={$story->module}&$otherParam&bugID=0&planID=0&todoID=0&extra=&type=$story->type", "<i class='icon icon-plus'></i>" . $lang->story->create, '', "class='btn btn-primary' data-app='$openApp'"); ?>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
|
||||
@@ -72,7 +72,7 @@ $config->task->datatable->fieldList['type']['required'] = 'no';
|
||||
|
||||
$config->task->datatable->fieldList['status']['title'] = 'statusAB';
|
||||
$config->task->datatable->fieldList['status']['fixed'] = 'no';
|
||||
$config->task->datatable->fieldList['status']['width'] = '80';
|
||||
$config->task->datatable->fieldList['status']['width'] = '60';
|
||||
$config->task->datatable->fieldList['status']['required'] = 'no';
|
||||
|
||||
$config->task->datatable->fieldList['estimate']['title'] = 'estimateAB';
|
||||
@@ -99,7 +99,7 @@ $config->task->datatable->fieldList['progress']['name'] = $lang->task->progr
|
||||
|
||||
$config->task->datatable->fieldList['deadline']['title'] = 'deadlineAB';
|
||||
$config->task->datatable->fieldList['deadline']['fixed'] = 'no';
|
||||
$config->task->datatable->fieldList['deadline']['width'] = '100';
|
||||
$config->task->datatable->fieldList['deadline']['width'] = '60';
|
||||
$config->task->datatable->fieldList['deadline']['required'] = 'no';
|
||||
|
||||
$config->task->datatable->fieldList['openedBy']['title'] = 'openedByAB';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#copyButton {width: 56px; background-color: #f1f1f1; opacity: 1;} /* Adjust for task #4151; */
|
||||
#copyButton {width: 80px; background-color: #f1f1f1; opacity: 1;} /* Adjust for task #4151; */
|
||||
|
||||
.title-group.required:after {display: none;}
|
||||
.title-group.required > .required:after {display: block; right: 29px; top: 5px;}
|
||||
|
||||
@@ -191,7 +191,8 @@ function setPreview()
|
||||
$('#preview a').attr('href', storyLink);
|
||||
$('#copyButton').removeClass('hidden');
|
||||
$('.title-group.required > div').attr('id', 'copyStory-input').removeClass('.required');
|
||||
$('div.colorpicker').css('right', '57px');//Adjust for task #4151;
|
||||
$('div.colorpicker').css('right', '80px');//Adjust for task #4151;
|
||||
$('#copyButton').css('width', '80px');
|
||||
}
|
||||
|
||||
setAfter();
|
||||
|
||||
@@ -60,7 +60,7 @@ class testcase extends control
|
||||
|
||||
$this->view->products = $this->products = $products;
|
||||
$openApp = ($this->app->openApp == 'project' or $this->app->openApp == 'execution') ? $this->app->openApp : 'qa';
|
||||
if(empty($this->products)) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$openApp&activeMenu=testcase&objectID=$objectID")));
|
||||
if(empty($this->products) and !helper::isAjaxRequest()) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$openApp&activeMenu=testcase&objectID=$objectID")));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -63,7 +63,7 @@ class testreport extends control
|
||||
|
||||
$this->view->products = $this->products = $products;
|
||||
$openApp = ($this->app->openApp == 'project' or $this->app->openApp == 'execution') ? $this->app->openApp : 'qa';
|
||||
if(empty($this->products)) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$openApp&activeMenu=testreport&objectID=$objectID")));
|
||||
if(empty($this->products) and !helper::isAjaxRequest()) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$openApp&activeMenu=testreport&objectID=$objectID")));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -32,7 +32,7 @@ class testsuite extends control
|
||||
parent::__construct($moduleName, $methodName);
|
||||
|
||||
$this->view->products = $this->products = $this->loadModel('product')->getPairs();
|
||||
if(empty($this->products)) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=qa&activeMenu=testsuite")));
|
||||
if(empty($this->products) and !helper::isAjaxRequest()) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=qa&activeMenu=testsuite")));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -58,7 +58,7 @@ class testtask extends control
|
||||
|
||||
$this->view->products = $this->products = $products;
|
||||
$openApp = ($this->app->openApp == 'project' or $this->app->openApp == 'execution') ? $this->app->openApp : 'qa';
|
||||
if(empty($this->products)) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$openApp&activeMenu=testtask&objectID=$objectID")));
|
||||
if(empty($this->products) and !helper::isAjaxRequest()) die($this->locate($this->createLink('product', 'showErrorNone', "moduleName=$openApp&activeMenu=testtask&objectID=$objectID")));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user