hqchart 1.1.14269 → 1.1.14276

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
1
  @font-face {
2
2
  font-family: "iconfont"; /* Project id 1040563 */
3
- src: url('iconfont.woff2?t=1732508423204') format('woff2'),
4
- url('iconfont.woff?t=1732508423204') format('woff'),
5
- url('iconfont.ttf?t=1732508423204') format('truetype');
3
+ src: url('iconfont.woff2?t=1734955349527') format('woff2'),
4
+ url('iconfont.woff?t=1734955349527') format('woff'),
5
+ url('iconfont.ttf?t=1734955349527') format('truetype');
6
6
  }
7
7
 
8
8
  .iconfont {
@@ -13,6 +13,18 @@
13
13
  -moz-osx-font-smoothing: grayscale;
14
14
  }
15
15
 
16
+ .icon-sortup:before {
17
+ content: "\e81b";
18
+ }
19
+
20
+ .icon-sort1:before {
21
+ content: "\e704";
22
+ }
23
+
24
+ .icon-sort-down:before {
25
+ content: "\f0c9";
26
+ }
27
+
16
28
  .icon-chicangzuheicon:before {
17
29
  content: "\e6b6";
18
30
  }
@@ -630,6 +630,12 @@ function GetBlackStyle()
630
630
  //Mergin:{ Left:5, Right:5, Top:4, Bottom:2 },
631
631
  Font:{ Size:12, Name:"微软雅黑" }
632
632
  },
633
+
634
+ //排序图标
635
+ SortIcon:
636
+ {
637
+ Color:['rgb(105,105,105)', "rgb(255,255,255)", "rgb(255,255,255)"],
638
+ },
633
639
 
634
640
  Item:
635
641
  {
@@ -1246,7 +1246,7 @@ HQData.Report_RequestStockData=function(data, callback)
1246
1246
  newItem[33]=kData;
1247
1247
 
1248
1248
 
1249
- newItem[101]=105.0;
1249
+ newItem[101]=HQData.GetRandomTestData(-90,1000);
1250
1250
  newItem[201]=`A-[${HQData.GetRandomTestData(-90,90)}]-B`;
1251
1251
 
1252
1252
 
@@ -1852,6 +1852,8 @@ HQData.Report_APIIndex=function(data, callback)
1852
1852
  HQData.APIIndex_DRAWBAND(data, callback);
1853
1853
  else if (request.Data.indexname=="API-MULTI_LINE")
1854
1854
  HQData.APIIndex_MULTI_LINE(data, callback);
1855
+ else if (request.Data.indexname=="API-MULTI_SVGICON")
1856
+ HQData.APIIndex_MULTI_SVGICON(data, callback);
1855
1857
  }
1856
1858
 
1857
1859
 
@@ -2102,3 +2104,139 @@ HQData.APIIndex_MULTI_LINE=function(data, callback)
2102
2104
  }
2103
2105
 
2104
2106
 
2107
+ HQData.APIIndex_MULTI_SVGICON=function(data, callback)
2108
+ {
2109
+ data.PreventDefault=true;
2110
+ var hqchart=data.HQChart;
2111
+ var kData=hqchart.GetKData();
2112
+
2113
+ var iconData=
2114
+ {
2115
+ name:'MULTI_SVGICON', type:1,
2116
+ Draw:
2117
+ {
2118
+ DrawType:'MULTI_SVGICON',
2119
+ DrawData:
2120
+ {
2121
+ Family:'iconfont',
2122
+ Icon:
2123
+ [
2124
+ //{ Date:20190916, Value:"High", Symbol:'\ue611', Color:'rgb(240,0,0)', Baseline:2 , YMove:-5}, //0 居中 1 上 2 下
2125
+ //{ Date:20190919, Value:15.3, Symbol:'\ue615', Color:'rgb(240,240,0)', Baseline:2 },
2126
+ //{ Date:20190909, Value:15.4, Symbol:'\ue615', Color:'rgb(240,100,30)'}
2127
+ ]
2128
+ }
2129
+ } //绘制图标数组
2130
+ };
2131
+
2132
+ var TEST_ICON_SYMBOL=['\ue678', '\ue66e', "\ue66b"];
2133
+ var TEST_ICON_COLOR=["'rgb(240,0,0)", "rgb(240,100,30)", "rgb(138,43, 226)", "rgb(151,255,255)", "rgb(255, 20, 147)"];
2134
+
2135
+ for(var i=kData.Data.length-20, j=0;i<kData.Data.length;++i)
2136
+ {
2137
+ var item=kData.Data[i];
2138
+
2139
+ if (i%3!=1) continue;
2140
+
2141
+ var iconIndex=Math.ceil(Math.random()*10) % TEST_ICON_SYMBOL.length;
2142
+ var colorIndex=Math.ceil(Math.random()*10) % TEST_ICON_COLOR.length;
2143
+
2144
+ if (j==2)
2145
+ {
2146
+ var iconItem=
2147
+ {
2148
+ Date:item.Date, Time:item.Time,
2149
+ Value:item.High,
2150
+ Symbol:TEST_ICON_SYMBOL[iconIndex],
2151
+ Color:TEST_ICON_COLOR[colorIndex],
2152
+ Baseline:2,
2153
+ YMove:-35,
2154
+ Line:{ Color:"rgb(153,50,204)", KData:"H", Width:1, Offset:[3,10], Dash:[5,5] },
2155
+ };
2156
+
2157
+ var iconItem2=
2158
+ {
2159
+ Date:item.Date, Time:item.Time,
2160
+ Value:item.Low,
2161
+ Symbol:TEST_ICON_SYMBOL[iconIndex],
2162
+ Color:TEST_ICON_COLOR[colorIndex],
2163
+ Baseline:2,
2164
+ YMove:50,
2165
+ };
2166
+
2167
+ iconData.Draw.DrawData.Icon.push(iconItem2);
2168
+ }
2169
+ else if (j==3)
2170
+ {
2171
+ var iconItem=
2172
+ {
2173
+ Date:item.Date, Time:item.Time,
2174
+ Value:"L",
2175
+ Symbol:TEST_ICON_SYMBOL[iconIndex],
2176
+ Color:TEST_ICON_COLOR[colorIndex],
2177
+ Baseline:1,
2178
+ YMove:5,
2179
+ };
2180
+ }
2181
+ else if (j==4)
2182
+ {
2183
+ var iconItem=
2184
+ {
2185
+ Date:item.Date, Time:item.Time,
2186
+ Value:item.Low*0.95,
2187
+ Symbol:TEST_ICON_SYMBOL[iconIndex],
2188
+ Color:TEST_ICON_COLOR[colorIndex],
2189
+ Baseline:1,
2190
+ YMove:5,
2191
+ Line:{ Color:"rgb(153,50,204)", KData:"L", Width:1, Offset:[3,10], Dash:[5,5] },
2192
+ Text:"提示信息:<br>这个是提示信息"
2193
+ };
2194
+ }
2195
+ else
2196
+ {
2197
+ var iconItem=
2198
+ {
2199
+ Date:item.Date, Time:item.Time,
2200
+ Value:item.High,
2201
+ Symbol:TEST_ICON_SYMBOL[iconIndex],
2202
+ Color:TEST_ICON_COLOR[colorIndex],
2203
+ Baseline:2,
2204
+ YMove:-20,
2205
+ Text:
2206
+ {
2207
+ AryText:
2208
+ [
2209
+ { Title:"日期:", Text:`${item.Date}`, Color:"rgb(230,230,230)", Align:"Left"},
2210
+ { Title:"提示:", Text:"提示信息xxxxx", Color:"rgb(250,0,0)",Align:"Left"}
2211
+ ]
2212
+ },
2213
+
2214
+ //Line:{ Color:"rgb(153,50,204)", KData:"H", Width:1, Offset:[3,10], Dash:[5,5] },
2215
+ };
2216
+
2217
+
2218
+ /*
2219
+ if (j%5==1)
2220
+ iconItem.Image={ Data:image1, Width:32, Height:32 };
2221
+ else if (j%5==3)
2222
+ iconItem.Image={ Data:image2, Width:32, Height:32 };
2223
+ */
2224
+ }
2225
+
2226
+ iconData.Draw.DrawData.Icon.push(iconItem);
2227
+ ++j;
2228
+ }
2229
+
2230
+ var apiData=
2231
+ {
2232
+ code:0,
2233
+ stock:{ name:hqchart.Name, symbol:hqchart.Symbol },
2234
+ outdata: { date:kData.GetDate() , outvar:[iconData] }
2235
+ };
2236
+
2237
+
2238
+ console.log('[HQData.APIIndex_MULTI_SVGICON] apiData ', apiData);
2239
+ callback(apiData);
2240
+ }
2241
+
2242
+