修改了后台新闻中心的UI,完善了部分功能
This commit is contained in:
parent
4cbf169e01
commit
57482c9844
|
@ -7,7 +7,6 @@ class Admin_NewsController extends Zend_Controller_Action
|
||||||
$this->view->config = Zend_Registry::get('config');
|
$this->view->config = Zend_Registry::get('config');
|
||||||
$this->messenger=$this->_helper->getHelper('FlashMessenger');
|
$this->messenger=$this->_helper->getHelper('FlashMessenger');
|
||||||
$this->view->messages = $this->messenger->getMessages();
|
$this->view->messages = $this->messenger->getMessages();
|
||||||
$this->_helper->layout->setLayout('administry');//新UI
|
|
||||||
}
|
}
|
||||||
function postDispatch()
|
function postDispatch()
|
||||||
{
|
{
|
||||||
|
@ -118,7 +117,9 @@ class Admin_NewsController extends Zend_Controller_Action
|
||||||
$id = $this->_request->getParam('id');
|
$id = $this->_request->getParam('id');
|
||||||
if($id>0)
|
if($id>0)
|
||||||
{
|
{
|
||||||
$sql = "select id,title,pubtime,typeid from news_archives where id=$id";
|
$sql = "SELECT arc.id,arc.title,arc.pubtime,arc.typeid,cat.url,cat.id as typeid from news_archives arc
|
||||||
|
LEFT JOIN news_catlog cat ON arc.typeid=cat.id
|
||||||
|
WHERE arc.id=$id";
|
||||||
$rs = $this->db->query($sql);
|
$rs = $this->db->query($sql);
|
||||||
$rows = $rs->fetch();
|
$rows = $rs->fetch();
|
||||||
|
|
||||||
|
@ -273,7 +274,6 @@ class Admin_NewsController extends Zend_Controller_Action
|
||||||
$types = $re->fetchAll();
|
$types = $re->fetchAll();
|
||||||
|
|
||||||
$this->view->types=$types;
|
$this->view->types=$types;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function archiveseditAction()
|
function archiveseditAction()
|
||||||
|
@ -331,15 +331,7 @@ class Admin_NewsController extends Zend_Controller_Action
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if(!empty($pubtimer))
|
$pubtime = strtotime($pubtime);
|
||||||
{
|
|
||||||
$pubtime = strtotime($pubtime);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$pubtime = time();
|
|
||||||
}
|
|
||||||
|
|
||||||
$date=array(
|
$date=array(
|
||||||
'title' => $title,
|
'title' => $title,
|
||||||
'writer' => $writer,
|
'writer' => $writer,
|
||||||
|
@ -399,22 +391,9 @@ class Admin_NewsController extends Zend_Controller_Action
|
||||||
}
|
}
|
||||||
}// 文章编辑
|
}// 文章编辑
|
||||||
|
|
||||||
|
function deleteAction(){
|
||||||
|
|
||||||
|
}//文章删除
|
||||||
/*
|
|
||||||
|
|
||||||
<div class="box box-info">Info box sample</div>
|
|
||||||
<div class="box box-warning">Warning box sample</div>
|
|
||||||
<div class="box box-error">Error box sample</div>
|
|
||||||
<div class="box box-error-msg">
|
|
||||||
<ol>
|
|
||||||
<li>Credit card number entered is invalid</li>
|
|
||||||
<li>Credit card verification number must be a valid number</li>
|
|
||||||
</ol>
|
|
||||||
</div>
|
|
||||||
<div class="box box-success">Success box sample</div>
|
|
||||||
|
|
||||||
*/
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -2,73 +2,53 @@
|
||||||
$this->headTitle($this->config->title->site);
|
$this->headTitle($this->config->title->site);
|
||||||
$this->headTitle('后台管理');
|
$this->headTitle('后台管理');
|
||||||
$this->headTitle()->setSeparator(' - ');
|
$this->headTitle()->setSeparator(' - ');
|
||||||
$this->headScript()->appendFile('/static/js/jquery.dataTables.min.js');
|
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
||||||
|
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||||
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||||
|
$this->breadcrumb('<a href="/admin/news">新闻中心</a>');
|
||||||
|
$this->breadcrumb('栏目管理');
|
||||||
?>
|
?>
|
||||||
|
<style>
|
||||||
|
.listingDetails{position:absolute;width:650px;}
|
||||||
|
.pad{position:absolute;background:#FFF;border:2px solid #444;border-radius:5px;padding:5px;display:none;}
|
||||||
|
</style>
|
||||||
|
<div id="leftPanel">
|
||||||
|
<?= $this->partial('news/left.phtml'); ?>
|
||||||
|
</div>
|
||||||
|
<div id="rightPanel">
|
||||||
|
<?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; ?>
|
||||||
|
|
||||||
<!-- Page title -->
|
<table id="report" class="stylized full" style="width:650px;">
|
||||||
<div id="pagetitle">
|
<thead>
|
||||||
<div class="wrapper">
|
<tr>
|
||||||
<h1>新闻中心</h1>
|
<th width="80%">栏目名称</th>
|
||||||
<!-- Quick search box -->
|
<th width="20%" style="vertical-align:top;">栏目管理</th>
|
||||||
<form action="" method="get"><input class="" type="text" id="q" name="q" /></form>
|
</tr>
|
||||||
</div>
|
</thead>
|
||||||
</div>
|
<tbody>
|
||||||
<!-- End of Page title -->
|
<?php
|
||||||
|
if(is_array($this->catlogs))
|
||||||
<!-- Page content -->
|
{
|
||||||
<div id="page">
|
foreach($this->catlogs as $k=>$v)
|
||||||
<!-- Wrapper -->
|
{
|
||||||
<div class="wrapper">
|
echo '
|
||||||
|
<tr>
|
||||||
<!-- Right column/section -->
|
<td>
|
||||||
<aside class="column width2 first">
|
<div id="paddiv'.$v['id'].'">
|
||||||
<?= $this->partial('news/left.phtml'); ?>
|
<a id="titlebtn'.$v['id'].'" class="title"><b>'.$v['title'].'</b></a>
|
||||||
</aside>
|
<div class="listingDetails">
|
||||||
<!-- End of Right column/section -->
|
<div class="pad">
|
||||||
|
<b>编辑栏目</b> <a href="javascript:;" class="closepad" style="float:right">关闭</a>
|
||||||
<!-- Left column/section -->
|
<form id="editform'.$v['id'].'" method="post" action="#">
|
||||||
<section class="column width6">
|
<fieldset>
|
||||||
|
|
||||||
<h3>栏目管理</h3>
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<?php if ($this->msg or $this->messages) :?>
|
|
||||||
<div class="box box-info">
|
|
||||||
<?php if ($this->msg) : ?>
|
|
||||||
<?php echo $this->msg; ?>
|
|
||||||
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?>
|
|
||||||
<?php echo $msg; ?>
|
|
||||||
<?php endforeach;endif; ?>
|
|
||||||
<script language="javascript">
|
|
||||||
setTimeout('$(".box-info").remove()',5000);
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
<?php endif; ?>
|
|
||||||
|
|
||||||
<table id="report" class="stylized full" style="">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th width="50%">栏目名称</th>
|
|
||||||
<th width="50%">栏目管理</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<?php
|
|
||||||
if(is_array($this->catlogs))
|
|
||||||
{
|
|
||||||
foreach($this->catlogs as $k=>$v)
|
|
||||||
{
|
|
||||||
echo '
|
|
||||||
<tr>
|
|
||||||
<td class="title">
|
|
||||||
<div id="paddiv'.$v['id'].'">
|
|
||||||
<a id="titlebtn'.$v['id'].'"><b>'.$v['title'].'</b></a>
|
|
||||||
<div class="listingDetails">
|
|
||||||
<div class="pad">
|
|
||||||
<b>编辑栏目</b>
|
|
||||||
<form id="editform'.$v['id'].'" method="post" action="#">
|
|
||||||
|
|
||||||
<fieldset>
|
|
||||||
<legend>栏目信息</legend>
|
<legend>栏目信息</legend>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
|
@ -125,29 +105,19 @@
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<hr/>
|
</div>
|
||||||
<a href="/admin/news/catlog/add/1" class="btn"><span class="icon icon-add"> </span>添加新栏目</a>
|
|
||||||
|
|
||||||
|
|
||||||
</section>
|
|
||||||
<!-- End of Left column/section -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<!-- End of Wrapper -->
|
|
||||||
</div>
|
|
||||||
<!-- End of Page content -->
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
$('#nav_news').addClass("current");
|
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
/* setup navigation, content boxes, etc... */
|
$('.title').bind('click', function() {
|
||||||
Administry.setup();
|
$('.pad').css('display','none');
|
||||||
/* expandable rows */
|
$(this).next('.listingDetails').children('.pad').show();
|
||||||
Administry.expandableRows();
|
});
|
||||||
|
$('.closepad').bind('click', function() {
|
||||||
|
$('.pad').css('display','none');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
function showpad(id){
|
function showpad(id){
|
||||||
$('#titlebtn'+id).click();
|
$('#titlebtn'+id).click();
|
||||||
|
|
|
@ -2,83 +2,59 @@
|
||||||
$this->headTitle($this->config->title->site);
|
$this->headTitle($this->config->title->site);
|
||||||
$this->headTitle('后台管理');
|
$this->headTitle('后台管理');
|
||||||
$this->headTitle()->setSeparator(' - ');
|
$this->headTitle()->setSeparator(' - ');
|
||||||
$this->headScript()->appendFile('/static/js/jquery.tagInput.min.js');
|
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
||||||
$this->headScript()->appendFile('/static/js/jquery.wysiwyg.min.js');
|
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||||
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||||
|
$this->breadcrumb('<a href="/admin/news">新闻中心</a>');
|
||||||
|
$this->breadcrumb('栏目添加');
|
||||||
?>
|
?>
|
||||||
|
<div id="leftPanel">
|
||||||
|
<?= $this->partial('news/left.phtml'); ?>
|
||||||
|
</div>
|
||||||
|
<div id="rightPanel">
|
||||||
|
<?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; ?>
|
||||||
|
<h3>添加栏目</h3>
|
||||||
|
<form id="sampleform" method="post" action="#">
|
||||||
|
|
||||||
<!-- Page title -->
|
<fieldset>
|
||||||
<div id="pagetitle">
|
<legend>栏目信息</legend>
|
||||||
<div class="wrapper">
|
|
||||||
<h1>新闻中心</h1>
|
|
||||||
<!-- Quick search box -->
|
|
||||||
<form action="" method="get"><input class="" type="text" id="q" name="q" /></form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!-- End of Page title -->
|
|
||||||
|
|
||||||
<!-- Page content -->
|
<p>
|
||||||
<div id="page">
|
<label class="required" for="ctitle">栏目标题:</label><br/>
|
||||||
<!-- Wrapper -->
|
<input type="text" id="ctitle" class="half" value="" name="ctitle"/>
|
||||||
<div class="wrapper">
|
</p>
|
||||||
|
|
||||||
<!-- Right column/section -->
|
<p>
|
||||||
<aside class="column width2 first">
|
<label class="required" for="ctitle">栏目URL:</label><br/>
|
||||||
<?= $this->partial('news/left.phtml'); ?>
|
<input type="text" id="url" class="half" value="" name="url"/>(仅小写英文字母与数字)
|
||||||
</aside>
|
<small>如填写: technology 则前台访问地址为: http://westdc.westgis.ac.cn/news/technology </small>
|
||||||
<!-- End of Right column/section -->
|
</p>
|
||||||
|
|
||||||
<!-- Left column/section -->
|
<p>
|
||||||
<section class="column width6">
|
<label class="required" for="keyword">关键字:</label><br/>
|
||||||
|
<input type="text" id="keyword" class="half" value="" name="keyword"/>
|
||||||
|
<small>e.g. 高程,气象,地理</small>
|
||||||
|
</p>
|
||||||
|
|
||||||
<h3>添加栏目</h3>
|
<p>
|
||||||
<form id="sampleform" method="post" action="#">
|
<label class="required" for="discript">描述:</label><br/>
|
||||||
|
<textarea id="discript" class="medium half" name="discript"></textarea>
|
||||||
|
<small>80个汉字以内,不能使用折行</small>
|
||||||
|
</p>
|
||||||
|
|
||||||
<fieldset>
|
<input type="hidden" name="submit" value="1" />
|
||||||
<legend>栏目信息</legend>
|
|
||||||
|
|
||||||
<p>
|
<p class="box"><input type="submit" class="btn btn-green big" value="提交"/> or <input type="reset" class="btn" value="重置"/></p>
|
||||||
<label class="required" for="ctitle">栏目标题:</label><br/>
|
|
||||||
<input type="text" id="ctitle" class="half" value="" name="ctitle"/>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
</fieldset>
|
||||||
<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>
|
</form>
|
||||||
<label class="required" for="keyword">关键字:</label><br/>
|
</div>
|
||||||
<input type="text" id="keyword" class="half" value="" name="keyword"/>
|
|
||||||
<small>e.g. 高程,气象,地理</small>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
|
||||||
<label class="required" for="discript">描述:</label><br/>
|
|
||||||
<textarea id="discript" class="medium half" name="discript"></textarea>
|
|
||||||
<small>80个汉字以内,不能使用折行</small>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<input type="hidden" name="submit" value="1" />
|
|
||||||
|
|
||||||
<p class="box"><input type="submit" class="btn btn-green big" value="提交"/> or <input type="reset" class="btn" value="重置"/></p>
|
|
||||||
|
|
||||||
</fieldset>
|
|
||||||
|
|
||||||
</form>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
|
|
||||||
</section>
|
|
||||||
<!-- End of Left column/section -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<!-- End of Wrapper -->
|
|
||||||
</div>
|
|
||||||
<!-- End of Page content -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
$('#nav_news').addClass("current");
|
|
||||||
</script>
|
|
|
@ -1,32 +1,7 @@
|
||||||
<div id="rightmenu">
|
<ul>
|
||||||
<header>
|
<li class="title">新闻中心</li>
|
||||||
<h3>新闻中心管理</h3>
|
<li><a href="/admin/news/catlog">栏目管理</a></li>
|
||||||
</header>
|
<li><a href="/admin/news/catlog/add/1">栏目添加</a></li>
|
||||||
<dl class="first">
|
<li><a href="/admin/news/newslist">新闻管理</a></li>
|
||||||
|
<li><a href="/admin/news/newsadd">新闻发布</a></li>
|
||||||
<dt><img width="16" height="16" alt="" SRC="/static/img/90.png"></dt>
|
</ul>
|
||||||
<dd><a href="/admin/news/catlog">栏目管理</a></dd>
|
|
||||||
<dd class="last">创建、编辑、删除栏目</dd>
|
|
||||||
|
|
||||||
<dt><img width="16" height="16" alt="" SRC="/static/img/27.png"></dt>
|
|
||||||
<dd><a href="/admin/news/newslist">新闻管理</a></dd>
|
|
||||||
<dd class="last">查看、编辑、搜索、删除新闻</dd>
|
|
||||||
|
|
||||||
<dt><img width="16" height="16" alt="" SRC="/static/img/21.png"></dt>
|
|
||||||
<dd><a href="/admin/news/newsadd">发布新闻</a></dd>
|
|
||||||
<dd class="last">为网站发布一篇新闻</dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
<div class="content-box">
|
|
||||||
<header>
|
|
||||||
<h3>Tips</h3>
|
|
||||||
</header>
|
|
||||||
<section>
|
|
||||||
<dl>
|
|
||||||
<dt>在栏目编辑中,再次点击“编辑”按钮可以关闭栏目编辑窗口</dt>
|
|
||||||
<dd><a href="/admin/news/catlog">去试试</a></dd>
|
|
||||||
<dt>新闻添加中可以直接上传图片</dt>
|
|
||||||
<dd><a href="/admin/news/newsadd">去试试</a></dd>
|
|
||||||
</dl>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
|
@ -2,10 +2,15 @@
|
||||||
$this->headTitle($this->config->title->site);
|
$this->headTitle($this->config->title->site);
|
||||||
$this->headTitle('后台管理');
|
$this->headTitle('后台管理');
|
||||||
$this->headTitle()->setSeparator(' - ');
|
$this->headTitle()->setSeparator(' - ');
|
||||||
|
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
||||||
|
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||||
$this->headScript()->appendFile('/static/js/jquery.tagInput.min.js');
|
$this->headScript()->appendFile('/static/js/jquery.tagInput.min.js');
|
||||||
$this->headScript()->appendFile('/static/js/kindeditor-min.js');
|
$this->headScript()->appendFile('/static/js/kindeditor-min.js');
|
||||||
$this->headScript()->appendFile('/static/js/kindlang/zh_CN.js');
|
$this->headScript()->appendFile('/static/js/kindlang/zh_CN.js');
|
||||||
$this->headLink()->appendStylesheet('/static/css/kindskin/default/default.css');
|
$this->headLink()->appendStylesheet('/static/css/kindskin/default/default.css');
|
||||||
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||||
|
$this->breadcrumb('<a href="/admin/news">新闻中心</a>');
|
||||||
|
$this->breadcrumb('新闻添加');
|
||||||
?>
|
?>
|
||||||
<?php
|
<?php
|
||||||
$auth = Zend_Auth::getInstance();
|
$auth = Zend_Auth::getInstance();
|
||||||
|
@ -16,6 +21,20 @@
|
||||||
$realname = $user->realname;
|
$realname = $user->realname;
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
<style>
|
||||||
|
.tagInput {}
|
||||||
|
.tagInputDiv {display:none;background-color:white;position:absolute;overflow:auto;border:1px solid lightgray;margin-top:-1px;}
|
||||||
|
.tagInputLine {color:black;font-weight:normal;padding:4px;}
|
||||||
|
.tagInputSel {background-color:gray;color:white;}
|
||||||
|
.tagInputLineTag {min-width:150px;display:inline-block;}
|
||||||
|
.tagInputLineFreq {min-width:50px;text-align:right;display:inline-block;float:right;}
|
||||||
|
.tagInputSuggestedTags {font-size: 11px;}
|
||||||
|
.tagInputSuggestedTags .label{display:block;background:0 none;color:#666;padding:0;margin-top:4px;}
|
||||||
|
.tagInputSuggestedTagList{}
|
||||||
|
.tagInputSuggestedTagList .tag{ padding:1px 4px;cursor:pointer;display:inline-block;margin:2px 1px;border:1px solid #bbb;}
|
||||||
|
.tagInputSuggestedTagList span.tag:hover{background-color:#bbb;color:#fff;}
|
||||||
|
.tagInputSuggestedTagList .tagUsed{border:1px solid #999;background-color:#999;color:#fff;}
|
||||||
|
</style>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
/* sample tags */
|
/* sample tags */
|
||||||
var tags=[
|
var tags=[
|
||||||
|
@ -24,10 +43,6 @@ var tags=[
|
||||||
];
|
];
|
||||||
|
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
|
|
||||||
/* setup navigation, content boxes, etc... */
|
|
||||||
Administry.setup();
|
|
||||||
|
|
||||||
KindEditor.ready(function(K) {
|
KindEditor.ready(function(K) {
|
||||||
editor=K.create('textarea[name="body"]', {
|
editor=K.create('textarea[name="body"]', {
|
||||||
cssPath : '/static/js/plugins/code/prettify.css',
|
cssPath : '/static/js/plugins/code/prettify.css',
|
||||||
|
@ -51,41 +66,12 @@ $(document).ready(function(){
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<!-- Page title -->
|
<div id="leftPanel">
|
||||||
<div id="pagetitle">
|
<?= $this->partial('news/left.phtml'); ?>
|
||||||
<div class="wrapper">
|
</div>
|
||||||
<h1>新闻中心</h1>
|
<div id="rightPanel">
|
||||||
<!-- Quick search box -->
|
|
||||||
<form action="" method="get"><input class="" type="text" id="q" name="q" /></form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!-- End of Page title -->
|
|
||||||
|
|
||||||
<!-- Page content -->
|
|
||||||
<div id="page">
|
|
||||||
<!-- Wrapper -->
|
|
||||||
<div class="wrapper">
|
|
||||||
|
|
||||||
<!-- Right column/section -->
|
|
||||||
<aside class="column width2 first">
|
|
||||||
<?= $this->partial('news/left.phtml'); ?>
|
|
||||||
<div class="content-box">
|
|
||||||
<header>
|
|
||||||
<h3>新闻标签</h3>
|
|
||||||
</header>
|
|
||||||
<section>
|
|
||||||
输入Tag标签,多个用半角逗号 “ , ”隔开,每个Tag标签长度小于6个汉字
|
|
||||||
<p><textarea id="keyword" class="small full" name="keyword"></textarea></p>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
</aside>
|
|
||||||
<!-- End of Right column/section -->
|
|
||||||
|
|
||||||
<!-- Left column/section -->
|
|
||||||
<section class="column width6">
|
<section class="column width6">
|
||||||
|
|
||||||
<h3>发布新闻</h3>
|
|
||||||
|
|
||||||
<form name="form" id="archivesadd" method="post" action="#">
|
<form name="form" id="archivesadd" method="post" action="#">
|
||||||
|
|
||||||
<fieldset>
|
<fieldset>
|
||||||
|
@ -161,15 +147,18 @@ $(document).ready(function(){
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
</form>
|
</form>
|
||||||
|
<div class="content-box">
|
||||||
|
<header>
|
||||||
|
<h3>新闻标签</h3>
|
||||||
|
</header>
|
||||||
|
<section>
|
||||||
|
输入Tag标签,多个用半角逗号 " , "隔开,每个Tag标签长度小于6个汉字
|
||||||
|
<p><textarea id="keyword" class="small full" name="keyword"></textarea></p>
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
</section>
|
</section>
|
||||||
<!-- End of Left column/section -->
|
<!-- End of Left column/section -->
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<!-- End of Wrapper -->
|
|
||||||
</div>
|
|
||||||
<!-- End of Page content -->
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
$(function(){
|
$(function(){
|
||||||
$('#nav_news').addClass("current");
|
$('#nav_news').addClass("current");
|
||||||
|
|
|
@ -2,101 +2,25 @@
|
||||||
$this->headTitle($this->config->title->site);
|
$this->headTitle($this->config->title->site);
|
||||||
$this->headTitle('后台管理');
|
$this->headTitle('后台管理');
|
||||||
$this->headTitle()->setSeparator(' - ');
|
$this->headTitle()->setSeparator(' - ');
|
||||||
$this->headScript()->appendFile('/static/js/jquery.tagInput.min.js');
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||||
$this->headScript()->appendFile('/static/js/kindeditor-min.js');
|
$this->breadcrumb('<a href="/admin/news">新闻中心</a>');
|
||||||
$this->headScript()->appendFile('/static/js/kindlang/zh_CN.js');
|
$this->breadcrumb('新闻发布');
|
||||||
$this->headLink()->appendStylesheet('/static/css/kindskin/default/default.css');
|
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
||||||
?>
|
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||||
<?php
|
|
||||||
$auth = Zend_Auth::getInstance();
|
|
||||||
if($auth->hasIdentity())
|
|
||||||
{
|
|
||||||
$user = $auth->getIdentity();
|
|
||||||
$uname=$user->username;
|
|
||||||
$realname = $user->realname;
|
|
||||||
}
|
|
||||||
?>
|
?>
|
||||||
|
<div id="leftPanel">
|
||||||
|
<?= $this->partial('news/left.phtml'); ?>
|
||||||
|
</div>
|
||||||
|
<div id="rightPanel">
|
||||||
|
<h3><?php echo $this->title;?></h3>
|
||||||
|
<ul>
|
||||||
|
<li><a href="/news/<?php echo $this->infos['url']; ?>/archive-<?php echo $this->infos['id']; ?>.html" target="_blank">查看文章</a></li>
|
||||||
|
<li><a href="/admin/news/newslist">返回文章列表</a></li>
|
||||||
|
<li><a href="/admin/news/newsedit/id/<?php echo $this->infos['id']; ?>">更改文章</a></li>
|
||||||
|
<li><a href="/admin/news/newsadd">发表新文章</a></li>
|
||||||
|
<li>页面将自动跳转至文章列表页</li>
|
||||||
|
</ul>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
/* sample tags */
|
setTimeout("self.location='/admin/news/newslist/typeid/<?php echo $this->infos['typeid'];?>'",5000);
|
||||||
var tags=[
|
|
||||||
{tag:"冻土",freq:30},{tag:"寒旱所",freq:25}, {tag:"大气",freq:10},{tag:"高原",freq:4},
|
|
||||||
{tag:"西部",freq:3},{tag:"地理",freq:8}, {tag:"环境",freq:3},{tag:"地质",freq:20}
|
|
||||||
];
|
|
||||||
|
|
||||||
$(document).ready(function(){
|
|
||||||
|
|
||||||
/* setup navigation, content boxes, etc... */
|
|
||||||
Administry.setup();
|
|
||||||
|
|
||||||
KindEditor.ready(function(K) {
|
|
||||||
editor=K.create('textarea[name="body"]', {
|
|
||||||
cssPath : '/static/js/plugins/code/prettify.css',
|
|
||||||
uploadJson : '/plugins/upload_json.php',
|
|
||||||
fileManagerJson : '/plugins/file_manager_json.php',
|
|
||||||
allowFileManager : true
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
/* tag input field */
|
|
||||||
$("#keyword").tagInput({
|
|
||||||
tags:tags,
|
|
||||||
//jsonUrl:"tags.json",
|
|
||||||
sortBy:"frequency",
|
|
||||||
suggestedTags:["冻土", "寒旱所", "大气", "高原", "西部", "环境"],
|
|
||||||
tagSeparator:",",
|
|
||||||
autoFilter:true,
|
|
||||||
autoStart:false,
|
|
||||||
//suggestedTagsPlaceHolder:$("#suggested"),
|
|
||||||
boldify:true
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
<!-- Page title -->
|
|
||||||
<div id="pagetitle">
|
|
||||||
<div class="wrapper">
|
|
||||||
<h1>新闻中心</h1>
|
|
||||||
<!-- Quick search box -->
|
|
||||||
<form action="" method="get"><input class="" type="text" id="q" name="q" /></form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!-- End of Page title -->
|
|
||||||
|
|
||||||
<!-- Page content -->
|
|
||||||
<div id="page">
|
|
||||||
<!-- Wrapper -->
|
|
||||||
<div class="wrapper">
|
|
||||||
|
|
||||||
<!-- Right column/section -->
|
|
||||||
<aside class="column width2 first">
|
|
||||||
<?= $this->partial('news/left.phtml'); ?>
|
|
||||||
</aside>
|
|
||||||
<!-- End of Right column/section -->
|
|
||||||
|
|
||||||
<!-- Left column/section -->
|
|
||||||
<section class="column width6">
|
|
||||||
|
|
||||||
<h3><?php echo $this->title;?></h3>
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li><a href="">查看文章</a></li>
|
|
||||||
<li><a href="">返回文章列表</a></li>
|
|
||||||
<li><a href="">更改文章</a></li>
|
|
||||||
<li><a href="">发表新文章</a></li>
|
|
||||||
<li>页面将自动跳转至文章列表页</li>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
</section>
|
|
||||||
<!-- End of Left column/section -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<!-- End of Wrapper -->
|
|
||||||
</div>
|
|
||||||
<!-- End of Page content -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
$(function(){
|
|
||||||
$('#nav_news').addClass("current");
|
|
||||||
});
|
|
||||||
setTimeout("self.location='/admin/news/list/typeid/<?php echo $this->view->typeid;?>'",500);
|
|
||||||
</script>
|
</script>
|
||||||
|
</li>
|
|
@ -2,10 +2,15 @@
|
||||||
$this->headTitle($this->config->title->site);
|
$this->headTitle($this->config->title->site);
|
||||||
$this->headTitle('后台管理');
|
$this->headTitle('后台管理');
|
||||||
$this->headTitle()->setSeparator(' - ');
|
$this->headTitle()->setSeparator(' - ');
|
||||||
|
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
||||||
|
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||||
$this->headScript()->appendFile('/static/js/jquery.tagInput.min.js');
|
$this->headScript()->appendFile('/static/js/jquery.tagInput.min.js');
|
||||||
$this->headScript()->appendFile('/static/js/kindeditor-min.js');
|
$this->headScript()->appendFile('/static/js/kindeditor-min.js');
|
||||||
$this->headScript()->appendFile('/static/js/kindlang/zh_CN.js');
|
$this->headScript()->appendFile('/static/js/kindlang/zh_CN.js');
|
||||||
$this->headLink()->appendStylesheet('/static/css/kindskin/default/default.css');
|
$this->headLink()->appendStylesheet('/static/css/kindskin/default/default.css');
|
||||||
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||||
|
$this->breadcrumb('<a href="/admin/news">新闻中心</a>');
|
||||||
|
$this->breadcrumb('新闻编辑');
|
||||||
?>
|
?>
|
||||||
<?php
|
<?php
|
||||||
$auth = Zend_Auth::getInstance();
|
$auth = Zend_Auth::getInstance();
|
||||||
|
@ -24,10 +29,6 @@ var tags=[
|
||||||
];
|
];
|
||||||
|
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
|
|
||||||
/* setup navigation, content boxes, etc... */
|
|
||||||
Administry.setup();
|
|
||||||
|
|
||||||
KindEditor.ready(function(K) {
|
KindEditor.ready(function(K) {
|
||||||
editor=K.create('textarea[name="body"]', {
|
editor=K.create('textarea[name="body"]', {
|
||||||
cssPath : '/static/js/plugins/code/prettify.css',
|
cssPath : '/static/js/plugins/code/prettify.css',
|
||||||
|
@ -51,132 +52,96 @@ $(document).ready(function(){
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<!-- Page title -->
|
<div id="leftPanel">
|
||||||
<div id="pagetitle">
|
<?= $this->partial('news/left.phtml'); ?>
|
||||||
<div class="wrapper">
|
</div>
|
||||||
<h1>新闻中心</h1>
|
<div id="rightPanel">
|
||||||
<!-- Quick search box -->
|
<section class="column width6">
|
||||||
<form action="" method="get"><input class="" type="text" id="q" name="q" /></form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!-- End of Page title -->
|
|
||||||
|
|
||||||
<!-- Page content -->
|
<h3>发布新闻</h3>
|
||||||
<div id="page">
|
|
||||||
<!-- Wrapper -->
|
|
||||||
<div class="wrapper">
|
|
||||||
|
|
||||||
<!-- Right column/section -->
|
<form name="form" id="archivesadd" method="post" action="#">
|
||||||
<aside class="column width2 first">
|
|
||||||
<?= $this->partial('news/left.phtml'); ?>
|
|
||||||
<div class="content-box">
|
|
||||||
<header>
|
|
||||||
<h3>新闻标签</h3>
|
|
||||||
</header>
|
|
||||||
<section>
|
|
||||||
输入Tag标签,多个用半角逗号 “ , ”隔开,每个Tag标签长度小于6个汉字
|
|
||||||
<p><textarea id="keyword" class="small full" name="keyword"><?php echo $this->ev['keyword']; ?></textarea></p>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
</aside>
|
|
||||||
<!-- End of Right column/section -->
|
|
||||||
|
|
||||||
<!-- Left column/section -->
|
<fieldset>
|
||||||
<section class="column width6">
|
<legend>新闻信息</legend>
|
||||||
|
<input type="hidden" id="image" class="half title" value="" name="image"/>
|
||||||
|
<p>
|
||||||
|
<label class="required" for="producttitle">标题</label><br/>
|
||||||
|
<input type="text" id="producttitle" class="half title" value="<?php echo $this->ev['title']; ?>" name="title"/>
|
||||||
|
</p>
|
||||||
|
|
||||||
<h3>发布新闻</h3>
|
<p>
|
||||||
|
<label class="required" for="writer">作者</label><br/>
|
||||||
|
<input type="text" id="writer" class="half title" value="<?php echo $this->ev['writer']; ?>" name="writer"/>
|
||||||
|
</p>
|
||||||
|
|
||||||
<form name="form" id="archivesadd" method="post" action="#">
|
<p>
|
||||||
|
<label for="source" class="required">来源</label><br/>
|
||||||
|
<input type="text" id="source" class="half title" value="<?php echo $this->ev['source']; ?>" name="source"/>
|
||||||
|
</p>
|
||||||
|
|
||||||
<fieldset>
|
<p>
|
||||||
<legend>新闻信息</legend>
|
<label for="description">内容简介(描述)</label><br/>
|
||||||
<input type="hidden" id="image" class="half title" value="" name="image"/>
|
<textarea id="description" class="small half" name="description"><?php echo $this->ev['description']; ?></textarea>
|
||||||
<p>
|
</p>
|
||||||
<label class="required" for="producttitle">标题</label><br/>
|
|
||||||
<input type="text" id="producttitle" class="half title" value="<?php echo $this->ev['title']; ?>" name="title"/>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
<label class="required" for="writer">作者</label><br/>
|
<label for="body">新闻内容</label><br/>
|
||||||
<input type="text" id="writer" class="half title" value="<?php echo $this->ev['writer']; ?>" name="writer"/>
|
<textarea id="body" class="large full" name="body"><?php echo $this->ev['body']; ?></textarea>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
|
||||||
<label for="source" class="required">来源</label><br/>
|
|
||||||
<input type="text" id="source" class="half title" value="<?php echo $this->ev['source']; ?>" name="source"/>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
|
||||||
<label for="description">内容简介(描述)</label><br/>
|
|
||||||
<textarea id="description" class="small half" name="description"><?php echo $this->ev['description']; ?></textarea>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
|
||||||
<label for="body">新闻内容</label><br/>
|
|
||||||
<textarea id="body" class="large full" name="body"><?php echo $this->ev['body']; ?></textarea>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="clearfix leading">
|
<div class="clearfix leading">
|
||||||
<div class="column width3 first">
|
<div class="column width3 first">
|
||||||
<p>
|
<p>
|
||||||
<label for="type" class="required">新闻栏目</label><br/>
|
<label for="type" class="required">新闻栏目</label><br/>
|
||||||
<select id="type" class="full" name="typeid">
|
<select id="type" class="full" name="typeid">
|
||||||
<option value="0">请选择栏目</option>
|
<option value="0">请选择栏目</option>
|
||||||
<?php
|
<?php
|
||||||
foreach($this->types as $v)
|
foreach($this->types as $v)
|
||||||
{
|
{
|
||||||
if($this->ev['typeid']==$v['id'])
|
if($this->ev['typeid']==$v['id'])
|
||||||
echo '<option value="'.$v['id'].'" selected="selected">'.$v['title'].'</option>';
|
echo '<option value="'.$v['id'].'" selected="selected">'.$v['title'].'</option>';
|
||||||
else
|
else
|
||||||
echo '<option value="'.$v['id'].'">'.$v['title'].'</option>';
|
echo '<option value="'.$v['id'].'">'.$v['title'].'</option>';
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
?>
|
||||||
</select>
|
</select>
|
||||||
<small>e.g. 研究成果</small>
|
<small>e.g. 研究成果</small>
|
||||||
</p>
|
</p>
|
||||||
<p><a href="/admin/news/catlog/add/1" target="_blank">+ 添加新栏目</a></p>
|
<p><a href="/admin/news/catlog/add/1" target="_blank">+ 添加新栏目</a></p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
<select id="pub" class="full" name="pub">
|
<select id="pub" class="full" name="pub">
|
||||||
<option value="1" <?php if($this->ev['pub']>=1) echo 'selected="selected"'; ?>>立即发布</option>
|
<option value="1" <?php if($this->ev['pub']>=1) echo 'selected="selected"'; ?>>立即发布</option>
|
||||||
<option value="0" <?php if($this->ev['pub']==0) echo 'selected="selected"'; ?>>存草稿</option>
|
<option value="0" <?php if($this->ev['pub']==0) echo 'selected="selected"'; ?>>存草稿</option>
|
||||||
<option value="-1" <?php if($this->ev['pub']<0) echo 'selected="selected"'; ?>>不发布</option>
|
<option value="-1" <?php if($this->ev['pub']<0) echo 'selected="selected"'; ?>>不发布</option>
|
||||||
</select>
|
</select>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="column width3">
|
<div class="column width3">
|
||||||
<p>
|
<p>
|
||||||
<input type="checkbox" id="pubtimeturn" name="pubtimer" value="1" /><label id="pubtimelable" for="productcat">定时发布?</label><br/>
|
<input type="checkbox" id="pubtimeturn" name="pubtimer" value="1" /><label id="pubtimelable" for="productcat">定时发布?</label><br/>
|
||||||
<input type="text" name="pubtime" id="pubtime" value="<?php echo date("Y-m-d H:i",$this->ev['pubtime']);?>" readonly="readonly" />
|
<input type="text" name="pubtime" id="pubtime" value="<?php echo date("Y-m-d H:i",$this->ev['pubtime']);?>" readonly="readonly" />
|
||||||
<small>e.g. 2011-10-28 9:35 or 2011-10-28 21:35</small>
|
<small>e.g. 2011-10-28 9:35 or 2011-10-28 21:35</small>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="return"></div>
|
<div id="return"></div>
|
||||||
|
|
||||||
<p class="box"><input type="button" onclick="addon();" id="submit" class="btn btn-green big" value="提交"/> or <input type="reset" class="btn" value="重置"/></p>
|
<p class="box"><input type="button" onclick="addon();" id="submit" class="btn btn-green big" value="提交"/> or <input type="reset" class="btn" value="重置"/></p>
|
||||||
|
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
</form>
|
</form>
|
||||||
</section>
|
</section>
|
||||||
<!-- End of Left column/section -->
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<!-- End of Wrapper -->
|
|
||||||
</div>
|
|
||||||
<!-- End of Page content -->
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
$(function(){
|
$(function(){
|
||||||
$('#nav_news').addClass("current");
|
|
||||||
|
|
||||||
$("#pubtimeturn").click( function () {
|
$("#pubtimeturn").click( function () {
|
||||||
if($(this).is(":checked"))
|
if($(this).is(":checked"))
|
||||||
{
|
{
|
||||||
|
|
|
@ -2,129 +2,114 @@
|
||||||
$this->headTitle($this->config->title->site);
|
$this->headTitle($this->config->title->site);
|
||||||
$this->headTitle('后台管理');
|
$this->headTitle('后台管理');
|
||||||
$this->headTitle()->setSeparator(' - ');
|
$this->headTitle()->setSeparator(' - ');
|
||||||
$this->headScript()->appendFile('/static/js/jquery.dataTables.min.js');
|
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
||||||
|
$this->headLink()->appendStylesheet('/css/admin.css');
|
||||||
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
||||||
|
$this->breadcrumb('<a href="/admin/news">新闻中心</a>');
|
||||||
|
$this->breadcrumb('新闻列表');
|
||||||
?>
|
?>
|
||||||
|
<style>
|
||||||
|
.listingDetails{position:absolute;width:650px;}
|
||||||
|
.pad{position:absolute;background:#FFF;border:2px solid #444;border-radius:5px;padding:5px;display:none;}
|
||||||
|
</style>
|
||||||
|
<div id="leftPanel">
|
||||||
|
<?= $this->partial('news/left.phtml'); ?>
|
||||||
|
</div>
|
||||||
|
<div id="rightPanel">
|
||||||
|
<?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; ?>
|
||||||
|
|
||||||
<!-- Page title -->
|
<div>
|
||||||
<div id="pagetitle">
|
<a href="javascript:;">按栏目查看</a>
|
||||||
<div class="wrapper">
|
|
||||||
<h1>新闻中心</h1>
|
<a href="/admin/news/newslist">所有新闻列表</a>
|
||||||
<!-- Quick search box -->
|
|
||||||
<form action="" method="get"><input class="" type="text" id="q" name="q" /></form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!-- End of Page title -->
|
|
||||||
|
|
||||||
<!-- Page content -->
|
</div>
|
||||||
<div id="page">
|
|
||||||
<!-- Wrapper -->
|
|
||||||
<div class="wrapper">
|
|
||||||
|
|
||||||
<!-- Right column/section -->
|
<?php if ($this->msg or $this->messages) :?>
|
||||||
<aside class="column width2 first">
|
<div class="box box-info">
|
||||||
<?= $this->partial('news/left.phtml'); ?>
|
<?php if ($this->msg) : ?>
|
||||||
</aside>
|
<?php echo $this->msg; ?>
|
||||||
<!-- End of Right column/section -->
|
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?>
|
||||||
|
<?php echo $msg; ?>
|
||||||
|
<?php endforeach;endif; ?>
|
||||||
|
<script language="javascript">
|
||||||
|
setTimeout('$(".box-info").remove()',5000);
|
||||||
|
</script>
|
||||||
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
|
|
||||||
<!-- Left column/section -->
|
<table id="report" class="stylized full" style="width:650px;">
|
||||||
<section class="column width6">
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th width="50%">新闻标题</th>
|
||||||
|
<th width="25%">所属栏目</th>
|
||||||
|
<th width="25%">新闻管理</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<?php
|
||||||
|
if(count($this->paginator))
|
||||||
|
{
|
||||||
|
foreach ($this->paginator as $v)
|
||||||
|
{
|
||||||
|
echo '
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<div id="paddiv'.$v['id'].'">
|
||||||
|
<a id="titlebtn'.$v['id'].'" class="title"><b>'.$v['title'].'</b></a>
|
||||||
|
<div class="listingDetails">
|
||||||
|
<div class="pad">
|
||||||
|
<b>详细信息</b> <a href="javascript:;" class="closepad" style="float:right">关闭</a>
|
||||||
|
<p>作者:'.$v['writer'].'</p>
|
||||||
|
<p>关键词:'.$v['keyword'].'</p>
|
||||||
|
<p>描述:'.$v['description'].'</p>
|
||||||
|
<p>添加时间:'.date("Y-m-d H:i",$v['writetime']).'</p>
|
||||||
|
<p>发布时间:'.date("Y-m-d H:i",$v['pubtime']).'</p>
|
||||||
|
<p>来源:'.$v['source'].'</p>
|
||||||
|
<p>点击:'.$v['click'].'</p>
|
||||||
|
</div>
|
||||||
|
</div></div>
|
||||||
|
</td>
|
||||||
|
<td><a href="/admin/news/newslist/type/'.$v['typeid'].'">'.$v['catlog'].'</a></td>
|
||||||
|
<td>
|
||||||
|
<a href="/admin/news/newsedit/id/'.$v['id'].'"><b>编辑</b></a>
|
||||||
|
<a href="/admin/news/delete/'.$v['id'].'" onclick="return confirm(\'是否确定删除该栏目\')">删除</a></td>
|
||||||
|
</tr>
|
||||||
|
';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
echo '
|
||||||
|
<tr><td>暂无数据</td><td></td></tr>
|
||||||
|
';
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
<h3>新闻列表</h3>
|
</tbody>
|
||||||
<hr/>
|
</table>
|
||||||
|
<div class="pagenavi"><?= $this->paginator; ?></div>
|
||||||
<div>
|
</div>
|
||||||
<a href="javascript:;">按栏目查看</a>
|
|
||||||
|
|
||||||
<a href="/admin/news/newslist">所有新闻列表</a>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<?php if ($this->msg or $this->messages) :?>
|
|
||||||
<div class="box box-info">
|
|
||||||
<?php if ($this->msg) : ?>
|
|
||||||
<?php echo $this->msg; ?>
|
|
||||||
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?>
|
|
||||||
<?php echo $msg; ?>
|
|
||||||
<?php endforeach;endif; ?>
|
|
||||||
<script language="javascript">
|
|
||||||
setTimeout('$(".box-info").remove()',5000);
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
<?php endif; ?>
|
|
||||||
|
|
||||||
<table id="report" class="stylized full" style="">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th width="50%">新闻标题</th>
|
|
||||||
<th width="25%">所属栏目</th>
|
|
||||||
<th width="25%">新闻管理</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<?php
|
|
||||||
if(count($this->paginator))
|
|
||||||
{
|
|
||||||
foreach ($this->paginator as $v)
|
|
||||||
{
|
|
||||||
echo '
|
|
||||||
<tr>
|
|
||||||
<td class="title">
|
|
||||||
<div id="paddiv'.$v['id'].'">
|
|
||||||
<a id="titlebtn'.$v['id'].'"><b>'.$v['title'].'</b></a>
|
|
||||||
<div class="listingDetails">
|
|
||||||
<div class="pad">
|
|
||||||
<b>详细信息</b>
|
|
||||||
<p>作者:'.$v['writer'].'</p>
|
|
||||||
<p>关键词:'.$v['keyword'].'</p>
|
|
||||||
<p>描述:'.$v['description'].'</p>
|
|
||||||
<p>添加时间:'.date("Y-m-d H:i",$v['writetime']).'</p>
|
|
||||||
<p>发布时间:'.date("Y-m-d H:i",$v['pubtime']).'</p>
|
|
||||||
<p>来源:'.$v['source'].'</p>
|
|
||||||
<p>点击:'.$v['click'].'</p>
|
|
||||||
</div>
|
|
||||||
</div></div>
|
|
||||||
</td>
|
|
||||||
<td><a href="/admin/news/newslist/type/'.$v['typeid'].'">'.$v['catlog'].'</a></td>
|
|
||||||
<td>
|
|
||||||
<a href="/admin/news/newsedit/id/'.$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>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
<div class="pagenavi"><?= $this->paginator; ?></div>
|
|
||||||
|
|
||||||
|
|
||||||
</section>
|
|
||||||
<!-- End of Left column/section -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<!-- End of Wrapper -->
|
|
||||||
</div>
|
|
||||||
<!-- End of Page content -->
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
$('#nav_news').addClass("current");
|
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
/* setup navigation, content boxes, etc... */
|
$('.title').bind('click', function() {
|
||||||
Administry.setup();
|
$('.pad').css('display','none');
|
||||||
/* expandable rows */
|
$(this).next('.listingDetails').children('.pad').show();
|
||||||
Administry.expandableRows();
|
});
|
||||||
|
$('.closepad').bind('click', function() {
|
||||||
|
$('.pad').css('display','none');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
function showpad(id){
|
function showpad(id){
|
||||||
$('#titlebtn'+id).click();
|
$('#titlebtn'+id).click();
|
||||||
}
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
Loading…
Reference in New Issue