public async Task <IViewComponentResult> InvokeAsync( string aspFor, string siteName, string path, int sizeInMb, string defaultFile, string allowedExtensions) { var accessToken = ViewBag.AccessToken as string ?? await _appsContainer.AccessToken(); var token = await _tokenService.GetUploadTokenAsync(accessToken, siteName, "Upload", path); var model = new AiurUploaderViewModel { Name = aspFor, PBToken = token, Path = path, SiteName = siteName, SizeInMB = sizeInMb, DefaultFile = defaultFile, AllowedExtensions = allowedExtensions }; return(View(model)); }
public async Task <IViewComponentResult> InvokeAsync( string aspFor, string siteName, string path, int sizeInMb, string defaultFile, string allowedExtensions) { var token = await GetUploadToken(siteName, path); var model = new AiurUploaderViewModel { Name = aspFor, PBToken = token, Path = path, SiteName = siteName, SizeInMB = sizeInMb, DefaultFile = defaultFile, AllowedExtensions = allowedExtensions }; return(View(model)); }