Merge branch 'sprint/183_xieqiyu_47995new' of https://gitlab.zcorp.cc/easycorp/zentaopms into xieqiyu
This commit is contained in:
@@ -194,8 +194,10 @@ $lang->action->desc->importfromgitlab = '$date, Issue associate created from
|
||||
$lang->action->desc->archived = '$date, archived by <strong>$actor</strong>.' . "\n";
|
||||
$lang->action->desc->restore = '$date, restore by <strong>$actor</strong>.' . "\n";
|
||||
$lang->action->desc->importedcard = '$date, imported to <strong>$extra</strong> by <strong>$actor</strong>.' . "\n";
|
||||
$lang->action->desc->importedplan = '$date, imported to <strong>$extra</strong> by <strong>$actor</strong>.' . "\n";
|
||||
$lang->action->desc->importedproductplan = '$date, imported to <strong>$extra</strong> by <strong>$actor</strong>.' . "\n";
|
||||
$lang->action->desc->importedrelease = '$date, imported to <strong>$extra</strong> by <strong>$actor</strong>.' . "\n";
|
||||
$lang->action->desc->importedexecution = '$date, imported to <strong>$extra</strong> by <strong>$actor</strong>.' . "\n";
|
||||
$lang->action->desc->importedbuild = '$date, imported to <strong>$extra</strong> by <strong>$actor</strong>.' . "\n";
|
||||
|
||||
/* Used to describe the history of operations related to parent-child tasks. */
|
||||
$lang->action->desc->createchildren = '$date, <strong>$actor</strong> created a child task <strong>$extra</strong>。' . "\n";
|
||||
@@ -336,8 +338,10 @@ $lang->action->label->activatedbychild = 'activated';
|
||||
$lang->action->label->createchild = 'activated';
|
||||
$lang->action->label->executed = 'executed';
|
||||
$lang->action->label->importedcard = 'imported';
|
||||
$lang->action->label->importedplan = 'imported';
|
||||
$lang->action->label->importedproductplan = 'imported';
|
||||
$lang->action->label->importedrelease = 'imported';
|
||||
$lang->action->label->importedexecution = 'imported';
|
||||
$lang->action->label->importedbuild = 'imported';
|
||||
|
||||
/* Dynamic information is grouped by object. */
|
||||
$lang->action->dynamicAction = new stdclass;
|
||||
|
||||
@@ -194,8 +194,10 @@ $lang->action->desc->importfromgitlab = '$date, 由 <strong>$actor</strong>
|
||||
$lang->action->desc->archived = '$date, 由 <strong>$actor</strong> 归档。' . "\n";
|
||||
$lang->action->desc->restore = '$date, 由 <strong>$actor</strong> 还原。' . "\n";
|
||||
$lang->action->desc->importedcard = '$date, 由 <strong>$actor</strong> 从看板 <strong>$extra</strong> 导入。' . "\n";
|
||||
$lang->action->desc->importedplan = '$date, 由 <strong>$actor</strong> 从产品计划 <strong>$extra</strong> 导入。' . "\n";
|
||||
$lang->action->desc->importedproductplan = '$date, 由 <strong>$actor</strong> 从产品计划 <strong>$extra</strong> 导入。' . "\n";
|
||||
$lang->action->desc->importedrelease = '$date, 由 <strong>$actor</strong> 从产品发布 <strong>$extra</strong> 导入。' . "\n";
|
||||
$lang->action->desc->importedexecution = '$date, 由 <strong>$actor</strong> 从项目执行 <strong>$extra</strong> 导入。' . "\n";
|
||||
$lang->action->desc->importedbuild = '$date, 由 <strong>$actor</strong> 从项目版本 <strong>$extra</strong> 导入。' . "\n";
|
||||
|
||||
/* 用来描述和父子任务相关的操作历史记录。*/
|
||||
$lang->action->desc->createchildren = '$date, 由 <strong>$actor</strong> 创建子任务 <strong>$extra</strong>。' . "\n";
|
||||
@@ -336,8 +338,10 @@ $lang->action->label->activatedbychild = '激活了';
|
||||
$lang->action->label->createchild = '激活了';
|
||||
$lang->action->label->executed = '执行了';
|
||||
$lang->action->label->importedcard = '导入了';
|
||||
$lang->action->label->importedplan = '导入了';
|
||||
$lang->action->label->importedproductplan = '导入了';
|
||||
$lang->action->label->importedrelease = '导入了';
|
||||
$lang->action->label->importedexecution = '导入了';
|
||||
$lang->action->label->importedbuild = '导入了';
|
||||
|
||||
/* 动态信息按照对象分组 */
|
||||
$lang->action->dynamicAction = new stdclass();
|
||||
|
||||
@@ -1053,6 +1053,13 @@ class actionModel extends model
|
||||
$user = $this->dao->select('id,realname')->from(TABLE_USER)->where('id')->eq($action->objectID)->fetch();
|
||||
if($user) $action->objectName = $user->realname;
|
||||
}
|
||||
elseif($action->objectType == 'kanbancard' and strpos($action->action, 'imported') !== false and $action->action != 'importedcard')
|
||||
{
|
||||
$objectType = str_replace('imported', '', $action->action);
|
||||
$objectTable = zget($this->config->objectTables, $objectType);
|
||||
$objectName = $objectType == 'productplan' ? 'title' : 'name';
|
||||
$action->objectName = $this->dao->select($objectName)->from($objectTable)->where('id')->eq($action->extra)->fetch($objectName);
|
||||
}
|
||||
|
||||
$projectID = isset($relatedProjects[$action->objectType][$action->objectID]) ? $relatedProjects[$action->objectType][$action->objectID] : 0;
|
||||
|
||||
|
||||
@@ -56,10 +56,11 @@ class buildModel extends model
|
||||
* @param string $type
|
||||
* @param int $param
|
||||
* @param string $orderBy
|
||||
* @param object $pager
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getProjectBuilds($projectID = 0, $type = 'all', $param = 0, $orderBy = 't1.date_desc,t1.id_desc')
|
||||
public function getProjectBuilds($projectID = 0, $type = 'all', $param = 0, $orderBy = 't1.date_desc,t1.id_desc', $pager = null)
|
||||
{
|
||||
return $this->dao->select('t1.*, t2.name as executionName, t2.id as executionID, t3.name as productName, t4.name as branchName')
|
||||
->from(TABLE_BUILD)->alias('t1')
|
||||
@@ -72,6 +73,7 @@ class buildModel extends model
|
||||
->beginIF($type == 'product' and $param)->andWhere('t1.product')->eq($param)->fi()
|
||||
->beginIF($type == 'bysearch')->andWhere($param)->fi()
|
||||
->orderBy($orderBy)
|
||||
->page($pager)
|
||||
->fetchAll('id');
|
||||
}
|
||||
|
||||
@@ -243,7 +245,7 @@ class buildModel extends model
|
||||
$branchName = $allBuilds[$buildID]->branchName ? $allBuilds[$buildID]->branchName : $this->lang->branch->main;
|
||||
$builds[$buildID] = (strpos($params, 'withbranch') !== false ? $branchName . '/' : '') . $releaseName;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $sysBuilds + $builds + $selectedBuilds;
|
||||
}
|
||||
|
||||
+106
-1
@@ -863,7 +863,7 @@ class kanban extends control
|
||||
|
||||
foreach($importedIDList as $cardID => $planID)
|
||||
{
|
||||
$this->loadModel('action')->create('kanbancard', $cardID, 'importedPlan', '', $planID);
|
||||
$this->loadModel('action')->create('kanbancard', $cardID, 'importedProductplan', '', $planID);
|
||||
}
|
||||
|
||||
return print(js::locate($this->createLink('kanban', 'view', "kanbanID=$kanbanID"), 'parent.parent'));
|
||||
@@ -882,6 +882,111 @@ class kanban extends control
|
||||
$this->display();
|
||||
}
|
||||
|
||||
/**
|
||||
* Import release.
|
||||
*
|
||||
* @param int $kanbanID
|
||||
* @param int $regionID
|
||||
* @param int $groupID
|
||||
* @param int $columnID
|
||||
* @param int $selectedProductID
|
||||
* @param int $recTotal
|
||||
* @param int $recPerPage
|
||||
* @param int $pageID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function importRelease($kanbanID = 0, $regionID = 0, $groupID = 0, $columnID = 0, $selectedProductID = 0, $recTotal = 0, $recPerPage = 30, $pageID = 1)
|
||||
{
|
||||
$this->loadModel('product');
|
||||
$this->loadModel('release');
|
||||
|
||||
/* Load pager. */
|
||||
$this->app->loadClass('pager', $static = true);
|
||||
$pager = new pager($recTotal, $recPerPage, $pageID);
|
||||
|
||||
$productPairs = $this->product->getPairs();
|
||||
$selectedProductID = empty($selectedProductID) ? key($productPairs) : $selectedProductID;
|
||||
|
||||
if($_POST)
|
||||
{
|
||||
$importedIDList = $this->kanban->importObject($kanbanID, $regionID, $groupID, $columnID, 'release');
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
|
||||
foreach($importedIDList as $cardID => $releaseID)
|
||||
{
|
||||
$this->loadModel('action')->create('kanbancard', $cardID, 'importedRelease', '', $releaseID);
|
||||
}
|
||||
|
||||
return print(js::locate($this->createLink('kanban', 'view', "kanbanID=$kanbanID"), 'parent.parent'));
|
||||
}
|
||||
|
||||
$this->view->products = $productPairs;
|
||||
$this->view->selectedProductID = $selectedProductID;
|
||||
$this->view->lanePairs = $this->kanban->getLanePairsByGroup($groupID);
|
||||
$this->view->releases2Imported = $this->release->getList($selectedProductID, 'all', 'all', 't1.date_desc', $pager);
|
||||
$this->view->pager = $pager;
|
||||
$this->view->kanbanID = $kanbanID;
|
||||
$this->view->regionID = $regionID;
|
||||
$this->view->groupID = $groupID;
|
||||
$this->view->columnID = $columnID;
|
||||
|
||||
$this->display();
|
||||
}
|
||||
|
||||
/**
|
||||
* Import build.
|
||||
*
|
||||
* @param int $kanbanID
|
||||
* @param int $regionID
|
||||
* @param int $groupID
|
||||
* @param int $columnID
|
||||
* @param int $selectedProjectID
|
||||
* @param int $recTotal
|
||||
* @param int $recPerPage
|
||||
* @param int $pageID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function importBuild($kanbanID = 0, $regionID = 0, $groupID = 0, $columnID = 0, $selectedProjectID = 0, $recTotal = 0, $recPerPage = 30, $pageID = 1)
|
||||
{
|
||||
if($_POST)
|
||||
{
|
||||
$importedIDList = $this->kanban->importObject($kanbanID, $regionID, $groupID, $columnID, 'build');
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
|
||||
foreach($importedIDList as $cardID => $buildID)
|
||||
{
|
||||
$this->loadModel('action')->create('kanbancard', $cardID, 'importedBuild', '', $buildID);
|
||||
}
|
||||
|
||||
return print(js::locate($this->createLink('kanban', 'view', "kanbanID=$kanbanID"), 'parent.parent'));
|
||||
}
|
||||
|
||||
$this->loadModel('project');
|
||||
$this->loadModel('build');
|
||||
|
||||
/* Load pager. */
|
||||
$this->app->loadClass('pager', $static = true);
|
||||
$pager = new pager($recTotal, $recPerPage, $pageID);
|
||||
|
||||
$projectPairs = $this->project->getPairsByProgram();
|
||||
$selectedProjectID = empty($selectedProjectID) ? key($projectPairs) : $selectedProjectID;
|
||||
|
||||
$this->view->projects = $projectPairs;
|
||||
$this->view->selectedProjectID = $selectedProjectID;
|
||||
$this->view->lanePairs = $this->kanban->getLanePairsByGroup($groupID);
|
||||
$this->view->builds2Imported = $this->build->getProjectBuilds($selectedProjectID, 'all', 0, 't1.date_desc,t1.id_desc', $pager);;
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter|nodeleted');
|
||||
$this->view->pager = $pager;
|
||||
$this->view->kanbanID = $kanbanID;
|
||||
$this->view->regionID = $regionID;
|
||||
$this->view->groupID = $groupID;
|
||||
$this->view->columnID = $columnID;
|
||||
|
||||
$this->display();
|
||||
}
|
||||
|
||||
/**
|
||||
* Import execution.
|
||||
*
|
||||
|
||||
@@ -45,3 +45,26 @@ function initColorPicker()
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* Reload object list.
|
||||
*
|
||||
* @param int $targetID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function reloadObjectList(targetID)
|
||||
{
|
||||
location.href = createLink('kanban', methodName, 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID + '&targetID=' + targetID);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set target lane ID.
|
||||
*
|
||||
* @param int $targetLaneID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function setTargetLane(targetLaneID)
|
||||
{
|
||||
$('#targetLane').val(targetLaneID);
|
||||
}
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
/**
|
||||
* Reload card list.
|
||||
*
|
||||
* @param int $kanbanID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function reloadCardList(targetID)
|
||||
{
|
||||
location.href = createLink('kanban','importcard','kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID + '&targetKanbanID=' + targetID);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set target lane ID.
|
||||
*
|
||||
* @param int $targetLaneID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function setTargetLane(targetLaneID)
|
||||
{
|
||||
$('#targetLane').val(targetLaneID);
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
/**
|
||||
* Reload card list.
|
||||
*
|
||||
* @param int $kanbanID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function reloadExecutionList(targetID)
|
||||
{
|
||||
location.href = createLink('kanban', 'importExecution','kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID + '&targetProductID=' + targetID);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set target lane ID.
|
||||
*
|
||||
* @param int $targetLaneID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function setTargetLane(targetLaneID)
|
||||
{
|
||||
$('#targetLane').val(targetLaneID);
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
/**
|
||||
* Reload card list.
|
||||
*
|
||||
* @param int $kanbanID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function reloadPlanList(targetID)
|
||||
{
|
||||
location.href = createLink('kanban','importPlan','kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID + '&targetProductID=' + targetID);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set target lane ID.
|
||||
*
|
||||
* @param int $targetLaneID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function setTargetLane(targetLaneID)
|
||||
{
|
||||
$('#targetLane').val(targetLaneID);
|
||||
}
|
||||
@@ -145,7 +145,7 @@ function renderHeaderCol($column, column, $header, kanbanData)
|
||||
|
||||
if(columnPrivs.includes('createCard') && column.parent != -1)
|
||||
{
|
||||
var cardUrl = createLink('kanban', 'importExecution', 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID);
|
||||
var cardUrl = createLink('kanban', 'importplan', 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&columnID=' + columnID);
|
||||
addItemBtn = ['<a data-contextmenu="columnCreate" data-toggle="modal" data-action="addItem" data-column="' + column.id + '" data-lane="' + laneID + '" href="' + cardUrl + '" class="text-primary iframe">', '<i class="icon icon-expand-alt"></i>', '</a>'].join('');
|
||||
}
|
||||
|
||||
|
||||
@@ -59,11 +59,13 @@ $lang->kanban->restore = 'Restore';
|
||||
$lang->kanban->child = 'Child';
|
||||
$lang->kanban->showClosed = 'Closed';
|
||||
$lang->kanban->importCard = 'Import Card';
|
||||
$lang->kanban->allKanban = 'All Kanban';
|
||||
$lang->kanban->importPlan = 'Import Plan';
|
||||
$lang->kanban->allProducts = 'All Products';
|
||||
$lang->kanban->importExecution = 'Import Execution';
|
||||
$lang->kanban->importRelease = 'Import Release';
|
||||
$lang->kanban->importExecution = 'Import ' . $lang->execution->common;
|
||||
$lang->kanban->importBuild = 'Import Build';
|
||||
$lang->kanban->allKanban = 'All Kanban';
|
||||
$lang->kanban->allProjects = 'All Projects';
|
||||
$lang->kanban->allProducts = 'All Products';
|
||||
|
||||
/* Fields. */
|
||||
$lang->kanban->space = 'Space';
|
||||
|
||||
@@ -59,11 +59,13 @@ $lang->kanban->restore = '还原';
|
||||
$lang->kanban->child = '子';
|
||||
$lang->kanban->showClosed = '显示已关闭';
|
||||
$lang->kanban->importCard = '转入卡片';
|
||||
$lang->kanban->allKanban = '所有看板';
|
||||
$lang->kanban->importPlan = '导入产品计划';
|
||||
$lang->kanban->allProducts = '所有产品';
|
||||
$lang->kanban->importExecution = '导入项目执行';
|
||||
$lang->kanban->importRelease = '导入产品发布';
|
||||
$lang->kanban->importExecution = '导入项目' . $lang->execution->common;
|
||||
$lang->kanban->importBuild = '导入项目版本';
|
||||
$lang->kanban->allKanban = '所有看板';
|
||||
$lang->kanban->allProjects = '所有项目';
|
||||
$lang->kanban->allProducts = '所有产品';
|
||||
|
||||
/* Fields. */
|
||||
$lang->kanban->space = '所属空间';
|
||||
|
||||
@@ -0,0 +1,84 @@
|
||||
<?php
|
||||
/**
|
||||
* The import build view of kanban module of ZenTaoPMS.
|
||||
*
|
||||
* @copyright Copyright 2009-2021 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com)
|
||||
* @license ZPL (http://zpl.pub/page/zplv12.html)
|
||||
* @author Qiyu Xie<xieqiyu@cnezsoft.com>
|
||||
* @package kanban
|
||||
* @version $Id: importbuild.html.php 5090 2022-01-19 14:19:24Z xieqiyu@cnezsoft.com $
|
||||
* @link https://www.zentao.net
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.lite.html.php';?>
|
||||
<?php include '../../common/view/kindeditor.html.php';?>
|
||||
<?php js::set('kanbanID', $kanbanID);?>
|
||||
<?php js::set('regionID', $regionID);?>
|
||||
<?php js::set('groupID', $groupID);?>
|
||||
<?php js::set('columnID', $columnID);?>
|
||||
<?php js::set('methodName', $this->app->rawMethod);?>
|
||||
<div id='mainContent' class='main-content'>
|
||||
<div class='center-block'>
|
||||
<div class='main-header'>
|
||||
<h2><?php echo $lang->kanban->importBuild;?></h2>
|
||||
</div>
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedProject;?></h4></div>
|
||||
<div class='table-col'><?php echo html::select('project', $projects, $selectedProjectID, "onchange='reloadObjectList(this.value)' class='form-control chosen'");?></div>
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedLane;?></h4></div>
|
||||
<div class='table-col'><?php echo html::select('lane', $lanePairs, '', "onchange='setTargetLane(this.value)' class='form-control chosen'");?></div>
|
||||
</div>
|
||||
<form class='main-table' method='post' data-ride='table' target='hiddenwin' id='importBuildForm'>
|
||||
<table class='table table-fixed' id='buildList'>
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="c-id">
|
||||
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
|
||||
<label></label>
|
||||
</div>
|
||||
<?php echo $lang->idAB;?>
|
||||
</th>
|
||||
<th class='c-name'><?php echo $lang->build->product;?></th>
|
||||
<th class='c-name'><?php echo $lang->build->name;?></th>
|
||||
<th class='c-name'><?php echo $lang->executionCommon;?></th>
|
||||
<th class='c-date'><?php echo $lang->build->date;?></th>
|
||||
<th class='c-user'><?php echo $lang->build->builder;?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach($builds2Imported as $build):?>
|
||||
<tr>
|
||||
<td class='c-id'>
|
||||
<div class="checkbox-primary">
|
||||
<input type='checkbox' name='builds[]' value='<?php echo $build->id;?>'/>
|
||||
<label></label>
|
||||
</div>
|
||||
<?php printf('%03d', $build->id);?>
|
||||
</td>
|
||||
<td title='<?php echo $build->productName;?>'><?php echo $build->productName;?></td>
|
||||
<?php if(common::hasPriv('build', 'view')):?>
|
||||
<td title='<?php echo $build->name;?>'><?php common::printLink('build', 'view', "buildID=$build->id", $build->name, '', "class='iframe'", true, true);?></td>
|
||||
<?php else:?>
|
||||
<td title='<?php echo $build->name;?>'><?php echo $build->name;?></td>
|
||||
<?php endif;?>
|
||||
<td title='<?php echo $build->executionName;?>'><?php echo $build->executionName;?></td>
|
||||
<td title='<?php echo $build->date;?>'><?php echo $build->date;?></td>
|
||||
<td title='<?php echo zget($users, $build->builder);?>'><?php echo zget($users, $build->builder);?></td>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
<tr><?php echo html::hidden('targetLane', key($lanePairs));?></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php if($builds2Imported):?>
|
||||
<div class='table-footer'>
|
||||
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
|
||||
<div class="table-actions btn-toolbar show-always"><?php echo html::submitButton($lang->kanban->importBuild, '', 'btn btn-default');?></div>
|
||||
<?php $pager->show('right', 'pagerjs');?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
</form>
|
||||
</div>
|
||||
<?php include '../../common/view/footer.lite.html.php';?>
|
||||
@@ -16,6 +16,7 @@
|
||||
<?php js::set('regionID', $regionID);?>
|
||||
<?php js::set('groupID', $groupID);?>
|
||||
<?php js::set('columnID', $columnID);?>
|
||||
<?php js::set('methodName', $this->app->rawMethod);?>
|
||||
<div id='mainContent' class='main-content'>
|
||||
<div class='center-block'>
|
||||
<div class='main-header'>
|
||||
@@ -24,7 +25,7 @@
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedKanban;?></h4></div>
|
||||
<div class='table-col'><?php echo html::select('kanban', $kanbanPairs, $selectedKanbanID, "onchange='reloadCardList(this.value)' class='form-control chosen'");?></div>
|
||||
<div class='table-col'><?php echo html::select('kanban', $kanbanPairs, $selectedKanbanID, "onchange='reloadObjectList(this.value)' class='form-control chosen'");?></div>
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedLane;?></h4></div>
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
<?php js::set('regionID', $regionID);?>
|
||||
<?php js::set('groupID', $groupID);?>
|
||||
<?php js::set('columnID', $columnID);?>
|
||||
<?php js::set('methodName', $this->app->rawMethod);?>
|
||||
<div id='mainContent' class='main-content'>
|
||||
<div class='center-block'>
|
||||
<div class='main-header'>
|
||||
@@ -24,7 +25,7 @@
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedProject;?></h4></div>
|
||||
<div class='table-col'><?php echo html::select('project', $projects, $selectedProjectID, "onchange='reloadExecutionList(this.value)' class='form-control chosen'");?></div>
|
||||
<div class='table-col'><?php echo html::select('project', $projects, $selectedProjectID, "onchange='reloadObjectList(this.value)' class='form-control chosen'");?></div>
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedLane;?></h4></div>
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
<?php js::set('regionID', $regionID);?>
|
||||
<?php js::set('groupID', $groupID);?>
|
||||
<?php js::set('columnID', $columnID);?>
|
||||
<?php js::set('methodName', $this->app->rawMethod);?>
|
||||
<div id='mainContent' class='main-content'>
|
||||
<div class='center-block'>
|
||||
<div class='main-header'>
|
||||
@@ -24,7 +25,7 @@
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedProduct;?></h4></div>
|
||||
<div class='table-col'><?php echo html::select('product', $products, $selectedProductID, "onchange='reloadPlanList(this.value)' class='form-control chosen'");?></div>
|
||||
<div class='table-col'><?php echo html::select('product', $products, $selectedProductID, "onchange='reloadObjectList(this.value)' class='form-control chosen'");?></div>
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedLane;?></h4></div>
|
||||
|
||||
@@ -0,0 +1,82 @@
|
||||
<?php
|
||||
/**
|
||||
* The import release view of kanban module of ZenTaoPMS.
|
||||
*
|
||||
* @copyright Copyright 2009-2021 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com)
|
||||
* @license ZPL (http://zpl.pub/page/zplv12.html)
|
||||
* @author Qiyu Xie<xieqiyu@cnezsoft.com>
|
||||
* @package kanban
|
||||
* @version $Id: importrelease.html.php 5090 2022-01-19 14:19:24Z xieqiyu@cnezsoft.com $
|
||||
* @link https://www.zentao.net
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.lite.html.php';?>
|
||||
<?php include '../../common/view/kindeditor.html.php';?>
|
||||
<?php js::set('kanbanID', $kanbanID);?>
|
||||
<?php js::set('regionID', $regionID);?>
|
||||
<?php js::set('groupID', $groupID);?>
|
||||
<?php js::set('columnID', $columnID);?>
|
||||
<?php js::set('methodName', $this->app->rawMethod);?>
|
||||
<div id='mainContent' class='main-content'>
|
||||
<div class='center-block'>
|
||||
<div class='main-header'>
|
||||
<h2><?php echo $lang->kanban->importRelease;?></h2>
|
||||
</div>
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedProduct;?></h4></div>
|
||||
<div class='table-col'><?php echo html::select('product', $products, $selectedProductID, "onchange='reloadObjectList(this.value)' class='form-control chosen'");?></div>
|
||||
</div>
|
||||
<div class='table-row' style="padding: 10px">
|
||||
<div class='table-col w-150px text-center'><h4><?php echo $lang->kanban->selectedLane;?></h4></div>
|
||||
<div class='table-col'><?php echo html::select('lane', $lanePairs, '', "onchange='setTargetLane(this.value)' class='form-control chosen'");?></div>
|
||||
</div>
|
||||
<form class='main-table' method='post' data-ride='table' target='hiddenwin' id='importReleaseForm'>
|
||||
<table class='table table-fixed' id='releaseList'>
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="c-id">
|
||||
<div class="checkbox-primary check-all" title="<?php echo $lang->selectAll?>">
|
||||
<label></label>
|
||||
</div>
|
||||
<?php echo $lang->idAB;?>
|
||||
</th>
|
||||
<th class='c-name'><?php echo $lang->release->name;?></th>
|
||||
<th class='c-name'><?php echo $lang->release->project;?></th>
|
||||
<th class='c-name'><?php echo $lang->release->build;?></th>
|
||||
<th class='c-date'><?php echo $lang->release->date;?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach($releases2Imported as $release):?>
|
||||
<tr>
|
||||
<td class='c-id'>
|
||||
<div class="checkbox-primary">
|
||||
<input type='checkbox' name='releases[]' value='<?php echo $release->id;?>'/>
|
||||
<label></label>
|
||||
</div>
|
||||
<?php printf('%03d', $release->id);?>
|
||||
</td>
|
||||
<?php if(common::hasPriv('release', 'view')):?>
|
||||
<td title='<?php echo $release->name;?>'><?php common::printLink('release', 'view', "releaseID=$release->id", $release->name, '', "class='iframe'", true, true);?></td>
|
||||
<?php else:?>
|
||||
<td title='<?php echo $release->name;?>'><?php echo $release->name;?></td>
|
||||
<?php endif;?>
|
||||
<td title='<?php echo $release->projectName;?>'><?php echo $release->projectName;?></td>
|
||||
<td title='<?php echo $release->buildName;?>'><?php echo $release->buildName;?></td>
|
||||
<td title='<?php echo $release->date;?>'><?php echo $release->date;?></td>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
<tr><?php echo html::hidden('targetLane', key($lanePairs));?></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php if($releases2Imported):?>
|
||||
<div class='table-footer'>
|
||||
<div class="checkbox-primary check-all"><label><?php echo $lang->selectAll?></label></div>
|
||||
<div class="table-actions btn-toolbar show-always"><?php echo html::submitButton($lang->kanban->importRelease, '', 'btn btn-default');?></div>
|
||||
<?php $pager->show('right', 'pagerjs');?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
</form>
|
||||
</div>
|
||||
<?php include '../../common/view/footer.lite.html.php';?>
|
||||
@@ -47,10 +47,11 @@ class releaseModel extends model
|
||||
* @param int $branch
|
||||
* @param string $type
|
||||
* @param string $orderBy
|
||||
* @param object $pager
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getList($productID, $branch = 'all', $type = 'all', $orderBy = 't1.date_desc')
|
||||
public function getList($productID, $branch = 'all', $type = 'all', $orderBy = 't1.date_desc', $pager = null)
|
||||
{
|
||||
return $this->dao->select('t1.*, t2.name as productName, t3.id as buildID, t3.name as buildName, t3.project, t4.name as projectName')
|
||||
->from(TABLE_RELEASE)->alias('t1')
|
||||
@@ -62,6 +63,7 @@ class releaseModel extends model
|
||||
->beginIF($type != 'all')->andWhere('t1.status')->eq($type)->fi()
|
||||
->andWhere('t1.deleted')->eq(0)
|
||||
->orderBy($orderBy)
|
||||
->page($pager)
|
||||
->fetchAll();
|
||||
}
|
||||
|
||||
@@ -480,13 +482,13 @@ class releaseModel extends model
|
||||
}
|
||||
|
||||
/**
|
||||
* Judge btn is clickable or not.
|
||||
*
|
||||
* @param int $release
|
||||
* @param string $action
|
||||
* Judge btn is clickable or not.
|
||||
*
|
||||
* @param int $release
|
||||
* @param string $action
|
||||
* @static
|
||||
* @access public
|
||||
* @return bool
|
||||
* @return bool
|
||||
*/
|
||||
public static function isClickable($release, $action)
|
||||
{
|
||||
@@ -498,7 +500,7 @@ class releaseModel extends model
|
||||
|
||||
/**
|
||||
* Send mail to release related users.
|
||||
*
|
||||
*
|
||||
* @param int $releaseID
|
||||
* @access public
|
||||
* @return void
|
||||
|
||||
Reference in New Issue
Block a user