This commit is contained in:
hufangzhou
2022-03-23 09:58:09 +08:00
parent 0c79df3fb6
commit 8b8b4f6989
2 changed files with 17 additions and 2 deletions

View File

@@ -113,3 +113,12 @@
.paramsTable th {text-align: left!important; font-size: 14px;}
.paramsTable td {text-align: left;}
.tree-group {position: relative;}
.tree-group > .module-name {white-space: nowrap; overflow: hidden; text-overflow: ellipsis; width: 100%; display: block;}
.tree li.active > .tree-group a {font-weight: 700; color: #0c64eb;}
.tree-actions {display: inline-block; margin-left: 5px; vertical-align: middle;}
.tree-group .tree-actions {display: none; position: absolute; right: 0; top: 0; background-color: #fff; white-space: nowrap;}
.tree-group:hover .tree-actions {display: block}
.tree-actions a {display: inline-block; margin-left: 5px; font-size: 13px; opacity: .6;}
.tree li.active > .tree-group a {font-weight: 700; color: #0c64eb;}

View File

@@ -2305,10 +2305,16 @@ EOT;
foreach($moduleDocs[0] as $doc)
{
$treeMenu[0] .= '<li' . ($doc->id == $docID ? ' class="active"' : ' class="independent"') . '>';
$treeMenu[0] .= "<div class='tree-group'><span class='module-name'>" . html::a(inlink('index', "libID=$rootID&moduelID=0&apiID={$doc->id}"), "<i class='icon icon-file-text text-muted'></i> &nbsp;" . $doc->title, '', "data-app='{$this->app->tab}' class='doc-title' title='{$doc->title}'") . '</span>';
$treeMenu[0] .= html::a(inlink('index', "libID=$rootID&moduelID=0&apiID={$doc->id}"), "<i class='icon icon-file-text text-muted'></i> &nbsp;" . $doc->title, '', "data-app='{$this->app->tab}' class='doc-title' title='{$doc->title}'");
if(common::hasPriv('api', 'edit'))
{
$treeMenu[0] .= "<div class='tree-actions'>";
$treeMenu[0] .= html::a(helper::createLink('api', 'edit', "docID={$doc->id}"), "<i class='icon icon-edit'></i>", '', "title={$this->lang->doc->edit} data-app='{$this->app->tab}'");
$treeMenu[0] .= '</div>';
}
$treeMenu[0] .= '</li>';
$treeMenu[0] .= '</div></li>';
}
}