hqchart 1.1.14340 → 1.1.14349

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.
@@ -5,7 +5,7 @@
5
5
 
6
6
 
7
7
 
8
- var HQCHART_VERSION="1.1.14339";
8
+ var HQCHART_VERSION="1.1.14348";
9
9
 
10
10
  function PrintHQChartVersion()
11
11
  {
@@ -57396,6 +57396,8 @@ HQData.Report_APIIndex=function(data, callback)
57396
57396
  HQData.APIIndex_DRAW_SIMPLE_PIE(data, callback);
57397
57397
  else if (request.Data.indexname=="API_DRAW_SIMPLE_RADAR")
57398
57398
  HQData.APIIndex_DRAW_SIMPLE_RADAR(data, callback);
57399
+ else if (request.Data.indexname=="API_MULTI_BAR")
57400
+ HQData.APIIndex_MULTI_BAR(data, callback);
57399
57401
 
57400
57402
  }
57401
57403
 
@@ -57994,6 +57996,73 @@ HQData.APIIndex_DRAW_SIMPLE_RADAR=function(data, callback)
57994
57996
  }
57995
57997
 
57996
57998
 
57999
+ HQData.APIIndex_MULTI_BAR=function(data, callback)
58000
+ {
58001
+ data.PreventDefault=true;
58002
+ var hqchart=data.HQChart;
58003
+ var kData=hqchart.GetKData();
58004
+
58005
+ var barData=
58006
+ {
58007
+ name:'MULTI_BAR', type:1,
58008
+ Draw:
58009
+ {
58010
+ DrawType:'MULTI_BAR',
58011
+ DrawData:[]
58012
+ } //绘制柱子数组
58013
+ };
58014
+
58015
+ //第一组柱子
58016
+ var point=
58017
+ {
58018
+ Color:'rgb(148,0,211)', //颜色
58019
+ Type:0,
58020
+ Name:"柱子上部",
58021
+ Point:
58022
+ [
58023
+ //{Date:20190916, Time: Value:15.5, Value2:0 },
58024
+ ],
58025
+ Width:10
58026
+ };
58027
+
58028
+ var point2=
58029
+ {
58030
+ Color:'rgb(55,228,181)', //颜色
58031
+ Type:1,
58032
+ Name:"柱子下部",
58033
+ Point:
58034
+ [
58035
+ //{Date:20190916, Time: Value:15.5, Value2:0 },
58036
+ ],
58037
+ Width:20
58038
+ };
58039
+
58040
+ for(var i=0;i<kData.Data.length;++i)
58041
+ {
58042
+ var item=kData.Data[i];
58043
+ point.Point.push({Date:item.Date, Time:item.Time, Value:(item.High+item.Low)/2, Value2:item.High});
58044
+ point2.Point.push({Date:item.Date, Time:item.Time, Value:(item.High+item.Low)/2, Value2:item.Low});
58045
+ }
58046
+
58047
+
58048
+
58049
+ barData.Draw.DrawData.push(point);
58050
+ barData.Draw.DrawData.push(point2);
58051
+
58052
+ var apiData=
58053
+ {
58054
+ code:0,
58055
+ stock:{ name:hqchart.Name, symbol:hqchart.Symbol },
58056
+ outdata: { date:kData.GetDate(), time:kData.GetTime() , outvar:[barData] }
58057
+ };
58058
+
58059
+
58060
+ console.log('[HQData.APIIndex_MULTI_BAR] apiData ', apiData);
58061
+ callback(apiData);
58062
+
58063
+ }
58064
+
58065
+
57997
58066
 
57998
58067
 
57999
58068
  /*暴露外部用的方法*/