* task children style

This commit is contained in:
滔哥
2017-10-23 17:15:45 +08:00
parent 4f14940ece
commit c9805574df
2 changed files with 14 additions and 6 deletions
+4 -1
View File
@@ -24,4 +24,7 @@
.pl-5px{padding-left:5px;}
tbody > tr > td > .btn-icon {margin-right: 2px}
.table-children td{background-color:#fff0f5!important;}
.table-children{border-left:2px solid #ccc;border-right:2px solid #ccc;}
.table-children.table-child-top{border-top:2px solid #ccc;}
.table-children.table-child-bottom{border-bottom:2px solid #ccc;}
.table-children td{background-color:#f0f8ff!important;}
+10 -5
View File
@@ -70,13 +70,18 @@ js::set('browseType', $browseType);
<tr class='text-center' data-id='<?php echo $task->id?>'>
<?php foreach ($setting as $key => $value) $this->task->printCell($value, $task, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table');?>
</tr>
<?php if(!empty($task->children)):?>
<?php foreach($task->children as $child):?>
<tr class='text-center table-children parent-<?php echo $task->id;?>' data-id='<?php echo $child->id?>'>
<?php
if(!empty($task->children))
{
$childrenNum = count($task->children);
foreach($task->children as $key=>$child)
{
?>
<tr class='text-center table-children<?php if($key==0) echo ' table-child-top';?><?php if(($key+1) == $childrenNum) echo ' table-child-bottom';?> parent-<?php echo $task->id;?>' data-id='<?php echo $child->id?>'>
<?php foreach ($setting as $key => $value) $this->task->printCell($value, $child, $users, $browseType, $branchGroups, $modulePairs, $useDatatable ? 'datatable' : 'table');?>
</tr>
<?php endforeach;?>
<?php endif;?>
<?php }?>
<?php }?>
<?php endforeach;?>
</tbody>
<tfoot>