hqchart 1.1.12687 → 1.1.12706

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.
Files changed (228) hide show
  1. package/lib/umychart.vue.js +94 -50
  2. package/package.json +15 -47
  3. package/src/jscommon/umychart.resource/js/codemirror/javascript.js +1 -1
  4. package/src/jscommon/umychart.uniapp.h5/umychart.uniapp.h5.js +409 -115
  5. package/src/jscommon/umychart.vue/umychart.vue.js +409 -115
  6. package/.babelrc +0 -6
  7. package/.vscode/settings.json +0 -4
  8. package/Makefile +0 -9
  9. package/README.md +0 -452
  10. package/index.js +0 -17
  11. package/postcss.config.js +0 -5
  12. package/src/index.html +0 -18
  13. package/src/jscommon/backup/announcement.png +0 -0
  14. package/src/jscommon/backup/announcement2.png +0 -0
  15. package/src/jscommon/backup/blocktrading.png +0 -0
  16. package/src/jscommon/backup/investor.png +0 -0
  17. package/src/jscommon/backup/pforecast.png +0 -0
  18. package/src/jscommon/backup/research.png +0 -0
  19. package/src/jscommon/backup/tradedetail.png +0 -0
  20. package/src/jscommon/backup/umychart - backup.js +0 -17631
  21. package/src/jscommon/backup/umychart.macro.js +0 -4
  22. package/src/jscommon/backup/umychart.macro.vue.js +0 -3
  23. package/src/jscommon/commonindextree.json +0 -92
  24. package/src/jscommon/index.html +0 -13
  25. package/src/jscommon/jschinamapdata.js +0 -3
  26. package/src/jscommon/umychart.NetworkFilterTest.js +0 -48803
  27. package/src/jscommon/umychart.aliYunnetwork.js +0 -47
  28. package/src/jscommon/umychart.cninfo.components/readme.txt +0 -1
  29. package/src/jscommon/umychart.complier.js +0 -25291
  30. package/src/jscommon/umychart.complier.node/umychart.complier.controller.js +0 -559
  31. package/src/jscommon/umychart.complier.node/umychart.complier.node.js +0 -7043
  32. package/src/jscommon/umychart.complier.node/umychart.data.node.js +0 -816
  33. package/src/jscommon/umychart.console.js +0 -12
  34. package/src/jscommon/umychart.deal.js +0 -1452
  35. package/src/jscommon/umychart.dragdiv.js +0 -48
  36. package/src/jscommon/umychart.index.data.js +0 -4132
  37. package/src/jscommon/umychart.js +0 -90257
  38. package/src/jscommon/umychart.keyboard.js +0 -1659
  39. package/src/jscommon/umychart.listctrl.js +0 -690
  40. package/src/jscommon/umychart.mind.js +0 -2203
  41. package/src/jscommon/umychart.network.js +0 -44
  42. package/src/jscommon/umychart.news.js +0 -823
  43. package/src/jscommon/umychart.node.build/buildall.bat +0 -1
  44. package/src/jscommon/umychart.node.build/umychart.node.bat +0 -1
  45. package/src/jscommon/umychart.node.build/umychart.node.export.js +0 -40
  46. package/src/jscommon/umychart.regressiontest.js +0 -400
  47. package/src/jscommon/umychart.report.js +0 -5803
  48. package/src/jscommon/umychart.scrollbar.js +0 -1345
  49. package/src/jscommon/umychart.stock.js +0 -4218
  50. package/src/jscommon/umychart.style.js +0 -618
  51. package/src/jscommon/umychart.testdata.js +0 -150
  52. package/src/jscommon/umychart.uniapp.build/buildall.bat +0 -1
  53. package/src/jscommon/umychart.uniapp.build/umychart.bat +0 -1
  54. package/src/jscommon/umychart.uniapp.build/umychart.export.js +0 -70
  55. package/src/jscommon/umychart.user.js +0 -137
  56. package/src/jscommon/umychart.version.js +0 -30
  57. package/src/jscommon/umychart.vue/umychart.aliYunnetwork.vue.js +0 -56
  58. package/src/jscommon/umychart.vue.build/buildall.bat +0 -4
  59. package/src/jscommon/umychart.vue.build/copy_codemirror.bat +0 -2
  60. package/src/jscommon/umychart.vue.build/umychart.aliYunnetwork.vue.export.js +0 -9
  61. package/src/jscommon/umychart.vue.build/umychart.dragdiv.bat +0 -1
  62. package/src/jscommon/umychart.vue.build/umychart.dragdiv.export.js +0 -6
  63. package/src/jscommon/umychart.vue.build/umychart.index.data.bat +0 -1
  64. package/src/jscommon/umychart.vue.build/umychart.index.data.export.js +0 -4
  65. package/src/jscommon/umychart.vue.build/umychart.listctrl.vue.export.js +0 -15
  66. package/src/jscommon/umychart.vue.build/umychart.regressiontest.vue.export.js +0 -7
  67. package/src/jscommon/umychart.vue.build/umychart.regressiontest.wechat.export.js +0 -12
  68. package/src/jscommon/umychart.vue.build/umychart.stock.bat +0 -1
  69. package/src/jscommon/umychart.vue.build/umychart.stock.vue.export.js +0 -16
  70. package/src/jscommon/umychart.vue.build/umychart.testdata.bat +0 -3
  71. package/src/jscommon/umychart.vue.build/umychart.testdata.vue.export.js +0 -7
  72. package/src/jscommon/umychart.vue.build/umychart.vue.bat +0 -8
  73. package/src/jscommon/umychart.vue.build/umychart.vue.export.js +0 -112
  74. package/src/jscommon/umychart.vue.components/empyt.vue +0 -51
  75. package/src/jscommon/umychart.vue.components/historydayline.vue +0 -240
  76. package/src/jscommon/umychart.vue.components/jsloader.adddialog.vue +0 -315
  77. package/src/jscommon/umychart.vue.components/jsloader.vue +0 -93
  78. package/src/jscommon/umychart.vue.components/jsvuecontainer.vue +0 -160
  79. package/src/jscommon/umychart.vue.components/jsvuecontainer2.0.vue +0 -391
  80. package/src/jscommon/umychart.vue.components/login.vue +0 -178
  81. package/src/jscommon/umychart.vue.components/queryContent.vue +0 -750
  82. package/src/jscommon/umychart.vue.components/readme.txt +0 -8
  83. package/src/jscommon/umychart.vue.components/searchsymbol.vue +0 -299
  84. package/src/jscommon/umychart.vue.components/simulatetrade.vue +0 -1471
  85. package/src/jscommon/umychart.vue.components/stockchart.vue +0 -343
  86. package/src/jscommon/umychart.vue.components/stockchartV2.vue +0 -195
  87. package/src/jscommon/umychart.vue.components/stockdeal.vue +0 -358
  88. package/src/jscommon/umychart.vue.components/stockdealcount.vue +0 -262
  89. package/src/jscommon/umychart.vue.components/stockdeallastest.vue +0 -316
  90. package/src/jscommon/umychart.vue.components/stockdrawtool.vue +0 -343
  91. package/src/jscommon/umychart.vue.components/stockfull.vue +0 -355
  92. package/src/jscommon/umychart.vue.components/stockinfo.demo.vue +0 -153
  93. package/src/jscommon/umychart.vue.components/stockinfo.vue +0 -685
  94. package/src/jscommon/umychart.vue.components/stockkline.demo.vue +0 -1904
  95. package/src/jscommon/umychart.vue.components/stockmultiorder.vue +0 -174
  96. package/src/jscommon/umychart.vue.components/stockmultiperiod.vue +0 -222
  97. package/src/jscommon/umychart.vue.components/stockorder.vue +0 -320
  98. package/src/jscommon/umychart.vue.components/stocktradeinfo.demo.vue +0 -250
  99. package/src/jscommon/umychart.vue.components/stocktradeinfo.vue +0 -1907
  100. package/src/jscommon/umychart.vue.components/test.vue +0 -0
  101. package/src/jscommon/umychart.wechat/getDate.wechat.js +0 -91
  102. package/src/jscommon/umychart.wechat/lighter.news.wechat.js +0 -262
  103. package/src/jscommon/umychart.wechat/readme.txt +0 -3
  104. package/src/jscommon/umychart.wechat/umychart.analyze.wechat.js +0 -551
  105. package/src/jscommon/umychart.wechat/umychart.apidraw.wechat.js +0 -126
  106. package/src/jscommon/umychart.wechat/umychart.bigV.wechat.js +0 -2510
  107. package/src/jscommon/umychart.wechat/umychart.chartframe.wechat.js +0 -2931
  108. package/src/jscommon/umychart.wechat/umychart.chartpaint.wechat.js +0 -9752
  109. package/src/jscommon/umychart.wechat/umychart.charttitle.wechat.js +0 -2023
  110. package/src/jscommon/umychart.wechat/umychart.complier.wechat.js +0 -14726
  111. package/src/jscommon/umychart.wechat/umychart.console.wechat.js +0 -8
  112. package/src/jscommon/umychart.wechat/umychart.coordinatedata.wechat.js +0 -3654
  113. package/src/jscommon/umychart.wechat/umychart.data.wechat.js +0 -2243
  114. package/src/jscommon/umychart.wechat/umychart.element.wechart.js +0 -132
  115. package/src/jscommon/umychart.wechat/umychart.explainer.wechat.js +0 -1077
  116. package/src/jscommon/umychart.wechat/umychart.extendchart.wechat.js +0 -1140
  117. package/src/jscommon/umychart.wechat/umychart.framesplit.wechat.js +0 -2247
  118. package/src/jscommon/umychart.wechat/umychart.hqIndexformula.wechat.js +0 -941
  119. package/src/jscommon/umychart.wechat/umychart.index.data.wechat.js +0 -3628
  120. package/src/jscommon/umychart.wechat/umychart.index.wechat.js +0 -4074
  121. package/src/jscommon/umychart.wechat/umychart.klineinfo.wechat.js +0 -836
  122. package/src/jscommon/umychart.wechat/umychart.markethot.js +0 -50
  123. package/src/jscommon/umychart.wechat/umychart.network.wechart.js +0 -62
  124. package/src/jscommon/umychart.wechat/umychart.news.wechat.js +0 -3568
  125. package/src/jscommon/umychart.wechat/umychart.regressiontest.wechat.js +0 -412
  126. package/src/jscommon/umychart.wechat/umychart.report.wechat.js +0 -3983
  127. package/src/jscommon/umychart.wechat/umychart.resource.wechat.js +0 -919
  128. package/src/jscommon/umychart.wechat/umychart.shareimage.wechat.js +0 -681
  129. package/src/jscommon/umychart.wechat/umychart.simulatetrade.wechat.js +0 -238
  130. package/src/jscommon/umychart.wechat/umychart.stock.wechat.js +0 -4035
  131. package/src/jscommon/umychart.wechat/umychart.style.wechat.js +0 -419
  132. package/src/jscommon/umychart.wechat/umychart.uniapp.canvas.helper.js +0 -99
  133. package/src/jscommon/umychart.wechat/umychart.user.wechat.js +0 -588
  134. package/src/jscommon/umychart.wechat/umychart.userlog.wechat.js +0 -240
  135. package/src/jscommon/umychart.wechat/umychart.vedio.wechat.js +0 -112
  136. package/src/jscommon/umychart.wechat/umychart.version.wechat.js +0 -36
  137. package/src/jscommon/umychart.wechat/umychart.wechat.3.0.js +0 -12051
  138. package/src/jscommon/umychart.wechat/umychart.wechat.js +0 -15460
  139. package/src/jscommon/umychart.worker.js +0 -114
  140. package/src/jscommon/umychart.ws.stock.js +0 -110
  141. package/src/jscommon/umychart_python/.vscode/launch.json +0 -15
  142. package/src/jscommon/umychart_python/__init__.py +0 -4
  143. package/src/jscommon/umychart_python/build.cmd +0 -2
  144. package/src/jscommon/umychart_python/setup.py +0 -25
  145. package/src/jscommon/umychart_python/umychart_cache_testcase.py +0 -165
  146. package/src/jscommon/umychart_python/umychart_complier_data.py +0 -781
  147. package/src/jscommon/umychart_python/umychart_complier_help.py +0 -175
  148. package/src/jscommon/umychart_python/umychart_complier_job.py +0 -193
  149. package/src/jscommon/umychart_python/umychart_complier_jsalgorithm.py +0 -4144
  150. package/src/jscommon/umychart_python/umychart_complier_jscomplier.py +0 -177
  151. package/src/jscommon/umychart_python/umychart_complier_jsexecute.py +0 -517
  152. package/src/jscommon/umychart_python/umychart_complier_jsparser.py +0 -864
  153. package/src/jscommon/umychart_python/umychart_complier_jssymboldata.py +0 -1238
  154. package/src/jscommon/umychart_python/umychart_complier_jssymboldata_cache.py +0 -146
  155. package/src/jscommon/umychart_python/umychart_complier_jssymboldata_json.py +0 -106
  156. package/src/jscommon/umychart_python/umychart_complier_pandas_help.py +0 -80
  157. package/src/jscommon/umychart_python/umychart_complier_scanner.py +0 -554
  158. package/src/jscommon/umychart_python/umychart_complier_testcase.py +0 -362
  159. package/src/jscommon/umychart_python/umychart_complier_util.py +0 -30
  160. package/src/jscommon/umychart_python/umychart_webtemplate.py +0 -131
  161. package/src/jscommon/umychart_python/updatehqchartweb.bat +0 -5
  162. package/src/jscommon/vendor.js +0 -2
  163. package/src/pages/block.list.demo.page/App.vue +0 -117
  164. package/src/pages/block.list.demo.page/index.js +0 -12
  165. package/src/pages/brushTool.demo.page/App.vue +0 -19
  166. package/src/pages/brushTool.demo.page/index.js +0 -12
  167. package/src/pages/container.demo.page/App.vue +0 -118
  168. package/src/pages/container.demo.page/index.js +0 -18
  169. package/src/pages/dataZoom.demo.page/App.vue +0 -265
  170. package/src/pages/dataZoom.demo.page/components/dataZoom.vue +0 -303
  171. package/src/pages/dataZoom.demo.page/index.js +0 -12
  172. package/src/pages/historydayline.demo.page/App.vue +0 -57
  173. package/src/pages/historydayline.demo.page/index.js +0 -12
  174. package/src/pages/hq.demo.page/App.vue +0 -163
  175. package/src/pages/hq.demo.page/index.js +0 -12
  176. package/src/pages/hqchart.black/App.vue +0 -90
  177. package/src/pages/hqchart.black/components/searchsymbol.vue +0 -299
  178. package/src/pages/hqchart.black/components/stockdrawtool.vue +0 -300
  179. package/src/pages/hqchart.black/components/stockfull.vue +0 -313
  180. package/src/pages/hqchart.black/components/stockinfo.vue +0 -428
  181. package/src/pages/hqchart.black/components/stockkline.demo.vue +0 -1652
  182. package/src/pages/hqchart.black/components/stocktradeinfo.vue +0 -1337
  183. package/src/pages/hqchart.black/index.js +0 -30
  184. package/src/pages/hqchart.black/router/candlestickChart.vue +0 -108
  185. package/src/pages/hqchart.black/router/pricePointsTable.vue +0 -294
  186. package/src/pages/hqchart.black/router/stockDeallas.vue +0 -417
  187. package/src/pages/hqchart.black/router/timeShareChart.vue +0 -108
  188. package/src/pages/hqchart.page/App.vue +0 -101
  189. package/src/pages/hqchart.page/index.js +0 -18
  190. package/src/pages/index/App.vue +0 -1408
  191. package/src/pages/index/index.js +0 -7
  192. package/src/pages/indexHq/App.vue +0 -110
  193. package/src/pages/indexHq/index.js +0 -18
  194. package/src/pages/login.demo.page/App.vue +0 -22
  195. package/src/pages/login.demo.page/index.js +0 -12
  196. package/src/pages/queryContent.demo.page/App.vue +0 -29
  197. package/src/pages/queryContent.demo.page/index.js +0 -18
  198. package/src/pages/ranking.black/App.vue +0 -199
  199. package/src/pages/ranking.black/index.js +0 -18
  200. package/src/pages/search.demo.page/App.vue +0 -28
  201. package/src/pages/search.demo.page/index.js +0 -12
  202. package/src/pages/simulatetrade.demo.page/app.vue +0 -121
  203. package/src/pages/simulatetrade.demo.page/index.js +0 -17
  204. package/src/pages/stockdeal.demo.page/App.vue +0 -63
  205. package/src/pages/stockdeal.demo.page/index.js +0 -19
  206. package/src/pages/stockdealcount.demo.page/App.vue +0 -37
  207. package/src/pages/stockdealcount.demo.page/index.js +0 -12
  208. package/src/pages/stockdeallastest.demo.page/App.vue +0 -74
  209. package/src/pages/stockdeallastest.demo.page/index.js +0 -18
  210. package/src/pages/stockinfo.demo.page/App.vue +0 -92
  211. package/src/pages/stockinfo.demo.page/index.html +0 -13
  212. package/src/pages/stockinfo.demo.page/index.js +0 -19
  213. package/src/pages/stockkline.demo.page/App.vue +0 -55
  214. package/src/pages/stockkline.demo.page/index.js +0 -18
  215. package/src/pages/stockmultiorder.demo.page/App.vue +0 -149
  216. package/src/pages/stockmultiorder.demo.page/index.js +0 -18
  217. package/src/pages/stockmultiperiod.demo.page/App.vue +0 -87
  218. package/src/pages/stockmultiperiod.demo.page/index.js +0 -18
  219. package/src/pages/stockorder.demo.page/App.vue +0 -69
  220. package/src/pages/stockorder.demo.page/index.js +0 -18
  221. package/src/pages/test/App.vue +0 -22
  222. package/src/pages/test/index.js +0 -7
  223. package/src/pages/tradeinfopage/app.vue +0 -40
  224. package/src/pages/tradeinfopage/index.js +0 -7
  225. package/src/pages/tradeinfopage/tradeinfo.html +0 -12
  226. package/src/utils/urlObj.js +0 -81
  227. package/src/vendor.js +0 -2
  228. package/webpack.config.js +0 -104
@@ -1,836 +0,0 @@
1
- /*
2
- copyright (c) 2018 jones
3
-
4
- http://www.apache.org/licenses/LICENSE-2.0
5
-
6
- 开源项目 https://github.com/jones2000/HQChart
7
-
8
- jones_2000@163.com
9
-
10
- 小程序信息地雷数据
11
- */
12
-
13
- import {
14
- g_JSChartResource,
15
- } from './umychart.resource.wechat.js'
16
-
17
- import
18
- {
19
- IFrameSplitOperator,
20
- } from './umychart.framesplit.wechat.js'
21
-
22
- var KLINE_INFO_TYPE=
23
- {
24
- INVESTOR:1, //互动易
25
- ANNOUNCEMENT:2, //公告
26
- PFORECAST:3, //业绩预告
27
-
28
- ANNOUNCEMENT_QUARTER_1:4, //一季度报
29
- ANNOUNCEMENT_QUARTER_2:5, //半年报
30
- ANNOUNCEMENT_QUARTER_3:6, //2季度报
31
- ANNOUNCEMENT_QUARTER_4:7, //年报
32
-
33
- RESEARCH:8, //调研
34
- BLOCKTRADING:9, //大宗交易
35
- TRADEDETAIL:10, //龙虎榜
36
-
37
- POLICY:11 //策略信息
38
- }
39
-
40
- function KLineInfoData()
41
- {
42
- this.ID;
43
- this.Date;
44
- this.Title;
45
- this.InfoType;
46
- this.ExtendData; //扩展数据
47
- }
48
-
49
- /*
50
- 信息地雷
51
- 信息地雷列表
52
- */
53
- function JSKLineInfoMap()
54
- {
55
- }
56
-
57
- JSKLineInfoMap.Get=function(id)
58
- {
59
- var infoMap=new Map(
60
- [
61
- ["互动易", {Create:function(){ return new InvestorInfo()} }],
62
- ["公告", {Create:function(){ return new AnnouncementInfo()} }],
63
- ["业绩预告", {Create:function(){ return new PforecastInfo()} }],
64
- ["调研", {Create:function(){ return new ResearchInfo()} }],
65
- ["大宗交易", {Create:function(){ return new BlockTrading()} }],
66
- ["龙虎榜", {Create:function(){ return new TradeDetail()} }],
67
- ["策略选股", {Create: function () { return new PolicyInfo() } }]
68
- ]
69
- );
70
-
71
- return infoMap.get(id);
72
- }
73
-
74
- function IKLineInfo()
75
- {
76
- this.MaxRequestDataCount=1000;
77
- this.StartDate=20160101;
78
- this.Data;
79
- this.ClassName='IKLineInfo';
80
- this.Explain="IKLineInfo";
81
-
82
- this.GetToday=function()
83
- {
84
- var date=new Date();
85
- var today=date.getFullYear()*10000+(date.getMonth()+1)*100+date.getDate();
86
- return today;
87
- }
88
-
89
- this.GetRequestData=function(hqChart)
90
- {
91
- var obj=
92
- {
93
- Symbol:hqChart.Symbol ,
94
- MaxRequestDataCount: hqChart.MaxRequestDataCount, //日线数据个数
95
- MaxRequestMinuteDayCount:hqChart.MaxRequestMinuteDayCount, //分钟数据请求的天数
96
- Period:hqChart.Period //周期
97
- };
98
-
99
- //K线数据范围
100
- var hisData=null;
101
- if (hqChart.ChartOperator_Temp_GetHistroyData) hisData=hqChart.ChartOperator_Temp_GetHistroyData();
102
- if (hisData)
103
- obj.DateRange=hisData.GetDateRange();
104
-
105
- return obj;
106
- }
107
-
108
- this.NetworkFilter=function(hqChart,callInfo)
109
- {
110
- if (!hqChart.NetworkFilter) return false;
111
-
112
- var self=this;
113
-
114
- var param=
115
- {
116
- HQChart:hqChart,
117
- };
118
-
119
- var obj=
120
- {
121
- Name:`${this.ClassName}::RequestData`, //类名::函数
122
- Explain:this.Explain,
123
- Request:this.GetRequestData(hqChart),
124
- Self:this,
125
- HQChart:hqChart,
126
- CallInfo:callInfo,
127
- PreventDefault:false
128
- };
129
-
130
- if (callInfo)
131
- {
132
- if (callInfo.Update==true)
133
- {
134
- obj.Update={ Start:{ Date: callInfo.StartDate } };
135
- param.Update={ Start:{ Date: callInfo.StartDate } };
136
- }
137
-
138
- obj.CallFunctionName=callInfo.FunctionName; //内部调用函数名
139
- }
140
-
141
- hqChart.NetworkFilter(obj, function(data)
142
- {
143
- self.RecvData(data,param);
144
- });
145
-
146
- if (obj.PreventDefault==true) return true; //已被上层替换,不调用默认的网络请求
147
-
148
- return false;
149
- }
150
- }
151
-
152
- /*
153
- 互动易
154
- */
155
- function InvestorInfo()
156
- {
157
- this.newMethod=IKLineInfo; //派生
158
- this.newMethod();
159
- delete this.newMethod;
160
-
161
- this.ClassName="InvestorInfo";
162
- this.Explain="互动易";
163
-
164
- this.RequestData=function(hqChart, obj)
165
- {
166
- var self = this;
167
- var param={ HQChart:hqChart };
168
- this.Data=[];
169
-
170
- if (this.NetworkFilter(hqChart,obj)) return; //已被上层替换,不调用默认的网络请求
171
-
172
- //请求数据
173
- wx.request({
174
- url: g_JSChartResource.Domain+g_JSChartResource.KLine.Info.Investor.ApiUrl,
175
- data:
176
- {
177
- "filed": ["question","answerdate","symbol","id"],
178
- "symbol": [param.HQChart.Symbol],
179
- "querydate":{"StartDate":this.StartDate,"EndDate":this.GetToday()},
180
- "start":0,
181
- "end":this.MaxRequestDataCount,
182
- },
183
- method:"post",
184
- dataType: "json",
185
- success: function (recvData)
186
- {
187
- self.RecvData(recvData,param);
188
- }
189
- });
190
-
191
- return true;
192
- }
193
-
194
- this.RecvData=function(recvData,param)
195
- {
196
- var data=recvData.data;
197
- if (!data || !data.list || data.list.length<=0) return;
198
-
199
- for (var i in data.list)
200
- {
201
- var item = data.list[i];
202
- var infoData=new KLineInfoData();
203
- infoData.Date=item.answerdate;
204
- infoData.Title=item.question;
205
- infoData.InfoType=KLINE_INFO_TYPE.INVESTOR;
206
- this.Data.push(infoData);
207
- }
208
-
209
- param.HQChart.UpdataChartInfo();
210
- param.HQChart.Draw();
211
- }
212
- }
213
-
214
- /*
215
- 公告
216
- */
217
- function AnnouncementInfo()
218
- {
219
- this.newMethod=IKLineInfo; //派生
220
- this.newMethod();
221
- delete this.newMethod;
222
-
223
- this.ClassName='AnnouncementInfo';
224
- this.Explain="公告";
225
-
226
- this.RequestData=function(hqChart, obj)
227
- {
228
- var self = this;
229
- var param={ HQChart:hqChart };
230
-
231
- if (obj && obj.Update===true) //更新模式 不清内存数据
232
- {
233
-
234
- }
235
- else
236
- {
237
- this.Data=[];
238
- }
239
-
240
- if (this.NetworkFilter(hqChart, obj)) return; //已被上层替换,不调用默认的网络请求
241
-
242
- //请求数据
243
- wx.request({
244
- url: g_JSChartResource.Domain+g_JSChartResource.KLine.Info.Announcement.ApiUrl,
245
- data:
246
- {
247
- "filed": ["title","releasedate","symbol","id"],
248
- "symbol": [param.HQChart.Symbol],
249
- "querydate":{"StartDate":this.StartDate,"EndDate":this.GetToday()},
250
- "start":0,
251
- "end":this.MaxRequestDataCount,
252
- },
253
- method:"post",
254
- dataType: "json",
255
- success: function (recvData)
256
- {
257
- self.RecvData(recvData,param);
258
- }
259
- });
260
-
261
- return true;
262
- }
263
-
264
- this.RecvData=function(recvData,param)
265
- {
266
- var data=recvData.data;
267
- if (!data) return;
268
- if (!data.report || data.report.length<=0) return;
269
-
270
- for (var i in data.report)
271
- {
272
- var item = data.report[i];
273
- var infoData=new KLineInfoData();
274
- infoData.Date=item.releasedate;
275
- infoData.Title=item.title;
276
- infoData.InfoType=KLINE_INFO_TYPE.ANNOUNCEMENT;
277
- for(var j in item.type)
278
- {
279
- var typeItem=item.type[j];
280
- switch(typeItem)
281
- {
282
- case "一季度报告":
283
- infoData.InfoType=KLINE_INFO_TYPE.ANNOUNCEMENT_QUARTER_1;
284
- break;
285
- case "半年度报告":
286
- infoData.InfoType=KLINE_INFO_TYPE.ANNOUNCEMENT_QUARTER_2;
287
- break;
288
- case "三季度报告":
289
- infoData.InfoType=KLINE_INFO_TYPE.ANNOUNCEMENT_QUARTER_3;
290
- break;
291
- case "年度报告":
292
- infoData.InfoType=KLINE_INFO_TYPE.ANNOUNCEMENT_QUARTER_4;
293
- break;
294
- }
295
- }
296
- this.Data.push(infoData);
297
- }
298
-
299
- param.HQChart.UpdataChartInfo();
300
- param.HQChart.Draw();
301
- }
302
- }
303
-
304
-
305
- /*
306
- 业绩预告
307
- */
308
- function PforecastInfo()
309
- {
310
- this.newMethod=IKLineInfo; //派生
311
- this.newMethod();
312
- delete this.newMethod;
313
-
314
- this.ClassName='PforecastInfo';
315
- this.Explain='业绩预告';
316
-
317
- this.RequestData=function(hqChart,obj)
318
- {
319
- var self = this;
320
- this.Data = [];
321
- var param={ HQChart:hqChart };
322
-
323
- if (this.NetworkFilter(hqChart,obj)) return; //已被上层替换,不调用默认的网络请求
324
-
325
- //请求数据
326
- wx.request({
327
- url: g_JSChartResource.Domain+g_JSChartResource.KLine.Info.Pforecast.ApiUrl,
328
- data:
329
- {
330
- "field": ["pforecast.type","pforecast.reportdate","fweek"],
331
- "condition":
332
- [
333
- {"item":["pforecast.reportdate","int32","gte",this.StartDate]}
334
- ],
335
- "symbol": [param.HQChart.Symbol],
336
- "start":0,
337
- "end":this.MaxRequestDataCount,
338
- },
339
- method:"post",
340
- dataType: "json",
341
- success: function (recvData)
342
- {
343
- self.RecvData(recvData,param);
344
- }
345
- });
346
- return true;
347
- }
348
-
349
- this.RecvData=function(recvData,param)
350
- {
351
- var data=recvData.data;
352
- if (!data.stock || data.stock.length!=1) return;
353
- if (!data.stock[0].stockday || data.stock[0].stockday.length<=0) return;
354
-
355
- for (var i in data.stock[0].stockday)
356
- {
357
- var item = data.stock[0].stockday[i];
358
- if (item.pforecast.length>0)
359
- {
360
- var dataItem=item.pforecast[0];
361
- var infoData=new KLineInfoData();
362
- infoData.Date= item.date;
363
- infoData.Title=dataItem.type;
364
- infoData.InfoType=KLINE_INFO_TYPE.PFORECAST;
365
- infoData.ExtendData={ Type:dataItem.type, ReportDate:dataItem.reportdate}
366
- if(item.fweek) //未来周涨幅
367
- {
368
- infoData.ExtendData.FWeek={};
369
- if (item.fweek.week1!=null) infoData.ExtendData.FWeek.Week1=item.fweek.week1;
370
- if (item.fweek.week4!=null) infoData.ExtendData.FWeek.Week4=item.fweek.week4;
371
- }
372
- this.Data.push(infoData);
373
- }
374
- }
375
-
376
- param.HQChart.UpdataChartInfo();
377
- param.HQChart.Draw();
378
- }
379
- }
380
-
381
- /*
382
- 投资者关系 (调研)
383
- */
384
- function ResearchInfo()
385
- {
386
- this.newMethod=IKLineInfo; //派生
387
- this.newMethod();
388
- delete this.newMethod;
389
-
390
- this.ClassName='ResearchInfo';
391
- this.Explain='投资者关系';
392
-
393
- this.RequestData=function(hqChart,obj)
394
- {
395
- var self = this;
396
- var param= { HQChart:hqChart };
397
-
398
- this.Data=[];
399
-
400
- if (this.NetworkFilter(hqChart,obj)) return; //已被上层替换,不调用默认的网络请求
401
-
402
- //请求数据
403
- wx.request({
404
- url: g_JSChartResource.Domain+g_JSChartResource.KLine.Info.Research.ApiUrl,
405
- data:
406
- {
407
- "filed": ["releasedate","researchdate","level","symbol","id"],
408
- "querydate":{"StartDate":this.StartDate,"EndDate":this.GetToday()},
409
- "symbol": [param.HQChart.Symbol],
410
- "start":0,
411
- "end":this.MaxRequestDataCount,
412
- },
413
- method:"post",
414
- dataType: "json",
415
- success: function (recvData)
416
- {
417
- self.RecvData(recvData,param);
418
- }
419
- });
420
-
421
- return true;
422
- }
423
-
424
- this.RecvData=function(recvData,param)
425
- {
426
- var data=recvData.data;
427
- if (!data) return;
428
- if (!data.list || data.list.length<=0) return;
429
-
430
- for (var i in data.list)
431
- {
432
- var item = data.list[i];
433
- var infoData=new KLineInfoData();
434
- infoData.ID=item.id;
435
- infoData.Date= item.researchdate;
436
- infoData.InfoType=KLINE_INFO_TYPE.RESEARCH;
437
- infoData.ExtendData={ Level:item.level };
438
- this.Data.push(infoData);
439
-
440
- }
441
-
442
- param.HQChart.UpdataChartInfo();
443
- param.HQChart.Draw();
444
- }
445
- }
446
-
447
- /*
448
- 大宗交易
449
- */
450
- function BlockTrading()
451
- {
452
- this.newMethod=IKLineInfo; //派生
453
- this.newMethod();
454
- delete this.newMethod;
455
-
456
- this.ClassName='BlockTrading';
457
- this.Explain='大宗交易';
458
-
459
- this.RequestData=function(hqChart,obj)
460
- {
461
- var self = this;
462
- var param={ HQChart:hqChart,};
463
- this.Data=[];
464
-
465
- if (this.NetworkFilter(hqChart,obj)) return; //已被上层替换,不调用默认的网络请求
466
-
467
- //请求数据
468
- wx.request({
469
- url: g_JSChartResource.Domain+g_JSChartResource.KLine.Info.BlockTrading.ApiUrl,
470
- data:
471
- {
472
- "field": ["blocktrading.price","blocktrading.vol","blocktrading.premium","fweek","price"],
473
- "condition":
474
- [
475
- {"item":["date","int32","gte",this.StartDate]},
476
- {"item":["blocktrading.vol","int32","gte","0"]}
477
- ],
478
- "symbol": [param.HQChart.Symbol],
479
- "start":0,
480
- "end":this.MaxRequestDataCount,
481
- },
482
- method:"post",
483
- dataType: "json",
484
- success: function (recvData)
485
- {
486
- self.RecvData(recvData,param);
487
- }
488
- });
489
-
490
- return true;
491
- }
492
-
493
- this.RecvData=function(recvData,param)
494
- {
495
- var data=recvData.data;
496
- if (!data || !data.stock || data.stock.length!=1) return;
497
- if (!data.stock[0].stockday || data.stock[0].stockday.length<=0) return;
498
-
499
- for (var i in data.stock[0].stockday)
500
- {
501
- var item = data.stock[0].stockday[i];
502
- var infoData=new KLineInfoData();
503
- infoData.Date= item.date;
504
- infoData.InfoType=KLINE_INFO_TYPE.BLOCKTRADING;
505
- infoData.ExtendData=
506
- {
507
- Price:item.blocktrading.price, //交易价格
508
- Premium:item.blocktrading.premium, //溢价 (百分比%)
509
- Vol:item.blocktrading.vol, //交易金额单位(万元)
510
- ClosePrice:item.price, //收盘价
511
- };
512
-
513
- if(item.fweek) //未来周涨幅
514
- {
515
- infoData.ExtendData.FWeek={};
516
- if (item.fweek.week1!=null) infoData.ExtendData.FWeek.Week1=item.fweek.week1;
517
- if (item.fweek.week4!=null) infoData.ExtendData.FWeek.Week4=item.fweek.week4;
518
- }
519
-
520
- this.Data.push(infoData);
521
- }
522
-
523
- param.HQChart.UpdataChartInfo();
524
- param.HQChart.Draw();
525
- }
526
- }
527
-
528
-
529
- /*
530
- 龙虎榜
531
- */
532
- function TradeDetail()
533
- {
534
- this.newMethod=IKLineInfo; //派生
535
- this.newMethod();
536
- delete this.newMethod;
537
-
538
- this.ClassName='TradeDetail';
539
- this.Explain='龙虎榜';
540
-
541
- this.RequestData=function(hqChart,obj)
542
- {
543
- var self = this;
544
- var param={ HQChart:hqChart };
545
-
546
- this.Data=[];
547
-
548
- if (this.NetworkFilter(hqChart,obj)) return; //已被上层替换,不调用默认的网络请求
549
-
550
- //请求数据
551
- wx.request({
552
- url: g_JSChartResource.Domain+g_JSChartResource.KLine.Info.TradeDetail.ApiUrl,
553
- data:
554
- {
555
- "field": ["tradedetail.typeexplain","tradedetail.type","fweek"],
556
- "condition":
557
- [
558
- {"item":["date","int32","gte",this.StartDate]},
559
- {"item":["tradedetail.type","int32","gte","0"]}
560
- ],
561
- "symbol": [param.HQChart.Symbol],
562
- "start":0,
563
- "end":this.MaxRequestDataCount,
564
- },
565
- method:"post",
566
- dataType: "json",
567
- success: function (recvData)
568
- {
569
- self.RecvData(recvData,param);
570
- }
571
- });
572
-
573
- return true;
574
- }
575
-
576
- this.RecvData=function(recvData,param)
577
- {
578
- var data=recvData.data;
579
- if (!data || !data.stock || data.stock.length!=1) return;
580
- if (!data.stock[0].stockday || data.stock[0].stockday.length<=0) return;
581
-
582
- for (var i in data.stock[0].stockday)
583
- {
584
- var item = data.stock[0].stockday[i];
585
-
586
- var infoData=new KLineInfoData();
587
- infoData.Date= item.date;
588
- infoData.InfoType=KLINE_INFO_TYPE.TRADEDETAIL;
589
- infoData.ExtendData={Detail:new Array()};
590
-
591
- for(var j in item.tradedetail)
592
- {
593
- var tradeItem=item.tradedetail[j];
594
- infoData.ExtendData.Detail.push({"Type":tradeItem.type,"TypeExplain":tradeItem.typeexplain});
595
- }
596
-
597
- if(item.fweek) //未来周涨幅
598
- {
599
- infoData.ExtendData.FWeek={};
600
- if (item.fweek.week1!=null) infoData.ExtendData.FWeek.Week1=item.fweek.week1;
601
- if (item.fweek.week4!=null) infoData.ExtendData.FWeek.Week4=item.fweek.week4;
602
- }
603
-
604
- this.Data.push(infoData);
605
- }
606
-
607
- param.HQChart.UpdataChartInfo();
608
- param.HQChart.Draw();
609
- }
610
- }
611
-
612
- //策略信息
613
- function PolicyInfo()
614
- {
615
- this.newMethod = IKLineInfo; //派生
616
- this.newMethod();
617
- delete this.newMethod;
618
-
619
- this.ClassName='PolicyInfo';
620
- this.Explain='策略信息';
621
- this.PolicyList = []; //筛选的策略名字 {Name:策略名, Guid:策略的GUID}
622
-
623
- this.SetPolicyList=function(aryPolicy)
624
- {
625
- for(let i in aryPolicy)
626
- {
627
- this.PolicyList.push({Name:aryPolicy[i]});
628
- }
629
- }
630
-
631
- this.RequestData = function (hqChart,obj)
632
- {
633
- var self = this;
634
- this.Data = [];
635
- var param = { HQChart: hqChart };
636
-
637
- // setTimeout(function () { self.RecvData(null, param); }, 2000); //模拟数据到达
638
-
639
- if (this.NetworkFilter(hqChart,obj)) return; //已被上层替换,不调用默认的网络请求
640
-
641
- //请求数据
642
- wx.request({
643
- url: g_JSChartResource.Domain + g_JSChartResource.KLine.Info.Policy.ApiUrl,
644
- data: {
645
- "symbol": [param.HQChart.Symbol],
646
- field: ["policy"],
647
- "condition": [
648
- { "item": ["date", "int32", "gte", this.StartDate, "lte", this.GetToday()] }],
649
- "start": 0,
650
- "end": this.MaxRequestDataCount
651
- },
652
- method: "post",
653
- dataType: "json",
654
- success: function (recvData) {
655
- self.RecvData(recvData, param);
656
- }
657
-
658
- })
659
-
660
- return true;
661
- }
662
-
663
- this.RecvData = function (recvData, param)
664
- {
665
- var data = recvData.data;
666
- if (!data.stock || data.stock.length != 1) return;
667
- if (!data.stock[0].stockday || data.stock[0].stockday.length <= 0) return;
668
-
669
- var setName=new Set();
670
- for(var i in this.PolicyList) //把需要过滤的策略名字放set里, 方便后面过滤
671
- {
672
- setName.add(this.PolicyList[i].Name);
673
- }
674
-
675
- for (var i in data.stock[0].stockday)
676
- {
677
- var item = data.stock[0].stockday[i];
678
- var infoData = new KLineInfoData();
679
- infoData.Date = item.date;
680
- infoData.InfoType = KLINE_INFO_TYPE.POLICY;
681
- infoData.ExtendData = [];
682
- for (var j in item.policy)
683
- {
684
- var name = item.policy[j].name;
685
- if (setName.has(name)) infoData.ExtendData.push({ Name: name });
686
- }
687
-
688
- if (infoData.ExtendData.length>0) this.Data.push(infoData);
689
- }
690
-
691
- param.HQChart.UpdataChartInfo();
692
- param.HQChart.Draw();
693
-
694
- if (param.HQChart.UpdateUICallback) param.HQChart.UpdateUICallback('RecvPolicyInfoData', this);
695
- }
696
- }
697
-
698
- ////////////////////////////////////////////////////////////////////////////////////////////
699
- // 走势图信息地雷
700
- //
701
- //
702
- ////////////////////////////////////////////////////////////////////////////////////////////
703
- function JSMinuteInfoMap() { }
704
-
705
- JSMinuteInfoMap.InfoMap = new Map(
706
- [
707
- ["大盘异动", { Create: function () { return new MarketEventInfo() } }],
708
- ]);
709
-
710
- JSMinuteInfoMap.Get = function (id)
711
- {
712
- return JSMinuteInfoMap.InfoMap.get(id);
713
- }
714
-
715
- function IMinuteInfo()
716
- {
717
- this.Data;
718
- this.ClassName = 'IMinuteInfo';
719
- }
720
-
721
- //////////////////////////////////////////////////////////////////////
722
- // 大盘异动
723
- // 结构 {Date:日期 Time:时间, Title:标题, Type:0 }
724
- ////////////////////////////////////////////////////////////////////
725
- function MarketEventInfo()
726
- {
727
- this.newMethod = IMinuteInfo; //派生
728
- this.newMethod();
729
- delete this.newMethod;
730
-
731
- this.ClassName = 'MarketEventInfo';
732
-
733
- this.RequestData = function (hqChart)
734
- {
735
- var self = this;
736
- this.Data = [];
737
- var param =
738
- {
739
- HQChart: hqChart
740
- };
741
-
742
- var url = g_JSChartResource.CacheDomain + '/cache/analyze/shszevent/marketevent/concept/' + hqChart.TradeDate + '.json';
743
-
744
- if (hqChart.NetworkFilter) {
745
- var obj =
746
- {
747
- Name: 'MarketEventInfo::RequestData', //类名::
748
- Explain: '大盘异动',
749
- Request: { Url: url, Type: 'Get', Data: { Date: hqChart.TradeDate, Symbol: hqChart.Symbol } },
750
- Self: this,
751
- PreventDefault: false
752
- };
753
- hqChart.NetworkFilter(obj, function (data)
754
- {
755
- self.RecvData(data, param);
756
- param.HQChart.UpdataChartInfo();
757
- param.HQChart.Draw();
758
- });
759
-
760
- if (obj.PreventDefault == true) return; //已被上层替换,不调用默认的网络请求
761
- }
762
-
763
- //请求数据
764
- wx.request({
765
- url: url,
766
- method: "get",
767
- dataType: "json",
768
- success: function (recvData) {
769
- self.RecvData(recvData, param);
770
- },
771
- error: function (http, e) {
772
- console.warn("[MarketEventInfo::RequestData] error, http ", e, http);
773
- }
774
- });
775
-
776
- return true;
777
- }
778
-
779
- this.RecvData = function (recvData, param)
780
- {
781
- var data=recvData.data;
782
- for (var i in data.event)
783
- {
784
- var event = data.event[i];
785
- for (var j in event.data)
786
- {
787
- var item = event.data[j];
788
- if (Array.isArray(item))
789
- {
790
- if (item.length < 2) continue;
791
- var info = { Date: event.date, Time: item[0], Title: item[1], Type: 0 };
792
- this.Data.push(info);
793
- }
794
- else //2.0 格式
795
- {
796
- if (!IFrameSplitOperator.IsNumber(item.Date) || !IFrameSplitOperator.IsNumber(item.Time) || !item.Title) continue;
797
- var info={ Date:item.Date, Time:item.Time, Title:item.Title, Type:0 };
798
- if (item.Color) info.Color=item.Color;
799
- if (item.BGColor) info.BGColor=item.BGColor;
800
- if (IFrameSplitOperator.IsNumber(item.Price)) info.Price=item.Price;
801
- if (item.Content) info.Content=item.Content;
802
- if (item.Link) info.Link=item.Link;
803
- this.Data.push(info);
804
- }
805
- }
806
- }
807
-
808
- param.HQChart.UpdataChartInfo();
809
- param.HQChart.Draw();
810
- }
811
- }
812
-
813
- //导出统一使用JSCommon命名空间名
814
- export
815
- {
816
- JSKLineInfoMap,
817
- KLINE_INFO_TYPE,
818
- JSMinuteInfoMap,
819
- };
820
-
821
- /*
822
- module.exports =
823
- {
824
- JSCommonKLineInfo:
825
- {
826
- JSKLineInfoMap: JSKLineInfoMap,
827
- KLINE_INFO_TYPE: KLINE_INFO_TYPE,
828
- JSMinuteInfoMap: JSMinuteInfoMap,
829
- },
830
-
831
- //单个类导出
832
- JSCommon_JSKLineInfoMap: JSKLineInfoMap,
833
- JSCommon_KLINE_INFO_TYPE: KLINE_INFO_TYPE,
834
- JSCommon_JSMinuteInfoMap: JSMinuteInfoMap,
835
- };
836
- */