|
@@ -339,7 +339,7 @@ public class cashbill extends Controller {
|
|
|
sqlList.add(sqlFactory.getSQL());
|
|
|
} else {
|
|
|
Rows rowscount = dbConnect.runSqlQuery(
|
|
|
- "select status from sa_cashbill where sa_cashbillid=" + sa_cashbillid);
|
|
|
+ "select status,billdate from sa_cashbill where sa_cashbillid=" + sa_cashbillid);
|
|
|
if (rowscount.isNotEmpty()){
|
|
|
if (!rowscount.get(0).getString("status").equals("新建")) {
|
|
|
return getErrReturnObject().setErrMsg("非新建状态的收支凭证无法更新").toString();
|
|
@@ -359,6 +359,13 @@ public class cashbill extends Controller {
|
|
|
sqlFactory.addParameter("source", "");
|
|
|
sqlFactory.addParameter("sourcenote", "");
|
|
|
sqlFactory.addParameter("period", period);
|
|
|
+ if( content.containsKey("billdate")){
|
|
|
+ sqlFactory.addParameter("billdate", content.getStringValue("billdate"));
|
|
|
+ }else{
|
|
|
+ sqlFactory.addParameter("billdate", rowscount.get(0).getString("billdate"));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
sqlList.add(sqlFactory.getSQL());
|
|
|
}
|
|
|
dbConnect.runSqlUpdate(sqlList);
|