/// <summary>
 /// Create a new T_OE_SYS_LOG object.
 /// </summary>
 /// <param name="sYS_LOG_ID">Initial value of the SYS_LOG_ID property.</param>
 /// <param name="lOG_DT">Initial value of the LOG_DT property.</param>
 public static T_OE_SYS_LOG CreateT_OE_SYS_LOG(global::System.Int32 sYS_LOG_ID, global::System.DateTime lOG_DT)
 {
     T_OE_SYS_LOG t_OE_SYS_LOG = new T_OE_SYS_LOG();
     t_OE_SYS_LOG.SYS_LOG_ID = sYS_LOG_ID;
     t_OE_SYS_LOG.LOG_DT = lOG_DT;
     return t_OE_SYS_LOG;
 }
Esempio n. 2
0
        //***************** REF_SYS_LOG *********************************************
        public static int InsertT_OE_SYS_LOG(string logType, string logMsg)
        {
            using (OpenEnvironmentEntities ctx = new OpenEnvironmentEntities())
            {
                try
                {
                    T_OE_SYS_LOG e = new T_OE_SYS_LOG();
                    e.LOG_TYPE = logType;
                    if (logMsg != null)
                        e.LOG_MSG = logMsg.SubStringPlus(0, 1999);
                    e.LOG_DT = System.DateTime.Now;

                    ctx.AddToT_OE_SYS_LOG(e);
                    ctx.SaveChanges();
                    return e.SYS_LOG_ID;
                }
                catch
                {
                    return 0;
                }
            }
        }
 /// <summary>
 /// Deprecated Method for adding a new object to the T_OE_SYS_LOG EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToT_OE_SYS_LOG(T_OE_SYS_LOG t_OE_SYS_LOG)
 {
     base.AddObject("T_OE_SYS_LOG", t_OE_SYS_LOG);
 }