Notify complete from Piscal to LeafWeb

This commit is contained in:
2016-05-04 12:12:35 -04:00
parent e9a9ae186c
commit e0788154ec
5 changed files with 23 additions and 7 deletions
+7 -6
View File
@@ -1,10 +1,6 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using System.IO.Compression;
using System.Linq;
using System.Runtime.InteropServices.ComTypes;
using System.Web;
using System.Web.Mvc;
using LeafWeb.Core.Entities;
@@ -104,15 +100,20 @@ namespace LeafWeb.Web.Controllers
return View("Index", viewModel);
}
public FileContentResult DownloadResults(int d)
public FileContentResult DownloadResults(int id)
{
var leafInput = DataService.GetLeafInput(d);
var leafInput = DataService.GetLeafInput(id);
var zip = leafInput.GetOutputFileZip();
return new FileContentResult(zip, "application/zip") {FileDownloadName = leafInput.Identifier + ".zip"};
}
public void NotifyComplete()
{
HangfireStartup.TriggerPiscalProcessQueue();
}
private FileInfo[] GetBackloadDirectoryFiles(string directoryName)
{
var path = Path.Combine(Server.MapPath("~/Files/"), directoryName + "\\");