华北水利水电学院毕业论文
IOException {
StockListDaoImpl dao=(StockListDaoImpl) DAOFactory.createDAO(StockListDaoImpl.class,conn);
List
//request.setAttribute(\
System.out.println(\);
//request.setAttribute(\
return this.SUCCESS; }
@Override protected String list(HttpServletRequest request, HttpServletResponse response)throws ServletException, IOException{
return this.SUCCESS; }
@Override
protected boolean validate(DTO dto) { return false; }
@Override
protected DTO initDTO(HttpServletRequest request) { return null; }
@Override
protected String delete(HttpServletRequest request,
HttpServletResponse response) throws ServletException, IOException {
return null; } }
1.14 5.3 仓库管理
5.3.1 功能描述
该模块主要是管理仓库的添加以及库存量查询和车辆的入库和出库
- 29 -
华北水利水电学院毕业论文
5.3.2 模块流程图
进货管理模块依照进货订单表选择入库通过进货订单表查询未入库信息通过仓库表可以获得库存信息仓库库存信息依照客户订单表选择汽车出库销售模块
5.3.3 界面风格
- 30 -
华北水利水电学院毕业论文
员工表输入员工编号和密码判断失败error.jsp成功index.jsp
5.3.4 代码实现(部分)
DAO实现方法:
package com.csms.depot.dao.impl;
import java.sql.SQLException; import java.util.List;
import com.csms.depot.bean.DepotDTO; import com.csms.depot.dao.DepotDAO; import com.csms.stock.bean.CarDTO;
import com.csms.stock.bean.StockListDTO; import com.softstone.mvc.dao.DaoSupport; import com.softstone.mvc.dao.DefaultParams; import com.softstone.mvc.model.Paging;
public class DepotDaoImpl extends DaoSupport implements DepotDAO {
public static final String SQL_DELETE=\ public static final String SQL_QUERY_ALL=\ public static final String SQL_INSERT=\ private String SQL_Findengine = \ engineId,carType,carPrice,carEst,facId,stockId from car_table where stockId=? and depotId is null\
private String SQL_FINDSINGLEDEPOT = \* from depot_table where depotId=?\
private String SQL_UPDATE = \depotId=?\
public static final String SQL1=\ car_table set depotId=? where engineId=?\
public static final String SQL2=\ stocklist_table set enterEst='已入库' where stockId=?\
//public static final String SQL3=\ engineId,carType from car_table where stockId=? and depotId is null \
- 31 -
华北水利水电学院毕业论文
public static final String SQL4=\depot_table set liveSum=liveSum-1 where depotId=?\
public static final String SQL5=\ orderlist_table set engineId=? where orderId=?\
public static final String SQL6=\ set carEst='已出售' where engineId=?\
public int SQL2(StockListDTO stock) { int ret = 1; DefaultParams params = new DefaultParams(); params.addParam(stock.getStockId()); List
public int SQL1(CarDTO car){ int ret=0; DefaultParams params=new DefaultParams(); params.addParam(car.getDepotId()); params.addParam(car.getEngineId()); try { ret=execute(SQL1, params); } catch (SQLException e) { e.printStackTrace(); } return ret; }
public int SQL3(String carId,int depotId,int orderId){ int ret=0; DefaultParams params1=new DefaultParams(); params1.addParam(depotId); try { ret=execute(SQL4, params1); } catch (SQLException e) { e.printStackTrace(); } DefaultParams params2=new DefaultParams();
- 32 -
相关推荐: