|
|
@@ -10,7 +10,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); |
|
|
|
* @link https://www.dedebiz.com
|
|
|
|
*/
|
|
|
|
require_once(DEDEINC."/channelunit.func.php");
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 栏目单元,主要用户管理后台管理处
|
|
|
|
*
|
|
|
@@ -27,7 +26,6 @@ class TypeUnit |
|
|
|
var $idArrary;
|
|
|
|
var $shortName;
|
|
|
|
var $CatalogNums;
|
|
|
|
|
|
|
|
//php5构造函数
|
|
|
|
function __construct()
|
|
|
|
{
|
|
|
@@ -38,17 +36,14 @@ class TypeUnit |
|
|
|
$this->idArrary = '';
|
|
|
|
$this->dsql = 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
function TypeUnit()
|
|
|
|
{
|
|
|
|
$this->__construct();
|
|
|
|
}
|
|
|
|
|
|
|
|
//清理类
|
|
|
|
function Close()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
//获取所有栏目的文档ID数
|
|
|
|
function UpdateCatalogNum()
|
|
|
|
{
|
|
|
@@ -58,7 +53,6 @@ class TypeUnit |
|
|
|
$this->CatalogNums[$row['typeid']] = $row['dd'];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function GetTotalArc($tid)
|
|
|
|
{
|
|
|
|
if (!is_array($this->CatalogNums)) {
|
|
|
@@ -77,7 +71,6 @@ class TypeUnit |
|
|
|
return $totalnum;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 读出所有分类,在类目管理页(list_type)中使用
|
|
|
|
*
|
|
|
@@ -90,7 +83,6 @@ class TypeUnit |
|
|
|
{
|
|
|
|
global $cfg_admin_channel, $admin_catalogs;
|
|
|
|
$this->dsql = $GLOBALS['dsql'];
|
|
|
|
|
|
|
|
//检测用户有权限的顶级栏目
|
|
|
|
if ($cfg_admin_channel == 'array') {
|
|
|
|
$admin_catalog = join(',', $admin_catalogs);
|
|
|
@@ -105,7 +97,6 @@ class TypeUnit |
|
|
|
$admin_catalogs = explode(',', $admin_catalog);
|
|
|
|
$admin_catalogs = array_unique($admin_catalogs);
|
|
|
|
}
|
|
|
|
|
|
|
|
$this->dsql->SetQuery("SELECT id,typedir,typename,ispart,sortrank,ishidden FROM `#@__arctype` WHERE reid=0 order by sortrank");
|
|
|
|
$this->dsql->Execute(0);
|
|
|
|
while ($row = $this->dsql->GetObject(0)) {
|
|
|
@@ -122,58 +113,57 @@ class TypeUnit |
|
|
|
} else {
|
|
|
|
$nss = '';
|
|
|
|
}
|
|
|
|
echo "<table width='100%' border='0' cellspacing='0' cellpadding='2'>\r\n";
|
|
|
|
echo "<table width='100%' border='0' cellspacing='0' cellpadding='2'>";
|
|
|
|
//普通列表
|
|
|
|
if ($ispart == 0) {
|
|
|
|
echo " <tr>\r\n";
|
|
|
|
echo " <td style='background-color:#FBFCE2;' width='2%' class='bline'><img style='cursor:pointer' id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' width='11' height='11'></td>\r\n";
|
|
|
|
echo " <td style='background-color:#FBFCE2;' class='bline'><table width='98%' border='0' cellspacing='0' cellpadding='0'><tr><td width='50%'><input class='np' type='checkbox' name='tids[]' value='{$id}'><a href='catalog_do.php?cid=".$id."&dopost=listArchives' oncontextmenu=\"CommonMenu(event,this,$id,'".urlencode($typeName)."')\"> {$nss}".$typeName."[ID:".$id."]</a>(文档:".$this->GetTotalArc($id).") <a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif'/></a>";
|
|
|
|
echo " </td><td align='right'>";
|
|
|
|
echo " <a href='{$GLOBALS['cfg_phpurl']}/list.php?tid={$id}' target='_blank' class='btn btn-success btn-sm' title='预览'><i class='fa fa-globe' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?cid={$id}&dopost=listArchives' class='btn btn-success btn-sm' title='内容'><i class='fa fa-list' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_add.php?id={$id}' class='btn btn-success btn-sm' title='增加子类'><i class='fa fa-plus-circle' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' class='btn btn-success btn-sm' title='移动'><i class='fa fa-share-square' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' class='btn btn-success btn-sm' title='删除'><i class='fa fa-trash' aria-hidden='true'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:35px;height:20px'></td></tr></table></td></tr>\r\n";
|
|
|
|
echo "<tr>";
|
|
|
|
echo "<td style='background-color:#FBFCE2;' width='2%' class='bline'><img id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' style='margin:0 10px;cursor:pointer'></td>";
|
|
|
|
echo "<td style='background-color:#FBFCE2;' class='bline'><table width='98%' border='0' cellspacing='0' cellpadding='0'><tr><td width='50%'><input class='np' type='checkbox' name='tids[]' value='{$id}'><a href='catalog_do.php?cid=".$id."&dopost=listArchives' oncontextmenu=\"CommonMenu(event,this,$id,'".urlencode($typeName)."')\"> {$nss}".$typeName."[ID:".$id."]</a>(文档:".$this->GetTotalArc($id).")<a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif' style='vertical-align:text-top'></a>";
|
|
|
|
echo "</td><td align='right'>";
|
|
|
|
echo "<a href='{$GLOBALS['cfg_phpurl']}/list.php?tid={$id}' target='_blank' class='btn btn-success btn-sm' title='预览'><i class='fa fa-globe'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?cid={$id}&dopost=listArchives' class='btn btn-success btn-sm' title='内容'><i class='fa fa-list'></i></a>";
|
|
|
|
echo "<a href='catalog_add.php?id={$id}' class='btn btn-success btn-sm' title='增加子类'><i class='fa fa-plus-circle'></i></a>";
|
|
|
|
echo "<a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' class='btn btn-success btn-sm' title='移动'><i class='fa fa-share-square'></i></a>";
|
|
|
|
echo "<a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' class='btn btn-success btn-sm' title='删除'><i class='fa fa-trash'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:30px;height:26px'></td></tr></table></td></tr>";
|
|
|
|
}
|
|
|
|
//带封面的频道
|
|
|
|
else if ($ispart == 1) {
|
|
|
|
echo " <tr >\r\n";
|
|
|
|
echo " <td style='background-color:#FBFCE2;' width='2%' class='bline'><img style='cursor:pointer' id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' width='11' height='11'></td>\r\n";
|
|
|
|
echo " <td style='background-color:#FBFCE2;' class='bline'><table width='98%' border='0' cellspacing='0' cellpadding='0'><tr><td width='50%'><input class='np' type='checkbox' name='tids[]' value='{$id}'><a href='catalog_do.php?cid=".$id."&dopost=listArchives' oncontextmenu=\"CommonMenuPart(event,this,$id,'".urlencode($typeName)."')\"> {$nss}".$typeName."[ID:".$id."]</a> <a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"> <img src='images/write2.gif'/> </a>";
|
|
|
|
echo " </td><td align='right'>";
|
|
|
|
echo " <a href='{$GLOBALS['cfg_phpurl']}/list.php?tid={$id}' target='_blank' class='btn btn-success btn-sm' title='预览'><i class='fa fa-globe' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?cid={$id}&dopost=listArchives' class='btn btn-success btn-sm' title='内容'><i class='fa fa-list' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_add.php?id={$id}' class='btn btn-success btn-sm' title='增加子类'><i class='fa fa-plus-circle' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' class='btn btn-success btn-sm' title='移动'><i class='fa fa-share-square' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' class='btn btn-success btn-sm' title='删除'><i class='fa fa-trash' aria-hidden='true'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:35px;height:20px'></td></tr></table></td></tr>\r\n";
|
|
|
|
echo "<tr>";
|
|
|
|
echo "<td style='background-color:#FBFCE2;' width='2%' class='bline'><img id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' style='margin:0 10px;cursor:pointer'></td>";
|
|
|
|
echo "<td style='background-color:#FBFCE2;' class='bline'><table width='98%' border='0' cellspacing='0' cellpadding='0'><tr><td width='50%'><input class='np' type='checkbox' name='tids[]' value='{$id}'><a href='catalog_do.php?cid=".$id."&dopost=listArchives' oncontextmenu=\"CommonMenuPart(event,this,$id,'".urlencode($typeName)."')\"> {$nss}".$typeName."[ID:".$id."]</a> <a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif' style='vertical-align:text-top'></a>";
|
|
|
|
echo "</td><td align='right'>";
|
|
|
|
echo "<a href='{$GLOBALS['cfg_phpurl']}/list.php?tid={$id}' target='_blank' class='btn btn-success btn-sm' title='预览'><i class='fa fa-globe'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?cid={$id}&dopost=listArchives' class='btn btn-success btn-sm' title='内容'><i class='fa fa-list'></i></a>";
|
|
|
|
echo "<a href='catalog_add.php?id={$id}' class='btn btn-success btn-sm' title='增加子类'><i class='fa fa-plus-circle'></i></a>";
|
|
|
|
echo "<a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' class='btn btn-success btn-sm' title='移动'><i class='fa fa-share-square'></i></a>";
|
|
|
|
echo "<a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' class='btn btn-success btn-sm' title='删除'><i class='fa fa-trash'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:35px;height:26px'></td></tr></table></td></tr>";
|
|
|
|
}
|
|
|
|
//独立页面
|
|
|
|
else if ($ispart == 2) {
|
|
|
|
echo " <tr height='26' bgcolor='#FBFCE2'>\r\n";
|
|
|
|
echo " <td width='2%' class='bline2'><img style='cursor:pointer' id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' width='11' height='11'></td>\r\n";
|
|
|
|
echo " <td class='bline2'><table width='98%' border='0' cellspacing='0' cellpadding='0'><tr><td width='50%'><input class='np' type='checkbox' name='tids[]' value='{$id}'><a href='catalog_edit.php?id=".$id."' oncontextmenu=\"SingleMenu(event,this,$id,'".urlencode($typeName)."')\"> {$nss}".$typeName."[ID:".$id."]</a> <a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif'/></a>";
|
|
|
|
echo " </td><td align='right'>";
|
|
|
|
echo " <a href='{$typeDir}' target='_blank' class='btn btn-success btn-sm' title='预览'><i class='fa fa-globe' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' class='btn btn-success btn-sm' title='移动'><i class='fa fa-share-square' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' class='btn btn-success btn-sm' title='删除'><i class='fa fa-trash' aria-hidden='true'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:35px;height:20px'></td></tr></table></td></tr>\r\n";
|
|
|
|
echo "<tr height='26' bgcolor='#FBFCE2'>";
|
|
|
|
echo "<td width='2%' class='bline2'><img id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' style='margin:0 10px;cursor:pointer'></td>";
|
|
|
|
echo "<td class='bline2'><table width='98%' border='0' cellspacing='0' cellpadding='0'><tr><td width='50%'><input class='np' type='checkbox' name='tids[]' value='{$id}'><a href='catalog_edit.php?id=".$id."' oncontextmenu=\"SingleMenu(event,this,$id,'".urlencode($typeName)."')\"> {$nss}".$typeName."[ID:".$id."]</a> <a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif' style='vertical-align:text-top'></a>";
|
|
|
|
echo "</td><td align='right'>";
|
|
|
|
echo "<a href='{$typeDir}' target='_blank' class='btn btn-success btn-sm' title='预览'><i class='fa fa-globe'></i></a>";
|
|
|
|
echo "<a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' class='btn btn-success btn-sm' title='移动'><i class='fa fa-share-square'></i></a>";
|
|
|
|
echo "<a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' class='btn btn-success btn-sm' title='删除'><i class='fa fa-trash'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:35px;height:26px'></td></tr></table></td></tr>";
|
|
|
|
}
|
|
|
|
echo " <tr><td colspan='2' id='suns".$id."'>";
|
|
|
|
echo "<tr><td colspan='2' id='suns".$id."'>";
|
|
|
|
$lastid = GetCookie('lastCid');
|
|
|
|
if ($channel == $id || $lastid == $id || isset($GLOBALS['exallct']) || $cfg_admin_channel == 'array') {
|
|
|
|
echo " <table width='100%' border='0' cellspacing='0' cellpadding='0'>\r\n";
|
|
|
|
echo "<table width='100%' border='0' cellspacing='0' cellpadding='0'>";
|
|
|
|
$this->LogicListAllSunType($id, " ");
|
|
|
|
echo " </table>\r\n";
|
|
|
|
echo "</table>";
|
|
|
|
}
|
|
|
|
echo "</td></tr>\r\n</table>\r\n";
|
|
|
|
echo "</td></tr></table>";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 获得子类目的递归调用
|
|
|
|
*
|
|
|
@@ -209,59 +199,55 @@ class TypeUnit |
|
|
|
} else {
|
|
|
|
$nss = '';
|
|
|
|
}
|
|
|
|
|
|
|
|
//普通列表
|
|
|
|
if ($ispart == 0) {
|
|
|
|
echo "<tr height='26' oncontextmenu=\"CommonMenu(event,this,$id,'".urlencode($typeName)."')\">\r\n";
|
|
|
|
echo "<tr height='26' oncontextmenu=\"CommonMenu(event,this,$id,'".urlencode($typeName)."')\">";
|
|
|
|
echo "<td class='nbline'>";
|
|
|
|
echo "<table width='98%' border='0' cellspacing='0' cellpadding='0'>";
|
|
|
|
echo "<tr onMouseMove=\"javascript:this.bgColor='#FAFCE0';\" onMouseOut=\"javascript:this.bgColor='#FFFFFF';\"><td width='50%'>";
|
|
|
|
echo "<input class='np' type='checkbox' name='tids[]' value='{$id}'>$step <img style='cursor:pointer' id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' width='11' height='11'> <a href='catalog_do.php?cid=".$id."&dopost=listArchives'>{$nss}".$typeName."[ID:".$id."]</a>(文档:".$this->GetTotalArc($id).") <a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif'/></a>";
|
|
|
|
echo "<img id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' style='margin:0 10px;cursor:pointer'><input class='np' type='checkbox' name='tids[]' value='{$id}'>$step<a href='catalog_do.php?cid=".$id."&dopost=listArchives'>{$nss}".$typeName."[ID:".$id."]</a>(文档:".$this->GetTotalArc($id).")<a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif' style='vertical-align:text-top'></a>";
|
|
|
|
echo "</td><td align='right'>";
|
|
|
|
echo " <a href='{$GLOBALS['cfg_phpurl']}/list.php?tid={$id}' target='_blank' title='预览' class='btn btn-success btn-sm'><i class='fa fa-globe' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?cid={$id}&dopost=listArchives' class='btn btn-success btn-sm' title='内容'><i class='fa fa-list' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_add.php?id={$id}' class='btn btn-success btn-sm' title='增加子类'><i class='fa fa-plus-circle' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' title='移动' class='btn btn-success btn-sm'><i class='fa fa-share-square' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' title='删除' class='btn btn-success btn-sm'><i class='fa fa-trash' aria-hidden='true'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:35px;height:20px'></td></tr></table></td></tr>\r\n";
|
|
|
|
echo "<a href='{$GLOBALS['cfg_phpurl']}/list.php?tid={$id}' target='_blank' title='预览' class='btn btn-success btn-sm'><i class='fa fa-globe'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?cid={$id}&dopost=listArchives' class='btn btn-success btn-sm' title='内容'><i class='fa fa-list'></i></a>";
|
|
|
|
echo "<a href='catalog_add.php?id={$id}' class='btn btn-success btn-sm' title='增加子类'><i class='fa fa-plus-circle'></i></a>";
|
|
|
|
echo "<a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' title='移动' class='btn btn-success btn-sm'><i class='fa fa-share-square'></i></a>";
|
|
|
|
echo "<a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' title='删除' class='btn btn-success btn-sm'><i class='fa fa-trash'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:30px;height:26px'></td></tr></table></td></tr>";
|
|
|
|
}
|
|
|
|
|
|
|
|
//封面频道
|
|
|
|
else if ($ispart == 1) {
|
|
|
|
echo " <tr height='26' oncontextmenu=\"CommonMenu(event,this,$id,'".urlencode($typeName)."')\">\r\n";
|
|
|
|
echo "<tr height='26' oncontextmenu=\"CommonMenu(event,this,$id,'".urlencode($typeName)."')\">";
|
|
|
|
echo "<td class='nbline'><table width='98%' border='0' cellspacing='0' cellpadding='0'><tr onMouseMove=\"javascript:this.bgColor='#FAFCE0';\" onMouseOut=\"javascript:this.bgColor='#FFFFFF';\"><td width='50%'>";
|
|
|
|
echo "<input class='np' type='checkbox' name='tids[]' value='{$id}'>$step <img style='cursor:pointer' id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' width='11' height='11'> <a href='catalog_do.php?cid=".$id."&dopost=listArchives'>{$nss}".$typeName."[ID:".$id."]</a> <a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif'/></a>";
|
|
|
|
echo "<img id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' style='margin:0 10px;cursor:pointer'><input class='np' type='checkbox' name='tids[]' value='{$id}'>$step <a href='catalog_do.php?cid=".$id."&dopost=listArchives'>{$nss}".$typeName."[ID:".$id."]</a><a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif' style='vertical-align:text-top'></a>";
|
|
|
|
echo "</td><td align='right'>";
|
|
|
|
echo "<a href='{$GLOBALS['cfg_phpurl']}/list.php?tid={$id}' target='_blank' title='预览' class='btn btn-success btn-sm'><i class='fa fa-globe' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?cid={$id}&dopost=listArchives' class='btn btn-success btn-sm' title='内容'><i class='fa fa-list' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_add.php?id={$id}' class='btn btn-success btn-sm' title='增加子类'><i class='fa fa-plus-circle' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' title='移动' class='btn btn-success btn-sm'><i class='fa fa-share-square' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' title='删除' class='btn btn-success btn-sm'><i class='fa fa-trash' aria-hidden='true'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:35px;height:20px'></td></tr></table></td></tr>\r\n";
|
|
|
|
echo "<a href='{$GLOBALS['cfg_phpurl']}/list.php?tid={$id}' target='_blank' title='预览' class='btn btn-success btn-sm'><i class='fa fa-globe'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?cid={$id}&dopost=listArchives' class='btn btn-success btn-sm' title='内容'><i class='fa fa-list'></i></a>";
|
|
|
|
echo "<a href='catalog_add.php?id={$id}' class='btn btn-success btn-sm' title='增加子类'><i class='fa fa-plus-circle'></i></a>";
|
|
|
|
echo "<a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' title='移动' class='btn btn-success btn-sm'><i class='fa fa-share-square'></i></a>";
|
|
|
|
echo "<a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' title='删除' class='btn btn-success btn-sm'><i class='fa fa-trash'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:30px;height:26px'></td></tr></table></td></tr>";
|
|
|
|
}
|
|
|
|
|
|
|
|
//独立页面
|
|
|
|
else if ($ispart == 2) {
|
|
|
|
echo "<tr height='26' oncontextmenu=\"SingleMenu(event,this,$id,'".urlencode($typeName)."')\">\r\n";
|
|
|
|
echo "<tr height='26' oncontextmenu=\"SingleMenu(event,this,$id,'".urlencode($typeName)."')\">";
|
|
|
|
echo "<td class='bline2'><table width='98%' border='0' cellspacing='0' cellpadding='0'>";
|
|
|
|
echo "<tr onMouseMove=\"javascript:this.bgColor='#FAFCE0';\" onMouseOut=\"javascript:this.bgColor='#FFFFFF';\"><td width='50%'>";
|
|
|
|
echo "<input class='np' type='checkbox' name='tids[]' value='{$id}'>$step <img style='cursor:pointer' id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' width='11' height='11'> <a href='catalog_do.php?cid=".$id."&dopost=listArchives'>{$nss}".$typeName."[ID:".$id."]</a> <a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif'/></a>";
|
|
|
|
echo "<img id='img".$id."' onClick=\"LoadSuns('suns".$id."',$id);\" src='images/dedeexplode.gif' style='margin:0 10px;cursor:pointer'><input class='np' type='checkbox' name='tids[]' value='{$id}'>$step <a href='catalog_do.php?cid=".$id."&dopost=listArchives'>{$nss}".$typeName."[ID:".$id."]</a><a onclick=\"AlertMsg('快捷编辑窗口','$id');\" href=\"javascript:;\"><img src='images/write2.gif' style='vertical-align:text-top'></a>";
|
|
|
|
echo "</td><td align='right'>";
|
|
|
|
echo " <a href='{$typeDir}' target='_blank' title='预览' class='btn btn-success btn-sm'><i class='fa fa-globe' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' title='移动' class='btn btn-success btn-sm'><i class='fa fa-share-square' aria-hidden='true'></i></a>";
|
|
|
|
echo " <a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' title='删除' class='btn btn-success btn-sm'><i class='fa fa-trash' aria-hidden='true'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:35px;height:20px'></td></tr></table></td></tr>\r\n";
|
|
|
|
echo "<a href='{$typeDir}' target='_blank' title='预览' class='btn btn-success btn-sm'><i class='fa fa-globe'></i></a>";
|
|
|
|
echo "<a href='catalog_edit.php?id={$id}' class='btn btn-success btn-sm' title='修改'><i class='fa fa-pencil-square-o'></i></a>";
|
|
|
|
echo "<a href='catalog_do.php?dopost=moveCatalog&typeid={$id}' title='移动' class='btn btn-success btn-sm'><i class='fa fa-share-square'></i></a>";
|
|
|
|
echo "<a href='catalog_del.php?id={$id}&typeoldname=".urlencode($typeName)."' title='删除' class='btn btn-success btn-sm'><i class='fa fa-trash'></i></a>";
|
|
|
|
echo " <input type='text' name='sortrank{$id}' value='{$rank}' style='width:30px;height:26px'></td></tr></table></td></tr>";
|
|
|
|
}
|
|
|
|
echo " <tr><td id='suns".$id."' style='display:none'><table width='100%' border='0' cellspacing='0' cellpadding='0'>";
|
|
|
|
echo "<tr><td id='suns".$id."' style='display:none'><table width='100%' border='0' cellspacing='0' cellpadding='0'>";
|
|
|
|
$this->LogicListAllSunType($id, $step." ");
|
|
|
|
echo "</table></td></tr>\r\n";
|
|
|
|
echo "</table></td></tr>";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 返回与某个目相关的下级目录的类目ID列表(删除类目或文章时调用)
|
|
|
|
*
|
|
|
@@ -283,17 +269,12 @@ class TypeUnit |
|
|
|
}
|
|
|
|
$this->dsql->SetQuery("SELECT id FROM `#@__arctype` WHERE reid=$id $csql");
|
|
|
|
$this->dsql->Execute("gs".$fid);
|
|
|
|
|
|
|
|
//if($this->dsql->GetTotalRow("gs".$fid)!=0)
|
|
|
|
//{
|
|
|
|
while ($row = $this->dsql->GetObject("gs".$fid)) {
|
|
|
|
$nid = $row->id;
|
|
|
|
$this->GetSunTypes($nid, $channel);
|
|
|
|
}
|
|
|
|
//}
|
|
|
|
return $this->idArray;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 删除类目
|
|
|
|
*
|
|
|
@@ -323,7 +304,6 @@ class TypeUnit |
|
|
|
$addtable = $typeinfos['addtable'];
|
|
|
|
$ispart = $typeinfos['ispart'];
|
|
|
|
$defaultname = $typeinfos['defaultname'];
|
|
|
|
|
|
|
|
//删除数据库里的相关记录
|
|
|
|
foreach ($this->idArray as $id) {
|
|
|
|
$myrow = $this->dsql->GetOne("SELECT * FROM `#@__arctype` WHERE id='$id'");
|
|
|
@@ -337,7 +317,6 @@ class TypeUnit |
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
//删除目录和目录里的所有文件 ### 禁止了此功能
|
|
|
|
//删除单独页面
|
|
|
|
if ($myrow['ispart'] == 2 && $myrow['typedir'] == '') {
|
|
|
@@ -345,7 +324,6 @@ class TypeUnit |
|
|
|
@unlink($this->baseDir.'/'.$myrow['defaultname']);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
//删除数据库信息
|
|
|
|
$this->dsql->ExecuteNoneQuery("DELETE FROM `#@__arctype` WHERE id='$id'");
|
|
|
|
$this->dsql->ExecuteNoneQuery("DELETE FROM `#@__arctiny` WHERE typeid='$id'");
|
|
|
@@ -356,7 +334,6 @@ class TypeUnit |
|
|
|
$this->dsql->ExecuteNoneQuery("DELETE FROM $addtable WHERE typeid='$id'");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
//删除目录和目录里的所有文件 ### 禁止了此功能
|
|
|
|
//删除单独页面
|
|
|
|
if ($ispart == 2 && $indir == "") {
|
|
|
@@ -368,7 +345,6 @@ class TypeUnit |
|
|
|
$this->idCounter = 0;
|
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 删除指定目录的所有文件
|
|
|
|
*
|
|
|
|