|  |  | 
 |  |  |             string UserName = sArray[1].ToString(); | 
 |  |  |             string refSav = sArray[2].ToString(); | 
 |  |  |             DBUtility.ClsPub.CurUserName = UserName; | 
 |  |  |  | 
 |  |  |             //保存权限 | 
 |  |  |             if (!DBUtility.ClsPub.Security_Log_second("OA_ErrMsgBackBill_Edit", 1, false, DBUtility.ClsPub.CurUserName)) | 
 |  |  |             { | 
 |  |  | 
 |  |  |                 objJsonResult.data = null; | 
 |  |  |                 return objJsonResult; | 
 |  |  |             } | 
 |  |  |  | 
 |  |  |             //判断会计期是否合理 | 
 |  |  |             string s = ""; | 
 |  |  |             int sYear = 0; | 
 |  |  | 
 |  |  |         { | 
 |  |  |             try | 
 |  |  |             { | 
 |  |  |                 ds = Get_TransFerBillList(sWhere); | 
 |  |  |                 if (ds == null) | 
 |  |  |                 //查看权限 | 
 |  |  |                 if (!DBUtility.ClsPub.Security_Log("OA_ErrMsgBackBill_Query", 1, false, user)) | 
 |  |  |                 { | 
 |  |  |                     objJsonResult.code = "0"; | 
 |  |  |                     objJsonResult.count = 0; | 
 |  |  |                     objJsonResult.Message = "查询数据异常,请与管理员联系!"; | 
 |  |  |                     objJsonResult.data = ds.Tables[0]; | 
 |  |  |                     objJsonResult.Message = "无查看权限!"; | 
 |  |  |                     objJsonResult.data = null; | 
 |  |  |                     return objJsonResult; | 
 |  |  |                 } | 
 |  |  |                 else | 
 |  |  |                 { | 
 |  |  |                     objJsonResult.code = "1"; | 
 |  |  |                     objJsonResult.count = 1; | 
 |  |  |                     objJsonResult.Message = "返回记录成功!"; | 
 |  |  |                     objJsonResult.data = ds.Tables[0]; | 
 |  |  |                     return objJsonResult; | 
 |  |  |                 } | 
 |  |  |  | 
 |  |  |                 ds = Get_TransFerBillList(sWhere); | 
 |  |  |  | 
 |  |  |                 //if (ds.Tables[0].Rows.Count != 0 || ds != null) | 
 |  |  |                 //{ | 
 |  |  |                 objJsonResult.code = "1"; | 
 |  |  |                 objJsonResult.count = 1; | 
 |  |  |                 objJsonResult.Message = "Sucess!"; | 
 |  |  |                 objJsonResult.data = ds.Tables[0]; | 
 |  |  |                 return objJsonResult; | 
 |  |  |                 //} | 
 |  |  |                 //else | 
 |  |  |                 //{ | 
 |  |  |                 //objJsonResult.code = "0"; | 
 |  |  |                 //objJsonResult.count = 0; | 
 |  |  |                 //objJsonResult.Message = "无数据"; | 
 |  |  |                 //objJsonResult.data = null; | 
 |  |  |                 //return objJsonResult; | 
 |  |  |                 //} | 
 |  |  |             } | 
 |  |  |             catch (Exception ex) | 
 |  |  |             { | 
 |  |  | 
 |  |  |                                       A.HSourceInterID,A.HSourceEntryID,A.HSourceBillNo,A.HSourceBillType | 
 |  |  |                                       from OA_ErrMsgBackBillMain A  | 
 |  |  |                                       inner join  OA_ErrMsgBackBillSub2 B on A.HInterID=B.HInterID  | 
 |  |  |                                       left join Gy_Department D on A.HDeptID=D.HItemID where 1=1 " + sWhere + ""); | 
 |  |  |                                       left join Gy_Department D on A.HDeptID=D.HItemID where 1=1 " + sWhere + "   order by HItemID desc "); | 
 |  |  |             return new SQLHelper.ClsCN().RunProcReturn(sql, "OA_ErrMsgBackBillMain"); | 
 |  |  |         } | 
 |  |  |  |