2011-09-23 07:34:40 +00:00
|
|
|
|
<?php
|
|
|
|
|
$this->headTitle($this->config->title->site);
|
|
|
|
|
$this->headTitle('后台管理');
|
|
|
|
|
$this->headTitle()->setSeparator(' - ');
|
2012-04-12 04:04:23 +00:00
|
|
|
|
$this->breadcrumb('<a href="/">首页</a>');
|
2012-03-27 07:02:36 +00:00
|
|
|
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
|
|
|
|
$this->breadcrumb('<a href="/admin/news">新闻中心</a>');
|
|
|
|
|
$this->breadcrumb('栏目管理');
|
2013-05-21 09:37:33 +00:00
|
|
|
|
$this->theme->AppendPlus($this,"colorbox");
|
2011-09-23 07:34:40 +00:00
|
|
|
|
?>
|
2012-03-27 07:02:36 +00:00
|
|
|
|
<style>
|
|
|
|
|
.listingDetails{position:absolute;width:650px;}
|
|
|
|
|
.pad{position:absolute;background:#FFF;border:2px solid #444;border-radius:5px;padding:5px;display:none;}
|
2013-05-21 09:37:33 +00:00
|
|
|
|
table thead tr th {background:#EBF2F6;color:#444;}
|
|
|
|
|
.high{background:#444;color:#FFF;}
|
2012-03-27 07:02:36 +00:00
|
|
|
|
</style>
|
2013-05-21 09:37:33 +00:00
|
|
|
|
<div class="row-fluid">
|
|
|
|
|
<div class="span3">
|
|
|
|
|
<?= $this->partial('news/left.phtml'); ?>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="span9">
|
|
|
|
|
<?php if ($this->msg or $this->messages) :?>
|
|
|
|
|
<div id="message">
|
|
|
|
|
<?php if ($this->msg) : ?>
|
|
|
|
|
<p><?php echo $this->msg; ?></p>
|
|
|
|
|
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?>
|
|
|
|
|
<p><?php echo $msg; ?></p>
|
|
|
|
|
<?php endforeach;endif; ?>
|
|
|
|
|
</div>
|
|
|
|
|
<?php endif; ?>
|
|
|
|
|
<div id="tabs-controller">
|
|
|
|
|
<ul class="unstyled">
|
|
|
|
|
<li class="box-shadow active"><a class="btn btn-primary" href="/admin/news/catlog/add/1">添加新栏目</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
<table id="report" class="table table-bordered table-hover">
|
|
|
|
|
<thead>
|
|
|
|
|
<tr>
|
|
|
|
|
<th width="50%">栏目名称</th>
|
|
|
|
|
<th width="20%">栏目类型</th>
|
|
|
|
|
<th width="30%" style="vertical-align:top;">栏目管理</th>
|
|
|
|
|
</tr>
|
|
|
|
|
</thead>
|
|
|
|
|
<tbody>
|
|
|
|
|
<?php
|
|
|
|
|
if(is_array($this->catlogs))
|
|
|
|
|
{
|
|
|
|
|
$top = 0;
|
|
|
|
|
$deep = 0;
|
|
|
|
|
foreach($this->catlogs as $k=>$v)
|
|
|
|
|
{
|
|
|
|
|
if($v[$this->deepField]>0)
|
|
|
|
|
{
|
|
|
|
|
$style = "text-indent:". $v[$this->deepField]*12 ."px;";
|
|
|
|
|
}else{
|
|
|
|
|
$style = "";
|
|
|
|
|
}
|
|
|
|
|
echo '
|
|
|
|
|
<tr>
|
|
|
|
|
<td>
|
|
|
|
|
<div id="paddiv'.$v['id'].'" style="'.$style.'">
|
|
|
|
|
<a id="titlebtn'.$v['id'].'" class="title"><b>'.$v['title'].'</b></a>
|
|
|
|
|
</td>
|
|
|
|
|
<td>
|
|
|
|
|
<b>'.$v['ptype'].'</b>
|
|
|
|
|
</td>
|
|
|
|
|
<td>
|
|
|
|
|
<a href="'.$v['url'].'" target="_blank">浏览</a>
|
|
|
|
|
<a href="/admin/news/move/up/'.$v['id'].'">上移</a>
|
|
|
|
|
<a href="/admin/news/move/down/'.$v['id'].'">下移</a>
|
|
|
|
|
<a href="/admin/news/newslist/type/'.$v['id'].'">文档</a>
|
|
|
|
|
<a href="/admin/news/catlog/edit/'.$v['id'].'"><b>编辑</b></a>
|
|
|
|
|
<a href="/admin/news/catlog/delete/'.$v['id'].'" onclick="return confirm(\'是否确定删除该栏目\')">删除</a></td>
|
|
|
|
|
</tr>';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}else{
|
|
|
|
|
echo '<tr><td>暂无数据</td><td></td></tr>';
|
|
|
|
|
}
|
|
|
|
|
?>
|
|
|
|
|
</tbody>
|
|
|
|
|
</table>
|
|
|
|
|
</div>
|
|
|
|
|
<div style="width:500px;display:none;" id="categoryForm">
|
|
|
|
|
<form id="category" style="width:500px;">
|
|
|
|
|
<p>
|
|
|
|
|
<label class="required" for="ctitle">栏目标题:</label><br/>
|
|
|
|
|
<input type="text" id="ctitle" class="half" value="" name="ctitle"/>
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
|
|
<p>
|
|
|
|
|
<label class="required" for="ctitle">栏目URL:</label><br/>
|
|
|
|
|
<input type="text" id="url" class="half" value="" name="url"/>(仅小写英文字母与数字)
|
|
|
|
|
<small>如填写: technology 则前台访问地址为: http://westdc.westgis.ac.cn/news/technology </small>
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
|
|
<p>
|
|
|
|
|
<label class="required" for="keyword">关键字:</label><br/>
|
|
|
|
|
<input type="text" id="keyword" class="half" value="" name="keyword"/>
|
|
|
|
|
<small>e.g. 高程,气象,地理</small>
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
|
|
<p>
|
|
|
|
|
<label class="required" for="description">描述:</label><br/>
|
|
|
|
|
<textarea id="description" class="small half" name="description"></textarea>
|
|
|
|
|
<small>80个汉字以内,不能使用折行</small>
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
|
|
<p>
|
|
|
|
|
<label class="required" for="displayorder">排序:</label><br/>
|
|
|
|
|
<input type="text" id="roders" class="half" value="" name="displayorder"/>
|
|
|
|
|
<small>e.g. 数字越大排序越靠前</small>
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
|
|
<input type="hidden" name="edit" value="" />
|
|
|
|
|
|
|
|
|
|
<p class="box"><input type="submit" class="btn btn-green big" value="提交"/> or <input type="reset" class="btn" value="重置"/></p>
|
|
|
|
|
|
|
|
|
|
<p class="box">
|
|
|
|
|
<input type="hidden" name="id" id="categoryID" value="" />
|
|
|
|
|
<input type="button" onclick="" id="submit" class="btn btn-green big" value="提交"/> or <input type="reset" class="btn" id="resetForm" value="重置"/>
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
|
|
<p id="formStatus" style="display:block;"> </p>
|
|
|
|
|
</form>
|
|
|
|
|
</div>
|
2012-03-27 07:02:36 +00:00
|
|
|
|
</div>
|
2011-09-23 07:34:40 +00:00
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
$(document).ready(function(){
|
2012-03-27 07:02:36 +00:00
|
|
|
|
$('.title').bind('click', function() {
|
2012-04-09 07:50:57 +00:00
|
|
|
|
$.colorbox({'innerWidth':'50%','html':$(this).next('.listingDetails').children('.pad').html()});
|
2012-03-27 07:02:36 +00:00
|
|
|
|
});
|
2011-09-23 07:34:40 +00:00
|
|
|
|
});
|
|
|
|
|
function showpad(id){
|
|
|
|
|
$('#titlebtn'+id).click();
|
|
|
|
|
}
|
|
|
|
|
</script>
|