216 lines
8.5 KiB
C#
216 lines
8.5 KiB
C#
using System;
|
|
using System.Data.Entity;
|
|
using System.Linq;
|
|
using EnVisage.Code;
|
|
using System.Collections.Generic;
|
|
|
|
namespace EnVisage.Models
|
|
{
|
|
public class ForecastDashboardModel
|
|
{
|
|
public Guid Id { get; set; }
|
|
public Guid ProjectId { get; set; }
|
|
public ScenarioType? Type { get; set; }
|
|
public string Name { get; set; }
|
|
public string ProjectName { get; set; }
|
|
public string TeamName { get; set; }
|
|
public Guid TeamId { get; set; }
|
|
public decimal? ProjectedRevenue { get; set; }
|
|
public decimal? ExpectedGrossMargin { get; set; }
|
|
public decimal? ExpectedGrossMargin_LM { get; set; }
|
|
public decimal? CalculatedGrossMargin { get; set; }
|
|
public decimal? CalculatedGrossMargin_LM { get; set; }
|
|
public int? UseLMMargin { get; set; }
|
|
public decimal? CGSplit { get; set; }
|
|
public decimal? EFXSplit { get; set; }
|
|
public DateTime? StartDate { get; set; }
|
|
public DateTime? EndDate { get; set; }
|
|
public int? Duration { get; set; }
|
|
public int? Priority { get; set; }
|
|
public decimal Probability { get; set; }
|
|
public decimal? TDDirectCosts { get; set; }
|
|
public decimal? TDDirectCosts_LM { get; set; }
|
|
public decimal? BUDirectCosts { get; set; }
|
|
public decimal? BUDirectCosts_LM { get; set; }
|
|
public ScenarioStatus? ScenarioStatus { get; set; }
|
|
public int? InactiveCount { get; set; }
|
|
public Dictionary<string,string> InactiveScenarios { get; set; }
|
|
public string Color { get; set; }
|
|
public decimal? CostSavings { get; set; }
|
|
public int? CostSavingsDuration { get; set; }
|
|
public DateTime? ROIDate { get; set; }
|
|
public DateTime? ProjectDeadline { get; set; }
|
|
public string HardSoftSavings { get; set; }
|
|
public string StrategicGoals { get; set; }
|
|
|
|
// SA. ENV-607. Performance values. Begin
|
|
// public decimal? PerformanceForecastCost { get; set; }
|
|
// public decimal? PerformanceActualCost { get; set; }
|
|
public decimal? PerformanceThresholdYellow { get; set; }
|
|
public decimal? PerformanceThresholdRed { get; set; }
|
|
public string PerformanceColor { get; set; }
|
|
// SA. ENV-607. End
|
|
|
|
public string ProjectStatus { get; set; }
|
|
|
|
public List<Guid> Groups { get; set; }
|
|
|
|
public ForecastDashboardModel(Guid id, string name, ScenarioType? type, decimal? projectedRevenue, decimal? expectedGrossMargin, decimal? expectedGrossMargin_LM, decimal? calculatedGrossMargin,
|
|
decimal? calculatedGrossMargin_LM, decimal? cGSplit, decimal? eFXSplit, DateTime? startDate, DateTime? endDate, int? duration, int? priority, decimal probability,
|
|
decimal? tDDirectCosts, decimal? tDDirectCosts_LM, decimal? bUDirectCosts, decimal? bUDirectCosts_LM, decimal? costSavings, int? costSavingsDuration, DateTime? rOIDate, string hardSoftSavings, DateTime? projectDeadline,
|
|
string projectStatus)
|
|
{
|
|
Id = id;
|
|
Name = name;
|
|
Type = type;
|
|
ProjectedRevenue = projectedRevenue;
|
|
ExpectedGrossMargin = expectedGrossMargin;
|
|
ExpectedGrossMargin_LM = expectedGrossMargin_LM;
|
|
CalculatedGrossMargin = calculatedGrossMargin;
|
|
CalculatedGrossMargin_LM = CalculatedGrossMargin_LM;
|
|
CGSplit = cGSplit;
|
|
EFXSplit = eFXSplit;
|
|
StartDate = startDate;
|
|
EndDate = endDate;
|
|
Duration = duration;
|
|
Priority = priority;
|
|
Probability = probability;
|
|
TDDirectCosts = tDDirectCosts;
|
|
TDDirectCosts_LM = tDDirectCosts_LM;
|
|
BUDirectCosts = bUDirectCosts;
|
|
BUDirectCosts_LM = bUDirectCosts_LM;
|
|
CostSavings = costSavings;
|
|
CostSavingsDuration = costSavingsDuration;
|
|
ROIDate = rOIDate;
|
|
HardSoftSavings = hardSoftSavings;
|
|
PerformanceColor = String.Empty;
|
|
ProjectDeadline = projectDeadline;
|
|
ProjectStatus = projectStatus;
|
|
}
|
|
|
|
public ForecastDashboardModel()
|
|
{
|
|
PerformanceColor = String.Empty;
|
|
}
|
|
|
|
}
|
|
|
|
public class ForecastDashboardOptionsModel
|
|
{
|
|
public string MenuId { get; set; }
|
|
public string AdditionalFilterParams { get; set; }
|
|
public string SourcePageModel { get; set; }
|
|
}
|
|
|
|
public class ForecastDashboardFilterModel
|
|
{
|
|
public DateTime? StartDate { get; set; }
|
|
public DateTime? EndDate { get; set; }
|
|
//public ScenarioType? Type { get; set; }
|
|
public List<Guid> ProjectStatuses { get; set; }
|
|
public List<Guid> Teams { get; set; }
|
|
public List<Guid> Views { get; set; }
|
|
public List<Guid> ProjectTypes { get; set; }
|
|
public bool FilterGroupByTeam { get; set; }
|
|
public List<Guid> FilterGroups { get; set; }
|
|
public Dictionary<string, string> AdditionalParams { get; set; }
|
|
public List<Guid> StrategicGoals { get; set; }
|
|
|
|
public ForecastDashboardFilterModel()
|
|
{
|
|
ProjectStatuses = new List<Guid>();
|
|
Teams = new List<Guid>();
|
|
Views = new List<Guid>();
|
|
ProjectTypes = new List<Guid>();
|
|
FilterGroups = new List<Guid>();
|
|
StrategicGoals = new List<Guid>();
|
|
AdditionalParams = new Dictionary<string, string>();
|
|
}
|
|
}
|
|
|
|
public class ForecastDashboardChartFilterModel
|
|
{
|
|
public DateTime? StartDate { get; set; }
|
|
public DateTime? EndDate { get; set; }
|
|
public string Type { get; set; }
|
|
public List<Guid> ProjectStatuses { get; set; }
|
|
public List<Guid> Teams { get; set; }
|
|
public List<Guid> Views { get; set; }
|
|
public List<Guid> ProjectTypes { get; set; }
|
|
public List<Guid> FilterGroups { get; set; }
|
|
public bool IsLaborMode { get; set; }
|
|
public bool IsUOMHours { get; set; }
|
|
public List<Guid> StrategicGoals { get; set; }
|
|
public Dictionary<string, string> AdditionalParams { get; set; }
|
|
|
|
public ForecastDashboardChartFilterModel()
|
|
{
|
|
ProjectStatuses = new List<Guid>();
|
|
Teams = new List<Guid>();
|
|
Views = new List<Guid>();
|
|
ProjectTypes = new List<Guid>();
|
|
FilterGroups = new List<Guid>();
|
|
StrategicGoals = new List<Guid>();
|
|
AdditionalParams = new Dictionary<string, string>();
|
|
}
|
|
}
|
|
|
|
public class ForecastDashboardPieChartFilterModel
|
|
{
|
|
public DateTime? StartDate { get; set; }
|
|
public DateTime? EndDate { get; set; }
|
|
public bool IsLaborMode { get; set; }
|
|
public List<Guid> FilterGroups { get; set; }
|
|
public List<Guid> ProjectTypes { get; set; }
|
|
public List<Guid> ProjectStatuses { get; set; }
|
|
public List<Guid> Teams { get; set; }
|
|
public List<Guid> Views { get; set; }
|
|
public List<Guid> StrategicGoals { get; set; }
|
|
public Dictionary<string, string> AdditionalParams { get; set; }
|
|
public string PresetColor { get; set; }
|
|
public bool PieForecastCost { get; set; }
|
|
|
|
public ForecastDashboardPieChartFilterModel()
|
|
{
|
|
FilterGroups = new List<Guid>();
|
|
ProjectTypes = new List<Guid>();
|
|
ProjectStatuses = new List<Guid>();
|
|
Teams = new List<Guid>();
|
|
Views = new List<Guid>();
|
|
StrategicGoals = new List<Guid>();
|
|
AdditionalParams = new Dictionary<string, string>();
|
|
}
|
|
}
|
|
|
|
public class ForecastDashboardPerformanceGraphFilterModel
|
|
{
|
|
public int GraphMode { get; set; }
|
|
public List<Guid> FilterGroups { get; set; }
|
|
public List<Guid> ProjectTypes { get; set; }
|
|
public List<Guid> Teams { get; set; }
|
|
public List<Guid> Views { get; set; }
|
|
|
|
public ForecastDashboardPerformanceGraphFilterModel()
|
|
{
|
|
FilterGroups = new List<Guid>();
|
|
ProjectTypes = new List<Guid>();
|
|
Teams = new List<Guid>();
|
|
Views = new List<Guid>();
|
|
}
|
|
}
|
|
|
|
public class ForecastDashboardInactiveScenariosFilterModel
|
|
{
|
|
public Guid? ProjectId { get; set; }
|
|
public DateTime? StartDate { get; set; }
|
|
public DateTime? EndDate { get; set; }
|
|
public ScenarioType? ScenarioType { get; set; }
|
|
public List<Guid> FilterGroups { get; set; }
|
|
public Guid? Shown { get; set; }
|
|
|
|
public ForecastDashboardInactiveScenariosFilterModel()
|
|
{
|
|
FilterGroups = new List<Guid>();
|
|
}
|
|
}
|
|
} |