新闻发布struts2+Hibernate 实现


新闻发布struts2+Hibernate 实现
资源截图
代码片段和文件信息
package com.action;


import javax.servlet.http.*;
import org.apache.struts.action.*;
import com.actionForm.AfficheForm;
import org.apache.struts.actions.DispatchAction;
import com.dao.AfficheDao;
import com.tool.Chinese;

public class AfficheAction extends DispatchAction {
    private Chinese chinese = new Chinese();
    private AfficheDao afficheDao = new AfficheDao();
//前台操作
    public ActionForward forntContentAfficheAction(ActionMapping mapping
                                                ActionForm form
                                                HttpServletRequest request
                                                HttpServletResponse response) {
  request.setAttribute(“form“afficheDao.selectOneAffiche(Integer.parseInt(request.getParameter(“id“))));
return mapping.findForward(“forntContentAfficheAction“);
    }
//后台操作

    //删除公告信息
    public ActionForward deleteAfficheAction(ActionMapping mapping
                                         ActionForm form
                                         HttpServletRequest request
                                         HttpServletResponse response) {
        afficheDao.deleteAffiche(Integer.parseInt(request.getParameter(“id“)));
            request.setAttribute(“result“ “删除公告信息成功!!!“);
            return mapping.findForward(“resultAfficheAction“);
    }
    //对公告信息的添加
    public ActionForward insertAfficheAction(ActionMapping mapping
                                             ActionForm form
                                             HttpServletRequest request
                                             HttpServletResponse response) {
        AfficheForm afficheForm = (AfficheForm) form;
        if (afficheForm.getContent() == null ||
            afficheForm.getContent().equals(““)) {
            return mapping.findForward(“insertAfficheAction“);
        } else {
            afficheForm.setCreateTime(afficheForm.getCreateTime());
            afficheForm.setContent(chinese.toChinese(afficheForm.getContent()));
            afficheForm.settitle(chinese.toChinese(afficheForm.gettitle()));
            afficheDao.insertAffiche(afficheForm);
            request.setAttribute(“result“ “添加公告信息成功!!!“);
            return mapping.findForward(“resultAfficheAction“);
        }
    }


    public ActionForward selectAfficheAction(ActionMapping mapping
                                             ActionForm form //对公告信息的全部查询
                                             HttpServletRequest request
                                             HttpServletResponse response) {

        request.setAttribute(“list“ afficheDao.selectAffiche());
        return mapping.findForward(“selectAfficheAction“);
    }

    //以自动编号为条件,查询公告信息
    public ActionForward selectOneAfficheAction(ActionMapping mapping
                                                ActionForm form
                                                HttpServletReques

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       4836  2017-01-10 22:12  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.classpath

     文件        451  2009-11-12 21:56  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.myhibernatedata

     文件        291  2017-01-10 22:07  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.mymetadata

     文件        240  2009-11-12 21:55  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.mystrutsdata

     文件       2034  2017-01-10 22:07  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.project

     文件        406  2009-11-12 21:55  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.settings.jsdtscope

     文件        395  2017-01-10 22:07  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.settingsorg.eclipse.jdt.core.prefs

     文件        382  2017-01-10 22:07  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.settingsorg.eclipse.wst.common.component

     文件        122  2017-01-10 22:07  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.settingsorg.eclipse.wst.common.project.facet.core.xml

     文件         49  2009-11-12 21:55  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.settingsorg.eclipse.wst.jsdt.ui.superType.container

     文件          6  2009-11-12 21:55  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNews.settingsorg.eclipse.wst.jsdt.ui.superType.name

     文件       1347  2010-08-24 19:40  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewsdatabase.sql

     文件          0  2009-11-12 21:56  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrcApplicationResources.properties

     文件       4456  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionAfficheAction.java

     文件       4775  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionForceAction.java

     文件       5431  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionManagerAction.java

     文件       8179  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionNewsAction.java

     文件       5179  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionSortAction.java

     文件        609  2009-11-12 22:12  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormAfficheForm.hbm.xml

     文件        844  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormAfficheForm.java

     文件        609  2009-11-12 22:12  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormForceForm.hbm.xml

     文件        876  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormForceForm.java

     文件        730  2009-11-12 22:13  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormManagerForm.hbm.xml

     文件       1563  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormManagerForm.java

     文件        728  2009-11-12 22:13  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormNewsForm.hbm.xml

     文件       1377  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormNewsForm.java

     文件        609  2009-11-12 22:14  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormSortForm.hbm.xml

     文件        959  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomactionFormSortForm.java

     文件       3311  2009-11-12 21:57  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomdaoAfficheDao.java

     文件       3358  2009-11-12 22:32  新闻发布系统源码,有前台后台,struts2+Hibernate 实现wyNewssrccomdaoForceDao.java

............此处省略215个文件信息

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件举报,一经查实,本站将立刻删除。

发表评论

评论列表(条)