Пример #1
0
        public void WriteExportLog(int _exportRowCount, string ExportDataMsg)
        {
            using (OracleConnection cn = OracleHelper.OpenConnection())
            {
                try
                {
                    string _ipaddr   = WCFClientInfo.IPAddr;
                    string _hostName = _ipaddr;

                    if (ExportDataMsg == null || ExportDataMsg.Trim() == "")
                    {
                        OralceLogWriter.WriteUserLog(decimal.Parse(SinoUserCtx.CurUser.UserID), "导出数据", string.Format("导了数据成功! 导出记录数:{0}", _exportRowCount),
                                                     1, _ipaddr, _hostName, ConfigFile.SystemID);
                    }
                    else
                    {
                        OralceLogWriter.WriteUserLog(decimal.Parse(SinoUserCtx.CurUser.UserID), "导出数据", string.Format("导了数据成功! 导出记录数:{0}  导出数据说明:{1}", _exportRowCount, ExportDataMsg),
                                                     1, _ipaddr, _hostName, ConfigFile.SystemID);
                    }
                }
                catch (Exception ex)
                {
                    OralceLogWriter.WriteSystemLog(string.Format("写入导出日志失败!导出内容:{0} 导出行数:{1} 错误信息:{2}", ExportDataMsg, _exportRowCount, ex.Message), "ERROR");
                }
            }
        }
Пример #2
0
        public void WriteClientUserLog(string Message, string LogType)
        {
            using (OracleConnection cn = OracleHelper.OpenConnection())
            {
                try
                {
                    string _ipaddr = WCFClientInfo.IPAddr;

                    OralceLogWriter.WriteUserLog(decimal.Parse(SinoUserCtx.CurUser.UserID), "客户端日志", Message, 1, _ipaddr, _ipaddr, ConfigFile.SystemID);
                }
                catch (Exception ex)
                {
                    OralceLogWriter.WriteSystemLog(string.Format("写入客户端日志失败!日志内容:{0} 类型:{1} 错误信息:{2}", Message, LogType, ex.Message), "ERROR");
                }
            }
        }
Пример #3
0
 public bool WriteUserLog(decimal _yhid, string _czlx, string _cxnr, decimal _resulttype, string _ipaddr, string _hostName, string _systemID)
 {
     return(OralceLogWriter.WriteUserLog(_yhid, _czlx, _cxnr, _resulttype, _ipaddr, _hostName, _systemID));
 }