public string ForgetPassword(string email, string Name) { if (PersonWork.ForgetPassword(email, Name) == true) { return("Your password send on email"); } return("Wrong Name or Email"); }
public string Authorization(string email, string password) { person = PersonWork.Authorization(email, password); if (person == null) { return("Wrong email or password"); } return("Authorization"); }
public string ChangeSecondName(string Name) { if (person == null) { return("Autorizat!!!"); } if (Name.Length < 8) { return("Small name"); } if (PersonWork.ChangeSecondName(person.Id, Name) == "Name is change") { person.SecondName = Name; return("Name is change"); } return("Name is change"); }
public string ChangePassword(string NewPassword) { if (person == null) { return("Autorizat!!!"); } if (NewPassword.Length < 8) { return("Small password"); } if (PersonWork.ChangePassword(person.Id, NewPassword) == "Password is change") { person.Password = NewPassword; return("Password is change"); } return("Password is change"); }
public string AddPerson(string FirstName, string SecondName, string Email, string Password, bool Gender = false, byte[] Img = null) { if (Email.Length < 8 || Email.Contains("@") == false || Email.Contains(".") == false) { return("Wrong email"); } if (Password.Length < 8) { return("Password must have minimum 8 sumvols"); } if (FirstName.Length == 0 || SecondName.Length == 0) { return("You need input FirstName and SecondName"); } return(PersonWork.AddPerson(new Person() { Email = Email, Password = Password, FirstName = FirstName, SecondName = SecondName, Gender = Gender, Image = Img })); }
public string TellMeAboutStartLot(int LotId) { return(PersonWork.TellMeAboutStartLot(person, LotId)); }
public void SendMessage(string Thema, string Message, Person to) { PersonWork.SendMessage(person, Thema, Message, to); }