DBUtility/ÒµÎñµ¥¾Ý/ClsXt_BaseBill.cs
@@ -456,13 +456,13 @@
                oCn.RunProc(sql);
                //检查单据子表所有行是否都关闭,若都关闭则自动关闭单据
                sql = "select * from " + MvarItemKeySub + " where HInterID=" + lngBillKey + " and HCloseMan=''";
                ds = oCn.RunProcReturn(sql, MvarItemKeySub);
                if(ds!=null && ds.Tables[0].Rows.Count == 0)
                {
                    sql = " Update " + MvarItemKey + " set HCloseMan='" + HCloseMan + "',HCloseDate=getdate(),HBillStatus=3,HCloseType = 0 Where HInterID=" + lngBillKey.ToString();
                    oCn.RunProc(sql);
                }
                //sql = "select * from " + MvarItemKeySub + " where HInterID=" + lngBillKey + " and HCloseMan=''";
                //ds = oCn.RunProcReturn(sql, MvarItemKeySub);
                //if(ds!=null && ds.Tables[0].Rows.Count == 0)
                //{
                //    sql = " Update " + MvarItemKey + " set HCloseMan='" + HCloseMan + "',HCloseDate=getdate(),HBillStatus=3,HCloseType = 0 Where HInterID=" + lngBillKey.ToString();
                //    oCn.RunProc(sql);
                //}
                //写入日志
                string WorkList = "行关闭,单据号:" + HBillNo + ";子表内码:" + HEntryID;