// Copyright 1998-2017 Epic Games, Inc. All Rights Reserved.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web.Mvc;
using Tools.CrashReporter.CrashReportWebSite.Controllers;
using System.IO;
namespace Tools.CrashReporter.CrashReportWebSite.Models
{
///
/// The view model for the Crash summary page.
///
public class CSV_ViewModel
{
/// A container of sorted CSV rows.
public List CSVRows { get; set; }
/// The date of the earliest Crash.
public long DateFrom { get; set; }
/// The date of the most recent Crash.
public long DateTo { get; set; }
/// The date of the earliest Crash.
public DateTime DateTimeFrom { get; set; }
/// The date of the most recent Crash.
public DateTime DateTimeTo { get; set; }
/// Unique Anonymous Crashes
public int UniqueCrashesFiltered { get; set; }
/// Total Affected Users
public int AffectedUsersFiltered { get; set; }
/// Total Crashes.
public int TotalCrashes { get; set; }
/// Total Crashes year to date.
public int TotalCrashesYearToDate { get; set; }
/// Total Crashes.
public int CrashesFilteredWithDate { get; set; }
/// Pathname where the CSV file is saved.
public string CSVPathname { get; set; }
/// Filename of the CSV file
public string GetCSVFilename()
{
return Path.GetFileName( CSVPathname );
}
/// Directory where the CSV files are saved.
public string GetCSVDirectory()
{
return Path.GetDirectoryName( CSVPathname );
}
/// Public directory where the CSV files are saved.
public string GetCSVPublicDirectory()
{
return @"\\DEVWEB-02\CrashReporterCSV";
}
/// Time spent in generating this site, formatted as a string.
public string GenerationTime { get; set; }
/// User input from the client.
public FormCollection FormCollection { get; set; }
}
}