commit
7816cec1ff
|
@ -269,40 +269,40 @@ namespace Core.ProfitTrailer
|
||||||
result = String.Concat(strategyLetter, "LOSS");
|
result = String.Concat(strategyLetter, "LOSS");
|
||||||
break;
|
break;
|
||||||
case "smagain":
|
case "smagain":
|
||||||
result = String.Concat(strategyLetter, "SMAG");
|
result = String.Concat(strategyLetter, "SMA-G");
|
||||||
break;
|
break;
|
||||||
case "emagain":
|
case "emagain":
|
||||||
result = String.Concat(strategyLetter, "EMAG");
|
result = String.Concat(strategyLetter, "EMA-G");
|
||||||
break;
|
break;
|
||||||
case "hmagain":
|
case "hmagain":
|
||||||
result = String.Concat(strategyLetter, "HMAG");
|
result = String.Concat(strategyLetter, "HMA-G");
|
||||||
break;
|
break;
|
||||||
case "dmagain":
|
case "dmagain":
|
||||||
result = String.Concat(strategyLetter, "DMAG");
|
result = String.Concat(strategyLetter, "DMA-G");
|
||||||
break;
|
break;
|
||||||
case "smaspread":
|
case "smaspread":
|
||||||
result = String.Concat(strategyLetter, "SMAS");
|
result = String.Concat(strategyLetter, "SMA-S");
|
||||||
break;
|
break;
|
||||||
case "emaspread":
|
case "emaspread":
|
||||||
result = String.Concat(strategyLetter, "EMAS");
|
result = String.Concat(strategyLetter, "EMA-S");
|
||||||
break;
|
break;
|
||||||
case "hmaspread":
|
case "hmaspread":
|
||||||
result = String.Concat(strategyLetter, "HMAS");
|
result = String.Concat(strategyLetter, "HMA-S");
|
||||||
break;
|
break;
|
||||||
case "dmaspread":
|
case "dmaspread":
|
||||||
result = String.Concat(strategyLetter, "DMAS");
|
result = String.Concat(strategyLetter, "DMA-S");
|
||||||
break;
|
break;
|
||||||
case "smacross":
|
case "smacross":
|
||||||
result = String.Concat(strategyLetter, "SMAC");
|
result = String.Concat(strategyLetter, "SMA-C");
|
||||||
break;
|
break;
|
||||||
case "emacross":
|
case "emacross":
|
||||||
result = String.Concat(strategyLetter, "EMAC");
|
result = String.Concat(strategyLetter, "EMA-C");
|
||||||
break;
|
break;
|
||||||
case "hmacross":
|
case "hmacross":
|
||||||
result = String.Concat(strategyLetter, "HMAC");
|
result = String.Concat(strategyLetter, "HMA-C");
|
||||||
break;
|
break;
|
||||||
case "dmacross":
|
case "dmacross":
|
||||||
result = String.Concat(strategyLetter, "DMAC");
|
result = String.Concat(strategyLetter, "DMA-C");
|
||||||
break;
|
break;
|
||||||
case "rsi":
|
case "rsi":
|
||||||
result = String.Concat(strategyLetter, "RSI");
|
result = String.Concat(strategyLetter, "RSI");
|
||||||
|
@ -314,13 +314,13 @@ namespace Core.ProfitTrailer
|
||||||
result = String.Concat(strategyLetter, "SRSI");
|
result = String.Concat(strategyLetter, "SRSI");
|
||||||
break;
|
break;
|
||||||
case "stochrsik":
|
case "stochrsik":
|
||||||
result = String.Concat(strategyLetter, "SRSIK");
|
result = String.Concat(strategyLetter, "SRSI-K");
|
||||||
break;
|
break;
|
||||||
case "stochrsid":
|
case "stochrsid":
|
||||||
result = String.Concat(strategyLetter, "SRSID");
|
result = String.Concat(strategyLetter, "SRSI-D");
|
||||||
break;
|
break;
|
||||||
case "stochrsicross":
|
case "stochrsicross":
|
||||||
result = String.Concat(strategyLetter, "SRSIC");
|
result = String.Concat(strategyLetter, "SRSI-C");
|
||||||
break;
|
break;
|
||||||
case "macd":
|
case "macd":
|
||||||
result = String.Concat(strategyLetter, "MACD");
|
result = String.Concat(strategyLetter, "MACD");
|
||||||
|
@ -359,19 +359,19 @@ namespace Core.ProfitTrailer
|
||||||
result = String.Concat(strategyLetter, "FIXED");
|
result = String.Concat(strategyLetter, "FIXED");
|
||||||
break;
|
break;
|
||||||
case "lowatrband":
|
case "lowatrband":
|
||||||
result = String.Concat(strategyLetter, "LATR");
|
result = String.Concat(strategyLetter, "L-ATR");
|
||||||
break;
|
break;
|
||||||
case "highatrband":
|
case "highatrband":
|
||||||
result = String.Concat(strategyLetter, "HATR");
|
result = String.Concat(strategyLetter, "H-ATR");
|
||||||
break;
|
break;
|
||||||
case "atrpercentage":
|
case "atrpercentage":
|
||||||
result = String.Concat(strategyLetter, "ATRPCT");
|
result = String.Concat(strategyLetter, "ATR-PCT");
|
||||||
break;
|
break;
|
||||||
case "vwappercentage":
|
case "vwappercentage":
|
||||||
result = String.Concat(strategyLetter, "VWAP");
|
result = String.Concat(strategyLetter, "VWAP");
|
||||||
break;
|
break;
|
||||||
case "mvwappercentage":
|
case "mvwappercentage":
|
||||||
result = String.Concat(strategyLetter, "MVWAP");
|
result = String.Concat(strategyLetter, "M-VWAP");
|
||||||
break;
|
break;
|
||||||
case "btcdominance":
|
case "btcdominance":
|
||||||
result = String.Concat(strategyLetter, "BTCDOM");
|
result = String.Concat(strategyLetter, "BTCDOM");
|
||||||
|
@ -425,13 +425,13 @@ namespace Core.ProfitTrailer
|
||||||
result = String.Concat(strategyLetter, "NODCA");
|
result = String.Concat(strategyLetter, "NODCA");
|
||||||
break;
|
break;
|
||||||
case "combimagain":
|
case "combimagain":
|
||||||
result = String.Concat(strategyLetter, "COMBIG");
|
result = String.Concat(strategyLetter, "COMBI-G");
|
||||||
break;
|
break;
|
||||||
case "combimaspread":
|
case "combimaspread":
|
||||||
result = String.Concat(strategyLetter, "COMBIS");
|
result = String.Concat(strategyLetter, "COMBI-S");
|
||||||
break;
|
break;
|
||||||
case "combimacross":
|
case "combimacross":
|
||||||
result = String.Concat(strategyLetter, "COMBIC");
|
result = String.Concat(strategyLetter, "COMBI-C");
|
||||||
break;
|
break;
|
||||||
case "macdpercentage":
|
case "macdpercentage":
|
||||||
result = String.Concat(strategyLetter, "MACDPERC");
|
result = String.Concat(strategyLetter, "MACDPERC");
|
||||||
|
|
|
@ -19,13 +19,13 @@
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
@{
|
@{
|
||||||
double currentBalance = Model.PTData.GetCurrentBalance();
|
string totalCurrentValueString = Model.totalCurrentValue.ToString("#,#0.00000000", new System.Globalization.CultureInfo("en-US"));
|
||||||
string currentBalanceString = currentBalance.ToString("#,#0.00000000", new System.Globalization.CultureInfo("en-US"));
|
if (Model.totalCurrentValue > 100)
|
||||||
if (currentBalance > 100) {
|
{
|
||||||
currentBalanceString = Math.Round(currentBalance, 2).ToString("#,#0.00", new System.Globalization.CultureInfo("en-US"));
|
totalCurrentValueString = Math.Round(Model.totalCurrentValue, 2).ToString("#,#0.00", new System.Globalization.CultureInfo("en-US"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
<th class="m-t-0 header-title text-left">Account Value: <text class="text-autocolor"> @currentBalanceString @Model.Summary.MainMarket </text> <small> <i class="fa fa-info-circle text-muted" data-toggle="tooltip" data-placement="top" title="This is based on your sales history, entries on the Transactions page and any currently held positions."></i></small></th>
|
<th class="m-t-0 header-title text-left">Total Account Value: <text class="text-autocolor"> @totalCurrentValueString @Model.Summary.MainMarket </text> <small> <i class="fa fa-info-circle text-muted" data-toggle="tooltip" data-placement="top" title="This is based on your sales history, entries on the Transactions page and any currently held positions."></i></small></th>
|
||||||
<th class="text-right">Starting Value: <text class="text-autocolor"> @Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance @Model.Summary.MainMarket </text> <small> <i class="fa fa-info-circle text-muted" data-toggle="tooltip" data-placement="top" title="This is the starting value found in your settings file"></i></small></th>
|
<th class="text-right">Starting Value: <text class="text-autocolor"> @Model.PTMagicConfiguration.GeneralSettings.Application.StartBalance @Model.Summary.MainMarket </text> <small> <i class="fa fa-info-circle text-muted" data-toggle="tooltip" data-placement="top" title="This is the starting value found in your settings file"></i></small></th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
|
|
@ -20,12 +20,13 @@ namespace Monitor.Pages
|
||||||
public Dictionary<DateTime, double> DailyGains = new Dictionary<DateTime, double>();
|
public Dictionary<DateTime, double> DailyGains = new Dictionary<DateTime, double>();
|
||||||
public Dictionary<DateTime, double> MonthlyGains = new Dictionary<DateTime, double>();
|
public Dictionary<DateTime, double> MonthlyGains = new Dictionary<DateTime, double>();
|
||||||
public DateTimeOffset DateTimeNow = Constants.confMinDate;
|
public DateTimeOffset DateTimeNow = Constants.confMinDate;
|
||||||
|
public double totalCurrentValue = 0;
|
||||||
public void OnGet()
|
public void OnGet()
|
||||||
{
|
{
|
||||||
base.Init();
|
base.Init();
|
||||||
|
|
||||||
BindData();
|
BindData();
|
||||||
|
BuildTCV();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void BindData()
|
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;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,10 +19,6 @@ namespace Monitor.Pages
|
||||||
public string LastGlobalSetting = "Default";
|
public string LastGlobalSetting = "Default";
|
||||||
public DateTimeOffset DateTimeNow = Constants.confMinDate;
|
public DateTimeOffset DateTimeNow = Constants.confMinDate;
|
||||||
public string AssetDistributionData = "";
|
public string AssetDistributionData = "";
|
||||||
public double currentBalance = 0;
|
|
||||||
public string currentBalanceString = "";
|
|
||||||
public double TotalBagCost = 0;
|
|
||||||
public double TotalBagValue = 0;
|
|
||||||
public double totalCurrentValue = 0;
|
public double totalCurrentValue = 0;
|
||||||
public void OnGet()
|
public void OnGet()
|
||||||
{
|
{
|
||||||
|
@ -170,7 +166,6 @@ namespace Monitor.Pages
|
||||||
|
|
||||||
foreach (Core.Main.DataObjects.PTMagicData.DCALogData dcaLogEntry in PTData.DCALog)
|
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);
|
string sellStrategyText = Core.ProfitTrailer.StrategyHelper.GetStrategyText(Summary, dcaLogEntry.SellStrategies, dcaLogEntry.SellStrategy, isSellStrategyTrue, isTrailingSellActive);
|
||||||
|
|
||||||
// Aggregate totals
|
// Aggregate totals
|
||||||
|
|
Loading…
Reference in New Issue