public bool Delete(int adminId) { CommonRepository repository = new CommonRepository(); Entity.m_ManagerAccount model = new Entity.m_ManagerAccount(); model.AdminId = adminId; return(repository.Delete(model)); }
public bool Add(int roleId, string adminName, string password) { bool Result = false; if (!string.IsNullOrEmpty(adminName) && !string.IsNullOrEmpty(password)) { Entity.m_ManagerAccount model = new Entity.m_ManagerAccount(); model.AdminName = adminName; model.Password = Framework.Core.TextHelper.MD5Encrypt(password); model.RoleId = roleId; model.IsStatus = true; CommonRepository repository = new CommonRepository(); return(repository.Add(model)); } return(Result); }