Exemple #1
0
 public void AdminInsert(Admin admin)
 {
     using (SqlCommand command = new SqlCommand("sp_AdminInsert",GetConnection()))
     {
         command.CommandType = CommandType.StoredProcedure;
         command.Parameters.Add(new SqlParameter("@Username",admin.UserName));
         command.Parameters.Add(new SqlParameter("@Password", admin.PassWord));
         command.Parameters.Add(new SqlParameter("@Email", admin.Email));
         command.Parameters.Add(new SqlParameter("@Name", admin.Name));
         command.ExecuteNonQuery();
     }
 }
Exemple #2
0
 public int AddAdmin(Admin admin)
 {
     Object[] values = { admin.AdminPassWord, admin.AdminUserName };
     int k = 0;
     try
     {
         k = ProcessByStore("Admin_add", columnName2insert, values);
     }
     catch (Exception ex)
     {
         throw ex;
     }
     return k;
 }
Exemple #3
0
 public void AdminInsert(Admin admin)
 {
     admin_dl.AdminInsert(admin);
 }
Exemple #4
0
 public static AdminBLL getAdminBLL(Admin sc)
 {
     return(iMapper.Map <AdminBLL>(sc));
 }