⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 warehousemonthbean.java

📁 我的系在线考试系统我的系在线考试系统我的系在线考试系统我的系在线考试系统我的系在线考试系统我的系在线考试系统我的系在线考试系统我的系在线考试系统
💻 JAVA
📖 第 1 页 / 共 2 页
字号:
	public double getShortAmo() {		return this.shortAmo;	}	public void setShortAmo(String sV) {		if (sV != null && !"".equals(sV)) {			this.shortAmo = Double.parseDouble(sV);		}	}	public void setShortAmo(double nV) {		this.shortAmo = nV;	}	public int getExamQua() {		return this.examQua;	}	public void setExamQua(String sV) {		if (sV != null && !"".equals(sV)) {			this.examQua = Integer.parseInt(sV);		}	}	public void setExamQua(int nV) {		this.examQua = nV;	}	public int getOther() {		return this.other;	}	public void setOther(String sV) {		if (sV != null && !"".equals(sV)) {			this.other = Integer.parseInt(sV);		}	}	public void setOther(int nV) {		this.other = nV;	}	public String getRemark() {		return this.remark;	}	public void setRemark(String sV) {		if (sV != null) {			this.remark = sV;		}	}	public double getRecRate() {		return this.recRate;	}	public void setRecRate(String sV) {		if (sV != null && !"".equals(sV)) {			this.recRate = Double.parseDouble(sV);		}	}	public void setRecRate(double nV) {		this.recRate = nV;	}	public int getWarehouseCode() {		return this.warehouseCode;	}	public void setWarehouseCode(String sV) {		if (sV != null && !"".equals(sV)) {			this.warehouseCode = Integer.parseInt(sV);		}	}	public void setWarehouseCode(int nV) {		this.warehouseCode = nV;	}	public String getWarehouseNo() {		return this.warehouseNo;	}	public void setWarehouseNo(String sV) {		if (sV != null) {			this.warehouseNo = sV;		}	}	public String getWarehouseName() {		return this.warehouseName;	}	public void setWarehouseName(String sV) {		if (sV != null) {			this.warehouseName = sV;		}	}	public String getUserName() {		return this.userName;	}	public void setUserName(String sV) {		if (sV != null) {			this.userName = sV;		}	}	public String getCrdateDate() {		return this.crdateDate;	}	public void setCrdateDate(String sV) {		if (sV != null) {			this.crdateDate = sV;		}	}	public String getOpTime() {		return this.opTime;	}	public void setOpTime(String sV) {		if (sV != null) {			this.opTime = sV;		}	}	public boolean insert() {		Connection conn = null;		PreparedStatement pstmt = null;		ResultSet rs = null;		try {			DatabaseConnection dc = new DatabaseConnection(jndiName);			conn = dc.getConnection();			String sql = "insert into warehouseMonth(warehouseMonthCode,computer,operator,sYear,sMonth,title,type,isFill,isAcc,isEnd,isExt,isExtAcc,isBack,createDate,currency,quab,amob,quaf,amof,recAmo,qua,amo,kaoAmo,shortAmo,examQua,other,remark,recRate,warehouseCode,warehouseNo,warehouseName,userName,crdateDate,opTime) values (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,getDate())";			pstmt = conn.prepareStatement(sql);			pstmt.setString(1, this.warehouseMonthCode);			pstmt.setInt(2, this.computer);			pstmt.setInt(3, this.operator);			pstmt.setString(4, this.sYear);			pstmt.setString(5, this.sMonth);			pstmt.setString(6, this.title);			pstmt.setInt(7, this.type);			pstmt.setBoolean(8, this.isFill);			pstmt.setBoolean(9, this.isAcc);			pstmt.setBoolean(10, this.isEnd);			pstmt.setBoolean(11, this.isExt);			pstmt.setBoolean(12, this.isExtAcc);			pstmt.setBoolean(13, this.isBack);			pstmt.setString(14, this.createDate);			pstmt.setString(15, this.currency);			pstmt.setInt(16, this.quab);			pstmt.setDouble(17, this.amob);			pstmt.setInt(18, this.quaf);			pstmt.setDouble(19, this.amof);			pstmt.setDouble(20, this.recAmo);			pstmt.setInt(21, this.qua);			pstmt.setDouble(22, this.amo);			pstmt.setDouble(23, this.kaoAmo);			pstmt.setDouble(24, this.shortAmo);			pstmt.setInt(25, this.examQua);			pstmt.setInt(26, this.other);			pstmt.setString(27, this.remark);			pstmt.setDouble(28, this.recRate);			pstmt.setInt(29, this.warehouseCode);			pstmt.setString(30, this.warehouseNo);			pstmt.setString(31, this.warehouseName);			pstmt.setString(32, this.userName);			pstmt.setString(33, this.crdateDate);			pstmt.execute();			return true;		} catch (Exception ex) {			ex.printStackTrace();			new WriteLog(jndiName, 0, 10000, "core", "kernel", "database", this					.getClass().getName()					+ ": " + ex.getMessage(), true, 0);			return false;		} finally {			try {				if (rs != null) {					rs.close();				}				if (pstmt != null) {					pstmt.close();				}				if (conn != null) {					conn.close();				}			} catch (Exception ex) {				ex.printStackTrace();			}		}	}	public boolean modify() {		Connection conn = null;		PreparedStatement pstmt = null;		ResultSet rs = null;		try {			DatabaseConnection dc = new DatabaseConnection(jndiName);			conn = dc.getConnection();			String sql = "update warehouseMonth set warehouseMonthCode=?,computer=?,operator=?,sYear=?,sMonth=?,title=?,type=?,isFill=?,isAcc=?,isEnd=?,isExt=?,isExtAcc=?,isBack=?,createDate=?,currency=?,quab=?,amob=?,quaf=?,amof=?,recAmo=?,qua=?,amo=?,kaoAmo=?,shortAmo=?,examQua=?,other=?,remark=?,recRate=?,warehouseCode=?,warehouseNo=?,warehouseName=?,userName=?,crdateDate=?,opTime=? where warehouseMonthCode=?";			pstmt = conn.prepareStatement(sql);			pstmt.setString(1, this.warehouseMonthCode);			pstmt.setInt(2, this.computer);			pstmt.setInt(3, this.operator);			pstmt.setString(4, this.sYear);			pstmt.setString(5, this.sMonth);			pstmt.setString(6, this.title);			pstmt.setInt(7, this.type);			pstmt.setBoolean(8, this.isFill);			pstmt.setBoolean(9, this.isAcc);			pstmt.setBoolean(10, this.isEnd);			pstmt.setBoolean(11, this.isExt);			pstmt.setBoolean(12, this.isExtAcc);			pstmt.setBoolean(13, this.isBack);			pstmt.setString(14, this.createDate);			pstmt.setString(15, this.currency);			pstmt.setInt(16, this.quab);			pstmt.setDouble(17, this.amob);			pstmt.setInt(18, this.quaf);			pstmt.setDouble(19, this.amof);			pstmt.setDouble(20, this.recAmo);			pstmt.setInt(21, this.qua);			pstmt.setDouble(22, this.amo);			pstmt.setDouble(23, this.kaoAmo);			pstmt.setDouble(24, this.shortAmo);			pstmt.setInt(25, this.examQua);			pstmt.setInt(26, this.other);			pstmt.setString(27, this.remark);			pstmt.setDouble(28, this.recRate);			pstmt.setInt(29, this.warehouseCode);			pstmt.setString(30, this.warehouseNo);			pstmt.setString(31, this.warehouseName);			pstmt.setString(32, this.userName);			pstmt.setString(33, this.crdateDate);			pstmt.setString(34, this.opTime);			pstmt.setString(35, this.warehouseMonthCode);			pstmt.execute();			return true;		} catch (Exception ex) {			ex.printStackTrace();			new WriteLog(jndiName, 0, 10000, "core", "kernel", "database", this					.getClass().getName()					+ ": " + ex.getMessage(), true, 0);			return false;		} finally {			try {				if (rs != null) {					rs.close();				}				if (pstmt != null) {					pstmt.close();				}				if (conn != null) {					conn.close();				}			} catch (Exception ex) {				ex.printStackTrace();			}		}	}	public boolean content() {		Connection conn = null;		PreparedStatement pstmt = null;		ResultSet rs = null;		try {			DatabaseConnection dc = new DatabaseConnection(jndiName);			conn = dc.getConnection();			String sql = "select * from warehouseMonth  where warehouseMonthCode=?";			pstmt = conn.prepareStatement(sql);			pstmt.setString(1, this.warehouseMonthCode);			rs = pstmt.executeQuery();			while (rs.next()) {				setWarehouseMonthCode(rs.getString("warehouseMonthCode"));				setComputer(rs.getInt("computer"));				setOperator(rs.getInt("operator"));				setSYear(rs.getString("sYear"));				setSMonth(rs.getString("sMonth"));				setTitle(rs.getString("title"));				setType(rs.getInt("type"));				setIsFill(rs.getBoolean("isFill"));				setIsAcc(rs.getBoolean("isAcc"));				setIsEnd(rs.getBoolean("isEnd"));				setIsExt(rs.getBoolean("isExt"));				setIsExtAcc(rs.getBoolean("isExtAcc"));				setIsBack(rs.getBoolean("isBack"));				setCreateDate(rs.getString("createDate"));				setCurrency(rs.getString("currency"));				setQuab(rs.getInt("quab"));				setAmob(rs.getDouble("amob"));				setQuaf(rs.getInt("quaf"));				setAmof(rs.getDouble("amof"));				setRecAmo(rs.getDouble("recAmo"));				setQua(rs.getInt("qua"));				setAmo(rs.getDouble("amo"));				setKaoAmo(rs.getDouble("kaoAmo"));				setShortAmo(rs.getDouble("shortAmo"));				setExamQua(rs.getInt("examQua"));				setOther(rs.getInt("other"));				setRemark(rs.getString("remark"));				setRecRate(rs.getDouble("recRate"));				setWarehouseCode(rs.getInt("warehouseCode"));				setWarehouseNo(rs.getString("warehouseNo"));				setWarehouseName(rs.getString("warehouseName"));				setUserName(rs.getString("userName"));				setCrdateDate(rs.getString("crdateDate"));				setOpTime(rs.getString("opTime"));				return true;			}			return false;		} catch (Exception ex) {			ex.printStackTrace();			new WriteLog(jndiName, 0, 10000, "core", "kernel", "database", this					.getClass().getName()					+ ": " + ex.getMessage(), true, 0);			return false;		} finally {			try {				if (rs != null) {					rs.close();				}				if (pstmt != null) {					pstmt.close();				}				if (conn != null) {					conn.close();				}			} catch (Exception ex) {				ex.printStackTrace();			}		}	}	public boolean isExistsByCode() {		Connection conn = null;		PreparedStatement pstmt = null;		ResultSet rs = null;		try {			DatabaseConnection dc = new DatabaseConnection(jndiName);			conn = dc.getConnection();			String sql = "select * from warehouseMonth  where warehouseMonthCode=?";			pstmt = conn.prepareStatement(sql);			pstmt.setString(1, this.warehouseMonthCode);			rs = pstmt.executeQuery();			while (rs.next()) {				return true;			}			return false;		} catch (Exception ex) {			ex.printStackTrace();			new WriteLog(jndiName, 0, 10000, "core", "kernel", "database", this					.getClass().getName()					+ ": " + ex.getMessage(), true, 0);			return false;		} finally {			try {				if (rs != null) {					rs.close();				}				if (pstmt != null) {					pstmt.close();				}				if (conn != null) {					conn.close();				}			} catch (Exception ex) {				ex.printStackTrace();			}		}	}	public boolean delete() {		Connection conn = null;		PreparedStatement pstmt = null;		ResultSet rs = null;		try {			DatabaseConnection dc = new DatabaseConnection(jndiName);			conn = dc.getConnection();			String sql = "delete from warehouseMonth  where warehouseMonthCode=?";			pstmt = conn.prepareStatement(sql);			pstmt.setString(1, this.warehouseMonthCode);			pstmt.execute();			return true;		} catch (Exception ex) {			ex.printStackTrace();			new WriteLog(jndiName, 0, 10000, "core", "kernel", "database", this					.getClass().getName()					+ ": " + ex.getMessage(), true, 0);			return false;		} finally {			try {				if (rs != null) {					rs.close();				}				if (pstmt != null) {					pstmt.close();				}				if (conn != null) {					conn.close();				}			} catch (Exception ex) {				ex.printStackTrace();			}		}	}	public Object clone() {		WarehouseMonthModel f = null;		try {			f = (WarehouseMonthModel) super.clone();		} catch (CloneNotSupportedException e) {			e.printStackTrace();		}		return f;	}}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -