Logistics_Manage_System/src/com/wt/jsonHandle/ResetPasswordJsonHandle.java
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
package com.wt.jsonHandle;
import java.util.HashMap;
import java.util.Map;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import org.apache.struts2.ServletActionContext;
import com.opensymphony.xwork2.ActionContext;
import com.opensymphony.xwork2.ActionSupport;
import com.wt.entity.User;
import com.wt.service.UserService;
public class ResetPasswordJsonHandle extends ActionSupport{
private static final long serialVersionUID = 1L;
private Map<String, Object> dataMap;
private UserService userService;
private Map<String, Object> session;
public void setUserService(UserService userService) {
this.userService = userService;
}
public String jsonResetPassword() {
dataMap = new HashMap<String, Object>();
session = ActionContext.getContext().getSession();
ActionContext context = ActionContext.getContext();
HttpServletRequest request = (HttpServletRequest)context.get(ServletActionContext.HTTP_REQUEST);
HttpSession httpSession = request.getSession();
// 获取用户输入的新密码等信息
String new_password = request.getParameter("new_password");
String captcha = request.getParameter("captcha");
String reset_captcha = request.getParameter("reset_captcha");
System.out.println("new_password --- " + new_password);
System.out.println("captcha --- " + captcha);
System.out.println("reset_captcha --- " + reset_captcha);
// 获取用户
String email = (String) httpSession.getAttribute("email");
User user = userService.emailCheck(email);
String validateCode = (String) httpSession.getAttribute("validateCode");
// 不区分大小写的操作,将获取的 captcha 参数转为大写字母
captcha = captcha.toUpperCase();
后面还有 34 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读 AI
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
