package action.news;
import com.opensymphony.xwork2.ActionSupport;
import model.News;
import service.NewsService;
@SuppressWarnings("serial")
public class AddNewsAction extends ActionSupport {
	//private int newsId;
	private String title,content,date,author,keyword;
	private NewsService newsService; 
	// 业务逻辑处理组件,用接口定义,不用类定义
	
	
	public String execute() throws Exception {
		News news = new News();
		//news.setNewsId(newsId);
		news.setTitle(title);
		news.setContent(content);
		news.setDate(date);
		news.setAuthor(author);
		news.setKeyword(keyword);
		
		if (newsService.addNews(news))
			return SUCCESS;
		else
			return ERROR;
	}
	public String getTitle() {
		return title;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	public String getContent() {
		return content;
	}
	public void setContent(String content) {
		this.content = content;
	}
	public String getDate() {
		return date;
	}
	public void setDate(String date) {
		this.date = date;
	}
	public String getAuthor() {
		return author;
	}
	public void setAuthor(String author) {
		this.author = author;
	}
	public String getKeyword() {
		return keyword;
	}
	public void setKeyword(String keyword) {
		this.keyword = keyword;
	}
	public NewsService getNewsService() {
		return newsService;
	}
	public void setNewsService(NewsService newsService) {
		this.newsService = newsService;
	}
}
 最近下载更多
最近下载更多
                
                微信网友_6248713511227392     LV11
                2022年12月5日
            
            
        
                顾北城     LV12
                2022年5月26日
            
            
        
                and123456     LV11
                2022年3月21日
            
            
        
                1798139161     LV4
                2022年2月9日
            
            
        
                xxxhhh1314     LV7
                2022年1月9日
            
            
        
                5555sd6asd3a2d3     LV6
                2021年12月17日
            
            
        
                uuuuuuuuuuuwwwwww     LV3
                2021年12月14日
            
            
        
                lsglsg9     LV23
                2021年11月24日
            
            
        
                1057148049     LV11
                2021年6月16日
            
            
        
                zxm0317     LV10
                2021年1月4日
            
            
         最近浏览更多
最近浏览更多
                
                光明正大黑小虎    
                6月19日
            
            
                    暂无贡献等级
            
        
                微信网友_7005760998215680     LV6
                2024年10月2日
            
            
        
                微信网友_6784866726285312    
                2023年12月26日
            
            
                    暂无贡献等级
            
        
                WBelong     LV8
                2023年12月25日
            
            
        
                19542347615     LV1
                2023年11月23日
            
            
        
                你爹正在加载中     LV4
                2023年9月11日
            
            
        
                多加两块钱     LV4
                2023年6月20日
            
            
        
                yemmmm666     LV1
                2023年6月12日
            
            
        
                n99999    
                2023年6月10日
            
            
                    暂无贡献等级
            
        
                微信网友_6509705287716864     LV2
                2023年6月8日
            
            
        
 
                 
                 
                