DC00015基于java web校园网上购物系统

news/2024/9/29 3:26:57/

1、项目功能演示

DC00015【含配套文档】基于java web校园网上购物系统

2、项目功能描述

 基于java web校园网上购物系统分为用户和系统管理员两个角色。

2.1 用户功能

1、系统登录、用户注册、忘记密码
2、商品浏览、商品详情
3、购物车、付款
4、我的订单
5、修改密码、个人信息修改、退出系统

2.2 系统管理员功能

1、系统登录
2、商品管理:新增商品种类、商品种类列表、商品录入、商品列表
3、订单管理:订单列表、商品发货
4、用户管理:用户列表
5、系统管理:密码修改
6、退出系统

3、项目运行截图(部分) 

4、项目核心代码 

 4.1 beans.xml

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xmlns:context="http://www.springframework.org/schema/context"xmlns:aop="http://www.springframework.org/schema/aop"xmlns:tx="http://www.springframework.org/schema/tx"xsi:schemaLocation="http://www.springframework.org/schema/beanshttp://www.springframework.org/schema/beans/spring-beans-2.5.xsdhttp://www.springframework.org/schema/contexthttp://www.springframework.org/schema/context/spring-context-2.5.xsdhttp://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsdhttp://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd"><context:annotation-config/><!-- 打开自动扫描 --><context:component-scan base-package="com.cds" /><!-- 配置数据源和数据库连接池 -->
<bean id="dataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource" destroy-method="close"><property name="driverClass" value="org.gjt.mm.mysql.Driver"/><property name="jdbcUrl" value="jdbc:mysql://localhost:3305/webshopping?useUnicode=true&amp;characterEncoding=UTF8" /><property name="user" value="root"/><property name="password" value="root"/><!--初始化时获取的连接数,取值应在minPoolSize与maxPoolSize之间。Default: 3 --><property name="initialPoolSize" value="1"/><!--连接池中保留的最小连接数。--><property name="minPoolSize" value="1"/>	<!--连接池中保留的最大连接数。Default: 15 --><property name="maxPoolSize" value="100"/><!--最大空闲时间,60秒内未使用则连接被丢弃。若为0则永不丢弃。Default: 0 --><property name="maxIdleTime" value="60"/>	<!--当连接池中的连接耗尽的时候c3p0一次同时获取的连接数。Default: 3 --><property name="acquireIncrement" value="5"/>	<!--每60秒检查所有连接池中的空闲连接。Default: 0 --><property name="idleConnectionTestPeriod" value="60"/></bean><!-- 将数据源注入到Spring的sessionFactory中 -->
<!--<bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">-->
<bean id="sessionFactory" class="org.springframework.orm.hibernate3.annotation.AnnotationSessionFactoryBean"> <property name="dataSource" ref="dataSource"/><property name="packagesToScan"><list><value>com.cds.po</value></list></property><property name="hibernateProperties"><props><prop key="hibernate.dialect">org.hibernate.dialect.MySQL5Dialect</prop><prop key="hibernate.hbm2ddl.auto">update</prop><prop key="hibernate.show_sql">true</prop><prop key="format_sql">true</prop></props></property></bean><!-- 配置spring的HibernateTemplate的事务模版 --><bean id="hibernateTemplate" class="org.springframework.orm.hibernate3.HibernateTemplate"><property name="sessionFactory" ref="sessionFactory"></property></bean></beans>	

 4.2 web.xml

<?xml version="1.0" encoding="utf-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xmlns="http://java.sun.com/xml/ns/javaee"xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" version="2.5"><context-param><param-name>contextConfigLocation</param-name><param-value>classpath:beans.xml</param-value></context-param><listener><listener-class>org.springframework.web.context.ContextLoaderListener</listener-class></listener><context-param><param-name>log4jConfigLocation</param-name><param-value>classpath:log4j.properties</param-value></context-param><listener><listener-class>org.springframework.web.util.Log4jConfigListener</listener-class></listener><filter><filter-name>struts2</filter-name><filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class></filter><filter-mapping><filter-name>struts2</filter-name><url-pattern>/*</url-pattern></filter-mapping><filter><filter-name>encoding</filter-name><filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class><init-param><param-name>encoding</param-name><param-value>utf-8</param-value></init-param></filter><filter-mapping><filter-name>encoding</filter-name><url-pattern>*.action</url-pattern></filter-mapping><context-param><param-name>webAppRootKey</param-name><param-value>webShopping</param-value></context-param><welcome-file-list><welcome-file>index.jsp</welcome-file></welcome-file-list>
</web-app>

 4.3 struct.xml

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE struts PUBLIC"-//Apache Software Foundation//DTD Struts Configuration 2.1//EN""http://struts.apache.org/dtds/struts-2.1.dtd"><struts>
<!-- 明确配置一下,会被第3方插件替换 --><constant name="struts.objectFactory" value="spring" /><constant name="struts.devMode" value="true" /><constant name="struts.i18n.encoding" value="UTF-8" /><!-- 文件上传大小限制 为10M --><constant name="struts.multipart.maxSize" value="10701096" /><constant name="struts.multipart.saveDir" value="/tmp"/><package name="webShopping"  extends="struts-default"><!-- 用户 --><action name="UserAction" class="userAction"><result name="login" >/login_error.jsp</result><result name="index">/login_success.jsp</result><result name="regsuccess">/register.jsp</result><result name="regerror">/register.jsp</result><result name="success">/reg_success.jsp</result><result name="error">/reg_error.jsp</result><result name="logout">/index.jsp</result><result name="updateUser" >/userInfo.jsp</result><result name="listUser" >/admin/include/user/userList.jsp</result><result name="queryUser" >/admin/include/user/userQuery.jsp</result><result name="findUsernull">/findPass.jsp</result><result name="findUser" >/resetPass.jsp</result><result name="updatePass">/resetPass.jsp</result><result name="upPass">/updatePass.jsp</result><result name="deleteUser">/admin/include/user/userList.jsp</result></action><!-- 管理员 --><action name="AdminAction" class="adminAction"><result name="login" >/admin/login.jsp</result><result name="index">/admin/index.jsp</result><result name="logout">/admin/login.jsp</result><result name="updateAdmin">/admin/include/admin/amend.jsp</result></action><!-- 商品种类 --><action name="CommodityClassAction" class="commodityClassAction"><result name="addCommodityClass" >/admin/include/commodityClass/commodityClassAdd.jsp</result><result name="listCommodityClass" >/admin/include/commodityClass/commodityClassList.jsp</result><result name="deleteCommodityClass" type="redirect">CommodityClassAction!listCommodityClass.action</result></action><!-- 商品 --><action name="CommodityAction" class="commodityAction"><result name="addComm" >/admin/include/commodity/commodityAdd.jsp</result><result name="addCommoditySuccess" >/admin/include/commodity/commodityAdd.jsp</result><result name="addCommodityError" >/admin/include/commodity/commodityAdd.jsp</result><result name="listCommodity" >/admin/include/commodity/commodityList.jsp</result><result name="deleteCommodity" type="redirect">CommodityAction!listCommodity.action</result><result name="findCommodityById" >/showdetails.jsp</result><result name="findCommodityByName" >/showByName.jsp</result><result name="findCommodityByClass" >/showByClass.jsp</result></action><!-- 购物车 --><action name="AddToCarAction" class="addToCarAction"><result name="success" >/showCar.jsp</result><result name="error" >/showCarnull.jsp</result><result name="delete" >/showCar.jsp</result></action><!-- 订单 --><action name="OrderFormAction" class="orderFormAction"><result name="listOrderForm" >/admin/include/order/orderList.jsp</result><result name="conOrder" >/admin/include/order/orderList.jsp</result><result name="queryOrder" >/admin/include/order/orderQuery.jsp</result><result name="findOrderFormByUserName">/showOrderForm.jsp</result><result name="payOrderForm">/payMent.jsp</result> <result name="addOrderForm" >/payMent.jsp</result><result name="payOrder">/showOrderForm.jsp</result> </action><!-- 留言 --><action name="MessageAction" class="messageAction"><result name="listMessage" >/admin/include/message/messageList.jsp</result><result name="queryMessage" >/admin/include/message/messageQuery.jsp</result><result name="deleteMessage" type="redirect">MessageAction!listMessage.action</result></action><!-- 主页 --><action name="GoIndexAction" class="goIndexAction"><result name="success">/index.jsp</result></action></package>
</struts>

5、项目内容包含

6、项目获取

6.1 方式一 

私信或者扫描下方名片获取完整项目。

6.2 方式二

点击此处直接获取万丈项目。 


http://www.ppmy.cn/news/1530876.html

相关文章

vue3中echarts柱状图横轴文字太多放不下怎么解决

问题&#xff1a;在做数据展示的时候&#xff0c;使用的是echarts&#xff0c;遇到了个问题&#xff0c;就是数据过多&#xff0c;但是设置的x轴的文字名称又太长&#xff0c;往往左边第一个或右边最后一个的名称展示不全&#xff0c;只有半个。 从网上找到了几种办法&#xff…

openmv与stm32通信

控制小车视觉循迹使用 OpenMV 往往是不够的。一般使用 OpenMV 对图像进行处理&#xff0c;将处理过后的数据使用串口发送给STM32&#xff0c;使用STM32控制小车行驶。本文主要讲解 OpenMV 模块与 STM32 间的串口通信以及两种循迹方案&#xff0c;分别是划分检测区域和线性回归。…

SpringBoot整合邮件功能(带附件)

前言 这篇文章只是记录一下在开发中使用邮箱功能 本人在项目中需要使用邮箱发送带附件的邮件&#xff0c;我们的附件可能是在线的阿里云OSS,也可能是系统生成的Excel&#xff0c;写了一个工具类&#xff0c;方便使用。 整合流程 QQ邮箱作为案例 1、添加依赖 <dependency&g…

服务器配置虚拟环境及离线安装python

本篇文章基于已经装好conda环境进行哈&#xff0c;不会安装conda可参考服务器离线安装anaconda-CSDN博客 1.打印现有虚拟环境列表 conda env list&#xff0c;可以看见我现在有base、ai、py38三个环境 2.删除指定虚拟环境 conda remove -n py38 --all&#xff0c;回车后输入ye…

Qwen2-VL论文阅读笔记

第1章介绍 论文亮点&#xff1a; 1、 the Naive Dynamic Resolution mechanism 2、Multimodal Rotary Position Embedding (M-RoPE) 2D Rotary Position Embedding 3、统一图片和视频的处理范式、增i强视觉感知能力 4、LVLMs的scaling laws&#xff1a;2B、8B、72B 5、 dynamic…

SpringBoot之登录校验关于JWT、Filter、interceptor、异常处理的使用

什么是登录校验&#xff1f; 所谓登录校验&#xff0c;指的是我们在服务器端接收到浏览器发送过来的请求之后&#xff0c;首先我们要对请求进行校验。先要校验一下用户登录了没有&#xff0c;如果用户已经登录了&#xff0c;就直接执行对应的业务操作就可以了&#xff1b;如果用…

甘蔗茎节检测系统源码分享

甘蔗茎节检测检测系统源码分享 [一条龙教学YOLOV8标注好的数据集一键训练_70全套改进创新点发刊_Web前端展示] 1.研究背景与意义 项目参考AAAI Association for the Advancement of Artificial Intelligence 项目来源AACV Association for the Advancement of Computer Vis…

List几种遍历方法速度

准备数据 ArrayList<Integer> list new ArrayList<Integer>();for (int i 0; i < 100000000; i) {list.add(i); }1.for循环 for (int i 0; i < list.size(); i) {Integer str list.get(i); }2.for-each循环 for (Integer vo:list) {}3.Lambda list.forEa…