public async Task <IActionResult> GetAlignmentName([FromBody] dynamic body) { Credentials credentials = await Credentials.FromSessionAsync(base.Request.Cookies, Response.Cookies); if (credentials == null) { return(null); } string itemId = body["itemId"]; string versionId = body["versionId"]; string projectId = itemId.Split("/").Reverse().ElementAt(2); string connectionId = body["connectionId"]; ExportAlignmentName exportAlignName = new ExportAlignmentName(); await exportAlignName.StartExportAlignmentName(credentials, projectId, versionId, connectionId, _env.WebRootPath); return(Ok()); }
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IWebHostEnvironment env) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); // clean up on every run... :) Controllers.ExportAlignmentName exportAlignmentName = new Controllers.ExportAlignmentName(); exportAlignmentName.ClearAccount(); } app.UseRouting(); app.UseEndpoints(routes => { routes.MapHub <Controllers.DesignAutomationHub>("/api/signalr/designautomation"); }); app.UseDefaultFiles(); app.UseStaticFiles(); app.UseHttpsRedirection(); app.UseMvc(); }