|
|
@@ -148,10 +148,10 @@ const chartOption = {
|
|
|
AryText.push({ Text: FormatTimeString(Time), Color: paint.DateTimeColor })
|
|
|
}
|
|
|
AryText.push(
|
|
|
- { Text: '开:' + handleNumberValue(Open.toFixed(decimalplace)), Color: paint.GetColor(Open, yclose) },
|
|
|
- { Text: '高:' + handleNumberValue(High.toFixed(decimalplace)), Color: paint.GetColor(High, yclose) },
|
|
|
- { Text: '低:' + handleNumberValue(Low.toFixed(decimalplace)), Color: paint.GetColor(Low, yclose) },
|
|
|
- { Text: '收:' + handleNumberValue(Close.toFixed(decimalplace)), Color: paint.GetColor(Close, yclose) }
|
|
|
+ { Text: '开:' + handleNumberValue(Open.toFixed(decimalplace)), Color: paint.GetColor(Open, yclose || Open) },
|
|
|
+ { Text: '高:' + handleNumberValue(High.toFixed(decimalplace)), Color: paint.GetColor(High, yclose || High) },
|
|
|
+ { Text: '低:' + handleNumberValue(Low.toFixed(decimalplace)), Color: paint.GetColor(Low, yclose || Low) },
|
|
|
+ { Text: '收:' + handleNumberValue(Close.toFixed(decimalplace)), Color: paint.GetColor(Close, yclose || Close) }
|
|
|
)
|
|
|
if (goods.value?.trademode !== 99) {
|
|
|
AryText.push(
|
|
|
@@ -191,23 +191,23 @@ const customHistoryDataStringFormat = () => {
|
|
|
Text: '',
|
|
|
Operator: function () {
|
|
|
const { FormatDateString, FormatTimeString } = Chart.IFrameSplitOperator
|
|
|
- const { Data } = this.Value
|
|
|
- const yclose = Data.YFClose ?? Data.YClose
|
|
|
- const rise = yclose ? Data.Close - yclose : 0 // 涨跌
|
|
|
+ const { Date, Time, Open, High, Low, Close, Vol, Amount, YClose, YFClose } = this.Value.Data
|
|
|
+ const yclose = YFClose ?? YClose
|
|
|
+ const rise = yclose ? Close - yclose : 0 // 涨跌
|
|
|
const increase = rise ? rise / yclose : 0 // 幅度
|
|
|
|
|
|
this.Height = 165
|
|
|
this.Text = `<dl class="app-hqchart-tooltip">`
|
|
|
- this.Text += `<dt><span>${FormatDateString(Data.Date)}</span>${Data.Time ? '<span>' + FormatTimeString(Data.Time) + '</span>' : ''}</dt>`
|
|
|
- this.Text += `<dd><span>开盘:</span><span class="${handlePriceColor(Data.Open, yclose)}">${handleNumberValue(Data.Open.toFixed(decimalplace))}</span></dd>`
|
|
|
- this.Text += `<dd><span>最高:</span><span class="${handlePriceColor(Data.High, yclose)}">${handleNumberValue(Data.High.toFixed(decimalplace))}</span></dd>`
|
|
|
- this.Text += `<dd><span>最低:</span><span class="${handlePriceColor(Data.Low, yclose)}">${handleNumberValue(Data.Low.toFixed(decimalplace))}</span></dd>`
|
|
|
- this.Text += `<dd><span>收盘:</span><span class="${handlePriceColor(Data.Close, yclose)}">${handleNumberValue(Data.Close.toFixed(decimalplace))}</span></dd>`
|
|
|
+ this.Text += `<dt><span>${FormatDateString(Date)}</span>${Time ? '<span>' + FormatTimeString(Time) + '</span>' : ''}</dt>`
|
|
|
+ this.Text += `<dd><span>开盘:</span><span class="${handlePriceColor(Open, yclose || Open)}">${handleNumberValue(Open.toFixed(decimalplace))}</span></dd>`
|
|
|
+ this.Text += `<dd><span>最高:</span><span class="${handlePriceColor(High, yclose || High)}">${handleNumberValue(High.toFixed(decimalplace))}</span></dd>`
|
|
|
+ this.Text += `<dd><span>最低:</span><span class="${handlePriceColor(Low, yclose || Low)}">${handleNumberValue(Low.toFixed(decimalplace))}</span></dd>`
|
|
|
+ this.Text += `<dd><span>收盘:</span><span class="${handlePriceColor(Close, yclose || Close)}">${handleNumberValue(Close.toFixed(decimalplace))}</span></dd>`
|
|
|
this.Text += `<dd><span>涨跌:</span><span class="${handlePriceColor(rise)}">${rise.toFixed(decimalplace)}</span></dd>`
|
|
|
this.Text += `<dd><span>幅度:</span><span class="${handlePriceColor(increase)}">${parsePercent(increase)}</span></dd>`
|
|
|
if (goods.value?.trademode !== 99) {
|
|
|
- this.Text += `<dd><span>数量:</span><span>${changeUnit(Data.Vol)}</span></dd>`
|
|
|
- this.Text += `<dd><span>金额:</span><span>${changeUnit(Data.Amount)}</span></dd>`
|
|
|
+ this.Text += `<dd><span>数量:</span><span>${changeUnit(Vol)}</span></dd>`
|
|
|
+ this.Text += `<dd><span>金额:</span><span>${changeUnit(Amount)}</span></dd>`
|
|
|
this.Height = 210
|
|
|
}
|
|
|
this.Text += `</dd>`
|