diff --git a/Core/ProfitTrailer/StrategyHelper.cs b/Core/ProfitTrailer/StrategyHelper.cs index 68e7508..4b7a363 100644 --- a/Core/ProfitTrailer/StrategyHelper.cs +++ b/Core/ProfitTrailer/StrategyHelper.cs @@ -269,40 +269,40 @@ namespace Core.ProfitTrailer result = String.Concat(strategyLetter, "LOSS"); break; case "smagain": - result = String.Concat(strategyLetter, "SMAG"); + result = String.Concat(strategyLetter, "SMA-G"); break; case "emagain": - result = String.Concat(strategyLetter, "EMAG"); + result = String.Concat(strategyLetter, "EMA-G"); break; case "hmagain": - result = String.Concat(strategyLetter, "HMAG"); + result = String.Concat(strategyLetter, "HMA-G"); break; case "dmagain": - result = String.Concat(strategyLetter, "DMAG"); + result = String.Concat(strategyLetter, "DMA-G"); break; case "smaspread": - result = String.Concat(strategyLetter, "SMAS"); + result = String.Concat(strategyLetter, "SMA-S"); break; case "emaspread": - result = String.Concat(strategyLetter, "EMAS"); + result = String.Concat(strategyLetter, "EMA-S"); break; case "hmaspread": - result = String.Concat(strategyLetter, "HMAS"); + result = String.Concat(strategyLetter, "HMA-S"); break; case "dmaspread": - result = String.Concat(strategyLetter, "DMAS"); + result = String.Concat(strategyLetter, "DMA-S"); break; case "smacross": - result = String.Concat(strategyLetter, "SMAC"); + result = String.Concat(strategyLetter, "SMA-C"); break; case "emacross": - result = String.Concat(strategyLetter, "EMAC"); + result = String.Concat(strategyLetter, "EMA-C"); break; case "hmacross": - result = String.Concat(strategyLetter, "HMAC"); + result = String.Concat(strategyLetter, "HMA-C"); break; case "dmacross": - result = String.Concat(strategyLetter, "DMAC"); + result = String.Concat(strategyLetter, "DMA-C"); break; case "rsi": result = String.Concat(strategyLetter, "RSI"); @@ -314,13 +314,13 @@ namespace Core.ProfitTrailer result = String.Concat(strategyLetter, "SRSI"); break; case "stochrsik": - result = String.Concat(strategyLetter, "SRSIK"); + result = String.Concat(strategyLetter, "SRSI-K"); break; case "stochrsid": - result = String.Concat(strategyLetter, "SRSID"); + result = String.Concat(strategyLetter, "SRSI-D"); break; case "stochrsicross": - result = String.Concat(strategyLetter, "SRSIC"); + result = String.Concat(strategyLetter, "SRSI-C"); break; case "macd": result = String.Concat(strategyLetter, "MACD"); @@ -359,19 +359,19 @@ namespace Core.ProfitTrailer result = String.Concat(strategyLetter, "FIXED"); break; case "lowatrband": - result = String.Concat(strategyLetter, "LATR"); + result = String.Concat(strategyLetter, "L-ATR"); break; case "highatrband": - result = String.Concat(strategyLetter, "HATR"); + result = String.Concat(strategyLetter, "H-ATR"); break; case "atrpercentage": - result = String.Concat(strategyLetter, "ATRPCT"); + result = String.Concat(strategyLetter, "ATR-PCT"); break; case "vwappercentage": result = String.Concat(strategyLetter, "VWAP"); break; case "mvwappercentage": - result = String.Concat(strategyLetter, "MVWAP"); + result = String.Concat(strategyLetter, "M-VWAP"); break; case "btcdominance": result = String.Concat(strategyLetter, "BTCDOM"); @@ -425,13 +425,13 @@ namespace Core.ProfitTrailer result = String.Concat(strategyLetter, "NODCA"); break; case "combimagain": - result = String.Concat(strategyLetter, "COMBIG"); + result = String.Concat(strategyLetter, "COMBI-G"); break; case "combimaspread": - result = String.Concat(strategyLetter, "COMBIS"); + result = String.Concat(strategyLetter, "COMBI-S"); break; case "combimacross": - result = String.Concat(strategyLetter, "COMBIC"); + result = String.Concat(strategyLetter, "COMBI-C"); break; case "macdpercentage": result = String.Concat(strategyLetter, "MACDPERC"); diff --git a/Monitor/Pages/SalesAnalyzer.cshtml b/Monitor/Pages/SalesAnalyzer.cshtml index f7716d2..cdf53d3 100644 --- a/Monitor/Pages/SalesAnalyzer.cshtml +++ b/Monitor/Pages/SalesAnalyzer.cshtml @@ -19,13 +19,13 @@ @{ - double currentBalance = Model.PTData.GetCurrentBalance(); - string currentBalanceString = currentBalance.ToString("#,#0.00000000", new System.Globalization.CultureInfo("en-US")); - if (currentBalance > 100) { - currentBalanceString = Math.Round(currentBalance, 2).ToString("#,#0.00", new System.Globalization.CultureInfo("en-US")); + string totalCurrentValueString = Model.totalCurrentValue.ToString("#,#0.00000000", new System.Globalization.CultureInfo("en-US")); + if (Model.totalCurrentValue > 100) + { + totalCurrentValueString = Math.Round(Model.totalCurrentValue, 2).ToString("#,#0.00", new System.Globalization.CultureInfo("en-US")); } } - Account Value:   @currentBalanceString   @Model.Summary.MainMarket + Total Account Value:   @totalCurrentValueString @Model.Summary.MainMarket Starting Value:   @Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance   @Model.Summary.MainMarket diff --git a/Monitor/Pages/SalesAnalyzer.cshtml.cs b/Monitor/Pages/SalesAnalyzer.cshtml.cs index dd8f41a..7c262bd 100644 --- a/Monitor/Pages/SalesAnalyzer.cshtml.cs +++ b/Monitor/Pages/SalesAnalyzer.cshtml.cs @@ -20,12 +20,13 @@ namespace Monitor.Pages public Dictionary DailyGains = new Dictionary(); public Dictionary MonthlyGains = new Dictionary(); public DateTimeOffset DateTimeNow = Constants.confMinDate; - + public double totalCurrentValue = 0; public void OnGet() { base.Init(); BindData(); + BuildTCV(); } private void BindData() @@ -135,5 +136,20 @@ namespace Monitor.Pages } } } + + private void BuildTCV() + { + double AvailableBalance = PTData.GetCurrentBalance(); + foreach (Core.Main.DataObjects.PTMagicData.DCALogData dcaLogEntry in PTData.DCALog) + { + totalCurrentValue = totalCurrentValue + ((dcaLogEntry.Amount * dcaLogEntry.CurrentPrice) / dcaLogEntry.Leverage); + } + totalCurrentValue = totalCurrentValue + AvailableBalance; + } + + + + + } } diff --git a/Monitor/Pages/_get/DashboardBottom.cshtml b/Monitor/Pages/_get/DashboardBottom.cshtml index 7964e06..35534aa 100644 --- a/Monitor/Pages/_get/DashboardBottom.cshtml +++ b/Monitor/Pages/_get/DashboardBottom.cshtml @@ -32,10 +32,14 @@ } }
-
-
Start: @Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance @Model.Summary.MainMarket
-
TCV: @totalCurrentValueString @Model.Summary.MainMarket
-
Gain: @Math.Round(((Model.totalCurrentValue - Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance) / Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance) * 100, 2)%
+
+ + Start:   @Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance @Model.Summary.MainMarket +     Gain: @Math.Round(((Model.totalCurrentValue - Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance) / Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance) * 100, 2)% + +
+
+ TCV:   @totalCurrentValueString @Model.Summary.MainMarket
diff --git a/Monitor/Pages/_get/DashboardBottom.cshtml.cs b/Monitor/Pages/_get/DashboardBottom.cshtml.cs index 2622f93..54ad18a 100644 --- a/Monitor/Pages/_get/DashboardBottom.cshtml.cs +++ b/Monitor/Pages/_get/DashboardBottom.cshtml.cs @@ -19,10 +19,6 @@ namespace Monitor.Pages public string LastGlobalSetting = "Default"; public DateTimeOffset DateTimeNow = Constants.confMinDate; public string AssetDistributionData = ""; - public double currentBalance = 0; - public string currentBalanceString = ""; - public double TotalBagCost = 0; - public double TotalBagValue = 0; public double totalCurrentValue = 0; public void OnGet() { @@ -171,7 +167,6 @@ namespace Monitor.Pages foreach (Core.Main.DataObjects.PTMagicData.DCALogData dcaLogEntry in PTData.DCALog) { - Core.Main.DataObjects.PTMagicData.MarketPairSummary mps = null; string sellStrategyText = Core.ProfitTrailer.StrategyHelper.GetStrategyText(Summary, dcaLogEntry.SellStrategies, dcaLogEntry.SellStrategy, isSellStrategyTrue, isTrailingSellActive); // Aggregate totals diff --git a/Monitor/Pages/_get/DashboardTop.cshtml b/Monitor/Pages/_get/DashboardTop.cshtml index be56fab..c743608 100644 --- a/Monitor/Pages/_get/DashboardTop.cshtml +++ b/Monitor/Pages/_get/DashboardTop.cshtml @@ -62,6 +62,7 @@ @string.Format("{0}%", (buyLogEntry.PercChange * 100).ToString("#,#0.00")) @string.Format("{0}", (buyLogEntry.Volume24h).ToString()) @buyLogEntry.CurrentPrice.ToString("#,#0.00000000", new System.Globalization.CultureInfo("en-US")) + @if (buyDisabled) { @Html.Raw(buyStrategyText) } else {