Enhance management cockpit analysis
This commit is contained in:
@@ -7,6 +7,35 @@ public class ManagementCockpitFileOption
|
||||
public DateTime LastModified { get; set; }
|
||||
}
|
||||
|
||||
public static class ManagementCockpitValueFieldKeys
|
||||
{
|
||||
public const string SalesPriceValue = nameof(SalesPriceValue);
|
||||
public const string Quantity = nameof(Quantity);
|
||||
public const string StandardCost = nameof(StandardCost);
|
||||
public const string StandardCostTotal = nameof(StandardCostTotal);
|
||||
}
|
||||
|
||||
public static class ManagementCockpitCurrencyOptions
|
||||
{
|
||||
public const string Native = "NATIVE";
|
||||
public const string Eur = "EUR";
|
||||
public const string Usd = "USD";
|
||||
}
|
||||
|
||||
public class ManagementCockpitValueFieldOption
|
||||
{
|
||||
public string Key { get; set; } = string.Empty;
|
||||
public string Label { get; set; } = string.Empty;
|
||||
public bool IsCurrencyAmount { get; set; }
|
||||
}
|
||||
|
||||
public class ManagementCockpitAnalysisOptions
|
||||
{
|
||||
public string ValueField { get; set; } = ManagementCockpitValueFieldKeys.SalesPriceValue;
|
||||
public List<string> AdditionalValueFields { get; set; } = [];
|
||||
public string TargetCurrency { get; set; } = ManagementCockpitCurrencyOptions.Native;
|
||||
}
|
||||
|
||||
public class ManagementCockpitSummary
|
||||
{
|
||||
public string Land { get; set; } = string.Empty;
|
||||
@@ -15,6 +44,11 @@ public class ManagementCockpitSummary
|
||||
public int RowCount { get; set; }
|
||||
public int InvoiceCount { get; set; }
|
||||
public int CustomerCount { get; set; }
|
||||
public string ValueFieldKey { get; set; } = ManagementCockpitValueFieldKeys.SalesPriceValue;
|
||||
public string ValueFieldLabel { get; set; } = "Sales Price/Value";
|
||||
public string DisplayCurrency { get; set; } = string.Empty;
|
||||
public int MissingExchangeRateCount { get; set; }
|
||||
public decimal AggregatedValueTotal { get; set; }
|
||||
public decimal SalesValueTotal { get; set; }
|
||||
public decimal EstimatedCostTotal { get; set; }
|
||||
public decimal EstimatedMarginTotal { get; set; }
|
||||
@@ -53,6 +87,8 @@ public class ManagementCockpitCentralFilter
|
||||
{
|
||||
public int Year { get; set; }
|
||||
public int? Month { get; set; }
|
||||
public string ValueField { get; set; } = ManagementCockpitValueFieldKeys.SalesPriceValue;
|
||||
public string TargetCurrency { get; set; } = ManagementCockpitCurrencyOptions.Native;
|
||||
}
|
||||
|
||||
public class ManagementCockpitCentralSummary
|
||||
@@ -62,6 +98,11 @@ public class ManagementCockpitCentralSummary
|
||||
public int SiteCount { get; set; }
|
||||
public int CountryCount { get; set; }
|
||||
public int CurrencyCount { get; set; }
|
||||
public string ValueFieldKey { get; set; } = ManagementCockpitValueFieldKeys.SalesPriceValue;
|
||||
public string ValueFieldLabel { get; set; } = "Sales Price/Value";
|
||||
public string DisplayCurrency { get; set; } = string.Empty;
|
||||
public decimal ValueTotal { get; set; }
|
||||
public int MissingExchangeRateCount { get; set; }
|
||||
public DateTime? PeriodStart { get; set; }
|
||||
public DateTime? PeriodEnd { get; set; }
|
||||
}
|
||||
@@ -74,9 +115,19 @@ public class ManagementCockpitTimeValueRow
|
||||
public int? Day { get; set; }
|
||||
public string Currency { get; set; } = string.Empty;
|
||||
public decimal SalesValue { get; set; }
|
||||
public Dictionary<string, ManagementCockpitAggregatedFieldValue> AdditionalValues { get; set; } = new(StringComparer.OrdinalIgnoreCase);
|
||||
public int RowCount { get; set; }
|
||||
}
|
||||
|
||||
public class ManagementCockpitAggregatedFieldValue
|
||||
{
|
||||
public string FieldKey { get; set; } = string.Empty;
|
||||
public string Label { get; set; } = string.Empty;
|
||||
public string Currency { get; set; } = string.Empty;
|
||||
public decimal Value { get; set; }
|
||||
public int MissingExchangeRateCount { get; set; }
|
||||
}
|
||||
|
||||
public class ManagementCockpitDimensionValueRow
|
||||
{
|
||||
public string Label { get; set; } = string.Empty;
|
||||
@@ -91,6 +142,7 @@ public class ManagementCockpitCentralResult
|
||||
public ManagementCockpitCentralFilter Filter { get; set; } = new();
|
||||
public ManagementCockpitCentralSummary Summary { get; set; } = new();
|
||||
public List<string> Notices { get; set; } = [];
|
||||
public List<ManagementCockpitValueFieldOption> AdditionalValueFields { get; set; } = [];
|
||||
public List<ManagementCockpitTimeValueRow> YearlyTotals { get; set; } = [];
|
||||
public List<ManagementCockpitTimeValueRow> MonthlyTotals { get; set; } = [];
|
||||
public List<ManagementCockpitTimeValueRow> DailyTotals { get; set; } = [];
|
||||
|
||||
Reference in New Issue
Block a user