public static void Delete(int IdTemplate)
 {
     SqlCommand cb = new SqlCommand("RemoveTemplates");
     DataAccess db = new DataAccess();
     cb.Parameters.AddWithValue("@IdTemplate", IdTemplate);
     db.EjecutarSp(cb);
 }
 public void Update()
 {
     SqlCommand cb = new SqlCommand("UpdateTemplates");
     DataAccess db = new DataAccess();
     cb.Parameters.AddWithValue("@IdTemplate", IdTemplate);
     cb.Parameters.AddWithValue("@Nombre", Nombre);
     cb.Parameters.AddWithValue("@Contenido", Contenido);
     db.EjecutarSp(cb);
 }
Esempio n. 3
0
 public void Insert()
 {
     SqlCommand cb = new SqlCommand("AddDataType");
     DataAccess db = new DataAccess();
     cb.Parameters.AddWithValue("@CSharpType", CSharpType);
     cb.Parameters.AddWithValue("@SqlType", SqlType);
     cb.Parameters.AddWithValue("@IdTipo", IdTipo);
     db.EjecutarSp(cb);
 }
Esempio n. 4
0
 public void Insert()
 {
     SqlCommand cb = new SqlCommand("AddEntity");
     DataAccess db = new DataAccess();
     cb.Parameters.AddWithValue("@Name", Name);
     cb.Parameters.AddWithValue("@Version", Version);
     cb.Parameters.AddWithValue("@Modification", Modification);
     db.EjecutarSp(cb);
 }
 public void Insert()
 {
     SqlCommand cb = new SqlCommand("AddEntityFields");
     DataAccess db = new DataAccess();
     cb.Parameters.AddWithValue("@EntityId", EntityId);
     cb.Parameters.AddWithValue("@Name", Name);
     cb.Parameters.AddWithValue("@DataType", DataType);
     cb.Parameters.AddWithValue("@Length", Length);
     db.EjecutarSp(cb);
 }
 public void Insert()
 {
     SqlCommand cb = new SqlCommand("AddTemplates");
     DataAccess db = new DataAccess();
     cb.Parameters.AddWithValue("@Nombre", Nombre);
     cb.Parameters.AddWithValue("@Contenido", Contenido);
     SqlParameter p = new SqlParameter("@NewId", System.Data.SqlDbType.Int);
     p.Direction = System.Data.ParameterDirection.Output;
     cb.Parameters.Add(p);
     db.EjecutarSp(cb);
     this.IdTemplate = (int)p.Value;
 }