添加分型强弱计算,可以直接跑服务了
This commit is contained in:
@@ -709,7 +709,7 @@
|
||||
// 添加买卖点悬浮提示元素
|
||||
const tooltipElement = document.createElement('div');
|
||||
tooltipElement.className = 'point-tooltip';
|
||||
document.body.appendChild(tooltipElement);
|
||||
// document.body.appendChild(tooltipElement);
|
||||
|
||||
// 助手函数:转换UTC时间到所选时区
|
||||
function convertToTimezone(utcDate, timezone) {
|
||||
@@ -2731,8 +2731,10 @@
|
||||
fx_strength_level: fx.fx_strength_level,
|
||||
is_strong_fx: fx.is_strong_fx
|
||||
});
|
||||
|
||||
const displayText = `${fx.fx_strength_level} ${fx.fx_strength.toFixed(1)}`;
|
||||
if (fx.fx_strength < 1) {
|
||||
displayText = ''
|
||||
}
|
||||
console.log('显示文本:', displayText);
|
||||
|
||||
// 添加标记配置调试
|
||||
@@ -2821,6 +2823,9 @@
|
||||
}
|
||||
|
||||
// 构建小周期分型显示文本
|
||||
if (fx.fx_strength < 1){
|
||||
displayText = ''
|
||||
}
|
||||
const displayText = `${fx.fx_strength_level} ${fx.fx_strength.toFixed(1)}`;
|
||||
|
||||
// 小周期分型标记配置 - 根据分型类型使用正确的箭头形状
|
||||
@@ -2828,7 +2833,6 @@
|
||||
time: timestamp,
|
||||
position: fx.is_bottom ? 'belowBar' : 'aboveBar',
|
||||
color: strengthColor,
|
||||
shape: fx.is_bottom ? 'arrowUp' : 'arrowDown', // 底分型向上箭头,顶分型向下箭头
|
||||
text: displayText,
|
||||
size: fx.is_strong_fx ? 2 : 1
|
||||
};
|
||||
@@ -2917,9 +2921,11 @@
|
||||
// 绑定同步事件
|
||||
bindSyncEvents(mainChartContainer, volumeChartContainer, macdChartContainer, mainChart, volumeChart, macdChart, showMacd);
|
||||
|
||||
// 设置图表默认时间范围
|
||||
setDefaultTimeRange();
|
||||
|
||||
// 只有在时间输入框都为空时才设置图表默认时间范围
|
||||
if (!$('#start_time').val() && !$('#end_time').val()) {
|
||||
setDefaultTimeRange();
|
||||
}
|
||||
|
||||
// 添加买卖点提示
|
||||
setupTooltip(mainChart);
|
||||
|
||||
@@ -3193,7 +3199,7 @@
|
||||
// 添加买卖点悬浮提示元素
|
||||
const tooltipElement = document.createElement('div');
|
||||
tooltipElement.className = 'point-tooltip';
|
||||
document.body.appendChild(tooltipElement);
|
||||
// document.body.appendChild(tooltipElement);
|
||||
|
||||
// 添加自定义十字线信息显示
|
||||
const crosshairTooltip = document.createElement('div');
|
||||
@@ -3207,7 +3213,7 @@
|
||||
crosshairTooltip.style.zIndex = '1000';
|
||||
crosshairTooltip.style.pointerEvents = 'none';
|
||||
crosshairTooltip.style.display = 'none';
|
||||
document.body.appendChild(crosshairTooltip);
|
||||
// document.body.appendChild(crosshairTooltip);
|
||||
|
||||
// 添加鼠标悬停事件显示提示
|
||||
if (mainChart) {
|
||||
|
||||
Reference in New Issue
Block a user