Merge branch '15.0.beta3' of http://gitlab.zcorp.cc/easycorp/zentaopms into 15.0.beta3
This commit is contained in:
@@ -59,7 +59,6 @@ class execution extends control
|
||||
*/
|
||||
public function index($locate = 'auto', $executionID = 0)
|
||||
{
|
||||
$this->lang->execution->menu = $this->lang->execution->homeMenu;
|
||||
if($locate == 'yes') $this->locate($this->createLink('execution', 'task'));
|
||||
|
||||
$this->commonAction($executionID);
|
||||
@@ -1170,17 +1169,22 @@ class execution extends control
|
||||
* Create a execution.
|
||||
*
|
||||
* @param string $projectID
|
||||
* @param string $productID
|
||||
* @param string $executionID
|
||||
* @param string $copyExecutionID
|
||||
* @param int $planID
|
||||
* @param string $confirm
|
||||
* @param string $productID
|
||||
*
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function create($productID = '', $executionID = '', $copyExecutionID = '', $planID = 0, $confirm = 'no', $projectID = 0)
|
||||
public function create($projectID = '', $executionID = '', $copyExecutionID = '', $planID = 0, $confirm = 'no', $productID = 0)
|
||||
{
|
||||
if($this->app->openApp == 'project')
|
||||
{
|
||||
commonModel::setAppObjectID('project', $projectID);
|
||||
}
|
||||
|
||||
$this->app->loadLang('program');
|
||||
$this->app->loadLang('stage');
|
||||
$this->app->loadLang('programplan');
|
||||
@@ -1260,6 +1264,7 @@ class execution extends control
|
||||
if(!empty($planID)) break;
|
||||
}
|
||||
}
|
||||
|
||||
if(!empty($planID))
|
||||
{
|
||||
$this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => inlink('create', "productID=&executionID=$executionID©ExecutionID=&planID=$planID&confirm=no")));
|
||||
@@ -1270,19 +1275,6 @@ class execution extends control
|
||||
}
|
||||
}
|
||||
|
||||
$isSprint = true;
|
||||
if($this->config->systemMode == 'new' and !empty($projectID))
|
||||
{
|
||||
$project = $this->project->getById($projectID);
|
||||
if($project->model == 'scrum')
|
||||
{
|
||||
unset($this->lang->execution->endList[62]);
|
||||
unset($this->lang->execution->endList[93]);
|
||||
unset($this->lang->execution->endList[186]);
|
||||
unset($this->lang->execution->endList[365]);
|
||||
}
|
||||
}
|
||||
|
||||
$executionID = key($this->executions);
|
||||
$this->execution->setMenu($this->executions, $executionID);
|
||||
|
||||
@@ -1307,7 +1299,6 @@ class execution extends control
|
||||
$this->view->copyExecutionID = $copyExecutionID;
|
||||
$this->view->branchGroups = $this->loadModel('branch')->getByProducts(array_keys($products));
|
||||
$this->view->users = $this->loadModel('user')->getPairs('nodeleted|noclosed');
|
||||
$this->view->isSprint = $isSprint;
|
||||
$this->display();
|
||||
}
|
||||
|
||||
@@ -2678,14 +2669,13 @@ class execution extends control
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function all($status = 'all', $projectID = 0, $from = 'execution', $orderBy = 'id_desc', $productID = 0, $recTotal = 0, $recPerPage = 10, $pageID = 1)
|
||||
public function all($status = 'all', $projectID = 0, $orderBy = 'id_desc', $productID = 0, $recTotal = 0, $recPerPage = 10, $pageID = 1)
|
||||
{
|
||||
$this->lang->execution->menu = $this->lang->execution->homeMenu;
|
||||
|
||||
$this->app->loadLang('my');
|
||||
$this->app->loadLang('product');
|
||||
$this->app->loadLang('programplan');
|
||||
|
||||
$from = $this->app->openApp;
|
||||
if($from == 'execution') $this->session->set('executionList', $this->app->getURI(true));
|
||||
if($from == 'project') $this->lang->navGroup->execution = 'project';
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ $(function()
|
||||
|
||||
var adjustMainCol = function()
|
||||
{
|
||||
if(isSprint) $('.main-form .col-main').css('width', Math.max(250, Math.floor(($('#productsBox').outerWidth() - 50)/3) + 10));
|
||||
$('.main-form .col-main').css('width', Math.max(250, Math.floor(($('#productsBox').outerWidth() - 50)/3) + 10));
|
||||
};
|
||||
adjustMainCol();
|
||||
$(window).on('resize', adjustMainCol);
|
||||
|
||||
@@ -39,14 +39,14 @@ function deleteItem(obj)
|
||||
|
||||
function setDeptUsers(obj)
|
||||
{
|
||||
dept = $(obj).val();//Get dept ID.
|
||||
link = createLink('project', 'manageMembers', 'projectID=' + projectID + '&team2Import=' + team2Import + '&dept=' + dept);//Create manageMembers link.
|
||||
dept = $(obj).val(); // Get dept ID.
|
||||
link = createLink('execution', 'manageMembers', 'executionID=' + executionID + '&team2Import=' + team2Import + '&dept=' + dept); // Create manageMembers link.
|
||||
location.href=link;
|
||||
}
|
||||
|
||||
function choseTeam2Copy(obj)
|
||||
{
|
||||
team = $(obj).val();
|
||||
link = createLink('project', 'manageMembers', 'projectID=' + projectID + '&team2Import=' + team);
|
||||
link = createLink('execution', 'manageMembers', 'executionID=' + executionID + '&team2Import=' + team);
|
||||
location.href=link;
|
||||
}
|
||||
|
||||
@@ -36,12 +36,12 @@
|
||||
<?php endif;?>
|
||||
<div class='btn-toolbar pull-left'>
|
||||
<?php foreach($lang->execution->featureBar['all'] as $key => $label):?>
|
||||
<?php echo html::a(inlink("all", "status=$key&projectID=$projectID&from=$from&orderBy=$orderBy&productID=$productID"), "<span class='text'>{$label}</span>", '', "class='btn btn-link' id='{$key}Tab'");?>
|
||||
<?php echo html::a(inlink("all", "status=$key&projectID=$projectID&orderBy=$orderBy&productID=$productID"), "<span class='text'>{$label}</span>", '', "class='btn btn-link' id='{$key}Tab' data-app='$from'");?>
|
||||
<?php endforeach;?>
|
||||
</div>
|
||||
<div class='btn-toolbar pull-right'>
|
||||
<?php common::printLink('execution', 'export', "status=$status&productID=$productID&orderBy=$orderBy&from=$from", "<i class='icon-export muted'> </i>" . $lang->export, '', "class='btn btn-link export'")?>
|
||||
<?php if(common::hasPriv('execution', 'create')) echo html::a($this->createLink('execution', 'create'), "<i class='icon icon-sm icon-plus'></i> " . ($from == 'execution' ? $lang->execution->createExec : $lang->execution->create), '', "class='btn btn-primary'");?>
|
||||
<?php if(common::hasPriv('execution', 'create')) echo html::a($this->createLink('execution', 'create', "projectID=$projectID"), "<i class='icon icon-sm icon-plus'></i> " . ($from == 'execution' ? $lang->execution->createExec : $lang->execution->create), '', "class='btn btn-primary' data-app='$from'");?>
|
||||
</div>
|
||||
</div>
|
||||
<div id='mainContent' class="main-row fade">
|
||||
|
||||
@@ -35,7 +35,6 @@
|
||||
<?php js::set('holders', $lang->execution->placeholder);?>
|
||||
<?php js::set('errorSameProducts', $lang->execution->errorSameProducts);?>
|
||||
<?php js::set('productID', empty($productID) ? 0 : $productID);?>
|
||||
<?php js::set('isSprint', $isSprint);?>
|
||||
<div id='mainContent' class='main-content'>
|
||||
<div class='center-block'>
|
||||
<div class='main-header'>
|
||||
@@ -86,31 +85,9 @@
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->execution->type;?></th>
|
||||
<td>
|
||||
<?php
|
||||
if($isSprint)
|
||||
{
|
||||
echo html::select('lifetime', $lang->execution->lifeTimeList, '', "class='form-control' onchange='showLifeTimeTips()'");
|
||||
}
|
||||
else
|
||||
{
|
||||
echo html::select('attribute', $lang->stage->typeList, '', "class='form-control'");
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
<td><?php echo html::select('lifetime', $lang->execution->lifeTimeList, '', "class='form-control' onchange='showLifeTimeTips()'"); ?></td>
|
||||
<td class='muted' colspan='2'><div id='lifeTimeTips'><?php echo $lang->execution->typeDesc;?></div></td>
|
||||
</tr>
|
||||
<?php if(!$isSprint):?>
|
||||
<tr>
|
||||
<th><?php echo $lang->programplan->percent;?></th>
|
||||
<td>
|
||||
<div class='input-group'>
|
||||
<?php echo html::input('percent', '', "class='form-control'");?>
|
||||
<span class='input-group-addon'>%</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif;?>
|
||||
<tr class='hide'>
|
||||
<th><?php echo $lang->execution->status;?></th>
|
||||
<td><?php echo html::hidden('status', 'wait');?></td>
|
||||
@@ -183,7 +160,6 @@
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='4' class='text-center form-actions'>
|
||||
<?php if($isSprint) echo html::hidden('lifetime', 'short');?>
|
||||
<?php echo html::submitButton();?>
|
||||
<?php echo html::backButton();?>
|
||||
</td>
|
||||
|
||||
Reference in New Issue
Block a user