资源简介

基于Java的电子商务平台,包含店铺管理、商品管理、订单管理、网站内容管理、系统管理、网站设置等基本功能,可作为单独的网上商城运行。整个基于SSH的架构,层次清晰,支持多种支付方式。

资源截图

代码片段和文件信息

package com.jeaw.ejgou.action.admin;

import java.util.HashSet;
import java.util.List;

import javax.annotation.Resource;
import javax.servlet.ServletContext;

import org.apache.commons.codec.digest.DigestUtils;
import org.apache.commons.lang.StringUtils;
import org.apache.struts2.convention.annotation.ParentPackage;
import org.springframework.beans.BeanUtils;
import org.springframework.security.AccountExpiredException;
import org.springframework.security.BadCredentialsException;
import org.springframework.security.DisabledException;
import org.springframework.security.LockedException;

import com.jeaw.ejgou.entity.Admin;
import com.jeaw.ejgou.entity.Role;
import com.jeaw.ejgou.service.AdminService;
import com.jeaw.ejgou.service.ArticleService;
import com.jeaw.ejgou.service.MemberService;
import com.jeaw.ejgou.service.MessageService;
import com.jeaw.ejgou.service.OrderService;
import com.jeaw.ejgou.service.ProductService;
import com.jeaw.ejgou.service.RoleService;
import com.opensymphony.xwork2.interceptor.annotations.InputConfig;
import com.opensymphony.xwork2.validator.annotations.EmailValidator;
import com.opensymphony.xwork2.validator.annotations.RegexFieldValidator;
import com.opensymphony.xwork2.validator.annotations.RequiredFieldValidator;
import com.opensymphony.xwork2.validator.annotations.RequiredStringValidator;
import com.opensymphony.xwork2.validator.annotations.StringLengthFieldValidator;
import com.opensymphony.xwork2.validator.annotations.Validations;

import freemarker.ext.beans.BeansWrapper;
import freemarker.template.TemplateHashModel;

/**
 * 后台Action类 - 后台管理、管理员
 */
@ParentPackage(“admin“)
public class AdminAction extends baseAdminAction {
private static final long serialVersionUID = -5383463207248344967L;

// Spring security 最后登录异常Session名称。
public static final String SPRING_SECURITY_LAST_EXCEPTION = “SPRING_SECURITY_LAST_EXCEPTION“;

private String loginUsername;

private Admin admin;
private List allRole;
private List roleList;

@Resource
private AdminService adminService;
@Resource
private RoleService roleService;
@Resource
private OrderService orderService;
@Resource
private MessageService messageService;
@Resource
private ProductService productService;
@Resource
private MemberService memberService;
@Resource
private ArticleService articleService;
@Resource
private ServletContext servletContext;

// 登录页面
public String login() {
String error = getParameter(“error“);
if (StringUtils.endsWithIgnoreCase(error “captcha“)) {
addActionerror(“验证码错误请重新输入!“);
return “login“;
}
Exception springSecurityLastException = (Exception)getSession(SPRING_SECURITY_LAST_EXCEPTION);
if (springSecurityLastException != null) {
if (springSecurityLastException instanceof BadCredentialsException) {
loginUsername = ((String)getSession(“SPRING_SECURITY_LAST_USERNAME“)).toLowerCase();
Admin admin = adminSer

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     文件        4084  2013-10-16 11:08  .classpath
     文件         305  2015-09-17 18:19  .mymetadata
     文件        1419  2015-09-17 18:19  .project
     目录           0  2015-05-31 14:58  .myeclipse\
     目录           0  2015-05-31 15:13  .settings\
     文件         500  2013-10-16 11:08  .settings\.jsdtscope
     文件        1040  2013-10-16 11:08  .settings\com.genuitec.eclipse.j2eedt.core.prefs
     文件          49  2013-10-16 11:08  .settings\org.eclipse.wst.jsdt.ui.superType.container
     文件           6  2013-10-16 11:08  .settings\org.eclipse.wst.jsdt.ui.superType.name
     目录           0  2015-09-17 18:27  docs\
     文件     4671919  2013-10-16 11:08  docs\FreeMarker中文手册.pdf
     文件      139264  2013-10-16 11:08  docs\IKAnalyzer中文分词器.doc
     文件           0  2013-10-16 11:08  docs\代码修改记录.txt
     文件      276480  2015-09-17 18:18  docs\电子商务平台开发指南.doc
     文件      508070  2013-10-16 11:08  docs\表结构及初始化数据.sql
     目录           0  2015-05-31 15:13  src\
     目录           0  2015-05-31 15:13  src\main\
     目录           0  2015-05-31 15:13  src\main\com\
     目录           0  2015-05-31 15:13  src\main\com\jeaw\
     目录           0  2015-05-31 15:13  src\main\com\jeaw\ejgou\
     目录           0  2015-05-31 15:13  src\main\com\jeaw\ejgou\action\
     目录           0  2015-05-31 15:13  src\main\com\jeaw\ejgou\action\admin\
     文件       10477  2013-10-16 11:07  src\main\com\jeaw\ejgou\action\admin\AdminAction.java
     文件        2507  2013-10-16 11:07  src\main\com\jeaw\ejgou\action\admin\AdminProfileAction.java
     文件        1546  2013-10-16 11:07  src\main\com\jeaw\ejgou\action\admin\AgreementAction.java
     文件        4663  2013-10-16 11:07  src\main\com\jeaw\ejgou\action\admin\AreaAction.java
     文件        4418  2013-10-16 11:07  src\main\com\jeaw\ejgou\action\admin\ArticleAction.java
     文件        4440  2013-10-16 11:07  src\main\com\jeaw\ejgou\action\admin\ArticleCategoryAction.java
     文件        6799  2013-10-16 11:08  src\main\com\jeaw\ejgou\action\admin\baseAdminAction.java
     文件        6803  2013-10-16 11:08  src\main\com\jeaw\ejgou\action\admin\BrandAction.java
     文件       10646  2013-10-16 11:07  src\main\com\jeaw\ejgou\action\admin\BuildHtmlAction.java
............此处省略1622个文件信息

评论

共有 条评论