当前位置:网站首页>基于SSH的网上商城设计
基于SSH的网上商城设计
2022-06-30 16:38:00 【biyezuopinvip】
资源下载地址:https://download.csdn.net/download/sheziqiong/85836171
资源下载地址:https://download.csdn.net/download/sheziqiong/85836171
目 录
摘 要 1
ABSTRACT 2
第一章 绪论 5
1.1 课题背景 5
1.2 目的和意义 5
1.3 系统设计思想 6
第二章 系统开发工具及技术背景 7
2.1 系统运行平台设置 7
2.1.1硬件环境 7
2.1.2软件环境 7
2.2 开发工具及技术简介 7
2.2.1开发工具简介 7
2.2.2技术简介 8
第三章 系统分析 9
3.1 可行性分析 9
3.1.1经济可行性 9
3.1.2技术可行性 9
3.1.3运行可能性 9
3.2 需求分析 9
3.2.1服务需求 9
3.2.2购物主流程 9
3.3 功能分析 10
3.3.1系统前台功能需求 10
3.3.2系统后台功能需求 11
第四章 数据库设计 12
4.1 数据分析 12
4.2 数据库的详细设计 12
4.2.1数据库E-R图 12
4.2.2数据库表 13
第五章 详细设计与实现 16
5.1 系统前台基本功能设计与实现 16
5.1.1注册 16
5.1.2登录和验证 18
5.1.3用户注销 19
5.1.4商品展示模块设计与实现 19
5.1.5购物车模块的设计与实现 20
5.1.7查看订单模块的设计与实现 22
5.2 系统后台管理功能设计与实现 23
5.2.1基本信息管理设计与实现 23
5.2.2订单信息管理设计与实现 23
5.2.3商品信息管理设计与实现 24
第六章 系统测试与性能分析 25
6.1 前台首页的测试 25
6.2 购物车模块的测试 25
6.3 用户注册模块的测试 26
6.4 商品管理模块的测试 26
6.4.1添加功能的测试 26
6.4.2删除功能的测试 27
第七章 结论 28
参考文献 29
致 谢 30
第四章 数据库设计
对于一个电子商务网站而言,为了支持较大的访问量带来的数据访问需求,使用桌面型的数据库管理系统是不能满足需要的,而且安全性也没有充分保障。因此,需要使用大型商业化企业级服务用途的数据库管理系统,如Mysql,Oracle等。本系统采用Mysql 数据库管理系统。
4.1 数据分析
对于本系统的数据库的需求而言,由于其主要是用于信息的提供、保存、更新和查询等。因此,需要分析该系统功能所隐含的对数据应用的需求,从而确定数据库的结构。
1)用户注册、登录、验证等功能需要对用户信息建立数据表,其中的数据项可能包括用户E_mail、昵称、密码、住址等;
2)查看商品分类信息和商品详细信息等功能既需要对商品大小类别进行管理,也需要针对每一个商品进行管理,因此至少需要两张数据表;
3)用户购物后产生的订单需要进行管理,这里也包括订单的基本信息和详细信息等;
4)订单生成后,在订单处理的过程中,需要出货等,因此可能需要记录订单的发送情况;
5)需要系统管理员对该系统进行管理,因而需要建立管理员信息数据表,其中的数据项包括管理员ID、密码等。
这样,至少要创建如下的数据结构和数据项
1)用户信息,包括用户ID,用户名等数据项;
2)管理员信息,包括管理员ID,密码等数据项;
3)商品信息,包括商品ID,产品名称、单价、特价等数据项;
4)商品一级类别信息,包括电子ID,类别名称等数据项;
5)商品二级类别信息,包括电子ID,类别名称等数据项;
6)订单信息,包括订单ID,用户编号,订货地址等数据项;
7)订单明细信息,包括订单ID,商品ID,订货时间等数据项;
4.2 数据库的详细设计
4.2.1 数据库E-R图
图4.1 数据库E-R图
部分代码:
package cn.itcast.shop.index.action;
import java.util.List;
import cn.itcast.shop.category.service.CategoryService;
import cn.itcast.shop.category.vo.Category;
import cn.itcast.shop.product.service.ProductService;
import cn.itcast.shop.product.vo.Product;
import com.opensymphony.xwork2.ActionContext;
import com.opensymphony.xwork2.ActionSupport;
/** * 首页访问的Action * * @author Kang * */
public class IndexAction extends ActionSupport {
/** * 注入一级分类的service */
private static final long serialVersionUID = 1L;
private CategoryService categoryService;
//注入ProductService
private ProductService productService;
public void setCategoryService(CategoryService categoryService) {
this.categoryService = categoryService;
}
public void setProductService(ProductService productService) {
this.productService = productService;
}
/** * 执行的访问首页的方法: */
public String execute() {
// 查询所有一级分类的方法
List<Category> cList = categoryService.findAll();
// 将一级分类的数据存入到session的范围
ActionContext.getContext().getSession().put("cList", cList);
//查询热门商品
List<Product> hList=productService.findHot();
//保存到值栈中去
ActionContext.getContext().getValueStack().set("hList", hList);
//查询最新商品
List<Product> nList=productService.findNew();
//保存到值栈中
ActionContext.getContext().getValueStack().set("nList", nList);
return "index";
}
}



















资源下载地址:https://download.csdn.net/download/sheziqiong/85836171
资源下载地址:https://download.csdn.net/download/sheziqiong/85836171
边栏推荐
- Write the simplest small program in C language Hello World
- Login box tricks
- IEEE TBD SCI impact factor increased to 4.271, ranking Q1!
- Several points in MySQL that are easy to ignore and forget
- Ten thousand volumes - list sorting [01]
- 腾讯云安装mysql数据库
- Ardunio esp32 obtains real-time temperature and humidity in mqtt protocol (DH11)
- Rainbow Brackets 插件的快捷键
- 如何写一个技术方案
- 每日面试1题-如何防止CDN防护被绕过
猜你喜欢

Develop those things: how to add text watermarks to videos?

Implementation of graduation project management system based on SSM

Course design for the end of the semester: product sales management system based on SSM

svg实现的订票UI效果

水平视觉错误效果js特效代码

Six photos vous montrent pourquoi TCP serre la main trois fois?

Exploration and practice of "flow batch integration" in JD

Advanced Mathematics (Seventh Edition) Tongji University General exercises one person solution

New skill: accelerate node through code cache JS startup

Booking UI effect implemented by svg
随机推荐
5G商用三年,未来创新何去何从?
. Net ORM framework hisql practice - Chapter 1 - integrating hisql
Plane intersection and plane equation
New research of HKUST & MsrA: about image to image conversion, finishing is all you need
基于eNSP的校园网设计的仿真模拟
Flutter custom component
Small tools (3) integration knife4j3.0.3 interface document
leetcode:787. The cheapest transfer flight in station K [k-step shortest path + DFS memory + defaultdict (dict)]
Development details of NFT casting trading platform
Radio and television 5g officially set sail, attracting attention on how to apply the golden band
Daily question brushing record (IX)
.NET ORM框架HiSql实战-第一章-集成HiSql
How to write a technical proposal
Develop those things: how to add text watermarks to videos?
【剑指Offer】52. 两个链表的第一个公共节点
. Net ORM framework hisql practice - Chapter 1 - integrating hisql
Generate confrontation network, from dcgan to stylegan, pixel2pixel, face generation and image translation.
[sword finger offer] sword finger offer 53 - ii Missing numbers from 0 to n-1
大文件处理(上传,下载)思考
Daily interview 1 question - how to prevent CDN protection from being bypassed