当前位置:网站首页>Book Mall system based on jsp+servlet+mysql
Book Mall system based on jsp+servlet+mysql
2022-07-20 17:44:00 【two billion sixteen million eight hundred and fifty-five thousa】
land
Registered members
Book sales
Book Search
Shopping cart management
Classification management
First level classification
Book management
Technical description
development tool : Idea/Eclipse
database : mysql
Jar Warehouse : Jar package
Front frame :jquery/Jsp
Back end framework : Jsp/Servlet
package cn.itcast.goods.admin.admin.web.servlet;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import cn.itcast.commons.CommonUtils;
import cn.itcast.goods.admin.admin.domain.Admin;
import cn.itcast.goods.admin.admin.service.AdminService;
import cn.itcast.servlet.BaseServlet;
public class AdminServlet extends BaseServlet {
private AdminService adminService = new AdminService();
/**
* Login function
* @param req
* @param resp
* @return
* @throws ServletException
* @throws IOException
*/
public String login(HttpServletRequest req, HttpServletResponse resp)
throws ServletException, IOException {
/*
* 1. Encapsulate form data to Admin
*/
Admin form = CommonUtils.toBean(req.getParameterMap(), Admin.class);
Admin admin = adminService.login(form);
if(admin == null) {
req.setAttribute("msg", " Wrong user name or password !");
return "/adminjsps/login.jsp";
}
req.getSession().setAttribute("admin", admin);
return "r:/adminjsps/admin/index.jsp";
}
}
边栏推荐
- Deep CNN based multi task learning for open set recognition
- DWB layer of data warehouse, 220620, HM,
- Towards Open World Object Detection
- D2 principle of multilayer neural network / principle of automatic derivation of neural network
- 220617, data warehouse DWD,
- 在GIS当侦探:通过ArcGIS Pro查找罪犯同伙
- 根据url下载图片保存到本地 有问题请留言
- 二叉树的深度优先和广度优先遍历方式的实现
- Devops failed!
- Huawei 5g is blocked in Europe, and another country has announced that it is considering banning it!
猜你喜欢
随机推荐
TCGA中RNA-counts数据中ensemble_ID转换成gene_ID的方法
设置默认为0但是添加为null
220617, data warehouse DWD,
Create a mini web server with vscode+express
tensorRT
020 machine learning data science package -numpy basic operation 1
SQL optimization limit1
Deep open intent classification with adaptive decision boundary aaai2021 interpretation of open set identification papers
sql优化 limit1
idea启动项目很慢
Doris connector and Flink CDC realize accurate access to MySQL database and table exactly once
016 机器学习数学基础:概论
PS high efficiency repair diagram
D1-从零理解神经网络
Unreal Engine01:环境配置
Eureka强制下线服务
七牛云刷新CDN缓存
Shadow Detection
NIO和IO
基于Jsp+Servlet+MySQL+Bootstrap简单的学生信息管理系统