Commit 00c77ff6 authored by ms-dev's avatar ms-dev

4.5.7更新

parent 39add30f
...@@ -31,6 +31,9 @@ QQ交流群号1:221335098<br/> ...@@ -31,6 +31,9 @@ QQ交流群号1:221335098<br/>
* CSS框架:Twitter Bootstrap 2.3.1。 * CSS框架:Twitter Bootstrap 2.3.1。
* 富文本:Ueditor * 富文本:Ueditor
#系统结构
#开发环境 #开发环境
建议开发者使用以下环境,这样避免版本带来的问题 建议开发者使用以下环境,这样避免版本带来的问题
* IDE:eclipse * IDE:eclipse
......
package com.mingsoft.cms.action.web;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import com.mingsoft.cms.parser.CmsParser;
import com.mingsoft.util.StringUtil;
/**
*
*
*
* <p>
* <b>铭飞科技</b>
* </p>
*
* <p>
* Copyright: Copyright (c) 2014 - 2015
* </p>
*
* @author killfen
*
* <p>
* Comments:该类作废,自定义页面请调用对应模块下面的DynamicPageAction
* </p>
*
* <p>
* Create Date:2015-4-20
* </p>
*
* <p>
* Modification history:动态生成页面,需要后台配置自定义页数据
* </p>
*/
@Controller("dynamicPageAction")
@RequestMapping("/mcms")
public class MCmsAction extends com.mingsoft.mdiy.action.BaseAction{
/**
* 替换时间的字符
*/
private String date = "{date/}";
/**
* 替换主机地址
*/
private String host = "{host/}";
/**
*文章解析器
*/
@Autowired
private CmsParser cmsParser;
//该类作废,自定义页面路径请填写对应模块下面的DynamicPageAction的路径
//如商城就为:/mall/{key}.do
/**
* 前段会员中心所有页面都可以使用该方法 请求地址例如: /{diy}.do,例如登陆界面,与注册界面都可以使用
*
* @param key
*/
@RequestMapping("/{diy}.do")
@ExceptionHandler(java.lang.NullPointerException.class)
public void diy(@PathVariable(value = "diy") String diy, HttpServletRequest req, HttpServletResponse resp) {
String content = this.generaterPage(diy,cmsParser,req);
if (StringUtil.isBlank(content)) {
this.outString(resp, this.getResString("err"));
return;
}
//增加时间
content = content.replace(date, StringUtil.getDateSimpleStr());
content = content.replace(host, this.getApp(req).getAppHostUrl());
this.outString(resp, content);
}
}
package com.mingsoft.cms.constant;
import com.mingsoft.base.constant.e.BaseEnum;
public enum ModelCode implements BaseEnum{
/**
* 内容:栏目模块编号
*/
CMS_COLUMN("02990000"),
/**
* 内容:文章模块编号
*/
CMS_ARTICLE("02980100"),
/**
* 内容:文章列表
*/
CMS_ARTICLE_BASIC("02980000"),
/**
* 内容:自定义搜索
*/
CMS_SEARCH("02050000"),
/**
* 内容:自定义模型
*/
CMS_CONTENT_MODEL("02060000"),
/**
* 内容:一键更新
*/
CMS_GENERATE_ALL("02070100"),
/**
* 内容:更新主页
*/
CMS_GENERATE_INDEX("02070200"),
/**
* 内容:更新文档
*/
CMS_GENERATE_ARTICLE("02070300"),
/**
* 内容: 更新栏目
*/
CMS_GENERATE_COLUMN("02070400"),
/**
* 内容:模版
*/
CMS_TEMPLETSKIN("02080000"),
/**
* 内容:织梦数据导入
*/
COM_DEDE_DATA_IMPORT("02090100"),
/**
* 内容:栏目属性管理模块
*/
CMS_COLUMN_TYPE("02090200");
/**
* 设置modelCode的常量
* @param code 常量
*/
ModelCode(String code) {
this.code = code;
}
private String code;
/**
* 返回该modelCode常量的字符串表示
* @return 字符串
*/
@Override
public String toString() {
// TODO Auto-generated method stub
return code;
}
/**
* 返回该modelCode常量的整型表示
* @return 整型
*/
public int toInt() {
// TODO Auto-generated method stub
return Integer.parseInt(code);
}
}
package com.mingsoft.cms.constant.e;
import com.mingsoft.base.constant.e.BaseCookieEnum;
/**
* cookie枚举类
* @author 王天培QQ:78750478
* @version
* 版本号:100-000-000<br/>
* 创建日期:2012-03-15<br/>
* 历史修订:<br/>
*/
public enum CookieEnum implements BaseCookieEnum{
/**
* QQ登录保存当前用户点击地址的session
*/
BASIC_HIT("basic_hit");
/**
* 设置CookieConst的常量
* @param attr 常量
*/
CookieEnum(String attr) {
this.attr = attr;
}
private String attr;
/**
* 返回该CookieConst常量的字符串表示
* @return 字符串
*/
@Override
public String toString() {
// TODO Auto-generated method stub
return attr;
}
}
package com.mingsoft.cms.parser.impl;
import java.io.File;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import com.mingsoft.basic.entity.ColumnEntity;
import com.mingsoft.parser.IParser;
import com.mingsoft.parser.IParserRegexConstant;
import com.mingsoft.util.RegexUtil;
import com.mingsoft.util.StringUtil;
/**
* 栏目标签 (列表标签) {ms:channel type=son typeid=}:栏目父标标签 {/ms:channel}:栏目父标签
* [field.typeindex/]:栏目序号标签 [field.typetitle/]:栏目名称标签 [field.typelink/]:栏目链接标签
* [field.typekeyword/]:栏目关键字 [field.typedescrip/]:栏目描述
*
* @author 成卫雄 QQ:330216230 技术支持:景德镇铭飞科技 官网:www.ming-soft.com
*/
public class ChannelParser extends IParser {
/**
* 列表临时标签,开始标签
*/
private final static String TAB_BEGIN_LIST = "{MS:TAB}";
/**
* 查找HTML中栏目列表的正则表达式的开始位置标签 栏目父标签 {ms:channel type=”sun” typeid=””}
*/
private final static String CHANNEL_BEGIN = "\\{ms:channel.*?\\}";
/**
* 列表临时标签,结束标签
*/
private final static String TAB_END_LIST = "{/MS:TAB}";
/**
* 查找HTML中栏目列表的正则表达式的结束位置标签 栏目父标签 {/ms:channel}
*/
private final static String CHANNEL_END = "\\{/ms:channel\\}";
/**
* 列表临时标签,内容规则
*/
private final static String TAB_BODY = "\\{MS:TAB\\}([\\s\\S]*?)\\{/MS:TAB}";
/**
* 栏目序号 根据显示条数显示的序号1 2 …..10 栏目子标签 [field.typeindex/]
*/
private final static String CHANNEL_INDEX = "\\[field.typeindex/\\]";
/**
* 标题 栏目名称 栏目子标签 [field.typetitle/]
*/
private final static String CHANNEL_TITLE = "\\[field.typetitle/\\]";
/**
* 栏目连接 栏目子标签 [field.typelink/]
*/
private final static String CHANNEL_LINK = "\\[field.typelink/\\]";
/**
* 栏目关键字 栏目子标签 [field.typekeyword/]
*/
private final static String CHANNEL_KEYWORD = "\\[field.typekeyword/\\]";
/**
* 栏目关键字 栏目子标签 [field.typekeyword/]
*/
private final static String CHANNEL_DESCRIP = "\\[field.typedescrip/\\]";
/**
* 获取栏目id
*/
private final static String CHANNEL_FIELE_ID="\\[field.typeid/\\]";
/**
* 分类选中样式
*/
public static final String CHANNEL_CLASS = "class";
/**
* 栏目列表的属性 类型String 取值范围:son|top son表示下级栏目(默认值) top顶级栏目(非必填) 栏目父标签
* {ms:channel type=”sun” typeid=””}
*/
public static final String CHANNEL_TYPE = "type";
/**
* 栏目列表的属性 类型String 取值范围:son|top son表示下级栏目(默认值) top顶级栏目(非必填) 栏目父标签
* {ms:channel type=”sun” typeid=””}
*/
public static final String CHANNEL_TYPE_SON = "son";
/**
* 栏目列表的属性 类型String 取值范围:son|top son表示下级栏目(默认值) top顶级栏目(非必填) 栏目父标签
* {ms:channel type=”sun” typeid=””}
*/
public static final String CHANNEL_TYPE_TOP = "top";
/**
* 栏目列表的属性 类型String 取值范围:son|top|level son表示下级栏目(默认值) top顶级栏目(非必填) level取同一级
* 栏目父标签 {ms:channel type=”sun” typeid=””}
*/
public static final String CHANNEL_TYPE_LEVEL = "level";
/**
* 栏目列表的属性 类型int 默认当前页面的栏目编号(非必填) 栏目父标签 {ms:channel type=”sun” typeid=}
*/
public static final String CHANNEL_TYPEID = "typeid";
/**
* 当前选中类别样式
*/
public static final String CHANNEL_FIELD_CLASS = "\\[field.class/\\]";
/**
* 分类是否显示子分类的属性名
* sibling=true:当该分类下没有子分类时显示其同级栏目
* sibling=false:当该分类下没有子分类时则不显示
*/
public static final String CHANNEL_TYP_SIBLING="sibling";
/**
* 分类显示的个数
*/
public static final String CHANNEL_TYPE_SIZE = "size";
/**
* 当前栏目
*/
private int curColumnId;
/**
* 选中样式
*/
private String className;
/**
* 构造替换栏目标签的必须参数
*
* @param htmlCotent
* HTML模版
* @param newContent
* 替换内容
*/
public ChannelParser(String htmlCotent, List<ColumnEntity> newContent, String page) {
// 在HTML模版中标记出要用内容替换的标签
String htmlCotents = channelPrplace(htmlCotent, TAB_BEGIN_LIST, CHANNEL_BEGIN);
htmlCotents = channelPrplace(htmlCotents, TAB_END_LIST, CHANNEL_END);
// 经过遍历后的数组标签
super.newCotent = articleTypeList(htmlCotents, newContent, page);
super.htmlCotent = htmlCotents;
}
/**
* 构造替换栏目标签的必须参数
*
* @param htmlCotent
* HTML模版
* @param newContent
* 替换内容
* @param page
* @param curColumnId
* 当前分类id
* @param className
* 选中分类样式
*/
public ChannelParser(String htmlCotent, List<ColumnEntity> newContent, String page, int curColumnId, String className) {
this.curColumnId = curColumnId;
this.className = className;
// 在HTML模版中标记出要用内容替换的标签
String htmlCotents = channelPrplace(htmlCotent, TAB_BEGIN_LIST, CHANNEL_BEGIN);
htmlCotents = channelPrplace(htmlCotents, TAB_END_LIST, CHANNEL_END);
// 经过遍历后的数组标签
super.newCotent = articleTypeList(htmlCotents, newContent, page);
super.htmlCotent = htmlCotents;
}
@Override
public String parse() {
// TODO Auto-generated method stub
String channelHtml = this.replaceFirst(TAB_BODY);
return channelHtml;
}
/**
* 将用需要用内容替换的标签换成标记标签
*
* @param htmlCotent
* 原HTML文件
* @return 替换好标签后的HTNL文件
*/
private String channelPrplace(String htmlCotent, String regexTab, String regex) {
String htmlCotents = "";
super.htmlCotent = htmlCotent;
super.newCotent = regexTab;
htmlCotents = this.replaceFirst(regex);
if (htmlCotents.equals("")) {
htmlCotents = "标签格式错误";
}
return htmlCotents;
}
@Override
public String replaceFirst(String regex) {
return RegexUtil.replaceFirst(htmlCotent, regex, newCotent);
}
/**
* 替换的数组内容
*
* @param htmlCotent
* 用标记标签替换好的HTML模版代码
* @param newContent
* 需要插入数组的内容
* @return 如果存在该标签返回替换后的标签和内容,如果不存在则返回空
*/
private String tabContent(String htmlCotent, String newContent, String regex) {
if (StringUtil.isBlank(newCotent)) {
newCotent = regex;
}
String htmlCotents = htmlCotent;
Pattern pattern = Pattern.compile(regex);
Matcher matcher = pattern.matcher(htmlCotent);
if (matcher.find()) {
htmlCotents = matcher.replaceAll(newContent.toString().replace("\\", "/"));
}
return htmlCotents;
}
/**
* 在替换好标签的HTML代码中将用标签替换的那段HTML代码截取出来
*
* @param htmlCotent
* 替换好标签后的HTML代码
* @return 标签替换的那段HTML代码截取出来
*/
private String tabHtml(String htmlCotent) {
Pattern patternList = Pattern.compile(TAB_BODY);
Matcher matcherList = patternList.matcher(htmlCotent);
if (matcherList.find()) {
htmlCotent = matcherList.group(1);
}
return htmlCotent;
}
/**
* 遍历文章数组,将取出的内容替换标签 [field.typeindex/]:栏目序号标签 [field.typetitle/]:栏目名称标签
* [field.typelink/]:栏目链接标签
*
* @param htmlCotent
* 原HTML代码
* @param articleList
* 文章数组
* @param webUrl
* 网站连接地址
* @return 用内容替换标签后的HTML代码
*/
private String articleTypeList(String htmlCotent, List<ColumnEntity> articleTypeList, String webUrl) {
String tabHtml = tabHtml(htmlCotent);
String htmlList = "";
if (articleTypeList != null && articleTypeList.size() != 0) {
for (int i = 0; i < articleTypeList.size(); i++) {
ColumnEntity articleType = articleTypeList.get(i);
// if (articleType.getCategoryCategoryId()==0) { //排除父节点
// continue;
// }
// 替换栏目序号标签
htmlList += tabContent(tabHtml, StringUtil.int2String((i + 1)), CHANNEL_INDEX);
// 替换栏目标题标签
htmlList = tabContent(htmlList, articleType.getCategoryTitle(), CHANNEL_TITLE);
// 替换栏目链接标签
String linkUrl = webUrl + File.separator + StringUtil.null2String(articleType.getColumnPath()) + File.separator + IParserRegexConstant.HTML_INDEX;
htmlList = tabContent(htmlList, linkUrl, CHANNEL_LINK);
// 替换栏目关键字标签
htmlList = tabContent(htmlList, articleType.getColumnKeyword(), CHANNEL_KEYWORD);
// 替换栏目描述标签
htmlList = tabContent(htmlList, articleType.getColumnDescrip(), CHANNEL_DESCRIP);
//替换栏目id标签
htmlList = tabContent(htmlList, articleType.getCategoryId()+"", CHANNEL_FIELE_ID);
if (this.curColumnId == articleType.getCategoryId() && !StringUtil.isBlank(className)) {
htmlList = tabContent(htmlList, className, CHANNEL_FIELD_CLASS);
} else {
htmlList = tabContent(htmlList, "", CHANNEL_FIELD_CLASS);
}
}
}
else {
htmlList = IParserRegexConstant.REGEX_CHANNEL_ERRO;
}
return htmlList;
}
// ——————————————————————————————————解析父标签中的属性开始——————————————————————————————————
/**
* 获取模版文件中栏目列表的个数
*
* @param html
* 文件模版
* @return 返回该字符串的个数
*/
public static int channelNum(String html) {
int channelNumBegin = count(html, CHANNEL_BEGIN);
return channelNumBegin;
}
/**
* 定位栏目标签中所有的属性
*/
private final static String CHANNEL_PROPERTY = "\\{ms:channel(.*)?\\}";
/**
* 取出栏目标签中的属性
*
* @param html
* HTML模版
* @return 属性集合
*/
public static Map<String, String> channelProperty(String html) {
Map<String, String> listPropertyMap = new HashMap<String, String>();
String listProperty = parseFirst(html, CHANNEL_PROPERTY, 1);
List<String> listPropertyName = parseAll(listProperty, PRORETY_NAME, 1);
List<String> listPropertyValue = parseAll(listProperty, PROPERTY_VALUE, 1);
for (int i = 0; i < listPropertyName.size(); i++) {
listPropertyMap.put(listPropertyName.get(i).toString(), listPropertyValue.get(i).toString());
}
return listPropertyMap;
}
// ——————————————————————————————————解析父标签中的属性结束——————————————————————————————————
}
package com.mingsoft.people.action;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.alibaba.fastjson.JSONObject;
import com.mingsoft.basic.biz.ICategoryBiz;
import com.mingsoft.basic.biz.IModelBiz;
import com.mingsoft.basic.constant.Const;
import com.mingsoft.basic.constant.e.CookieConstEnum;
import com.mingsoft.basic.entity.CategoryEntity;
import com.mingsoft.basic.entity.ModelEntity;
import com.mingsoft.people.biz.IPeopleStudentBiz;
import com.mingsoft.people.constant.ModelCode;
import com.mingsoft.people.entity.PeopleStudentEntity;
import com.mingsoft.util.ExcelUtil;
import com.mingsoft.util.PageUtil;
import com.mingsoft.util.StringUtil;
/**
*
* <p>
* <b>铭飞科技-会员系统</b>
* </p>
*
* <p>
* Copyright: Copyright (c) 2014 - 2015
* </p>
*
* @author 史爱华
*
*
* <p>
* Comments: 学生信息管理
* </p>
*
* <p>
* Create Date:2014-10-31
* </p>
*
* <p>
* Modification history:
* </p>
*/
@Controller
@RequestMapping("/manager/people/student")
public class PeopleStudentAction extends BaseAction{
/**
*
*/
@Autowired
private IPeopleStudentBiz peopleStudentBiz;
@Autowired
private ICategoryBiz categoryBiz;
@Autowired
private IModelBiz modelBiz;
@RequestMapping("/list")
public String list(ModelMap mode,HttpServletRequest request,HttpServletResponse response){
Map map = assemblyRequestMap(request);
//获取应用ID
int appId = this.getAppId(request);
//查询用户总数
int peopleCount = this.peopleStudentBiz.getCountByMap(appId,map);
int pageNo = 1;
if(request.getParameter("pageNo")!=null){
pageNo=Integer.parseInt(request.getParameter("pageNo").toString());
}
//查询城市的模块实体
ModelEntity model = modelBiz.getEntityByModelCode(com.mingsoft.basic.constant.ModelCode.CITY);
int modelId = 0;
if(model!=null){
//获取城市的模块id
modelId = model.getModelId();
}
//查询城市数据
List<CategoryEntity> listCategory = categoryBiz.queryByAppIdOrModelId(appId,modelId);
JSONObject ja = new JSONObject();
mode.addAttribute("listCategory", listCategory);
//分页通用类
PageUtil page=new PageUtil(pageNo,peopleCount,getUrl(request)+"/manager/people/student/list.do");
List<PeopleStudentEntity> listPeopleStudent = this.peopleStudentBiz.queryByMap(appId, page,map);
mode.addAttribute("listPeopleStudent", listPeopleStudent);
mode.addAttribute("page", page);
return Const.VIEW+"/people/student/people_student_list";
}
/**
* 获取用户详细信息
* @param peopleId 用户ID
* @param request
* @param response
*/
@RequestMapping("/{peopleId}/query")
public void query(@PathVariable int peopleId,HttpServletRequest request,HttpServletResponse response){
//获取用户实体信息
PeopleStudentEntity peopleStudent = peopleStudentBiz.getPeopleStudent(peopleId);
//判断用户是否存在
if(peopleStudent==null){
//返回错误信息
this.outJson(response,ModelCode.PEOPLE,false,this.getResString("people.session.msg.null.error"));
return ;
}
//返回用户详细信息
this.outJson(response, ModelCode.PEOPLE_USER,true,null,JSONObject.toJSONString(peopleStudent));
}
/**
* 编辑用户信息
* @param peopleId 用户ID
* @param request
* @param response
*/
@RequestMapping("/{peopleId}/edit")
public String edit(@PathVariable int peopleId,HttpServletRequest request,HttpServletResponse response){
//获取用户实体信息
PeopleStudentEntity peopleStudent = peopleStudentBiz.getPeopleStudent(peopleId);
request.setAttribute("peopleStudent", peopleStudent);
return Const.VIEW+"/people/student/people_student";
}
@RequestMapping("/update")
@ResponseBody
public void update(@ModelAttribute PeopleStudentEntity peopleStudent,HttpServletRequest request,HttpServletResponse response){
peopleStudentBiz.updatePeopleStudent(peopleStudent);
// 获取cookie
String cookie =this.getCookie(request, CookieConstEnum.BACK_COOKIE);
this.outJson(response, null, true,String.valueOf(cookie));
}
/**
* 导出学生数据
* @param request
* @param response
*/
@RequestMapping("/exprotStudentsExcel")
public void exportSendExcel(HttpServletRequest request, HttpServletResponse response) {
Map map = assemblyRequestMap(request);
int appId = this.getAppId(request);
List<PeopleStudentEntity> listPeopleStudent = this.peopleStudentBiz.queryByMap(appId, null,map);
String[] titles = new String[] {"编号", "姓名","学校", "电话","所在系"};
List<Object> values = new ArrayList<Object>();
for (int i = 0; i < listPeopleStudent.size(); i++) {
PeopleStudentEntity peopleStudent = (PeopleStudentEntity) listPeopleStudent.get(i);
Object[] objs = new Object[titles.length];
objs[0] = i + 1;
objs[1] =peopleStudent.getPeopleUserRealName();
objs[2] =peopleStudent.getPeopleStudentSchool();
objs[3] = peopleStudent.getPeoplePhone();//姓名
objs[4] = peopleStudent.getPeopleStudentDepartment();
values.add(objs);
}
ExcelUtil.exportExcel("学生信息" + StringUtil.getDateSimpleStr() + ".xls", titles, values, response);
}
}
package com.mingsoft.people.action.people;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import com.alibaba.fastjson.JSONObject;
import com.mingsoft.base.entity.ListJson;
import com.mingsoft.people.action.BaseAction;
import com.mingsoft.people.biz.IPeopleAddressBiz;
import com.mingsoft.people.constant.ModelCode;
import com.mingsoft.people.constant.e.PeopleAddressEnum;
import com.mingsoft.people.entity.PeopleAddressEntity;
import com.mingsoft.people.entity.PeopleEntity;
import com.mingsoft.util.StringUtil;
/**
*
* 普通用户收货地址信息控制层(外部请求接口)
* @author yangxy
* @version
* 版本号:【100-000-000】
* 创建日期:2015年8月23日
* 历史修订:
*/
@Controller("peopleAddress")
@RequestMapping("/people/address")
public class PeopleAddressAction extends BaseAction{
/**
* 注入用户收货地址业务层
*/
@Autowired
private IPeopleAddressBiz peopleAddressBiz;
/**
* 通过用户id和站点id查询用户收货地址列表
* @param request
* @param response
*/
@RequestMapping("/queryAddressList")
public void queryAddressList(HttpServletRequest request,HttpServletResponse response){
//通过session得到用户实体
PeopleEntity peopleEntity = this.getPeopleBySession(request);
if(peopleEntity==null){
//当session不存在返回错误信息
this.outJson(response,null,false,this.getResString("people.session.msg.null.error",com.mingsoft.people.constant.Const.RESOURCES));
return;
}
//通过用户id和站点id查询用户收货地址列表
List<PeopleAddressEntity> list = peopleAddressBiz.queryListByAppIdAndPeopleId(peopleEntity.getPeopleId(), this.getAppId(request));
//将总数放入json参数
ListJson json = new ListJson(list.size(), list);
//返回列表
this.outJson(response,JSONObject.toJSONString(json));
}
/**
* 保存用户收货地址
* @param peopleAddressEntity 用户收货序列化地址实体
* @param request
* @param response
*/
@RequestMapping("/save")
public void save(@ModelAttribute PeopleAddressEntity peopleAddressEntity, HttpServletRequest request,HttpServletResponse response){
//通过session得到用户实体
PeopleEntity peopleEntity = this.getPeopleBySession(request);
if(peopleEntity==null){
//当session不存在返回错误信息
this.outJson(response,ModelCode.PEOPLE_USER,false,this.getResString("people.session.msg.null.error",com.mingsoft.people.constant.Const.RESOURCES));
return ;
}
// 判断用户信息是否为空
if (peopleAddressEntity == null) {
this.outJson(response, ModelCode.PEOPLE_REGISTER, false, this.getResString("people.msg.null.error"), this.getResString("people.msg.null.error"));
return;
}
// 验证手机号
if (StringUtil.isBlank(peopleAddressEntity.getPeopleAddressPhone())) {
this.outJson(response, ModelCode.PEOPLE_REGISTER, false, this.getResString("people.msg.phone.error", com.mingsoft.people.constant.Const.RESOURCES));
return;
}
//验证邮箱
if(!StringUtil.isBlank(peopleAddressEntity.getPeopleAddressMail())){
if (StringUtil.checkEmail(peopleAddressEntity.getPeopleAddressMail())) {
this.outJson(response, ModelCode.PEOPLE_REGISTER, false, this.getResString("people.msg.mail.error", com.mingsoft.people.constant.Const.RESOURCES));
return;
}
}
//判断省、市、详细地址是否为空
if(StringUtil.isBlank(peopleAddressEntity.getPeopleAddressProvince())||StringUtil.isBlank(peopleAddressEntity.getPeopleAddressCity())||StringUtil.isBlank(peopleAddressEntity.getPeopleAddressAddress())){
this.outJson(response, ModelCode.PEOPLE_REGISTER, false, this.getResString("people.user.msg.null.error"));
return;
}
//通过peopleId查询用户默认收货地址实体
PeopleAddressEntity entity = peopleAddressBiz.getDefaultEntity(peopleEntity.getPeopleId(), PeopleAddressEnum.ADDRESS_DEFAULT);
//判断该用户是否有地址(默认状态为0)
if(entity!=null){
//注入地址状态1(非默认状态)
peopleAddressEntity.setPeopleAddressDefault(PeopleAddressEnum.ADDRESS_NOT_DEFAULT);
}
//注入用户id
peopleAddressEntity.setPeopleAddressPeopleId(peopleEntity.getPeopleId());
//注入站点id
peopleAddressEntity.setPeopleAddressAppId(this.getAppId(request));
//进行保存
peopleAddressBiz.saveEntity(peopleAddressEntity);
this.outJson(response,null,true,JSONObject.toJSONString(peopleAddressEntity));
}
/**
* 更新用户收货地址
* @param peopleAddressEntity 用户收货地址序列化实体
* @param request
* @param response
*/
@RequestMapping("/update")
public void update(@ModelAttribute PeopleAddressEntity peopleAddressEntity,HttpServletRequest request,HttpServletResponse response){
//通过session得到用户实体
PeopleEntity peopleEntity = this.getPeopleBySession(request);
if(peopleEntity==null){
//当session不存在返回错误信息
this.outJson(response,ModelCode.PEOPLE_USER,false,this.getResString("people.session.msg.null.error",com.mingsoft.people.constant.Const.RESOURCES));
return ;
}
// 判断用户信息是否为空
if (StringUtil.isBlank(peopleAddressEntity.getPeopleAddressProvince())||StringUtil.isBlank(peopleAddressEntity.getPeopleAddressCity())||StringUtil.isBlank(peopleAddressEntity.getPeopleAddressAddress())) {
this.outJson(response, ModelCode.PEOPLE_REGISTER, false, this.getResString("people.msg.null.error"), this.getResString("people.msg.null.error"));
return;
}
// 验证手机号
if (StringUtil.isBlank(peopleAddressEntity.getPeopleAddressPhone())) {
this.outJson(response, ModelCode.PEOPLE_REGISTER, false, this.getResString("people.msg.phone.error", com.mingsoft.people.constant.Const.RESOURCES));
return;
}
//通过peopleId查询用户默认收货地址实体
PeopleAddressEntity entity = peopleAddressBiz.getDefaultEntity(peopleEntity.getPeopleId(), PeopleAddressEnum.ADDRESS_DEFAULT);
//如果将地址状态修改为默认,且不是自身,则将之前默认地址设为非默认
if(peopleAddressEntity.getPeopleAddressDefault()==PeopleAddressEnum.ADDRESS_DEFAULT.toInt() && peopleAddressEntity.getPeopleAddressId()!=entity.getPeopleAddressId()){
entity.setPeopleAddressDefault(PeopleAddressEnum.ADDRESS_NOT_DEFAULT);
peopleAddressBiz.updateEntity(entity);
}
//更新用户地址
peopleAddressBiz.updateEntity(peopleAddressEntity);
this.outJson(response,null,true);
}
/**
* 根据收货地址id删除收货信息
* @param peopleAddressId 收货地址id
* @param request
* @param response
*/
@RequestMapping("/{peopleAddressId}/delete")
public void delete(@PathVariable int peopleAddressId,HttpServletRequest request,HttpServletResponse response){
//通过session得到用户实体
PeopleEntity peopleEntity = this.getPeopleBySession(request);
if(peopleEntity==null){
//当session不存在返回错误信息
this.outJson(response,ModelCode.PEOPLE_USER,false,this.getResString("people.session.msg.null.error",com.mingsoft.people.constant.Const.RESOURCES));
return ;
}
//根据收货地址id删除收货信息
peopleAddressBiz.deleteEntity(peopleAddressId, this.getAppId(request));
this.outJson(response,null, true);
}
/**
* 通过用户session中的peopleId查询用户默认收获地址实体
* @param request
* @param response
*/
@RequestMapping("/getEntityByDefault")
public void getEntityByDefault(HttpServletRequest request,HttpServletResponse response){
//通过session得到用户实体
PeopleEntity peopleEntity = this.getPeopleBySession(request);
if(peopleEntity==null){
//当session不存在返回错误信息
this.outJson(response,ModelCode.PEOPLE_USER,false,this.getResString("people.session.msg.null.error",com.mingsoft.people.constant.Const.RESOURCES));
return ;
}
//通过peopleId查询用户默认收获地址实体
PeopleAddressEntity entity = peopleAddressBiz.getDefaultEntity(peopleEntity.getPeopleId(), PeopleAddressEnum.ADDRESS_DEFAULT);
//返回用户实体
if(entity!=null){
this.outJson(response,JSONObject.toJSONString(entity));
}else{
this.outJson(response, null, false);
}
}
/**
* 通过peopleAddressId查询用户收货地址实体
* @param peopleAddressId 用户收货地址id
* @param resquest
* @param response
*/
@RequestMapping("/{peopleAddressId}/getEntity")
public void getEntity(@PathVariable int peopleAddressId,HttpServletRequest resquest,HttpServletResponse response){
//通过用户地址id查询用户地址实体
PeopleAddressEntity entity = (PeopleAddressEntity) peopleAddressBiz.getEntity(peopleAddressId);
//返回json形式的实体
this.outJson(response,JSONObject.toJSONString(entity));
}
}
package com.mingsoft.people.action.people;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import com.alibaba.fastjson.JSONObject;
import com.mingsoft.people.biz.IPeopleStudentBiz;
import com.mingsoft.people.constant.ModelCode;
import com.mingsoft.people.entity.PeopleEntity;
import com.mingsoft.people.entity.PeopleStudentEntity;
import com.mingsoft.people.action.BaseAction;
/**
*
* <p>
* <b>铭飞科技-会员系统</b>
* </p>
*
* <p>
* Copyright: Copyright (c) 2014 - 2015
* </p>
*
* @author 史爱华
*
*
* <p>
* Comments:普通用户详细信息控制层(外部请求接口)
* </p>
*
* <p>
* Create Date:2015-03-24
* </p>
*
* <p>
* Modification history:
* </p>
*/
@Controller("webPeopleStudent")
@RequestMapping("/people/student")
public class PeopleStudentAction extends BaseAction{
@Autowired
private IPeopleStudentBiz peopleStudentBiz;
/**
* 查询学生信息
* @param request
* @param response
*/
@RequestMapping("/getStudentInfor")
public void getStudentInfor(HttpServletRequest request,HttpServletResponse response){
//获取用户session
PeopleEntity people = this.getPeopleBySession(request);
if(people == null){
//当session不存在返回错误信息
this.outJson(response,ModelCode.PEOPLE_USER,false,this.getResString("people.session.msg.null.error",com.mingsoft.people.constant.Const.RESOURCES));
return ;
}
PeopleStudentEntity peopleStudents = (PeopleStudentEntity) this.peopleStudentBiz.getEntity(people.getPeopleId());
if(peopleStudents == null){
//没用用户详细信息
this.outJson(response, ModelCode.PEOPLE_USER,false,this.getResString("people.user.msg.null.error",com.mingsoft.people.constant.Const.RESOURCES));
return ;
}
//查询学生的具体信息
this.outJson(response, ModelCode.PEOPLE_USER,true,null,JSONObject.toJSONString(this.peopleStudentBiz.getStudentInfor(people.getPeopleId())));
}
}
package com.mingsoft.people.aop;
import javax.servlet.http.HttpServletRequest;
import com.mingsoft.base.entity.SessionEntity;
import com.mingsoft.people.constant.e.SessionConstEnum;
/**
* bbs切面基础方法
*
* @author 史爱华
* @version 版本号:100-000-000<br/>
* 创建日期:2015-12-14<br/>
* 历史修订:<br/>
*/
public abstract class BaseAop extends com.mingsoft.basic.aop.BaseAop {
/**
* 读取用户sessoin
*
* @param request
* HttpServletRequest对象
* @return 返回获取到的用户session,获取不到返回nul
*/
protected SessionEntity getPeopleBySession(HttpServletRequest request) {
// 传入用户请求,读取用户的session || super,调用父类的protected属性的getSession方法
Object obj = this.getSession(request, SessionConstEnum.PEOPLE_SESSION);
if (obj != null) {
// 返回用户的所有信息
return (SessionEntity) obj;
}
return null;
}
}
package com.mingsoft.people.biz;
import java.util.List;
import com.mingsoft.base.biz.IBaseBiz;
import com.mingsoft.people.constant.e.PeopleAddressEnum;
import com.mingsoft.people.entity.PeopleAddressEntity;
/**
*
* 用户收货地址业务层
* @author yangxy
* @version
* 版本号:【100-000-000】
* 创建日期:2015年8月23日
* 历史修订:
*/
public interface IPeopleAddressBiz extends IBaseBiz{
/**
* 通过用户id和站点id查询用户收货地址列表
* @param peopleId 用户id
* @param appId 站点id
* @return 收货地址实体
*/
List<PeopleAddressEntity> queryListByAppIdAndPeopleId(int peopleId,int appId);
/**
* 根据用户收货地址id和站点id删除收货地址
* @param peopleAddressId 用户收货地址id
* @param appId 站点id
*/
void deleteEntity(int peopleAddressId,int appId);
/**
* 根据用户id和地址属性得到地址实体
* @param peopleId 用户id
* @param addressDefault 地址属性(默认为0,非默认为1)
* @return 默认用户收货地址
*/
PeopleAddressEntity getDefaultEntity(int peopleId,PeopleAddressEnum addressDefault);
}
package com.mingsoft.people.biz;
import com.mingsoft.base.biz.IBaseBiz;
import com.mingsoft.people.entity.PeopleOpenEntity;
/**
* 开发平台用户接口 例如qq模块
* @author 肥猪
* @version
* 版本号:100-000-000<br/>
* 创建日期:2016年1月25日<br/>
* 历史修订:<br/>
*/
public interface IPeopleOpenBiz extends IBaseBiz{
/**
* 根据平台openid读取用户编号
* @param openId 平台openid信息
* @return null:无数据
*/
PeopleOpenEntity getByOpenId(String openId);
/**
* 保存开源用户信息,
* @param peopleOpen
*/
void savePeopleOpen(PeopleOpenEntity peopleOpen);
}
package com.mingsoft.people.biz;
import java.util.List;
import java.util.Map;
import com.mingsoft.people.entity.PeopleStudentEntity;
import com.mingsoft.util.PageUtil;
/**
*
*
* <p>
* <b>铭飞CMS-铭飞内容管理系统</b>
* </p>
*
* <p>
* Copyright: Copyright (c) 2014 - 2015
* </p>
*
* <p>
* Company:景德镇铭飞科技有限公司
* </p>
*
* @author 史爱华
*
* @version 300-001-001
*
* <p>
* 版权所有 铭飞科技
* </p>
*
* <p>
* Comments: 学生信息业务层接口,继承IPeopleBiz接口
* </p>
*
* <p>
* Create Date:2014-12-19
* </p>
*
* <p>
* Modification history:
* </p>
*/
public interface IPeopleStudentBiz extends IPeopleBiz {
/**
* 学生信息实体保存</br>
* 只能有子类继承时调用的</br>
* @param peopleStudentEntity 用户信息
* @return 新增成功后用户ID
*/
public int savePeopleStudent(PeopleStudentEntity peopleStudentEntity);
/**
* 更新学生信息</br>
* 只能在有子类时调用</br>
* @param peopleStudentEntity 学生信息
*/
public void updatePeopleStudent(PeopleStudentEntity peopleStudentEntity);
/**
* 删除学生信息</br>
* 只能在有子类时调用</br>
* @param peopleId 用户ID
*/
public void deletePeopleStudent(int peopleId);
/**
* 查询学生信息
* @param peopleId
* @return 学生实体
*/
public PeopleStudentEntity getPeopleStudent(int peopleId);
/**
* 查询app下学生的信息
* @param appId 应用id
* @param page 分页对象
* @return 学生列表信息
*/
public List<PeopleStudentEntity> queryListPageByAppId(Integer appId ,PageUtil page);
/**
* 根据用户id查找学生的具体信息
* @param peopleId
* @return 学生信息
*/
public Map getStudentInfor(Integer peopleId);
/**
* 根据条件查询总数
* @param appId 应用id
* @param page 分页对象
* @param where 查询条件
* key:依据查询字段 value:字段值
* @return 学生列表信息
*/
public List<PeopleStudentEntity> queryByMap(Integer appId ,PageUtil page,Map where);
/**
* 根据条件查询总数
* @param appId 应用id
* @param where
* key:依据查询字段 value:字段值
* @return 符合条件的学生总数
*/
public int getCountByMap(Integer appId ,Map where);
}
package com.mingsoft.people.biz.impl;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.mingsoft.base.biz.impl.BaseBizImpl;
import com.mingsoft.base.dao.IBaseDao;
import com.mingsoft.people.biz.IPeopleAddressBiz;
import com.mingsoft.people.constant.e.PeopleAddressEnum;
import com.mingsoft.people.dao.IPeopleAddressDao;
import com.mingsoft.people.entity.PeopleAddressEntity;
/**
*
* 用户收货地址业务处理层
* @author yangxy
* @version
* 版本号:【100-000-000】
* 创建日期:2015年8月23日
* 历史修订:
*/
@Service("peopleAddressBizImpl")
public class PeopleAddressBizImpl extends BaseBizImpl implements IPeopleAddressBiz{
/**
* 注入用户收货地址持久层
*/
@Autowired
private IPeopleAddressDao peopleAddressDao;
/**
* 获取peopleAddressDao
*/
@Override
protected IBaseDao getDao() {
// TODO Auto-generated method stub
return peopleAddressDao;
}
@Override
public List<PeopleAddressEntity> queryListByAppIdAndPeopleId(int peopleId, int appId) {
// TODO Auto-generated method stub
return peopleAddressDao.queryListByAppIdAndPeopleId(peopleId, appId);
}
@Override
public void deleteEntity(int peopleAddressId, int appId) {
// TODO Auto-generated method stub
peopleAddressDao.deleteEntity(peopleAddressId, appId);
}
@Override
public PeopleAddressEntity getDefaultEntity(int peopleId, PeopleAddressEnum addressDefault) {
// TODO Auto-generated method stub
return peopleAddressDao.getDefaultEntity(peopleId, addressDefault.toInt());
}
}
package com.mingsoft.people.biz.impl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.mingsoft.base.dao.IBaseDao;
import com.mingsoft.people.biz.IPeopleOpenBiz;
import com.mingsoft.people.dao.IPeopleDao;
import com.mingsoft.people.dao.IPeopleOpenDao;
import com.mingsoft.people.dao.IPeopleUserDao;
import com.mingsoft.people.entity.PeopleOpenEntity;
/**
* 开发平台用户
*
* @author 王天培
* @version 版本号:100-000-000<br/>
* 创建日期:2016年1月25日<br/>
* 历史修订:<br/>
*/
@Service("peopleOpenBizImpl")
public class PeopleOpenBizImpl extends PeopleUserBizImpl implements IPeopleOpenBiz {
@Autowired
private IPeopleOpenDao peopleOpenDao;
/**
* 用户信息持久化层注入
*/
@Autowired
private IPeopleUserDao peopleUserDao;
@Autowired
private IPeopleDao peopleDao;
@Override
protected IBaseDao getDao() {
return peopleOpenDao;
}
@Override
public void savePeopleOpen(PeopleOpenEntity peopleOpen) {
// TODO Auto-generated method stub
peopleDao.saveEntity(peopleOpen);
peopleUserDao.saveEntity(peopleOpen);
peopleOpenDao.saveEntity(peopleOpen);
}
@Override
public PeopleOpenEntity getByOpenId(String openId) {
// TODO Auto-generated method stub
return peopleOpenDao.getByOpenId(openId);
}
}
package com.mingsoft.people.biz.impl;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.mingsoft.basic.biz.ICategoryBiz;
import com.mingsoft.people.biz.IPeopleBiz;
import com.mingsoft.people.biz.IPeopleUserBiz;
import com.mingsoft.base.dao.IBaseDao;
import com.mingsoft.people.biz.IPeopleStudentBiz;
import com.mingsoft.people.dao.IPeopleStudentDao;
import com.mingsoft.basic.entity.CategoryEntity;
import com.mingsoft.people.entity.PeopleStudentEntity;
import com.mingsoft.util.PageUtil;
/**
*
*
* <p>
* <b>铭飞CMS-铭飞内容管理系统</b>
* </p>
*
* <p>
* Copyright: Copyright (c) 2014 - 2015
* </p>
*
* <p>
* Company:景德镇铭飞科技有限公司
* </p>
*
* @author 刘继平
*
* @version 300-001-001
*
* <p>
* 版权所有 铭飞科技
* </p>
*
* <p>
* Comments: 用户信息业务层层实现类,继承PeopleBizImpl,实现IPeoplePrivateBiz接口
* </p>
*
* <p>
* Create Date:2014-9-4
* </p>
*
* <p>
* Modification history:
* </p>
*/
@Service("peopleStudentBiz")
public class PeopleStudentBizImpl extends PeopleBizImpl implements IPeopleStudentBiz {
/**
* 学生信息持久化层注入
*/
@Autowired
private IPeopleStudentDao peopleStudentDao;
@Autowired
private IPeopleUserBiz peopleUserBiz;
@Autowired
private IPeopleBiz peopleBiz;
@Autowired
private ICategoryBiz categoryBiz;
@Override
protected IBaseDao getDao() {
return peopleStudentDao;
}
@Override
public int savePeopleStudent(PeopleStudentEntity peopleStudentEntity) {
peopleUserBiz.savePeople(peopleStudentEntity);
return peopleStudentDao.saveEntity(peopleStudentEntity);
}
@Override
public void updatePeopleStudent(PeopleStudentEntity peopleStudentEntity) {
// TODO Auto-generated method stub
peopleUserBiz.updateEntity(peopleStudentEntity);
peopleBiz.updatePeople(peopleStudentEntity);
this.peopleStudentDao.updateEntity(peopleStudentEntity);
}
@Override
public void deletePeopleStudent(int peopleId) {
deletePeople(peopleId);
this.peopleStudentDao.deleteEntity(peopleId);
}
@Override
public PeopleStudentEntity getPeopleStudent(int peopleId) {
// TODO Auto-generated method stub
return this.peopleStudentDao.getPeopleStudent(peopleId);
}
@Override
public List<PeopleStudentEntity> queryListPageByAppId(Integer appId,
PageUtil page) {
// TODO Auto-generated method stub
return peopleStudentDao.queryPageListByAppId(appId, page);
}
@Override
public Map getStudentInfor(Integer peopleId) {
PeopleStudentEntity peopleStudent = (PeopleStudentEntity) this.peopleStudentDao.getPeopleStudent(peopleId);
//查询学生的城市信息
CategoryEntity city = categoryBiz.getCategory(peopleStudent.getPeopleStudentCityID());
Map map = new HashMap();
if(city!=null){
map.put("city", city.getCategoryTitle());
CategoryEntity province = (CategoryEntity)categoryBiz.getEntity(city.getCategoryCategoryId());
if(province!=null){
map.put("province", province.getCategoryTitle());
}
}
map.put("peopleStudent", peopleStudent);
return map;
}
@Override
public List<PeopleStudentEntity> queryByMap(Integer appId,PageUtil page ,Map where){
return this.peopleStudentDao.queryByMap(appId, page, where);
}
@Override
public int getCountByMap(Integer appId, Map where) {
// TODO Auto-generated method stub
return this.peopleStudentDao.getCountByMap(appId, where);
}
}
package com.mingsoft.people.constant;
import com.mingsoft.base.constant.e.BaseEnum;
/**
*
* 铭飞会员系统 会员模块编码
* @author 铭飞开发团队
* @version
* 版本号:100-000-000<br/>
* 创建日期:2016年3月30日<br/>
* 历史修订:<br/>
*/
public enum ModelCode implements BaseEnum{
/**
* 用户信息模块
*/
PEOPLE("07000000"),
/**
* 用户注册
*/
PEOPLE_REGISTER("07010100"),
/**
* 用户登录
*/
PEOPLE_LOGIN("07010200"),
/**
* 普通用户管理
*/
PEOPLE_USER("07020100");
/**
* 设置modelCode的常量
* @param code 常量
*/
ModelCode(String code) {
this.code = code;
}
private String code;
/**
* 返回该modelCode常量的字符串表示
* @return 字符串
*/
@Override
public String toString() {
// TODO Auto-generated method stub
return code;
}
/**
* 返回该modelCode常量的整型表示
* @return 整型
*/
public int toInt() {
// TODO Auto-generated method stub
return Integer.parseInt(code);
}
}
package com.mingsoft.people.constant.e;
import com.mingsoft.base.constant.e.BaseCookieEnum;
public enum CookieConstEnum implements BaseCookieEnum {
/**
* 用户的cookie
*/
PEOPLE_COOKIE("people_cookie");
/**
* 设置session常量
*
* @param attr
* 常量
*/
CookieConstEnum(String attr) {
this.attr = attr;
}
private String attr;
/**
* 返回SessionConst常量的字符串表示
*
* @return 字符串
*/
@Override
public String toString() {
// TODO Auto-generated method stub
return attr;
}
}
package com.mingsoft.people.constant.e;
import com.mingsoft.base.constant.e.BaseSessionEnum;
/**
* 铭飞会员系统
* @author 铭飞开发团队
* @version
* 版本号:100-000-000<br/>
* 创建日期:2016年3月31日<br/>
* 历史修订:<br/>
*/
public enum SessionConstEnum implements BaseSessionEnum {
/**
* 用户的session
*/
PEOPLE_SESSION("people_session"),
/**
* 用户取回密码的session
*/
PEOPLE_GET_PASSWORD_SESSION("people_get_password_session"),
/**
* 用户验证手机号、用名称、邮箱的session
*/
PEOPLE_EXISTS_SESSION("people_exists_session"),
/**
* 重置密码session
*/
PEOPLE_RESET_PASSWORD_SESSION("people_reset_password_session"),
/**
* 用户更改手机号码的session
*/
PEOPEL_SET_PHONE_SESSION("people_set_phone_seesion");
/**
* 设置session常量
*
* @param attr
* 常量
*/
SessionConstEnum(String attr) {
this.attr = attr;
}
private String attr;
/**
* 返回SessionConst常量的字符串表示
*
* @return 字符串
*/
@Override
public String toString() {
// TODO Auto-generated method stub
return attr;
}
}
package com.mingsoft.people.dao;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import com.mingsoft.base.dao.IBaseDao;
import com.mingsoft.people.constant.e.PeopleEnum;
import com.mingsoft.people.entity.PeopleAddressEntity;
/**
*
* 用户收货地址持久化层
* @author yangxy
* @version
* 版本号:【100-000-000】
* 创建日期:2015年8月23日
* 历史修订:
*/
public interface IPeopleAddressDao extends IBaseDao{
/**
* 通过用户id和站点id查询用户收货地址列表
* @param peopleId 用户id
* @param appId 站点id
* @return 用户收货地址列表
*/
List<PeopleAddressEntity> queryListByAppIdAndPeopleId(@Param("peopleAddressPeopleId")int peopleId,@Param("peopleAddressAppId")int appId);
/**
* 根据用户收货地址id和站点id删除收货地址
* @param peopleAddressId 用户收货地址id
* @param appId 站点id
*/
void deleteEntity(@Param("peopleAddressId")int peopleAddressId,@Param("peopleAddressAppId")int appId);
/**
* 根据用户id和地址属性得到地址实体
* @param peopleId 用户id
* @param addressDefault 地址属性(默认为0,非默认为1)
* @return 默认用户收货地址
*/
PeopleAddressEntity getDefaultEntity(@Param("peopleAddressPeopleId")int peopleId,@Param("peopleAddressDefault")int addressDefault);
}
package com.mingsoft.people.dao;
import com.mingsoft.base.dao.IBaseDao;
import com.mingsoft.people.entity.PeopleOpenEntity;
/**
* 开发平台用户
* @author 肥猪
* @version
* 版本号:100-000-000<br/>
* 创建日期:2016年1月25日<br/>
* 历史修订:<br/>
*/
public interface IPeopleOpenDao extends IBaseDao{
/**
* 根据平台openid读取用户编号
* @param openId 平台openid信息
* @return null没有找到数据
*/
PeopleOpenEntity getByOpenId(String openId);
}
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="com.mingsoft.people.dao.IPeopleOpenDao">
<resultMap type="com.mingsoft.people.entity.PeopleOpenEntity"
id="peopleOpen">
<result column="OPEN_PEOPLE_ID" property="peopleOpenPeopleId" />
<result column="OPEN_ID" property="peopleOpenId" />
<result column="OPEN_PLATFORM" property="peopleOpenPlatform" />
</resultMap>
<select id="getByOpenId" resultMap="peopleOpen">
SELECT OPEN_PEOPLE_ID FROM
PEOPLE_OPEN WHERE OPEN_ID = #{openId}
</select>
<insert id="saveEntity" parameterType="com.mingsoft.people.entity.PeopleOpenEntity">
INSERT INTO PEOPLE_OPEN
(OPEN_PEOPLE_ID,OPEN_ID,OPEN_PLATFORM)
VALUES(#{peopleId},#{peopleOpenId},#{peopleOpenPlatform});
</insert>
</mapper>
\ No newline at end of file
package com.mingsoft.people.dao;
import java.util.List;
import java.util.Map;
import org.apache.ibatis.annotations.Param;
import com.mingsoft.base.dao.IBaseDao;
import com.mingsoft.people.entity.PeopleStudentEntity;
import com.mingsoft.util.PageUtil;
/**
*
*
* <p>
* <b>铭飞CMS-铭飞内容管理系统</b>
* </p>
*
* <p>
* Copyright: Copyright (c) 2014 - 2015
* </p>
*
* <p>
* Company:景德镇铭飞科技有限公司
* </p>
*
* @author 史爱华
*
* @version 300-001-001
*
* <p>
* 版权所有 铭飞科技
* </p>
*
* <p>
* Comments:学生信息持久化层接口,继承IBaseDao
* </p>
*
* <p>
* Create Date:2014-12-19
* </p>
*
* <p>
* Modification history:
* </p>
*/
public interface IPeopleStudentDao extends IBaseDao {
/**
* 获取学生实体信息
* @param peopleId 用户id
* @return 学生实体
*/
PeopleStudentEntity getPeopleStudent(int peopleId);
/**
* 查询app下学生的信息
* @param appId 应用id
* @param page 分页实体
* @return 学生列表
*/
List<PeopleStudentEntity> queryPageListByAppId(@Param("appId") Integer appId,@Param("page" ) PageUtil page);
/**
* 根据条件查询学生总数
* @param appId 应用id
* @param page 分页实体
* @param where 查询条件集合
* @return 学生列表
*/
List<PeopleStudentEntity> queryByMap(@Param("appId") Integer appId,@Param("page" ) PageUtil page,@Param("where" )Map where);
/**
* 根据条件查询学生总数
* @param appId 应用id
* @param page 分页实体
* @param where 查询条件集合
* @return 学生总数
*/
int getCountByMap(@Param("appId") Integer appId,@Param("where")Map where);
}
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<!-- 用户信息持久层继承IBaseDao -->
<mapper namespace="com.mingsoft.people.dao.IPeopleStudentDao">
<!-- 表字段开始-->
<sql id="column_list">
ps.ps_peopleID,ps.ps_education,ps.ps_indate,ps.ps_cityID,ps.ps_school,ps.ps_department,ps.ps_specialty,
ps.ps_class,ps.ps_no,ps.ps_room
</sql>
<sql id="column_peopleStudent_list">
ps.ps_peopleID,ps.ps_education,ps.ps_indate,ps.ps_cityID,ps.ps_school,ps.ps_department,ps.ps_specialty,ps.ps_class,ps.ps_no,ps.ps_room,
P.PEOPLE_ID,P.PEOPLE_PHONE,P.PEOPLE_NAME,P.PEOPLE_PASSWORD,P.PEOPLE_DATETIME,P.PEOPLE_APP_ID,P.PEOPLE_MAIL
</sql>
<!-- 表字段结束 -->
<!-- 将实体属性与表字段对接开始 -->
<resultMap id="resultMap" type="com.mingsoft.people.entity.PeopleStudentEntity">
<id column="ps_peopleID" property="peopleStudentPeopleId"/><!-- 将实体的ID属性与表的ID字段对接 -->
<result column="ps_education" property="peopleStudentEducation"/><!--学生的学历 -->
<result column="ps_indate" property="peopleStudentIndate"/><!--学生的入学年份 -->
<result column="ps_cityID" property="peopleStudentCityID"/><!--学生所在城市 -->
<result column="ps_school" property="peopleStudentSchool"/><!--学生所在学校 -->
<result column="ps_department" property="peopleStudentDepartment"/><!--学生所在院系-->
<result column="ps_specialty" property="peopleStudentSpecialty"/><!--学生所在的专业-->
<result column="ps_class" property="peopleStudentClass"/><!--学生所在的班级-->
<result column="ps_no" property="peopleStudentNo"/><!--学生的学号-->
<result column="ps_room" property="peopleStudentRoom"/><!--学生的宿舍号-->
<result column="PEOPLE_ID" property="peopleId"/><!-- 将实体的ID属性与表的ID字段对接 -->
<result column="PEOPLE_PHONE" property="peoplePhone"/><!-- 将实体的peoplePhone属性与表的peoplePhone字段对接 -->
<result column="PEOPLE_NAME" property="peopleName"/><!-- 将实体的peopleName属性与表的peopleName字段对接 -->
<result column="PEOPLE_PASSWORD" property="peoplePassword"/><!-- 将实体的peoplePwd属性与表的peoplePwd字段对接 -->
<result column="PEOPLE_DATETIME" property="peopleDateTime"/><!-- 将实体的peopleDateTime属性与表的peopleDateTime字段对接 -->
<result column="PEOPLE_APP_ID" property="peopleAppId"/><!-- 用户所属的应用ID -->
<result column="PEOPLE_MAIL" property="peopleMail"/><!-- 用户邮箱 -->
<result column="PEOPLE_STATE" property="peopleState"/><!-- 用户状态-->
<result column="PU_REAL_NAME" property="peopleUserRealName"/><!--用户的真实名称 -->
<result column="PU_ADDRESS" property="peopleUserAddress"/><!-- 用户地址 -->
<result column="PU_ICON" property="peopleUserIcon"/><!-- 用户头像 -->
<result column="PU_NICKNAME" property="peopleUserNickName"/><!-- 用户昵称 -->
<result column="PU_SEX" property="peopleUserSex"/><!-- 用户性别0.未知;1.男;2.女 -->
<result column="PU_BIRTHDAY" property="peopleUserBirthday"/><!-- 用户生日 -->
<result column="PU_APP_ID" property="peopleUserAppId"/><!-- 用户应用ID -->
<result column="PU_CARD" property="peopleUserCard"/><!-- 用户身份证号码 -->
</resultMap>
<!-- 将实体属性与表字段对接结束-->
<!-- 新增学生信息开始 -->
<insert id="saveEntity" useGeneratedKeys="true" keyProperty="peopleId" parameterType="com.mingsoft.base.entity.BaseEntity">
insert into people_student
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="peopleId != null">ps_peopleID,</if>
<if test="peopleStudentEducation != null">ps_education,</if>
<if test="peopleStudentIndate != null">ps_indate,</if>
<if test="peopleStudentCityID != null">ps_cityID,</if>
<if test="peopleStudentSchool != null">ps_school,</if>
<if test="peopleStudentDepartment != null">ps_department,</if>
<if test="peopleStudentClass != null">ps_class,</if>
<if test="peopleStudentNo != null">ps_no,</if>
<if test="peopleStudentRoom != null">ps_room,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="peopleId != null">#{peopleId},</if>
<if test="peopleStudentEducation != null">#{peopleStudentEducation},</if>
<if test="peopleStudentIndate != null">#{peopleStudentIndate},</if>
<if test="peopleStudentCityID != null">#{peopleStudentCityID},</if>
<if test="peopleStudentSchool != null">#{peopleStudentSchool},</if>
<if test="peopleStudentDepartment != null">#{peopleStudentDepartment},</if>
<if test="peopleStudentClass != null">#{peopleStudentClass},</if>
<if test="peopleStudentNo != null">#{peopleStudentNo},</if>
<if test="peopleStudentRoom != null">#{peopleStudentRoom},</if>
</trim>
</insert>
<!-- 新增学生信息结束 -->
<!-- 更新学生开始 -->
<update id="updateEntity" parameterType="com.mingsoft.base.entity.BaseEntity">
update people_Student
<set>
<if test="peopleStudentEducation != null">ps_education=#{peopleStudentEducation},</if>
<if test="peopleStudentIndate != null">ps_indate=#{peopleStudentIndate},</if>
<if test="peopleStudentCityID != null">ps_cityID=#{peopleStudentCityID},</if>
<if test="peopleStudentSchool != null">ps_school=#{peopleStudentSchool},</if>
<if test="peopleStudentDepartment != null">ps_department=#{peopleStudentDepartment},</if>
<if test="peopleStudentClass != null">ps_class=#{peopleStudentClass},</if>
<if test="peopleStudentNo != null">ps_no=#{peopleStudentNo},</if>
<if test="peopleStudentRoom != null">ps_room=#{peopleStudentRoom},</if>
<if test="peopleStudentSpecialty != null">ps_specialty=#{peopleStudentSpecialty},</if>
</set>
where ps_peopleID = #{peopleId}
</update>
<!-- 更新学生结束 -->
<!-- 根据Id查询实体开始 -->
<select id="getEntity" resultMap="resultMap" parameterType="int">
select <include refid="column_peopleStudent_list"/>
from people p
left join people_student ps on p.people_id=ps.ps_peopleID
where
p.people_id = #{peopleId}
</select>
<!-- 根据Id查询实体结束 -->
<!-- 删除用户开始 -->
<delete id="deleteEntity" parameterType="int">
delete from people_student where ps_peopleID = #{peopleID}
</delete>
<!-- 删除用户结束 -->
<!-- 根据Id查询学生实体开始 -->
<select id="getPeopleStudent" resultMap="resultMap" parameterType="int">
select * from v_people_student where ps_peopleID=#{peopleId}
</select>
<!-- 查询站点下学生的信息开始 -->
<select id="queryPageListByAppId" resultMap="resultMap" >
select * from v_people_student where PEOPLE_APP_ID=#{appId}
<if test="page != null">
limit ${page.pageNo*page.pageSize},#{page.pageSize}
</if>
</select>
<!-- 查询站点下学生的信息结束-->
<select id="queryByMap" resultMap="resultMap">
select * from v_people_student
<where>
<if test="appId != null">
and PEOPLE_APP_ID = #{appId}
</if>
<if test="where!=null">
<if test="where.peopleStudentCityID!=null">
and ps_cityID=#{where.peopleStudentCityID}
</if>
<if test="where.peopleStudentSchool!= null">
and ps_school=#{where.peopleStudentSchool}
</if>
<if test="where.peopleState!= null">
and PEOPLE_STATE=#{where.peopleState}
</if>
<if test="where.peopleUserRealName != null">
and PU_REAL_NAME=#{where.peopleUserRealName}
</if>
</if>
order by PEOPLE_ID desc
<if test="page != null">
limit ${page.pageNo*page.pageSize},#{page.pageSize};
</if>
</where>
</select>
<select id="getCountByMap" resultType="int">
select count(*) from v_people_student
<where>
<if test="appId != null">
and PEOPLE_APP_ID = #{appId}
</if>
<if test="where!=null">
<if test="where.peopleStudentCityID!=null">
and ps_cityID=#{where.peopleStudentCityID}
</if>
<if test="where.peopleStudentSchool!= null">
and ps_school=#{where.peopleStudentSchool}
</if>
<if test="where.peopleState != null">
and PEOPLE_STATE=#{where.peopleState}
</if>
</if>
</where>
</select>
</mapper>
\ No newline at end of file
package com.mingsoft.people.entity;
import com.mingsoft.base.constant.e.BaseEnum;
import com.mingsoft.base.entity.BaseEntity;
/**
*
* 用户收货地址实体类
* @author yangxy
* @version
* 版本号:【100-000-000】
* 创建日期:2015年8月24日
* 历史修订:
*/
public class PeopleAddressEntity extends BaseEntity{
/**
* 用户收货地址自增长Id
*/
int peopleAddressId;
/**
* 对应用户基础信息拓展表的id
*/
int peopleAddressPeopleId;
/**
* 用户收货人姓名
*/
String peopleAddressConsigneeName;
/**
* 收货人所在的省
*/
String peopleAddressProvince;
/**
* 收货人所在的市
*/
String peopleAddressCity;
/**
* 收货人所在区
*/
String peopleAddressDistrict;
/**
* 收货人的详细收货地址
*/
String peopleAddressAddress;
/**
* 收货人邮箱
*/
String peopleAddressMail;
/**
* 收货人手机
*/
String peopleAddressPhone;
/**
* 是否是收货人最终收货地址。0代表是,1代表不是,默认为0
*/
int peopleAddressDefault;
/**
* 对应的站点id
*/
int peopleAddressAppId;
public int getPeopleAddressId() {
return peopleAddressId;
}
public void setPeopleAddressId(int peopleAddressId) {
this.peopleAddressId = peopleAddressId;
}
public int getPeopleAddressPeopleId() {
return peopleAddressPeopleId;
}
public void setPeopleAddressPeopleId(int peopleAddressPeopleId) {
this.peopleAddressPeopleId = peopleAddressPeopleId;
}
public String getPeopleAddressConsigneeName() {
return peopleAddressConsigneeName;
}
public void setPeopleAddressConsigneeName(String peopleAddressConsigneeName) {
this.peopleAddressConsigneeName = peopleAddressConsigneeName;
}
public String getPeopleAddressProvince() {
return peopleAddressProvince;
}
public void setPeopleAddressProvince(String peopleAddressProvince) {
this.peopleAddressProvince = peopleAddressProvince;
}
public String getPeopleAddressCity() {
return peopleAddressCity;
}
public void setPeopleAddressCity(String peopleAddressCity) {
this.peopleAddressCity = peopleAddressCity;
}
public String getPeopleAddressDistrict() {
return peopleAddressDistrict;
}
public void setPeopleAddressDistrict(String peopleAddressDistrict) {
this.peopleAddressDistrict = peopleAddressDistrict;
}
public String getPeopleAddressAddress() {
return peopleAddressAddress;
}
public void setPeopleAddressAddress(String peopleAddressAddress) {
this.peopleAddressAddress = peopleAddressAddress;
}
public String getPeopleAddressMail() {
return peopleAddressMail;
}
public void setPeopleAddressMail(String peopleAddressMail) {
this.peopleAddressMail = peopleAddressMail;
}
public String getPeopleAddressPhone() {
return peopleAddressPhone;
}
public void setPeopleAddressPhone(String peopleAddressPhone) {
this.peopleAddressPhone = peopleAddressPhone;
}
public int getPeopleAddressDefault() {
return peopleAddressDefault;
}
/**
* 推荐使用枚举类形参方法,此方法过时
* @param peopleAddressDefault
*/
@Deprecated
public void setPeopleAddressDefault(int peopleAddressDefault) {
this.peopleAddressDefault = peopleAddressDefault;
}
/**
* 枚举类形参方法
* @param peopleAddressDefault
*/
public void setPeopleAddressDefault(BaseEnum peopleAddressDefault) {
this.peopleAddressDefault = peopleAddressDefault.toInt();
}
public int getPeopleAddressAppId() {
return peopleAddressAppId;
}
public void setPeopleAddressAppId(int peopleAddressAppId) {
this.peopleAddressAppId = peopleAddressAppId;
}
}
package com.mingsoft.people.entity;
import com.mingsoft.base.entity.BaseEntity;
/**
* 开发平台用户
* @author 肥猪
* @version
* 版本号:100-000-000<br/>
* 创建日期:2016年1月25日<br/>
* 历史修订:<br/>
*/
public class PeopleOpenEntity extends PeopleUserEntity{
private int peopleOpenPeopleId;
private String peopleOpenId;
private int peopleOpenPlatform;
public int getPeopleOpenPeopleId() {
return peopleOpenPeopleId;
}
public void setPeopleOpenPeopleId(int peopleOpenPeopleId) {
this.peopleOpenPeopleId = peopleOpenPeopleId;
}
public String getPeopleOpenId() {
return peopleOpenId;
}
public void setPeopleOpenId(String peopleOpenId) {
this.peopleOpenId = peopleOpenId;
}
public int getPeopleOpenPlatform() {
return peopleOpenPlatform;
}
public void setPeopleOpenPlatform(int peopleOpenPlatform) {
this.peopleOpenPlatform = peopleOpenPlatform;
}
}
package com.mingsoft.people.entity;
/**
*
*
*
* <p>
* <b>铭飞科技</b>
* </p>
*
* <p>
* Copyright: Copyright (c) 2014 - 2015
* </p>
*
* @author 王天培
* QQ:78750478
*
* <p>
* Comments:学生
* </p>
*
* <p>
* Create Date:2014-12-18
* </p>
*
* <p>
* Modification history:
* </p>
*/
public class PeopleStudentEntity extends PeopleUserEntity{
private int peopleStudentPeopleId;
/**
* 学生学历
*/
private int peopleStudentEducation;
/**
* 学生入学年份
*/
private int peopleStudentIndate;
/**
* 大学所在城市
*/
private int peopleStudentCityID;
/**
* 学校名称
*/
private String peopleStudentSchool;
/**
* 所在院系
*/
private String peopleStudentDepartment;
/**
* 所在专业
*/
private String peopleStudentSpecialty;
/**
* 学生班级
*/
private String peopleStudentClass;
/**
* 学生学号
*/
private String peopleStudentNo;
/**
* 学生宿舍号
*/
private String peopleStudentRoom;
/**
* 获取学生所在城市
* @return
*/
public int getPeopleStudentCityID() {
return peopleStudentCityID;
}
/**
* 获取学生班级
* @return
*/
public String getPeopleStudentClass() {
return peopleStudentClass;
}
/**
* 获取学生所在系部
* @return
*/
public String getPeopleStudentDepartment() {
return peopleStudentDepartment;
}
/**
* 获取学生学历
* @return
*/
public int getPeopleStudentEducation() {
return peopleStudentEducation;
}
/**
* 获取学生入学年份
* @return
*/
public int getPeopleStudentIndate() {
return peopleStudentIndate;
}
/**
* 获取学生学号
* @return
*/
public String getPeopleStudentNo() {
return peopleStudentNo;
}
/**
*
* @return
*/
public int getPeopleStudentPeopleId() {
return peopleStudentPeopleId;
}
/**
* 获取学生宿舍号
* @return
*/
public String getPeopleStudentRoom() {
return peopleStudentRoom;
}
/**
* 获取学生所在学校
* @return
*/
public String getPeopleStudentSchool() {
return peopleStudentSchool;
}
/**
* 获取学生专业
* @return
*/
public String getPeopleStudentSpecialty() {
return peopleStudentSpecialty;
}
/**
* 设置学生所在城市
* @param peopleStudentCityID
*/
public void setPeopleStudentCityID(int peopleStudentCityID) {
this.peopleStudentCityID = peopleStudentCityID;
}
/**
* 设置学生班级
* @param peopleStudentClass
*/
public void setPeopleStudentClass(String peopleStudentClass) {
this.peopleStudentClass = peopleStudentClass;
}
/**
* 设置学生所在系部
* @param peopleStudentDepartment
*/
public void setPeopleStudentDepartment(String peopleStudentDepartment) {
this.peopleStudentDepartment = peopleStudentDepartment;
}
/**
* 设置学生学历
* @param peopleStudentEducation
*/
public void setPeopleStudentEducation(int peopleStudentEducation) {
this.peopleStudentEducation = peopleStudentEducation;
}
/**
* 设置学生入学年份
* @param peopleStudentIndate
*/
public void setPeopleStudentIndate(int peopleStudentIndate) {
this.peopleStudentIndate = peopleStudentIndate;
}
/**
* 设置学生学号
* @param peopleStudentNo
*/
public void setPeopleStudentNo(String peopleStudentNo) {
this.peopleStudentNo = peopleStudentNo;
}
/**
*
* @param peopleStudentPeopleId
*/
public void setPeopleStudentPeopleId(int peopleStudentPeopleId) {
this.peopleStudentPeopleId = peopleStudentPeopleId;
}
/**
* 设置学生的宿舍号
* @param peopleStudentRoom
*/
public void setPeopleStudentRoom(String peopleStudentRoom) {
this.peopleStudentRoom = peopleStudentRoom;
}
/**
* 设置学生所在学校
* @param peopleStudentSchool
*/
public void setPeopleStudentSchool(String peopleStudentSchool) {
this.peopleStudentSchool = peopleStudentSchool;
}
/**
* 设置用户专业
* @param peopleStudentSpecialty
*/
public void setPeopleStudentSpecialty(String peopleStudentSpecialty) {
this.peopleStudentSpecialty = peopleStudentSpecialty;
}
}
package com.mingsoft.people.parser;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;
import com.mingsoft.basic.parser.IGeneralParser;
@Component
@Scope("prototype")
public class PeopleParser extends IGeneralParser {
@Override
public String parse(String html,Object... obj) {
super.htmlContent = html;
init(obj);
htmlContent = parseGeneral();
return htmlContent;
}
}
package com.mingsoft.people.servlet;
import javax.servlet.http.HttpServletRequest;
import com.mingsoft.people.constant.e.SessionConstEnum;
import com.mingsoft.people.entity.PeopleEntity;
/**
* 铭飞会员系统
* @author 铭飞开发团队
* @version
* 版本号:100-000-000<br/>
* 创建日期:2016年3月31日<br/>
* 历史修订:<br/>
*/
public abstract class BaseServlet extends com.mingsoft.basic.servlet.BaseServlet{
/**
* 获取用户session.没有返回null
*/
protected PeopleEntity getPeopleBySession(HttpServletRequest request) {
Object obj = this.getSession(request, SessionConstEnum.PEOPLE_SESSION);
if (obj != null) {
return (PeopleEntity) obj;
}
return null;
}
/**
* 设置用户session
*
* @param request
* @param people
* 用户实体
*/
protected void setPeopleBySession(HttpServletRequest request, PeopleEntity people) {
this.setSession(request, SessionConstEnum.PEOPLE_SESSION, people);
}
/**
* 移除用户session
*
* @param request
*/
protected void removePeopleBySession(HttpServletRequest request) {
super.removeSession(request, SessionConstEnum.PEOPLE_SESSION);
}
}
/classes/ /classes/
/test-classes/
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment