package com.controller;
import java.io.File;
import java.io.IOException;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.io.PrintWriter;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;
import com.entity.Xiaoshouxinxi;
import com.server.XiaoshouxinxiServer;
import com.util.PageBean;
import net.sf.json.JSONObject;
import com.util.db;
import java.sql.SQLException;
import java.sql.*;
@Controller
public class XiaoshouxinxiController {
@Resource
private XiaoshouxinxiServer xiaoshouxinxiService;
@RequestMapping("addXiaoshouxinxi.do")
public String addXiaoshouxinxi(HttpServletRequest request,Xiaoshouxinxi xiaoshouxinxi,HttpSession session) throws SQLException{
Timestamp time=new Timestamp(System.currentTimeMillis());
xiaoshouxinxi.setAddtime(time.toString().substring(0, 19));
xiaoshouxinxiService.add(xiaoshouxinxi);
db dbo = new db();dbo.hsgexecute("update kucunxinxi set kucun=kucun-"+xiaoshouxinxi.getXiaoshoushuliang()+" where shangpinmingcheng='"+xiaoshouxinxi.getShangpinmingcheng()+"'");
session.setAttribute("backxx", "添加成功");
session.setAttribute("backurl", request.getHeader("Referer"));
//session.setAttribute("backurl", "xiaoshouxinxiList.do");
return "redirect:postback.jsp";
//return "redirect:xiaoshouxinxiList.do";
}
// 处理编辑
@RequestMapping("doUpdateXiaoshouxinxi.do")
public String doUpdateXiaoshouxinxi(int id,ModelMap map,Xiaoshouxinxi xiaoshouxinxi){
xiaoshouxinxi=xiaoshouxinxiService.getById(id);
map.put("xiaoshouxinxi", xiaoshouxinxi);
return "xiaoshouxinxi_updt";
}
// 后台详细
@RequestMapping("xiaoshouxinxiDetail.do")
public String xiaoshouxinxiDetail(int id,ModelMap map,Xiaoshouxinxi xiaoshouxinxi){
xiaoshouxinxi=xiaoshouxinxiService.getById(id);
map.put("xiaoshouxinxi", xiaoshouxinxi);
return "xiaoshouxinxi_detail";
}
// 前台详细
@RequestMapping("xsxxDetail.do")
public String xsxxDetail(int id,ModelMap map,Xiaoshouxinxi xiaoshouxinxi){
xiaoshouxinxi=xiaoshouxinxiService.getById(id);
map.put("xiaoshouxinxi", xiaoshouxinxi);
return "xiaoshouxinxidetail";
}
//
@RequestMapping("updateXiaoshouxinxi.do")
public String updateXiaoshouxinxi(int id,ModelMap map,Xiaoshouxinxi xiaoshouxinxi,HttpServletRequest request,HttpSession session){
xiaoshouxinxiService.update(xiaoshouxinxi);
session.setAttribute("backxx", "修改成功");
session.setAttribute("backurl", request.getHeader("Referer"));
return "redirect:postback.jsp";
//String url = request.getHeader("Referer");
//return "redirect:"+url;
//return "redirect:xiaoshouxinxiList.do";
}
// 分页查询
@RequestMapping("xiaoshouxinxiList.do")
public String xiaoshouxinxiList(@RequestParam(value="page",required=false)String page,
ModelMap map,HttpSession session,Xiaoshouxinxi xiaoshouxinxi, String bianhao, String shangpinmingcheng, String shangpinleixing, String kucun, String xiaoshoushuliang1,String xiaoshoushuliang2, String xiaoshoujiage1,String xiaoshoujiage2, String xiaoshouzonge, String xiaoshouriqi1,String xiaoshouriqi2, String xiaoshouyuan, String issh){
if(page==null||page.equals("")){
page="1";
}
PageBean pageBean=new PageBean(Integer.parseInt(page), 15);
Map<String, Object> pmap=new HashMap<String,Object>();
pmap.put("pageno", pageBean.getStart());
pmap.put("pageSize", 15);
if(bianhao==null||bianhao.equals("")){pmap.put("bianhao", null);}else{pmap.put("bianhao", bianhao);}
if(shangpinmingcheng==null||shangpinmingcheng.equals("")){pmap.put("shangpinmingcheng", null);}else{pmap.put("shangpinmingcheng", shangpinmingcheng);}
if(shangpinleixing==null||shangpinleixing.equals("")){pmap.put("shangpinleixing", null);}else{pmap.put("shangpinleixing", shangpinleixing);}
if(kucun==null||kucun.equals("")){pmap.put("kucun", null);}else{pmap.put("kucun", kucun);}
if(xiaoshoushuliang1==null||xiaoshoushuliang1.equals("")){pmap.put("xiaoshoushuliang1", null);}else{pmap.put("xiaoshoushuliang1", xiaoshoushuliang1);}
if(xiaoshoushuliang2==null||xiaoshoushuliang2.equals("")){pmap.put("xiaoshoushuliang2", null);}else{pmap.put("xiaoshoushuliang2", xiaoshoushuliang2);}
if(xiaoshoujiage1==null||xiaoshoujiage1.equals("")){pmap.put("xiaoshoujiage1", null);}else{pmap.put("xiaoshoujiage1", xiaoshoujiage1);}
if(xiaoshoujiage2==null||xiaoshoujiage2.equals("")){pmap.put("xiaoshoujiage2", null);}else{pmap.put("xiaoshoujiage2", xiaoshoujiage2);}
if(xiaoshouzonge==null||xiaoshouzonge.equals("")){pmap.put("xiaoshouzonge", null);}else{pmap.put("xiaoshouzonge", xiaoshouzonge);}
if(xiaoshouriqi1==null||xiaoshouriqi1.equals("")){pmap.put("xiaoshouriqi1", null);}else{pmap.put("xiaoshouriqi1", xiaoshouriqi1);}
if(xiaoshouriqi2==null||xiaoshouriqi2.equals("")){pmap.put("xiaoshouriqi2", null);}else{pmap.put("xiaoshouriqi2", xiaoshouriqi2);}
if(xiaoshouyuan==null||xiaoshouyuan.equals("")){pmap.put("xiaoshouyuan", null);}else{pmap.put("xiaoshouyuan", xiaoshouyuan);}
int total=xiaoshouxinxiService.getCount(pmap);
pageBean.setTotal(total);
List<Xiaoshouxinxi> list=xiaoshouxinxiService.getByPage(pmap);
map.put("page", pageBean);
map.put("list", list);
session.setAttribute("p", 1);
return "xiaoshouxinxi_list";
}
@RequestMapping("xiaoshouxinxi_yanben1.do")
public String xiaoshouxinxi_yanben1(@RequestParam(value="page",required=false)String page,
ModelMap map,HttpSession session,Xiaoshouxinxi xiaoshouxinxi, String bianhao, String shangpinmingcheng, String shangpinleixing, String kucun, String xiaoshoushuliang1,String xiaoshoushuliang2, String xiaoshoujiage1,String xiaoshoujiage2, String xiaoshouzonge, String xiaoshouriqi1,String xiaoshouriqi2, String xiaoshouyuan, String issh){
if(page==null||page.equals("")){
page="1";
}
PageBean pageBean=new PageBean(Integer.parseInt(page), 15);
Map<String, Object> pmap=new HashMap<String,Object>();
pmap.put("pageno", pageBean.getStart());
pmap.put("pageSize", 15);
if(bianhao==null||bianhao.equals("")){pmap.put("bianhao", null);}else{pmap.put("bianhao", bianhao);}
if(shangpinmingcheng==null||shangpinmingcheng.equals("")){pmap.put("shangpinmingcheng", null);}else{pmap.put("shangpinmingcheng", shangpinmingcheng);}
if(shangpinleixing==null||shangpinleixing.equals("")){pmap.put("shangpinleixing", null);}else{pmap.put("shangpinleixing", shangpinleixing);}
if(kucun==null||kucun.equals("")){pmap.put("kucun", null);}else{pmap.put("kucun", kucun);}
if(xiaoshoushuliang1==null||xiaoshoushuliang1.equals("")){pmap.put("xiaoshoushuliang1", null);}else{pmap.put("xiaoshoushuliang1", xiaoshoushuliang1);}
if(xiaoshoushuliang2==null||xiaoshoushuliang2.equals("")){pmap.put("xiaoshoushuliang2", null);}else{pmap.put("xiaoshoushuliang2", xiaoshoushuliang2);}
if(xiaoshoujiage1==null||xiaoshoujiage1.equals("")){pmap.put("xiaoshoujiage1", null);}else{pmap.put("xiaoshoujiage1", xiaoshoujiage1);}
if(xiaoshoujiage2==null||xiaoshoujiage2.equals("")){pmap.put("xiaoshoujiage2", null);}else{pmap.put("xiaoshoujiage2", xiaoshoujiage2);}
if(xiaoshouzonge==null||xiaoshouzonge.equals("")){pmap.put("xiaoshouzonge", null);}else{pmap.put("xiaoshouzonge", xiaoshouzonge);}
if(xiaoshouriqi1==null||xiaoshouriqi1.equals("")){pmap.put("xiaoshouriqi1", null);}else{pmap.put("xiaoshouriqi1", xiaoshouriqi1);}
if(xiaoshouriqi2==null||xiaoshouriqi2.equals("")){pmap.put("xiaoshouriqi2", null);}else{pmap.put("xiaoshouriqi2",
没有合适的资源?快使用搜索试试~ 我知道了~
基于SSM框架超市管理系统设计毕业设计程序
共491个文件
jsp:94个
java:83个
class:83个
需积分: 50 36 下载量 151 浏览量
2020-07-30
11:11:04
上传
评论 12
收藏 28.22MB ZIP 举报
温馨提示
采用java技术构建的一个管理系统。整个开发过程首先对系统进行需求分析,得出系统的主要功能。接着对系统进行总体设计和详细设计。总体设计主要包括系统功能设计、系统总体结构设计、系统数据结构设计和系统安全设计等;详细设计主要包括系统数据库访问的实现,主要功能模块的具体实现,模块实现关键代码等。最后对系统进行功能测试,并对测试结果进行分析总结。 包括程序毕设程序源代码一份,数据库一份,完美运行。配置环境里面有说明。如有不会运行源代码私信。
资源推荐
资源详情
资源评论
收起资源包目录
基于SSM框架超市管理系统设计毕业设计程序 (491个子文件)
KucunyuanController.class 18KB
Info.class 18KB
YuangongxinxiController.class 18KB
XiaoshouyuanController.class 18KB
CaigouyuanController.class 18KB
KucunxinxiController.class 17KB
XiaoshouxinxiController.class 16KB
CaigouxinxiController.class 16KB
db.class 14KB
YonghuzhuceController.class 9KB
VeDate.class 9KB
AllusersController.class 7KB
ShoucangjiluController.class 7KB
LiuyanbanController.class 7KB
XinwentongzhiController.class 6KB
YouqinglianjieController.class 6KB
PinglunController.class 6KB
Yonghuzhuce.class 4KB
Kucunyuan.class 4KB
StrUtil.class 4KB
Yuangongxinxi.class 3KB
Caigouyuan.class 3KB
Xiaoshouyuan.class 3KB
Xiaoshouxinxi.class 3KB
Caigouxinxi.class 3KB
Kucunxinxi.class 3KB
LiuyanbanServerImpi.class 3KB
YouqinglianjieServerImpi.class 3KB
XiaoshouxinxiServerImpi.class 3KB
YuangongxinxiServerImpi.class 3KB
XiaoshouyuanServerImpi.class 3KB
CaigouxinxiServerImpi.class 3KB
YonghuzhuceServerImpi.class 3KB
KucunxinxiServerImpi.class 3KB
CaigouyuanServerImpi.class 3KB
KucunyuanServerImpi.class 3KB
XinwentongzhiServerImpi.class 3KB
AllusersServerImpi.class 3KB
Xinwentongzhi.class 2KB
Liuyanban.class 2KB
ShoucangjiluServerImpi.class 2KB
PinglunServerImpi.class 2KB
hsgloginController.class 2KB
Pinglun.class 2KB
Shoucangjilu.class 2KB
Md5.class 2KB
SetChar.class 2KB
IndexController.class 2KB
Youqinglianjie.class 2KB
Allusers.class 2KB
PageBean.class 1KB
PageInfo.class 1KB
testFilter.class 1KB
YouqinglianjieMapper.class 1KB
YuangongxinxiMapper.class 1020B
XinwentongzhiMapper.class 1020B
XiaoshouxinxiMapper.class 1020B
LiuyanbanMapper.class 1016B
XiaoshouyuanMapper.class 1009B
CaigouxinxiMapper.class 998B
YonghuzhuceMapper.class 998B
KucunxinxiMapper.class 987B
CaigouyuanMapper.class 987B
KucunyuanMapper.class 976B
CheckCode.class 922B
AllusersMapper.class 898B
ShoucangjiluMapper.class 898B
YouqinglianjieServer.class 896B
XiaoshouxinxiServer.class 885B
YuangongxinxiServer.class 885B
XiaoshouyuanServer.class 874B
YonghuzhuceServer.class 863B
CaigouxinxiServer.class 863B
LiuyanbanServer.class 860B
PinglunMapper.class 858B
KucunxinxiServer.class 852B
CaigouyuanServer.class 852B
KucunyuanServer.class 841B
XinwentongzhiServer.class 796B
ShoucangjiluServer.class 763B
AllusersServer.class 763B
PinglunServer.class 723B
Constant.class 674B
.classpath 1KB
org.eclipse.wst.common.component 592B
org.eclipse.wst.jsdt.ui.superType.container 49B
layout.css 9KB
base.css 5KB
datepicker.css 4KB
datepicker.css 4KB
CssAdmin.css 3KB
woncore.css 3KB
dtree.css 795B
WdatePicker.css 158B
h1_01.gif 38KB
hsg2.gif 21KB
dl.gif 6KB
hsg1.gif 6KB
hsg3.gif 3KB
loading.gif 2KB
共 491 条
- 1
- 2
- 3
- 4
- 5
资源评论
程序VX_sheji288
- 粉丝: 153
- 资源: 191
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- TRIZ矛盾矩阵表.pdf
- ssm基于SSM框架的购物商城系统+jsp.zip
- ssm基于SSM框架的个人博客网站的设计与实现+vue.zip
- ssm基于SSM框架的金鱼销售平台的开发和实现+jsp.zip
- ssm基于SSM框架的德云社票务系统的设计与实现+vue.zip
- ssm基于SSM框架的安全教育平台+vue.zip
- ssm基于ssm框架的大学生就业信息平台+jsp.zip
- ssm基于SSM的养老院老人健康监护平台设计与实现+vue.zip
- ssm基于ssm的疫情物质管理系统+jsp.zip
- ssm基于SSM的药房药品采购集中管理系统的设计与实现+vue.zip
- ssm基于SSM的乡镇篮球队管理系统+jsp.zip
- ssm基于ssm的新能源汽车在线租赁管理系统+vue.zip
- ssm基于SSM的校园二手物品交易平台+vue.zip
- ssm基于ssm的人才招聘网站+jsp.zip
- ssm基于SSM的高校疫情管理系统设计与实现+vue.zip
- ssm基于ssm的线上课程管理系统+jsp.zip
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功