Example #1
0
        public void RegisterMember(model.Member a_member, view.Console a_view, model.Menu a_menu)
        {
            a_member.name = a_view.RegisterName();
                a_member.personalIdentityNumber = a_view.RegisterPersonalIdentityNumber();

                using (StreamWriter writer = new StreamWriter("memberRegister.txt", true))
                {
                    a_member.id++;
                    writer.WriteLine(a_member.id + "\t" + a_member.name + "\t" + a_member.personalIdentityNumber);
                    writer.Close();
                    a_view.ConfirmChange("Member registered: " + "Id: " + a_member.id + ", Name: " + a_member.name + ", Personal identity number: " + a_member.personalIdentityNumber);

                    a_menu.ChooseFromMenu(a_member, a_menu);
                }
        }