Esempio n. 1
0
            public bool signUp(Models.DataClassesDataContext data, string email, string password
                               , string fullname, string phone, string address
                               , DateTime birthday, Constants.Gender gender)
            {
                bool doesAccountToAddExist = checkThisMemberAccountExist(data, email, password);

                if (!doesAccountToAddExist)
                {
                    Models.tbl_member account = new Models.tbl_member();
                    account.email         = email;
                    account.address       = address;
                    account.date_added    = DateTime.Now;
                    account.last_modified = DateTime.Now;
                    account.name          = fullname;
                    account.password      = password;
                    account.status        = (byte)Constants.AccountStatus.INACTIVE;
                    account.birthday      = birthday;
                    account.gender        = (byte)gender;
                    account.phone         = phone;

                    data.tbl_members.InsertOnSubmit(account);
                    data.SubmitChanges();

                    //Send email to activate account
                    EmailHelper.getInstance().sendActivatingMail(email);
                    return(true);
                }
                return(false);
            }
Esempio n. 2
0
 public ProfileDTO(int age, double income, double bonus, Constants.Gender gender, double deduction)
 {
     Age       = age;
     Income    = income;
     Bonus     = bonus;
     Gender    = gender;
     Deduction = deduction;
 }
 public TaxResultDTO(int age, double income, double bonus, Constants.Gender gender, double deduction)
     : base(age, income, bonus, gender, deduction)
 {
 }