基于javaweb+mysql的在线商城购物商城水果蔬菜批发商城(前台、后台)
运行环境
Java≥8、MySQL≥5.7、Tomcat≥8
开发工具
eclipse/idea/myeclipse/sts等均可配置运行
适用
课程设计,大作业,毕业设计,项目练习,学习演示等
功能说明
后台管理:用户、新闻公告、果蔬类型、城市信息、配货点、果蔬商品、订单、评价等管理等
前台购物:注册登录、公告、商品、购买、评价等
idea:
eclipse/myeclipse:
前台购物:
后台管理:
技术框架
JavaBean MVC JSP SSM(Spring SpringMVC MyBatis) MySQL Bootstrap JavaScript
@RequestMapping("getAllPeihuo.action")
public String getAllPeihuo(String number) {
List<Peihuo> peihuoList = this.peihuoService.getAllPeihuo();
PageHelper.getPage(peihuoList, "peihuo", null, null, 10, number, this.getRequest(), null);
return "admin/listpeihuo";
}
// 显示全部数据
@RequestMapping("getNetWork.action")
public String getNetWork(String number) {
List<Peihuo> peihuoList = this.peihuoService.getAllPeihuo();
PageHelper.getPage(peihuoList, "peihuo", null, null, 10, number, this.getRequest(), null);
return "users/network";
}
return day;
}
public static String getNowMonth(String sdate) {
sdate = sdate.substring(0, 8) + "01";
Date date = VeDate.strToDate(sdate);
Calendar c = Calendar.getInstance();
c.setTime(date);
int u = c.get(Calendar.DAY_OF_WEEK);
String newday = VeDate.getNextDay(sdate, (1 - u) + "");
return newday;
}
public static String getNo(int k) {
return getUserDate("yyyyMMddhhmmss") + getRandom(k);
}
public static String getRandom(int i) {
border: 0;
background-color: #005aa9;
font-weight: bold;
}
</style>
<script type="text/javascript">
var $s = function(id) {
return "string" == typeof id ? document.getElementById(id) : id;
};
var Class = {
create : function() {
return function() {
this.initialize.apply(this, arguments);
}
}
}
Object.extend = function(destination, source) {
for ( var property in source) {
destination[property] = source[property];
jiancai.setHits(name);
}
if ("sellnum".equals(cond)) {
jiancai.setSellnum(name);
}
if ("contents".equals(cond)) {
jiancai.setContents(name);
}
}
List<String> nameList = new ArrayList<String>();
List<String> valueList = new ArrayList<String>();
nameList.add(cond);
valueList.add(name);
PageHelper.getPage(this.jiancaiService.getJiancaiByLike(jiancai), "jiancai", nameList, valueList, 10, number, this.getRequest(), "query");
name = null;
cond = null;
return "admin/queryjiancai";
}
// 确认收货
@RequestMapping("over.action")
public String over(String id) {
this.front();
if (this.getSession().getAttribute("userid") == null) {
return "redirect:/index/preLogin.action"