Trading View fixes
This commit is contained in:
parent
0a15c7c8c9
commit
32eae76431
|
@ -536,20 +536,14 @@ namespace Core.Helper
|
|||
string result = "#";
|
||||
if (platform.Equals("TradingView"))
|
||||
{
|
||||
result = "https://www.tradingview.com/symbols/" + market.ToUpper() + "/?exchange=" + exchange.ToUpper();
|
||||
}
|
||||
else if (platform.Equals("TradingViewFutures"))
|
||||
{
|
||||
result = "https://www.tradingview.com/chart/?symbol=";
|
||||
|
||||
string pairName = SystemHelper.StripBadCode(market, Constants.WhiteListMinimal);
|
||||
|
||||
if (pairName.StartsWith(mainMarket))
|
||||
if (exchange.Equals("binancefutures", StringComparison.InvariantCultureIgnoreCase))
|
||||
{
|
||||
pairName = pairName.Replace(mainMarket, "") + mainMarket;
|
||||
result = "https://www.tradingview.com/chart/?symbol=BINANCE:" + market.ToUpper() + "PERP";
|
||||
}
|
||||
else
|
||||
{
|
||||
result = "https://www.tradingview.com/?symbol=" + exchange.ToUpper() + ":" + market.ToUpper();
|
||||
}
|
||||
|
||||
result += pairName + "PERP";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -614,7 +608,15 @@ namespace Core.Helper
|
|||
pairName = pairName.Replace(mainMarket, "") + mainMarket;
|
||||
}
|
||||
|
||||
result += pairName;
|
||||
if (exchange.Equals("binancefutures", StringComparison.InvariantCultureIgnoreCase))
|
||||
{
|
||||
result = "BINANCE:" + pairName + "PERP";
|
||||
}
|
||||
else
|
||||
{
|
||||
result += pairName;
|
||||
}
|
||||
|
||||
|
||||
|
||||
return result;
|
||||
|
|
|
@ -243,7 +243,6 @@
|
|||
<select name="Monitor_LinkPlatform" class="form-control">
|
||||
<option selected="@(Model.PTMagicConfiguration.GeneralSettings.Monitor.LinkPlatform.Equals("Exchange", StringComparison.InvariantCultureIgnoreCase))">Exchange</option>
|
||||
<option selected="@(Model.PTMagicConfiguration.GeneralSettings.Monitor.LinkPlatform.Equals("TradingView", StringComparison.InvariantCultureIgnoreCase))">TradingView</option>
|
||||
<option selected="@(Model.PTMagicConfiguration.GeneralSettings.Monitor.LinkPlatform.Equals("TradingViewFutures", StringComparison.InvariantCultureIgnoreCase))">TradingViewFutures</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -6,7 +6,7 @@ using Core.Helper;
|
|||
using Microsoft.Extensions.DependencyInjection;
|
||||
|
||||
|
||||
[assembly: AssemblyVersion("2.5.4")]
|
||||
[assembly: AssemblyVersion("2.5.5")]
|
||||
[assembly: AssemblyProduct("PT Magic")]
|
||||
|
||||
namespace PTMagic
|
||||
|
|
Loading…
Reference in New Issue