Cleanup - charter will now display arbitrary count of graphs

This commit is contained in:
2018-08-28 20:47:27 -04:00
parent ad41465c05
commit 590f2e68ef
4 changed files with 4 additions and 7 deletions
+1 -1
View File
@@ -6,6 +6,6 @@ namespace LeafWeb.Core.Charter
{
public string CurveId { get; set; }
public IList<CurveParamSet> ParamSets { get; set; } = new List<CurveParamSet>();
public IList<CurveParamSet> ParamSets { get; } = new List<CurveParamSet>();
}
}
-3
View File
@@ -1,10 +1,7 @@
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Linq;
using System.Linq.Expressions;
using System.Reflection;
using Fasterflect;
namespace LeafWeb.Core.Utility
{
+1 -1
View File
@@ -1 +1 @@
C:\Users\poprhythm\AppData\Local\Temp\Temporary ASP.NET Files\vs\f80e29bb\faae20bf\App_Web_all.generated.cs.8f9494c4.u298vp5l.dll
C:\Users\poprhythm\AppData\Local\Temp\Temporary ASP.NET Files\vs\f80e29bb\faae20bf\App_Web_all.generated.cs.8f9494c4.0nm7wrgc.dll
+2 -2
View File
@@ -78,7 +78,7 @@ namespace LeafWeb.WebCms.Controllers
return new HttpStatusCodeResult(HttpStatusCode.NotFound, $"Unhandled exception thrown wihle parsing {leafOutputFile.Filename}.");
}
if (curveData == null)
if (curveData == null || curveData.ParamSets.Count == 0)
return new HttpStatusCodeResult(HttpStatusCode.NotFound, $"No curve data was loaded from {leafOutputFile.Filename}.");
var charts = GetChartBitmaps(curveData).ToList();
@@ -104,7 +104,7 @@ namespace LeafWeb.WebCms.Controllers
LeafGasComparison[] leafGasComparisons;
using (var parser = new LeafGasComparisonParser(fileContents))
leafGasComparisons = parser.Parse(curveId);
return CurveDataConverter.Convert(leafGasComparisons).First();
return CurveDataConverter.Convert(leafGasComparisons).FirstOrDefault();
}
catch (Exception e)
{