* Fix code details.
This commit is contained in:
@@ -74,3 +74,8 @@ body {background-color: #fff}
|
||||
.region .kanban-item.has-color .info > .label-light {color: #FFFFFF;}
|
||||
.region .kanban-item.has-color .info > .label-pri {border-color: #FFFFFF;}
|
||||
.region .kanban-item .item-more {position: absolute; right: 6px; top: 0px;}
|
||||
|
||||
.kanban-col[data-type=ADD] {display: none;}
|
||||
.kanban-col[data-type=EMPTY] {display: none;}
|
||||
.kanban-item:hover .title {padding-right: 10px;}
|
||||
.gray .actions {display:none;}
|
||||
|
||||
+10
-1
@@ -228,6 +228,13 @@ class kanbanModel extends model
|
||||
return $this->dao->findByID($kanbanID)->from(TABLE_KANBAN)->fetch();
|
||||
}
|
||||
|
||||
/**
|
||||
* Get kanban data.
|
||||
*
|
||||
* @param int $kanbanID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function getKanbanData($kanbanID)
|
||||
{
|
||||
$kanbanData = array();
|
||||
@@ -277,7 +284,7 @@ class kanbanModel extends model
|
||||
*
|
||||
* @param int $kanbanID
|
||||
* @access public
|
||||
* @return void
|
||||
* @return array
|
||||
*/
|
||||
public function getRegionPairs($kanbanID)
|
||||
{
|
||||
@@ -352,12 +359,14 @@ class kanbanModel extends model
|
||||
|
||||
$actions = array('createColumn', 'copyColumn', 'editColumn', 'splitColumn', 'setWIP', 'archiveColumn', 'restoreColumn', 'deleteColumn');
|
||||
|
||||
/* Group by parent. */
|
||||
$parentColumnGroup = array();
|
||||
foreach($columnGroup as $group => $columns)
|
||||
{
|
||||
foreach($columns as $column)
|
||||
{
|
||||
$column->actions = array();
|
||||
/* Judge column action priv. */
|
||||
foreach($actions as $action)
|
||||
{
|
||||
if($this->isClickable($column, $action)) $column->actions[] = $action;
|
||||
|
||||
@@ -1,14 +1,5 @@
|
||||
<?php
|
||||
include '../../common/view/header.html.php';
|
||||
include '../../common/view/kanban.html.php';
|
||||
?>
|
||||
|
||||
<style>
|
||||
.kanban-col[data-type=ADD] {display: none;}
|
||||
.kanban-col[data-type=EMPTY] {display: none;}
|
||||
.kanban-item:hover .title {padding-right: 10px;}
|
||||
.gray .actions {display:none;}
|
||||
</style>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<?php include '../../common/view/kanban.html.php';?>
|
||||
|
||||
<?php
|
||||
$laneCount = 0;
|
||||
@@ -31,24 +22,24 @@ $canCreateLane = commonModel::hasPriv('kanban', 'createLane');
|
||||
?>
|
||||
|
||||
<div id="kanban">
|
||||
<?php foreach($regions as $region):?>
|
||||
<div class="region <?php if($canSortRegion) echo 'sort';?>" data-id="<?php echo $region->id;?>">
|
||||
<div class="region-header dropdown">
|
||||
<span class="strong"><?php echo $region->name;?></span>
|
||||
<label class="label label-region"><?php echo $this->lang->kanbanlane->common . ' ' . $region->laneCount;?></label>
|
||||
<i class="icon icon-double-angle-up"></i>
|
||||
<?php if($canEditRegion || $canCreateLane || $canDeleteRegion):?>
|
||||
<button class="btn btn-link action" type="button" data-toggle="dropdown"><i class="icon icon-more-v"></i></button>
|
||||
<ul class="dropdown-menu pull-right">
|
||||
<?php if($canEditRegion) echo '<li>' . html::a(inlink('editRegion', "regionID={$region->id}"), $this->lang->kanban->editRegion, "data-toggle='modal'") . '</li>';?>
|
||||
<?php if($canCreateLane) echo '<li>' . html::a(inlink('createLane', "kanbanID={$project->id}®ionID={$region->id}"), $this->lang->kanban->createLane, "data-toggle='modal'") . '</li>';?>
|
||||
<?php if($canDeleteRegion) echo '<li>' . html::a(inlink('deleteRegion', "regionID={$region->id}"), $this->lang->kanban->deleteRegion, "class='confirmer' data-confirmTitle='{$lang->kanbanregion->confirmDelete}' data-confirmDetail='{$lang->kanbanregion->confirmDeleteDetail}'") . '</li>';?>
|
||||
</ul>
|
||||
<?php endif;?>
|
||||
<?php foreach($regions as $region):?>
|
||||
<div class="region <?php if($canSortRegion) echo 'sort';?>" data-id="<?php echo $region->id;?>">
|
||||
<div class="region-header dropdown">
|
||||
<span class="strong"><?php echo $region->name;?></span>
|
||||
<label class="label label-region"><?php echo $this->lang->kanbanlane->common . ' ' . $region->laneCount;?></label>
|
||||
<i class="icon icon-double-angle-up"></i>
|
||||
<?php if($canEditRegion || $canCreateLane || $canDeleteRegion):?>
|
||||
<button class="btn btn-link action" type="button" data-toggle="dropdown"><i class="icon icon-more-v"></i></button>
|
||||
<ul class="dropdown-menu pull-right">
|
||||
<?php if($canEditRegion) echo '<li>' . html::a(inlink('editRegion', "regionID={$region->id}"), $this->lang->kanban->editRegion, "data-toggle='modal'") . '</li>';?>
|
||||
<?php if($canCreateLane) echo '<li>' . html::a(inlink('createLane', "kanbanID={$project->id}®ionID={$region->id}"), $this->lang->kanban->createLane, "data-toggle='modal'") . '</li>';?>
|
||||
<?php if($canDeleteRegion) echo '<li>' . html::a(inlink('deleteRegion', "regionID={$region->id}"), $this->lang->kanban->deleteRegion, "class='confirmer' data-confirmTitle='{$lang->kanbanregion->confirmDelete}' data-confirmDetail='{$lang->kanbanregion->confirmDeleteDetail}'") . '</li>';?>
|
||||
</ul>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
<div id='kanban<?php echo $region->id;?>' data-id='<?php echo $region->id;?>' class='kanban'></div>
|
||||
</div>
|
||||
<div id='kanban<?php echo $region->id;?>' data-id='<?php echo $region->id;?>' class='kanban'></div>
|
||||
</div>
|
||||
<?php endforeach;?>
|
||||
<?php endforeach;?>
|
||||
</div>
|
||||
<div id='moreTasks'></div>
|
||||
<div id='moreColumns'></div>
|
||||
|
||||
Reference in New Issue
Block a user