/// <summary> /// Create a new Morte object. /// </summary> /// <param name="id">Initial value of the id property.</param> /// <param name="id_sessao">Initial value of the id_sessao property.</param> /// <param name="mortes">Initial value of the mortes property.</param> /// <param name="morteshora">Initial value of the morteshora property.</param> /// <param name="dt">Initial value of the dt property.</param> public static Morte CreateMorte(global::System.Decimal id, global::System.Decimal id_sessao, global::System.Decimal mortes, global::System.Decimal morteshora, global::System.DateTime dt) { Morte morte = new Morte(); morte.id = id; morte.id_sessao = id_sessao; morte.mortes = mortes; morte.morteshora = morteshora; morte.dt = dt; return morte; }
/// <summary> /// Deprecated Method for adding a new object to the Mortes EntitySet. Consider using the .Add method of the associated ObjectSet<T> property instead. /// </summary> public void AddToMortes(Morte morte) { base.AddObject("Mortes", morte); }
public void IncluiNovaMorte(estSessao s, estMorte m, string key) { if (key != "3kl4j3lk5n3lk3j43kl4j34n3,m4n34k34hj3l4h34nm3,.n43") { throw new Exception("Chave inválida"); } BotWoWEntities b = EntityContextBot.GetContext; Morte m1 = new Morte(); m1.mortes = m.mortes; m1.morteshora = m.morteshora; m1.id_sessao = s.id; m1.dt = m.dt; m1.RealZoneText = m.RealZoneText; m1.SubZoneText = m.SubZoneText; b.Mortes.AddObject(m1); b.SaveChanges(); }