Exemple #1
0
        public ActionResult SignIn()
        {
            GoogleAnalyticsViewModel viewModel = new GoogleAnalyticsViewModel();

            viewModel.Url = GoogleAnalyticsServiceManager.GetRequestUrl();
            return(View(viewModel));
        }
 protected override void OnActionExecuting(ActionExecutingContext filterContext)
 {
     base.OnActionExecuting(filterContext);
     try
     {
         analyticsService = GoogleAnalyticsServiceManager.GetAnalyticsService();
     }
     catch
     {
         filterContext.Result = RedirectToAction("SignIn", "GoogleAnalytics");
     }
 }
Exemple #3
0
 public ActionResult Callback(string code)
 {
     GoogleAnalyticsServiceManager.SaveRefreshToken(code);
     return(RedirectToAction("Index", "Index"));
 }