public RegisterationTapView(FacebookViewModel facebookViewModel = null)
        {
            InitializeComponent();

            Children.Add(new ProfileView(new User(), facebookViewModel));
            Children.Add(new AddVechicleInfo(new Vehicle()));
        }
        public ProfileViewModel(IPageService pageService, User user, FacebookViewModel facebookViewModel = null)
        {
            this.pageService = pageService;

            if (user.UserName == null)
            {
                user.RoleId = "2";
                if (facebookViewModel != null)
                {
                    facebookProfile = facebookViewModel?.FacebookProfile;
                    user.UserName   = facebookProfile?.Email;
                    user.Name       = facebookProfile?.Name;
                    user.LoginType  = "facebook";
                }
            }

            this.user = user;
        }
Esempio n. 3
0
        public FacebookProfileCsPage(IPageService pageService)
        {
            this.pageService = pageService;
            BindingContext   = new FacebookViewModel();

            Title           = "Facebook Profile";
            BackgroundColor = Color.White;

            var apiRequest =
                "https://www.facebook.com/dialog/oauth?client_id="
                + ClientId
                + "&display=popup&response_type=token&redirect_uri=https://uthayakumarbooks.com/&scope=email";

            var webView = new WebView
            {
                Source        = apiRequest,
                HeightRequest = 1
            };

            webView.Navigated += WebViewOnNavigated;

            Content = webView;
        }
 public ProfileView(User user, FacebookViewModel facebookViewModel = null)
 {
     BindingContext = new ProfileViewModel(new PageService(), user, facebookViewModel);
     InitializeComponent();
 }
Esempio n. 5
0
 private async Task GoToProfilePageAsync(FacebookViewModel vm)
 {
     await pageService.PushAsync(new RegisterationTapView(vm));
 }