public ActionResult Index() { string token = Request.QueryString["token"]; string isbn = Request.QueryString["eISBN"]; if (token != null && isbn != null && token.ToString() != "" && isbn.ToString() != "") { SSOws sso = new SSOws(); OLRws olr = new OLRws(); SSOwsResult tokenResult = sso.validateToken(token); if (tokenResult.resultDescription == "Success") { getEntitlementParameters parameters = new getEntitlementParameters(); parameters.userToken = token; filter eisbnFilter = new filter(); parameters.userToken = token; eisbnFilter.filterType = "EISBN"; eisbnFilter.filerValue = isbn; parameters.filter = eisbnFilter; OLRwsResult entitlementResult = olr.getEntitlements(parameters); if (entitlementResult.resultDescription == "Success") { // All good; do nothing } else { return View("AccessDenied"); } } else { return View("AccessDenied"); } } else { return View("AccessDenied"); } return View(); }
/// <remarks/> public void getEntitlementsAsync(getEntitlementParameters getEntitlements1, object userState) { if ((this.getEntitlementsOperationCompleted == null)) { this.getEntitlementsOperationCompleted = new System.Threading.SendOrPostCallback(this.OngetEntitlementsOperationCompleted); } this.InvokeAsync("getEntitlements", new object[] { getEntitlements1}, this.getEntitlementsOperationCompleted, userState); }
/// <remarks/> public void getEntitlementsAsync(getEntitlementParameters getEntitlements1) { this.getEntitlementsAsync(getEntitlements1, null); }