123456789101112131415161718192021222324252627282930313233 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using cuidian.Sql;
- using Logs;
- namespace OperationLog
- {
- public class Utils
- {
- public static void WriteErrorLog(string operType, string msg)
- {
- string msgSql = "insert into errmsg(opertype,msg) values('{0}','{1}')";
-
- try
- {
- DbUtils.ExecuteNonQuery(string.Format(msgSql,operType,msg), ConnectionUtils.Instance.GetConnection("TempDB"));
- }
- catch (Exception ex)
- {
- LogHelper.Debug(ex.Message);
- }
- }
- public static void UpdateTempRecord(string sql)
- {
- DbUtils.ExecuteNonQuery(sql, ConnectionUtils.Instance.GetConnection("TempDB"));
- }
-
- }
- }
|