您的位置:首页 > Web前端 > JavaScript

基于JSP+SERVLET的新闻发布系统(三)

2013-07-19 18:50 477 查看
拖了这么久。。今天把栏目管理还有新闻管理模块的也挂出来。。

栏目管理跟用户管理一样。

这里重点讲解新闻管理。

效果图如上:



1,可选择栏目类别,且栏目类别是动态生成的。

默认生成的文章是未审核状态的。

栏目类别:
<select name="typeId" id="typeId" style="width: 100">
<option value="">
请选择
</option>
<%
NewsType type = new NewsType();
NewsTypeService typeService = new NewsTypeService();
List<NewsType> typeList = typeService.findAll(type);
if(typeList!=null&&typeList.size()>0){
for(int i=0;i<typeList.size();i++){
type = typeList.get(i);%>
<option value="<%=type.getTypeId() %>">
<%=type.getTypeName() %>
</option>
<%}
}%>
</select>


,2,文本编辑器使用的是百度开发的ueditor,很好用,方便简单,具体使用方法可上官网查找。

<script  id="editor" type="text/plain" name="content">初始化</script>


<script  id="editor" type="text/plain" name="content">${news.content }</script>

3,全选操作。

function ChkAllClick(sonName, cbAllId) {
var arrSon = document.getElementsByName(sonName);
var cbAll = document.getElementById(cbAllId);
var tempState = cbAll.checked;
for (i = 0; i < arrSon.length; i++) {
if (arrSon[i].checked != tempState)
arrSon[i].click();
}
}


猛搓下载源码-》》》http://download.csdn.net/detail/a331251021/5783043
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐