Admin import functional

This commit is contained in:
2014-02-02 10:19:02 -05:00
parent 13c5c6cde5
commit 3ab80e283a
41 changed files with 2809 additions and 101 deletions
@@ -89,7 +89,7 @@ namespace MileageTraker.Web.ViewModels.CreateLog
public IEnumerable<ValidationResult> Validate(ValidationContext validationContext)
{
if (LogType == MileageLogType.GasPurchase
&& (string.IsNullOrEmpty(GasPurchased) || double.Parse(GasPurchased) == 0))
&& (string.IsNullOrEmpty(GasPurchased) || Math.Abs(double.Parse(GasPurchased) - 0) < double.Epsilon))
yield return new ValidationResult("Enter amount of gas purchased", new [] {"GasPurchased"});
if (LogType.Value == 0)