Example #1
0
        private void OnGetListMember(object obj)
        {
            if (IsBusyBindProp)
            {
                return;
            }

            IsBusyBindProp = true;

            // Thuc hien cong viec tai day
            var logic_Member = new MemberLogic(Helper.GetConnectionString());

            var listMember = logic_Member.GetAllAsync();

            IsBusyBindProp = false;
        }
Example #2
0
        public override async void OnNavigatedTo(INavigationParameters parameters)
        {
            base.OnNavigatedTo(parameters);

            switch (parameters.GetNavigationMode())
            {
            case NavigationMode.Back:
                break;

            case NavigationMode.New:

                var logic      = new MemberLogic(Helper.GetConnectionString());
                var listMember = logic.GetAllAsync();

                ListMemberBindProp = new ObservableCollection <Member>(listMember);

                if (parameters.ContainsKey(Param.PARAM_MEMBER_EMAIL))
                {
                    EmailBindProp = parameters[Param.PARAM_MEMBER_EMAIL] as string;
                }
                if (parameters.ContainsKey(Param.PARAM_TITLE))
                {
                    TitleBindProp = parameters[Param.PARAM_TITLE] as string;
                    TitleBindProp = "Member";
                }
                if (parameters.ContainsKey(Param.PARAM_ADD_MEMBER))
                {
                    var member = parameters[Param.PARAM_ADD_MEMBER] as Member;
                    ListMemberBindProp.Add(member);
                }

                break;

            case NavigationMode.Forward:
                break;

            case NavigationMode.Refresh:
                break;

            default:
                break;
            }
        }