public static bool InsertTireSpecParamsEditLog(SqlConnection conn, TireSpecParamsEditLog log)
        {
            string sql      = @"INSERT INTO [Configuration].[dbo].[tbl_TireSpecParamsEditLog]
           ([PId]
           ,[ChangeBefore]
           ,[ChangeAfter]
           ,[Operator]
           ,[CreateTime]
           ,[LastUpdateDataTime])
     VALUES
           (@PId
           ,@ChangeBefore
           ,@ChangeAfter
           ,@Operator
           ,GETDATE()
           ,GETDATE())";
            var    sqlParam = new[]
            {
                new SqlParameter("@PId", log.PId),
                new SqlParameter("@ChangeBefore", log.ChangeBefore),
                new SqlParameter("@ChangeAfter", log.ChangeAfter),
                new SqlParameter("@Operator", log.Operator),
            };

            return(SqlHelper.ExecuteNonQuery(conn, CommandType.Text, sql, sqlParam) > 0 ? true : false);
        }
예제 #2
0
 public bool InsertTireSpecParamsEditLog(TireSpecParamsEditLog log)
 {
     try
     {
         return(handler.InsertTireSpecParamsEditLog(log));
     }
     catch (TuhuBizException)
     {
         throw;
     }
     catch (Exception ex)
     {
         var exception = new DownloadAppException(1, "InsertTireSpecParamsEditLog", ex);
         Logger.Log(Level.Error, exception, "InsertTireSpecParamsEditLog");
         throw ex;
     }
 }
        public bool InsertTireSpecParamsEditLog(TireSpecParamsEditLog log)
        {
            Func <SqlConnection, bool> action = (connection) => DalTireSpecParamsConfig.InsertTireSpecParamsEditLog(connection, log);

            return(dbManager.Execute(action));
        }