|
@@ -254,22 +254,22 @@ public class OAHandler {
|
|
|
BaseUtil.showError("申请金额为0,不能提交");
|
|
|
}
|
|
|
StringBuffer sb = new StringBuffer();
|
|
|
- Object dept = baseDao.getFieldDataByCondition("feeplease", "fp_department", "fp_id=" + fp_id);
|
|
|
SqlRowList rs1 = baseDao.queryForRowSet(
|
|
|
- "select fpd_detno,fpd_d1,fpd_id,fp_department from FeePleaseDetail,feeplease where fp_id=fpd_fpid and fpd_fpid=?", fp_id);
|
|
|
+ "select fpd_detno,fpd_d1,fpd_id,nvl(FPD_DEPARTMENT,fp_department) dept from FeePleaseDetail,feeplease where fp_id=fpd_fpid and fpd_fpid=?", fp_id);
|
|
|
while (rs1.next()) {
|
|
|
+ Object dept = rs1.getObject("dept");
|
|
|
SqlRowList rs = baseDao.queryForRowSet(
|
|
|
"select fcs_departmentname from FeeCategorySet where fcs_departmentname=? and fcs_itemname=?", dept,
|
|
|
rs1.getObject("fpd_d1"));
|
|
|
if (!rs.hasNext()) {
|
|
|
sb.append("第" + rs1.getObject("fpd_detno") + "行部门[" + dept + "]费用用途[" + rs1.getObject("fpd_d1") + "]在费用申请科目没有设置,不能提交");
|
|
|
}
|
|
|
+ baseDao.execute("update FeePleaseDetail set fpd_catecode=(select max(fcs_catecode) from FeeCategorySet where fcs_departmentname='"
|
|
|
+ + dept + "' and fcs_itemname=fpd_d1 and nvl(fcs_nature,' ')=nvl(fpd_nature,' ')) where fpd_id=" + rs1.getObject("fpd_id"));
|
|
|
}
|
|
|
if (sb.length() > 0) {
|
|
|
BaseUtil.showError(sb.toString());
|
|
|
}
|
|
|
- baseDao.execute("update FeePleaseDetail set fpd_catecode=(select max(fcs_catecode) from FeeCategorySet where fcs_departmentname='"
|
|
|
- + dept + "' and fcs_itemname=fpd_d1 and nvl(fcs_nature,' ')=nvl(fpd_nature,' ')) where fpd_fpid=" + fp_id);
|
|
|
}
|
|
|
|
|
|
/**
|