CssValueFunction.cs 143 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using SCC.Models;
  6. namespace SCC.Crawler.DT
  7. {
  8. public class CssValueFunction
  9. {
  10. #region 单值
  11. /// <summary>
  12. /// 单值单列期号
  13. /// </summary>
  14. /// <param name="isValue"></param>
  15. /// <param name="fomart"></param>
  16. /// <param name="attr"></param>
  17. /// <param name="css"></param>
  18. /// <param name="itemValue"></param>
  19. /// <param name="index"></param>
  20. /// <returns></returns>
  21. public static string SingleCell_TermItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  22. string itemValue, int index)
  23. {
  24. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  25. }
  26. /// <summary>
  27. /// 单值单列开奖号012路值
  28. /// </summary>
  29. /// <param name="isValue"></param>
  30. /// <param name="fomart"></param>
  31. /// <param name="attr"></param>
  32. /// <param name="css"></param>
  33. /// <param name="itemValue"></param>
  34. /// <param name="index"></param>
  35. /// <returns></returns>
  36. public static string SingleCell_012StatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  37. string itemValue, int index)
  38. {
  39. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  40. }
  41. /// <summary>
  42. /// 单值单列和尾
  43. /// </summary>
  44. /// <param name="isValue"></param>
  45. /// <param name="fomart"></param>
  46. /// <param name="attr"></param>
  47. /// <param name="css"></param>
  48. /// <param name="itemValue"></param>
  49. /// <param name="index"></param>
  50. /// <returns></returns>
  51. public static string SingleCell_HeWeiItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  52. string itemValue, int index)
  53. {
  54. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  55. }
  56. /// <summary>
  57. /// 单值单列跨度值
  58. /// </summary>
  59. /// <param name="isValue"></param>
  60. /// <param name="fomart"></param>
  61. /// <param name="attr"></param>
  62. /// <param name="css"></param>
  63. /// <param name="itemValue"></param>
  64. /// <param name="index"></param>
  65. /// <returns></returns>
  66. public static string SingleCell_SpanItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  67. string itemValue, int index)
  68. {
  69. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  70. }
  71. /// <summary>
  72. /// 单值单列组三跨度值
  73. /// </summary>
  74. /// <param name="isValue"></param>
  75. /// <param name="fomart"></param>
  76. /// <param name="attr"></param>
  77. /// <param name="css"></param>
  78. /// <param name="itemValue"></param>
  79. /// <param name="index"></param>
  80. /// <returns></returns>
  81. public static string SingleCell_ZSSpanItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  82. string itemValue, int index)
  83. {
  84. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  85. }
  86. /// <summary>
  87. /// 单值单列和值
  88. /// </summary>
  89. /// <param name="isValue"></param>
  90. /// <param name="fomart"></param>
  91. /// <param name="attr"></param>
  92. /// <param name="css"></param>
  93. /// <param name="itemValue"></param>
  94. /// <param name="index"></param>
  95. /// <returns></returns>
  96. public static string SingleCell_SumItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  97. string itemValue, int index)
  98. {
  99. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  100. }
  101. /// <summary>
  102. /// 单值单列试机号
  103. /// </summary>
  104. /// <param name="isValue"></param>
  105. /// <param name="fomart"></param>
  106. /// <param name="attr"></param>
  107. /// <param name="css"></param>
  108. /// <param name="itemValue"></param>
  109. /// <param name="index"></param>
  110. /// <returns></returns>
  111. public static string SingleCell_ShiJiHaoItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  112. string itemValue, int index)
  113. {
  114. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  115. }
  116. /// <summary>
  117. /// 单值多列试机号分布
  118. /// </summary>
  119. /// <param name="isValue"></param>
  120. /// <param name="fomart"></param>
  121. /// <param name="attr"></param>
  122. /// <param name="css"></param>
  123. /// <param name="itemValue"></param>
  124. /// <param name="index"></param>
  125. /// <returns></returns>
  126. public static string SingleValue_ShiJiHao(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  127. string itemValue, int index)
  128. {
  129. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  130. }
  131. /// <summary>
  132. /// 单值多列组三形态
  133. /// </summary>
  134. /// <param name="isValue"></param>
  135. /// <param name="fomart"></param>
  136. /// <param name="attr"></param>
  137. /// <param name="css"></param>
  138. /// <param name="itemValue"></param>
  139. /// <param name="index"></param>
  140. /// <returns></returns>
  141. public static string SingleValue_ZsStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  142. string itemValue, int index)
  143. {
  144. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  145. }
  146. /// <summary>
  147. /// 单值多列组三奇偶形态
  148. /// </summary>
  149. /// <param name="isValue"></param>
  150. /// <param name="fomart"></param>
  151. /// <param name="attr"></param>
  152. /// <param name="css"></param>
  153. /// <param name="itemValue"></param>
  154. /// <param name="index"></param>
  155. /// <returns></returns>
  156. public static string SingleValue_ZsJoStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  157. string itemValue, int index)
  158. {
  159. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  160. }
  161. /// <summary>
  162. /// 单值多列和尾分布形态
  163. /// </summary>
  164. /// <param name="isValue"></param>
  165. /// <param name="fomart"></param>
  166. /// <param name="attr"></param>
  167. /// <param name="css"></param>
  168. /// <param name="itemValue"></param>
  169. /// <param name="index"></param>
  170. /// <returns></returns>
  171. public static string SingleValue_HeWeiItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  172. string itemValue, int index)
  173. {
  174. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  175. }
  176. /// <summary>
  177. /// 单值多列组三大小形态
  178. /// </summary>
  179. /// <param name="isValue"></param>
  180. /// <param name="fomart"></param>
  181. /// <param name="attr"></param>
  182. /// <param name="css"></param>
  183. /// <param name="itemValue"></param>
  184. /// <param name="index"></param>
  185. /// <returns></returns>
  186. public static string SingleValue_ZsDxStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  187. string itemValue, int index)
  188. {
  189. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  190. }
  191. /// <summary>
  192. /// 单值多列组三012形态
  193. /// </summary>
  194. /// <param name="isValue"></param>
  195. /// <param name="fomart"></param>
  196. /// <param name="attr"></param>
  197. /// <param name="css"></param>
  198. /// <param name="itemValue"></param>
  199. /// <param name="index"></param>
  200. /// <returns></returns>
  201. public static string SingleValue_Zs012StatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  202. string itemValue, int index)
  203. {
  204. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  205. }
  206. /// <summary>
  207. /// 单值单列后区号码
  208. /// </summary>
  209. /// <param name="isValue"></param>
  210. /// <param name="fomart"></param>
  211. /// <param name="attr"></param>
  212. /// <param name="css"></param>
  213. /// <param name="itemValue"></param>
  214. /// <param name="index"></param>
  215. /// <returns></returns>
  216. public static string SingleCell_HqItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  217. string itemValue, int index)
  218. {
  219. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  220. }
  221. /// <summary>
  222. /// 单值单列重号项
  223. /// </summary>
  224. /// <param name="isValue"></param>
  225. /// <param name="fomart"></param>
  226. /// <param name="attr"></param>
  227. /// <param name="css"></param>
  228. /// <param name="itemValue"></param>
  229. /// <param name="index"></param>
  230. /// <returns></returns>
  231. public static string SingleCell_RepeatedNumber(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  232. string itemValue, int index)
  233. {
  234. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  235. }
  236. /// <summary>
  237. /// 单值单列连号项
  238. /// </summary>
  239. /// <param name="isValue"></param>
  240. /// <param name="fomart"></param>
  241. /// <param name="attr"></param>
  242. /// <param name="css"></param>
  243. /// <param name="itemValue"></param>
  244. /// <param name="index"></param>
  245. /// <returns></returns>
  246. public static string SingleCell_LinkNumber(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  247. string itemValue, int index)
  248. {
  249. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  250. }
  251. /// <summary>
  252. /// 和值(区间)分布
  253. /// </summary>
  254. /// <param name="isValue"></param>
  255. /// <param name="fomart"></param>
  256. /// <param name="attr"></param>
  257. /// <param name="css"></param>
  258. /// <param name="itemValue"></param>
  259. /// <param name="index"></param>
  260. /// <returns></returns>
  261. public static string SingleValue_SumItemGroup(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  262. string itemValue, int index)
  263. {
  264. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  265. }
  266. /// <summary>
  267. /// 单值单列开奖号码
  268. /// </summary>
  269. /// <param name="isValue"></param>
  270. /// <param name="fomart"></param>
  271. /// <param name="attr"></param>
  272. /// <param name="css"></param>
  273. /// <param name="itemValue"></param>
  274. /// <param name="index"></param>
  275. /// <returns></returns>
  276. public static string SingleCell_OpenCodeItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  277. string itemValue, int index)
  278. {
  279. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  280. }
  281. /// <summary>
  282. /// 单值单列012比
  283. /// </summary>
  284. /// <param name="isValue"></param>
  285. /// <param name="fomart"></param>
  286. /// <param name="attr"></param>
  287. /// <param name="css"></param>
  288. /// <param name="itemValue"></param>
  289. /// <param name="index"></param>
  290. /// <returns></returns>
  291. public static string SingleCell_ProportionOf012Item(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  292. string itemValue, int index)
  293. {
  294. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  295. }
  296. /// <summary>
  297. /// 单值单列大小比例
  298. /// </summary>
  299. /// <param name="isValue"></param>
  300. /// <param name="fomart"></param>
  301. /// <param name="attr"></param>
  302. /// <param name="css"></param>
  303. /// <param name="itemValue"></param>
  304. /// <param name="index"></param>
  305. /// <returns></returns>
  306. public static string SingleCell_ProportionOfDxItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  307. string itemValue, int index)
  308. {
  309. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  310. }
  311. /// <summary>
  312. /// 单值单列质合形态比例
  313. /// </summary>
  314. /// <param name="isValue"></param>
  315. /// <param name="fomart"></param>
  316. /// <param name="attr"></param>
  317. /// <param name="css"></param>
  318. /// <param name="itemValue"></param>
  319. /// <param name="index"></param>
  320. /// <returns></returns>
  321. public static string SingleCell_ProportionOfZhItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  322. string itemValue, int index)
  323. {
  324. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  325. }
  326. /// <summary>
  327. /// 单值单列奇偶比例
  328. /// </summary>
  329. /// <param name="isValue"></param>
  330. /// <param name="fomart"></param>
  331. /// <param name="attr"></param>
  332. /// <param name="css"></param>
  333. /// <param name="itemValue"></param>
  334. /// <param name="index"></param>
  335. /// <returns></returns>
  336. public static string SingleCell_ProportionOfJoItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css,
  337. string itemValue, int index)
  338. {
  339. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  340. }
  341. /// <summary>
  342. /// 单值多列号码项
  343. /// </summary>
  344. /// <param name="isValue"></param>
  345. /// <param name="fomart"></param>
  346. /// <param name="attr"></param>
  347. /// <param name="css"></param>
  348. /// <param name="itemValue"></param>
  349. /// <param name="index"></param>
  350. /// <returns></returns>
  351. public static string SingleValue_NumberItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  352. {
  353. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  354. }
  355. /// <summary>
  356. /// 单值多列大小状态项
  357. /// </summary>
  358. /// <param name="isValue"></param>
  359. /// <param name="fomart"></param>
  360. /// <param name="attr"></param>
  361. /// <param name="css"></param>
  362. /// <param name="itemValue"></param>
  363. /// <param name="index"></param>
  364. /// <returns></returns>
  365. public static string SingleValue_DaXiaoStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  366. {
  367. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  368. }
  369. /// <summary>
  370. /// 单值多列012分布项
  371. /// </summary>
  372. /// <param name="isValue"></param>
  373. /// <param name="fomart"></param>
  374. /// <param name="attr"></param>
  375. /// <param name="css"></param>
  376. /// <param name="itemValue"></param>
  377. /// <param name="index"></param>
  378. /// <returns></returns>
  379. public static string SingleValue_Number012StatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  380. {
  381. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  382. }
  383. /// <summary>
  384. /// 单值多列奇偶状态项
  385. /// </summary>
  386. /// <param name="isValue"></param>
  387. /// <param name="fomart"></param>
  388. /// <param name="attr"></param>
  389. /// <param name="css"></param>
  390. /// <param name="itemValue"></param>
  391. /// <param name="index"></param>
  392. /// <returns></returns>
  393. public static string SingleValue_JiOuStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  394. {
  395. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  396. }
  397. /// <summary>
  398. /// 单值多列多于两个号码跨度项
  399. /// </summary>
  400. /// <param name="isValue"></param>
  401. /// <param name="fomart"></param>
  402. /// <param name="attr"></param>
  403. /// <param name="css"></param>
  404. /// <param name="itemValue"></param>
  405. /// <param name="index"></param>
  406. /// <returns></returns>
  407. public static string SingleValue_SpanItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  408. {
  409. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  410. }
  411. /// <summary>
  412. /// 单值多列两个号码跨度项
  413. /// </summary>
  414. /// <param name="isValue"></param>
  415. /// <param name="fomart"></param>
  416. /// <param name="attr"></param>
  417. /// <param name="css"></param>
  418. /// <param name="itemValue"></param>
  419. /// <param name="index"></param>
  420. /// <returns></returns>
  421. public static string SingleValue_SpanNumberItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  422. {
  423. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  424. }
  425. /// <summary>
  426. /// 单值多列开奖号码和值奇偶分布项
  427. /// </summary>
  428. /// <param name="isValue"></param>
  429. /// <param name="fomart"></param>
  430. /// <param name="attr"></param>
  431. /// <param name="css"></param>
  432. /// <param name="itemValue"></param>
  433. /// <param name="index"></param>
  434. /// <returns></returns>
  435. public static string SingleValue_HzJoStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  436. {
  437. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  438. }
  439. /// <summary>
  440. /// 单值多列开奖号码和值大小分布项
  441. /// </summary>
  442. /// <param name="isValue"></param>
  443. /// <param name="fomart"></param>
  444. /// <param name="attr"></param>
  445. /// <param name="css"></param>
  446. /// <param name="itemValue"></param>
  447. /// <param name="index"></param>
  448. /// <returns></returns>
  449. public static string SingleValue_HzDxStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  450. {
  451. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  452. }
  453. /// <summary>
  454. /// 单值多列开奖号码和值分布
  455. /// </summary>
  456. /// <param name="isValue"></param>
  457. /// <param name="fomart"></param>
  458. /// <param name="attr"></param>
  459. /// <param name="css"></param>
  460. /// <param name="itemValue"></param>
  461. /// <param name="index"></param>
  462. /// <returns></returns>
  463. public static string SingleValue_SumItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  464. {
  465. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  466. }
  467. /// <summary>
  468. /// 单值单列开奖号码质合项
  469. /// </summary>
  470. /// <param name="isValue"></param>
  471. /// <param name="fomart"></param>
  472. /// <param name="attr"></param>
  473. /// <param name="css"></param>
  474. /// <param name="itemValue"></param>
  475. /// <param name="index"></param>
  476. /// <returns></returns>
  477. public static string SingleCell_ZhiHeStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  478. {
  479. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  480. }
  481. /// <summary>
  482. /// 单值多列开奖号码质合分布项
  483. /// </summary>
  484. /// <param name="isValue"></param>
  485. /// <param name="fomart"></param>
  486. /// <param name="attr"></param>
  487. /// <param name="css"></param>
  488. /// <param name="itemValue"></param>
  489. /// <param name="index"></param>
  490. /// <returns></returns>
  491. public static string SingleValue_ZhiHeStatusItem(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  492. {
  493. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  494. }
  495. /// <summary>
  496. /// 单值多列组三类型
  497. /// </summary>
  498. /// <param name="isValue"></param>
  499. /// <param name="fomart"></param>
  500. /// <param name="attr"></param>
  501. /// <param name="css"></param>
  502. /// <param name="itemValue"></param>
  503. /// <param name="index"></param>
  504. /// <returns></returns>
  505. public static string SingleValue_ZuHeStatusItem<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  506. {
  507. if (itemValue == "组三")
  508. {
  509. return GetCssValue(isValue, fomart, attr, css, "3", index);
  510. }
  511. if (itemValue == "组六")
  512. {
  513. return GetCssValueExtend1(isValue, fomart, attr, css, "6", index);
  514. }
  515. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  516. }
  517. /// <summary>
  518. /// 单值单列双色球AC值
  519. /// </summary>
  520. /// <param name="isValue"></param>
  521. /// <param name="fomart"></param>
  522. /// <param name="attr"></param>
  523. /// <param name="css"></param>
  524. /// <param name="itemValue"></param>
  525. /// <param name="index"></param>
  526. /// <returns></returns>
  527. public static string SingleCell_Ac<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  528. {
  529. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  530. }
  531. /// <summary>
  532. /// 单值单列双色球三区比
  533. /// </summary>
  534. /// <param name="isValue"></param>
  535. /// <param name="fomart"></param>
  536. /// <param name="attr"></param>
  537. /// <param name="css"></param>
  538. /// <param name="itemValue"></param>
  539. /// <param name="index"></param>
  540. /// <returns></returns>
  541. public static string SingleCell_SanQu<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  542. {
  543. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  544. }
  545. /// <summary>
  546. /// 单值单列AC值奇偶值
  547. /// </summary>
  548. /// <param name="isValue"></param>
  549. /// <param name="fomart"></param>
  550. /// <param name="attr"></param>
  551. /// <param name="css"></param>
  552. /// <param name="itemValue"></param>
  553. /// <param name="index"></param>
  554. /// <returns></returns>
  555. public static string SingleCell_AcJiOu<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  556. {
  557. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  558. }
  559. /// <summary>
  560. /// 单值单列AC值质合值
  561. /// </summary>
  562. /// <param name="isValue"></param>
  563. /// <param name="fomart"></param>
  564. /// <param name="attr"></param>
  565. /// <param name="css"></param>
  566. /// <param name="itemValue"></param>
  567. /// <param name="index"></param>
  568. /// <returns></returns>
  569. public static string SingleCell_AcZhiHe<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  570. {
  571. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  572. }
  573. /// <summary>
  574. /// 单值单列AC值012路
  575. /// </summary>
  576. /// <param name="isValue"></param>
  577. /// <param name="fomart"></param>
  578. /// <param name="attr"></param>
  579. /// <param name="css"></param>
  580. /// <param name="itemValue"></param>
  581. /// <param name="index"></param>
  582. /// <returns></returns>
  583. public static string SingleCell_Ac012Lu<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  584. {
  585. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  586. }
  587. /// <summary>
  588. /// 和尾奇偶状态
  589. /// </summary>
  590. /// <param name="isValue"></param>
  591. /// <param name="fomart"></param>
  592. /// <param name="attr"></param>
  593. /// <param name="css"></param>
  594. /// <param name="itemValue"></param>
  595. /// <param name="index"></param>
  596. /// <returns></returns>
  597. public static string SingleValue_HeWeiJiOu<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  598. {
  599. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  600. }
  601. /// <summary>
  602. /// 单值单列试机号和值项
  603. /// </summary>
  604. /// <param name="isValue"></param>
  605. /// <param name="fomart"></param>
  606. /// <param name="attr"></param>
  607. /// <param name="css"></param>
  608. /// <param name="itemValue"></param>
  609. /// <param name="index"></param>
  610. /// <returns></returns>
  611. public static string SingleCell_ShiJiHaoHzItem<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  612. {
  613. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  614. }
  615. /// <summary>
  616. /// 单值单列试机号跨度项
  617. /// </summary>
  618. /// <param name="isValue"></param>
  619. /// <param name="fomart"></param>
  620. /// <param name="attr"></param>
  621. /// <param name="css"></param>
  622. /// <param name="itemValue"></param>
  623. /// <param name="index"></param>
  624. /// <returns></returns>
  625. public static string SingleCell_ShiJiHaoSpanItem<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  626. {
  627. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  628. }
  629. /// <summary>
  630. /// 单值单列试机号大小比项
  631. /// </summary>
  632. /// <param name="isValue"></param>
  633. /// <param name="fomart"></param>
  634. /// <param name="attr"></param>
  635. /// <param name="css"></param>
  636. /// <param name="itemValue"></param>
  637. /// <param name="index"></param>
  638. /// <returns></returns>
  639. public static string SingleCell_ProportionOfShiJiHaoDxItem<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  640. {
  641. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  642. }
  643. /// <summary>
  644. /// 单值多列试机号组三组六类型比项
  645. /// </summary>
  646. /// <param name="isValue"></param>
  647. /// <param name="fomart"></param>
  648. /// <param name="attr"></param>
  649. /// <param name="css"></param>
  650. /// <param name="itemValue"></param>
  651. /// <param name="index"></param>
  652. /// <returns></returns>
  653. public static string SingleValue_ShiJiHaoTypeItem<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  654. {
  655. if (itemValue == "组三")
  656. {
  657. return GetCssValue(isValue, fomart, attr, css, "3", index);
  658. }
  659. if (itemValue == "组六")
  660. {
  661. return GetCssValueExtend1(isValue, fomart, attr, css, "6", index);
  662. }
  663. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  664. }
  665. /// <summary>
  666. /// 单值单列组三号码
  667. /// </summary>
  668. /// <param name="isValue"></param>
  669. /// <param name="fomart"></param>
  670. /// <param name="attr"></param>
  671. /// <param name="css"></param>
  672. /// <param name="itemValue"></param>
  673. /// <param name="index"></param>
  674. /// <returns></returns>
  675. public static string SingleCell_ZsHaoMaItem<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  676. {
  677. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  678. }
  679. /// <summary>
  680. /// 单值单列组三遗漏
  681. /// </summary>
  682. /// <param name="isValue"></param>
  683. /// <param name="fomart"></param>
  684. /// <param name="attr"></param>
  685. /// <param name="css"></param>
  686. /// <param name="itemValue"></param>
  687. /// <param name="index"></param>
  688. /// <returns></returns>
  689. public static string SingleCell_ZsMissItem<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  690. {
  691. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  692. }
  693. /// <summary>
  694. /// 单值单列试机号奇偶比比项
  695. /// </summary>
  696. /// <param name="isValue"></param>
  697. /// <param name="fomart"></param>
  698. /// <param name="attr"></param>
  699. /// <param name="css"></param>
  700. /// <param name="itemValue"></param>
  701. /// <param name="index"></param>
  702. /// <returns></returns>
  703. public static string SingleCell_ProportionOfShiJiHaoJoItem<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  704. {
  705. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  706. }
  707. #endregion
  708. #region 多值
  709. /// <summary>
  710. /// 多值多列重号分布
  711. /// </summary>
  712. /// <param name="isValue"></param>
  713. /// <param name="fomart"></param>
  714. /// <param name="attr"></param>
  715. /// <param name="css"></param>
  716. /// <param name="itemValue"></param>
  717. /// <param name="index"></param>
  718. /// <returns></returns>
  719. public static string MultiValue_RepeatNumber<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  720. {
  721. //IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  722. ////上一期数据 ,下一期数据
  723. //IList<int> lastOpenCode = null, nextOpenCode = null;
  724. ////根据Cid判断_彩种
  725. //switch (ItemConfig.Cid)
  726. //{
  727. // case 2:
  728. // case 3: //P5
  729. // IList<TCP3Info> TCP3lastList = TCP3Service.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  730. // if (null != TCP3lastList && TCP3lastList[0].Term == LocalEntity.Term && TCP3lastList.Count == 2)
  731. // {
  732. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCP3lastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  733. // }
  734. // IList<TCP3Info> TCP3nextList = TCP3Service.ToListForNextTrend(LocalEntity.Term, null);
  735. // if (null != TCP3nextList && TCP3nextList[0].Term == LocalEntity.Term && TCP3nextList.Count == 2)//获取后一期开奖数据
  736. // {
  737. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCP3nextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  738. // }
  739. // if (null != lastOpenCode && lastOpenCode.Contains(itemValue.ToInt())) //如果上期开奖号码中有本期项值(即重号)
  740. // {
  741. // return GetCssValueExtend1(isValue, fomart, attr, css, itemValue, index);
  742. // }
  743. // if (null != nextOpenCode && nextOpenCode.Contains(itemValue.ToInt())) //如果下期开奖号码中有本期项值(即重号)
  744. // {
  745. // return GetCssValueExtend1(isValue, fomart, attr, css, itemValue, index);
  746. // }
  747. // return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  748. // case 4: //双色球
  749. // IList<FCSSQInfo> FCSSQlastList = FCSSQService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  750. // if (null != FCSSQlastList && FCSSQlastList[0].Term == LocalEntity.Term && FCSSQlastList.Count == 2)
  751. // {
  752. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  753. // }
  754. // IList<FCSSQInfo> FCSSQnextList = FCSSQService.ToListForNextTrend(LocalEntity.Term, null);
  755. // if (null != FCSSQnextList && FCSSQnextList[0].Term == LocalEntity.Term && FCSSQnextList.Count == 2)//获取后一期开奖数据
  756. // {
  757. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  758. // }
  759. // if (css != null) //有样式
  760. // {
  761. // if (css.ChildList == null) //没有子样式
  762. // {
  763. // if (isValue) //项值
  764. // {
  765. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  766. // }
  767. // else //遗漏
  768. // {
  769. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  770. // }
  771. // }
  772. // else //有子样式
  773. // {
  774. // foreach (var item in css.ChildList)
  775. // {
  776. // for (int i = item.endNum; i >= item.startNum; i--)
  777. // {
  778. // if (isValue)
  779. // {
  780. // if (index == i - css.ChildList[0].startNum)
  781. // {
  782. // if (null != lastOpenCode && lastOpenCode.Contains(itemValue.ToInt())) //如果上期开奖号码中有本期项值(即重号)
  783. // {
  784. // return string.Format(fomart, item.Extend1, attr, itemValue);
  785. // }
  786. // if (null != nextOpenCode && nextOpenCode.Contains(itemValue.ToInt())) //如果下期开奖号码中有本期项值(即重号)
  787. // {
  788. // return string.Format(fomart, item.Extend1, attr, itemValue);
  789. // }
  790. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  791. // }
  792. // }
  793. // else
  794. // {
  795. // if (index == i - css.ChildList[0].startNum)
  796. // {
  797. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  798. // }
  799. // }
  800. // }
  801. // }
  802. // }
  803. // }
  804. // break;
  805. // case 5: //七乐彩
  806. // IList<FCQLCInfo> FCQLClastList = FCQLCService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  807. // if (null != FCQLClastList && FCQLClastList[0].Term == LocalEntity.Term && FCQLClastList.Count == 2)
  808. // {
  809. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCQLClastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  810. // }
  811. // IList<FCQLCInfo> FCQLCnextList = FCQLCService.ToListForNextTrend(LocalEntity.Term, null);
  812. // if (null != FCQLCnextList && FCQLCnextList[0].Term == LocalEntity.Term && FCQLCnextList.Count == 2)//获取后一期开奖数据
  813. // {
  814. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCQLCnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  815. // }
  816. // if (css != null) //有样式
  817. // {
  818. // if (css.ChildList == null) //没有子样式
  819. // {
  820. // if (isValue) //项值
  821. // {
  822. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  823. // }
  824. // else //遗漏
  825. // {
  826. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  827. // }
  828. // }
  829. // else //有子样式
  830. // {
  831. // foreach (var item in css.ChildList)
  832. // {
  833. // for (int i = item.endNum; i >= item.startNum; i--)
  834. // {
  835. // if (isValue)
  836. // {
  837. // if (index == i - css.ChildList[0].startNum)
  838. // {
  839. // if (null != lastOpenCode && lastOpenCode.Contains(itemValue.ToInt())) //如果上期开奖号码中有本期项值(即重号)
  840. // {
  841. // if (list[list.Count - 1] == itemValue.ToInt()) //是特别号码
  842. // {
  843. // return string.Format(fomart, item.Extend3, attr, itemValue);
  844. // }
  845. // return string.Format(fomart, item.Extend2, attr, itemValue);
  846. // }
  847. // if (null != nextOpenCode && nextOpenCode.Contains(itemValue.ToInt())) //如果下期开奖号码中有本期项值(即重号)
  848. // {
  849. // if (list[list.Count - 1] == itemValue.ToInt()) //是特别号码
  850. // {
  851. // return string.Format(fomart, item.Extend3, attr, itemValue);
  852. // }
  853. // return string.Format(fomart, item.Extend2, attr, itemValue);
  854. // }
  855. // if (list[list.Count - 1] == itemValue.ToInt()) //是特别号码
  856. // {
  857. // return string.Format(fomart, item.Extend1, attr, itemValue);
  858. // }
  859. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  860. // }
  861. // }
  862. // else
  863. // {
  864. // if (index == i - css.ChildList[0].startNum)
  865. // {
  866. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  867. // }
  868. // }
  869. // }
  870. // }
  871. // }
  872. // }
  873. // break;
  874. // case 12: //大乐透
  875. // IList<TCDLTInfo> TCDLTlastList = TCDLTService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  876. // if (null != TCDLTlastList && TCDLTlastList[0].Term == LocalEntity.Term && TCDLTlastList.Count == 2)
  877. // {
  878. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  879. // }
  880. // IList<TCDLTInfo> TCDLTnextList = TCDLTService.ToListForNextTrend(LocalEntity.Term, null);
  881. // if (null != TCDLTnextList && TCDLTnextList[0].Term == LocalEntity.Term && TCDLTnextList.Count == 2)//获取后一期开奖数据
  882. // {
  883. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  884. // }
  885. // if (css != null) //有样式
  886. // {
  887. // if (css.ChildList == null) //没有子样式
  888. // {
  889. // if (isValue) //项值
  890. // {
  891. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  892. // }
  893. // else //遗漏
  894. // {
  895. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  896. // }
  897. // }
  898. // else //有子样式
  899. // {
  900. // foreach (var item in css.ChildList)
  901. // {
  902. // for (int i = item.endNum; i >= item.startNum; i--)
  903. // {
  904. // if (isValue)
  905. // {
  906. // if (index == i - css.ChildList[0].startNum)
  907. // {
  908. // if (null != lastOpenCode && lastOpenCode.Contains(itemValue.ToInt())) //如果上期开奖号码中有本期项值(即重号)
  909. // {
  910. // return string.Format(fomart, item.Extend1, attr, itemValue);
  911. // }
  912. // if (null != nextOpenCode && nextOpenCode.Contains(itemValue.ToInt())) //如果下期开奖号码中有本期项值(即重号)
  913. // {
  914. // return string.Format(fomart, item.Extend1, attr, itemValue);
  915. // }
  916. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  917. // }
  918. // }
  919. // else
  920. // {
  921. // if (index == i - css.ChildList[0].startNum)
  922. // {
  923. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  924. // }
  925. // }
  926. // }
  927. // }
  928. // }
  929. // }
  930. // break;
  931. //}
  932. return string.Format(fomart, "", attr, itemValue); //没有样式(填充默认颜色)
  933. }
  934. /// <summary>
  935. /// 多值多列连号
  936. /// </summary>
  937. /// <param name="isValue"></param>
  938. /// <param name="fomart"></param>
  939. /// <param name="attr"></param>
  940. /// <param name="css"></param>
  941. /// <param name="itemValue"></param>
  942. /// <param name="index"></param>
  943. /// <returns></returns>
  944. public static string MultiValue_LinkNumber<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  945. {
  946. IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  947. //根据Cid判断_彩种
  948. switch (ItemConfig.Cid)
  949. {
  950. case 4: //双色球
  951. if (css != null) //有样式
  952. {
  953. if (css.ChildList == null) //没有子样式
  954. {
  955. if (isValue) //项值
  956. {
  957. return string.Format(fomart, css.NumberCssName, attr, itemValue);
  958. }
  959. else //遗漏
  960. {
  961. return string.Format(fomart, css.MissCssName, attr, itemValue);
  962. }
  963. }
  964. else //有子样式
  965. {
  966. foreach (var item in css.ChildList)
  967. {
  968. for (int i = item.endNum; i >= item.startNum; i--)
  969. {
  970. if (isValue)
  971. {
  972. if (index == i - css.ChildList[0].startNum)
  973. {
  974. if (list.Contains(itemValue.ToInt() - 1) || list.Contains(itemValue.ToInt() + 1)) //是连号用扩展样式1
  975. {
  976. return string.Format(fomart, item.Extend1, attr, itemValue);
  977. }
  978. return string.Format(fomart, item.NumberCssName, attr, itemValue);
  979. }
  980. }
  981. else
  982. {
  983. if (index == i - css.ChildList[0].startNum)
  984. {
  985. return string.Format(fomart, item.MissCssName, attr, itemValue);
  986. }
  987. }
  988. }
  989. }
  990. }
  991. }
  992. break;
  993. case 5: //七乐彩
  994. if (css != null) //有样式
  995. {
  996. if (css.ChildList == null) //没有子样式
  997. {
  998. if (isValue) //项值
  999. {
  1000. return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1001. }
  1002. else //遗漏
  1003. {
  1004. return string.Format(fomart, css.MissCssName, attr, itemValue);
  1005. }
  1006. }
  1007. else //有子样式
  1008. {
  1009. foreach (var item in css.ChildList)
  1010. {
  1011. for (int i = item.endNum; i >= item.startNum; i--)
  1012. {
  1013. if (isValue)
  1014. {
  1015. if (index == i - css.ChildList[0].startNum)
  1016. {
  1017. if (list.Contains(itemValue.ToInt() - 1) || list.Contains(itemValue.ToInt() + 1)) //是连号用扩展样式(红球用扩展2,蓝球用扩展3)
  1018. {
  1019. if (itemValue.ToInt() == list[list.Count - 1])//蓝球连号
  1020. {
  1021. return string.Format(fomart, item.Extend3, attr, itemValue);
  1022. }
  1023. return string.Format(fomart, item.Extend2, attr, itemValue);
  1024. }
  1025. if (itemValue.ToInt() == list[list.Count - 1])//不是连号,是项值(蓝球)
  1026. {
  1027. return string.Format(fomart, item.Extend1, attr, itemValue);
  1028. }
  1029. return string.Format(fomart, item.NumberCssName, attr, itemValue);//不是连号,是项值(红球)
  1030. }
  1031. }
  1032. else
  1033. {
  1034. if (index == i - css.ChildList[0].startNum)
  1035. {
  1036. return string.Format(fomart, item.MissCssName, attr, itemValue);
  1037. }
  1038. }
  1039. }
  1040. }
  1041. }
  1042. }
  1043. break;
  1044. case 12: //大乐透
  1045. if (css != null) //有样式
  1046. {
  1047. if (css.ChildList == null) //没有子样式
  1048. {
  1049. if (isValue) //项值
  1050. {
  1051. return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1052. }
  1053. else //遗漏
  1054. {
  1055. return string.Format(fomart, css.MissCssName, attr, itemValue);
  1056. }
  1057. }
  1058. else //有子样式
  1059. {
  1060. foreach (var item in css.ChildList)
  1061. {
  1062. for (int i = item.endNum; i >= item.startNum; i--)
  1063. {
  1064. if (isValue)
  1065. {
  1066. if (index == i - css.ChildList[0].startNum)
  1067. {
  1068. if (list.Contains(itemValue.ToInt() - 1) || list.Contains(itemValue.ToInt() + 1)) //是连号用扩展样式1
  1069. {
  1070. return string.Format(fomart, item.Extend1, attr, itemValue);
  1071. }
  1072. return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1073. }
  1074. }
  1075. else
  1076. {
  1077. if (index == i - css.ChildList[0].startNum)
  1078. {
  1079. return string.Format(fomart, item.MissCssName, attr, itemValue);
  1080. }
  1081. }
  1082. }
  1083. }
  1084. }
  1085. }
  1086. break;
  1087. }
  1088. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  1089. }
  1090. /// <summary>
  1091. /// 多值多列开奖号码
  1092. /// </summary>
  1093. /// <param name="isValue"></param>
  1094. /// <param name="fomart"></param>
  1095. /// <param name="attr"></param>
  1096. /// <param name="css"></param>
  1097. /// <param name="itemValue"></param>
  1098. /// <param name="index"></param>
  1099. /// <returns></returns>
  1100. public static string MultiValue_OpenCodeItem<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  1101. {
  1102. IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1103. IDictionary<int, int> d = new Dictionary<int, int>();
  1104. //根据Cid判断_彩种
  1105. switch (ItemConfig.Cid)
  1106. {
  1107. case 1: //福彩3D
  1108. case 2: //体彩P3
  1109. case 88: //江苏快3 djp 2016-06-16 新增组三样式形态
  1110. case 86: //安徽快3
  1111. case 87: //湖北快3 暂未开奖2016-06-16
  1112. case 89: //吉林快3
  1113. case 96: //河北快3
  1114. case 97: //内蒙古快3
  1115. foreach (var item in list)
  1116. {
  1117. if (!d.ContainsKey(item))
  1118. d.Add(item, 0);
  1119. d[item]++;
  1120. }
  1121. foreach (var item in d.Keys)
  1122. {
  1123. if (2 == d[item])
  1124. {
  1125. if (item.ToString() == itemValue)
  1126. {
  1127. return GetCssValueExtend1(isValue, fomart, attr, css, itemValue, index);
  1128. }
  1129. }
  1130. if (3 == d[item])
  1131. {
  1132. return GetCssValueExtend2(isValue, fomart, attr, css, itemValue, index);
  1133. }
  1134. }
  1135. break;
  1136. case 5: //七乐彩
  1137. case 60: //福建31选7
  1138. case 61: //福建36选7
  1139. case 65: //华东15选5
  1140. case 68: //新疆35选7
  1141. case 69: //南粤36选7
  1142. if (list[list.Count - 1].ToString() == itemValue)
  1143. {
  1144. return GetCssValueExtend1(isValue, fomart, attr, css, itemValue, index);
  1145. }
  1146. break;
  1147. case 19: //七星彩
  1148. foreach (var item in list)
  1149. {
  1150. if (!d.ContainsKey(item))
  1151. d.Add(item, 0);
  1152. d[item]++;
  1153. }
  1154. foreach (var item in d.Keys)
  1155. {
  1156. if (2 <= d[item])
  1157. {
  1158. if (item.ToString() == itemValue)
  1159. {
  1160. return GetCssValueExtend1(isValue, fomart, attr, css, itemValue, index);
  1161. }
  1162. }
  1163. }
  1164. break;
  1165. }
  1166. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  1167. }
  1168. /// <summary>
  1169. /// 多值多列折号
  1170. /// </summary>
  1171. /// <param name="isValue"></param>
  1172. /// <param name="fomart"></param>
  1173. /// <param name="attr"></param>
  1174. /// <param name="css"></param>
  1175. /// <param name="itemValue"></param>
  1176. /// <param name="index"></param>
  1177. /// <returns></returns>
  1178. public static string MultiValue_ZheHaoNumber<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  1179. {
  1180. //IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1181. ////上一期数据 ,下一期数据
  1182. //IList<int> lastOpenCode = null, nextOpenCode = null;
  1183. ////根据Cid判断_彩种
  1184. //switch (ItemConfig.Cid)
  1185. //{
  1186. // case 4: //双色球
  1187. // IList<FCSSQInfo> FCSSQlastList = FCSSQService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  1188. // if (null != FCSSQlastList && FCSSQlastList[0].Term == LocalEntity.Term && FCSSQlastList.Count == 2)
  1189. // {
  1190. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1191. // }
  1192. // IList<FCSSQInfo> FCSSQnextList = FCSSQService.ToListForNextTrend(LocalEntity.Term, null);
  1193. // if (null != FCSSQnextList && FCSSQnextList[0].Term == LocalEntity.Term && FCSSQnextList.Count == 2)//获取后一期开奖数据
  1194. // {
  1195. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1196. // }
  1197. // if (css != null) //有样式
  1198. // {
  1199. // if (css.ChildList == null) //没有子样式
  1200. // {
  1201. // if (isValue) //项值
  1202. // {
  1203. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1204. // }
  1205. // else //遗漏
  1206. // {
  1207. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  1208. // }
  1209. // }
  1210. // else //有子样式
  1211. // {
  1212. // foreach (var item in css.ChildList)
  1213. // {
  1214. // for (int i = item.endNum; i >= item.startNum; i--)
  1215. // {
  1216. // if (isValue)
  1217. // {
  1218. // if (index == i - css.ChildList[0].startNum)
  1219. // {
  1220. // if (null != lastOpenCode && ((lastOpenCode.Contains(itemValue.ToInt() - 1) && list.Contains(itemValue.ToInt() - 1)) || (lastOpenCode.Contains(itemValue.ToInt() - 1) && lastOpenCode.Contains(itemValue.ToInt())) || (lastOpenCode.Contains(itemValue.ToInt()) && lastOpenCode.Contains(itemValue.ToInt() + 1)) || (lastOpenCode.Contains(itemValue.ToInt() + 1) && list.Contains(itemValue.ToInt() + 1)) || (lastOpenCode.Contains(itemValue.ToInt()) && list.Contains(itemValue.ToInt() - 1)) || (lastOpenCode.Contains(itemValue.ToInt()) && list.Contains(itemValue.ToInt() + 1)))) //根据上期开奖号码判断当前是否折号
  1221. // {
  1222. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1223. // }
  1224. // if (null != nextOpenCode && ((nextOpenCode.Contains(itemValue.ToInt() - 1) && list.Contains(itemValue.ToInt() - 1)) || (nextOpenCode.Contains(itemValue.ToInt() - 1) && nextOpenCode.Contains(itemValue.ToInt())) || (nextOpenCode.Contains(itemValue.ToInt()) && nextOpenCode.Contains(itemValue.ToInt() + 1)) || (nextOpenCode.Contains(itemValue.ToInt() + 1) && list.Contains(itemValue.ToInt() + 1)) || (nextOpenCode.Contains(itemValue.ToInt()) && list.Contains(itemValue.ToInt() - 1)) || (nextOpenCode.Contains(itemValue.ToInt()) && list.Contains(itemValue.ToInt() + 1)))) //根据下期开奖号码判断当前是否折号
  1225. // {
  1226. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1227. // }
  1228. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1229. // }
  1230. // }
  1231. // else
  1232. // {
  1233. // if (index == i - css.ChildList[0].startNum)
  1234. // {
  1235. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  1236. // }
  1237. // }
  1238. // }
  1239. // }
  1240. // }
  1241. // }
  1242. // break;
  1243. // case 12: //大乐透
  1244. // IList<TCDLTInfo> TCDLTlastList = TCDLTService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  1245. // if (null != TCDLTlastList && TCDLTlastList[0].Term == LocalEntity.Term && TCDLTlastList.Count == 2)
  1246. // {
  1247. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1248. // }
  1249. // IList<TCDLTInfo> TCDLTnextList = TCDLTService.ToListForNextTrend(LocalEntity.Term, null);
  1250. // if (null != TCDLTnextList && TCDLTnextList[0].Term == LocalEntity.Term && TCDLTnextList.Count == 2)//获取后一期开奖数据
  1251. // {
  1252. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1253. // }
  1254. // if (css != null) //有样式
  1255. // {
  1256. // if (css.ChildList == null) //没有子样式
  1257. // {
  1258. // if (isValue) //项值
  1259. // {
  1260. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1261. // }
  1262. // else //遗漏
  1263. // {
  1264. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  1265. // }
  1266. // }
  1267. // else //有子样式
  1268. // {
  1269. // foreach (var item in css.ChildList)
  1270. // {
  1271. // for (int i = item.endNum; i >= item.startNum; i--)
  1272. // {
  1273. // if (isValue)
  1274. // {
  1275. // if (index == i - css.ChildList[0].startNum)
  1276. // {
  1277. // if (null != lastOpenCode && ((lastOpenCode.Contains(itemValue.ToInt() - 1) && list.Contains(itemValue.ToInt() - 1)) || (lastOpenCode.Contains(itemValue.ToInt() - 1) && lastOpenCode.Contains(itemValue.ToInt())) || (lastOpenCode.Contains(itemValue.ToInt()) && lastOpenCode.Contains(itemValue.ToInt() + 1)) || (lastOpenCode.Contains(itemValue.ToInt() + 1) && list.Contains(itemValue.ToInt() + 1)) || (lastOpenCode.Contains(itemValue.ToInt()) && list.Contains(itemValue.ToInt() - 1)) || (lastOpenCode.Contains(itemValue.ToInt()) && list.Contains(itemValue.ToInt() + 1)))) //根据上期开奖号码判断当前是否折号
  1278. // {
  1279. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1280. // }
  1281. // if (null != nextOpenCode && ((nextOpenCode.Contains(itemValue.ToInt() - 1) && list.Contains(itemValue.ToInt() - 1)) || (nextOpenCode.Contains(itemValue.ToInt() - 1) && nextOpenCode.Contains(itemValue.ToInt())) || (nextOpenCode.Contains(itemValue.ToInt()) && nextOpenCode.Contains(itemValue.ToInt() + 1)) || (nextOpenCode.Contains(itemValue.ToInt() + 1) && list.Contains(itemValue.ToInt() + 1)) || (nextOpenCode.Contains(itemValue.ToInt()) && list.Contains(itemValue.ToInt() - 1)) || (nextOpenCode.Contains(itemValue.ToInt()) && list.Contains(itemValue.ToInt() + 1)))) //根据下期开奖号码判断当前是否折号
  1282. // {
  1283. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1284. // }
  1285. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1286. // }
  1287. // }
  1288. // else
  1289. // {
  1290. // if (index == i - css.ChildList[0].startNum)
  1291. // {
  1292. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  1293. // }
  1294. // }
  1295. // }
  1296. // }
  1297. // }
  1298. // }
  1299. // break;
  1300. //}
  1301. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  1302. }
  1303. /// <summary>
  1304. /// 多值多列斜连号分布
  1305. /// </summary>
  1306. /// <param name="isValue"></param>
  1307. /// <param name="fomart"></param>
  1308. /// <param name="attr"></param>
  1309. /// <param name="css"></param>
  1310. /// <param name="itemValue"></param>
  1311. /// <param name="index"></param>
  1312. /// <returns></returns>
  1313. public static string MultiValue_XieLianHaoNumber<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  1314. {
  1315. //IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1316. ////上一期数据 ,下一期数据
  1317. //IList<int> lastOpenCode = null, nextOpenCode = null;
  1318. ////根据Cid判断_彩种
  1319. //switch (ItemConfig.Cid)
  1320. //{
  1321. // case 4: //双色球
  1322. // IList<FCSSQInfo> FCSSQlastList = FCSSQService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  1323. // if (null != FCSSQlastList && FCSSQlastList[0].Term == LocalEntity.Term && FCSSQlastList.Count == 2)
  1324. // {
  1325. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1326. // }
  1327. // IList<FCSSQInfo> FCSSQnextList = FCSSQService.ToListForNextTrend(LocalEntity.Term, null);
  1328. // if (null != FCSSQnextList && FCSSQnextList[0].Term == LocalEntity.Term && FCSSQnextList.Count == 2)//获取后一期开奖数据
  1329. // {
  1330. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1331. // }
  1332. // if (css != null) //有样式
  1333. // {
  1334. // if (css.ChildList == null) //没有子样式
  1335. // {
  1336. // if (isValue) //项值
  1337. // {
  1338. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1339. // }
  1340. // else //遗漏
  1341. // {
  1342. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  1343. // }
  1344. // }
  1345. // else //有子样式
  1346. // {
  1347. // foreach (var item in css.ChildList)
  1348. // {
  1349. // for (int i = item.endNum; i >= item.startNum; i--)
  1350. // {
  1351. // if (isValue)
  1352. // {
  1353. // if (index == i - css.ChildList[0].startNum)
  1354. // {
  1355. // if (null != lastOpenCode && (lastOpenCode.Contains(itemValue.ToInt() - 1) || lastOpenCode.Contains(itemValue.ToInt() + 1))) //根据上期开奖号码判断当前是否斜连号
  1356. // {
  1357. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1358. // }
  1359. // if (null != nextOpenCode && (nextOpenCode.Contains(itemValue.ToInt() - 1) || nextOpenCode.Contains(itemValue.ToInt() + 1))) //根据下期开奖号码判断当前是否斜连号
  1360. // {
  1361. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1362. // }
  1363. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1364. // }
  1365. // }
  1366. // else
  1367. // {
  1368. // if (index == i - css.ChildList[0].startNum)
  1369. // {
  1370. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  1371. // }
  1372. // }
  1373. // }
  1374. // }
  1375. // }
  1376. // }
  1377. // break;
  1378. // case 12: //大乐透
  1379. // IList<TCDLTInfo> TCDLTlastList = TCDLTService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  1380. // if (null != TCDLTlastList && TCDLTlastList[0].Term == LocalEntity.Term && TCDLTlastList.Count == 2)
  1381. // {
  1382. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1383. // }
  1384. // IList<TCDLTInfo> TCDLTnextList = TCDLTService.ToListForNextTrend(LocalEntity.Term, null);
  1385. // if (null != TCDLTnextList && TCDLTnextList[0].Term == LocalEntity.Term && TCDLTnextList.Count == 2)//获取后一期开奖数据
  1386. // {
  1387. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1388. // }
  1389. // if (css != null) //有样式
  1390. // {
  1391. // if (css.ChildList == null) //没有子样式
  1392. // {
  1393. // if (isValue) //项值
  1394. // {
  1395. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1396. // }
  1397. // else //遗漏
  1398. // {
  1399. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  1400. // }
  1401. // }
  1402. // else //有子样式
  1403. // {
  1404. // foreach (var item in css.ChildList)
  1405. // {
  1406. // for (int i = item.endNum; i >= item.startNum; i--)
  1407. // {
  1408. // if (isValue)
  1409. // {
  1410. // if (index == i - css.ChildList[0].startNum)
  1411. // {
  1412. // if (null != lastOpenCode && (lastOpenCode.Contains(itemValue.ToInt() - 1) || lastOpenCode.Contains(itemValue.ToInt() + 1))) //根据上期开奖号码判断当前是否斜连号
  1413. // {
  1414. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1415. // }
  1416. // if (null != nextOpenCode && (nextOpenCode.Contains(itemValue.ToInt() - 1) || nextOpenCode.Contains(itemValue.ToInt() + 1))) //根据下期开奖号码判断当前是否斜连号
  1417. // {
  1418. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1419. // }
  1420. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1421. // }
  1422. // }
  1423. // else
  1424. // {
  1425. // if (index == i - css.ChildList[0].startNum)
  1426. // {
  1427. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  1428. // }
  1429. // }
  1430. // }
  1431. // }
  1432. // }
  1433. // }
  1434. // break;
  1435. //}
  1436. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  1437. }
  1438. /// <summary>
  1439. /// 多值多列跳号
  1440. /// </summary>
  1441. /// <param name="isValue"></param>
  1442. /// <param name="fomart"></param>
  1443. /// <param name="attr"></param>
  1444. /// <param name="css"></param>
  1445. /// <param name="itemValue"></param>
  1446. /// <param name="index"></param>
  1447. /// <returns></returns>
  1448. public static string MultiValue_XieTiaoHaoNumber<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  1449. {
  1450. //IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1451. ////上一期数据 ,下一期数据
  1452. //IList<int> lastOpenCode = null, nextOpenCode = null, lastlastOpenCode = null, nextnextOpenCode = null; ;
  1453. ////根据Cid判断_彩种
  1454. //switch (ItemConfig.Cid)
  1455. //{
  1456. // case 4: //双色球
  1457. // IList<FCSSQInfo> FCSSQlastList = FCSSQService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  1458. // if (null != FCSSQlastList && FCSSQlastList[0].Term == LocalEntity.Term && FCSSQlastList.Count == 2)
  1459. // {
  1460. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1461. // IList<FCSSQInfo> FCSSQlastlastList = FCSSQService.ToListForTrend(FCSSQlastList[1].Term, null);//获取前一期开奖数据
  1462. // if (null != FCSSQlastlastList && FCSSQlastlastList[0].Term == FCSSQlastList[1].Term && FCSSQlastlastList.Count == 2)
  1463. // {
  1464. // lastlastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQlastlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1465. // }
  1466. // }
  1467. // IList<FCSSQInfo> FCSSQnextList = FCSSQService.ToListForNextTrend(LocalEntity.Term, null);
  1468. // if (null != FCSSQnextList && FCSSQnextList[0].Term == LocalEntity.Term && FCSSQnextList.Count == 2)//获取后一期开奖数据
  1469. // {
  1470. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1471. // IList<FCSSQInfo> FCSSQnextnextList = FCSSQService.ToListForNextTrend(FCSSQnextList[1].Term, null);//获取前一期开奖数据
  1472. // if (null != FCSSQnextnextList && FCSSQnextnextList[0].Term == FCSSQnextList[1].Term && FCSSQnextnextList.Count == 2)
  1473. // {
  1474. // nextnextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQnextnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1475. // }
  1476. // }
  1477. // if (css != null) //有样式
  1478. // {
  1479. // if (css.ChildList == null) //没有子样式
  1480. // {
  1481. // if (isValue) //项值
  1482. // {
  1483. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1484. // }
  1485. // else //遗漏
  1486. // {
  1487. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  1488. // }
  1489. // }
  1490. // else //有子样式
  1491. // {
  1492. // foreach (var item in css.ChildList)
  1493. // {
  1494. // for (int i = item.endNum; i >= item.startNum; i--)
  1495. // {
  1496. // if (isValue)
  1497. // {
  1498. // if (index == i - css.ChildList[0].startNum)
  1499. // {
  1500. // if (null != lastlastOpenCode && (lastlastOpenCode.Contains(itemValue.ToInt() + 2) || lastlastOpenCode.Contains(itemValue.ToInt() - 2)))
  1501. // //根据上上期开奖号码判断当前是否为斜跳号
  1502. // {
  1503. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1504. // }
  1505. // if (null != nextnextOpenCode && (nextnextOpenCode.Contains(itemValue.ToInt() + 2) || nextnextOpenCode.Contains(itemValue.ToInt() - 2)))
  1506. // //根据下下期开奖号码判断当前是否为斜跳号
  1507. // {
  1508. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1509. // }
  1510. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1511. // }
  1512. // }
  1513. // else
  1514. // {
  1515. // if (index == i - css.ChildList[0].startNum)
  1516. // {
  1517. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  1518. // }
  1519. // }
  1520. // }
  1521. // }
  1522. // }
  1523. // }
  1524. // break;
  1525. // case 12: //大乐透
  1526. // IList<TCDLTInfo> TCDLTlastList = TCDLTService.ToListForTrend(LocalEntity.Term, null); //获取前一期开奖数据
  1527. // if (null != TCDLTlastList && TCDLTlastList[0].Term == LocalEntity.Term && TCDLTlastList.Count == 2)
  1528. // {
  1529. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTlastList[1] as TEntity,
  1530. // ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1531. // IList<TCDLTInfo> TCDLTlastlastList = TCDLTService.ToListForTrend(TCDLTlastList[1].Term, null);
  1532. // //获取前一期开奖数据
  1533. // if (null != TCDLTlastlastList && TCDLTlastlastList[0].Term == TCDLTlastList[1].Term &&
  1534. // TCDLTlastlastList.Count == 2)
  1535. // {
  1536. // lastlastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTlastlastList[1] as TEntity,
  1537. // ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1538. // }
  1539. // }
  1540. // IList<TCDLTInfo> TCDLTnextList = TCDLTService.ToListForNextTrend(LocalEntity.Term, null);
  1541. // if (null != TCDLTnextList && TCDLTnextList[0].Term == LocalEntity.Term && TCDLTnextList.Count == 2)
  1542. // //获取后一期开奖数据
  1543. // {
  1544. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTnextList[1] as TEntity,
  1545. // ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1546. // IList<TCDLTInfo> TCDLTnextnextList = TCDLTService.ToListForNextTrend(TCDLTnextList[1].Term, null);
  1547. // //获取前一期开奖数据
  1548. // if (null != TCDLTnextnextList && TCDLTnextnextList[0].Term == TCDLTnextList[1].Term &&
  1549. // TCDLTnextnextList.Count == 2)
  1550. // {
  1551. // nextnextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTnextnextList[1] as TEntity,
  1552. // ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1553. // }
  1554. // }
  1555. // if (css != null) //有样式
  1556. // {
  1557. // if (css.ChildList == null) //没有子样式
  1558. // {
  1559. // if (isValue) //项值
  1560. // {
  1561. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1562. // }
  1563. // else //遗漏
  1564. // {
  1565. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  1566. // }
  1567. // }
  1568. // else //有子样式
  1569. // {
  1570. // foreach (var item in css.ChildList)
  1571. // {
  1572. // for (int i = item.endNum; i >= item.startNum; i--)
  1573. // {
  1574. // if (isValue)
  1575. // {
  1576. // if (index == i - css.ChildList[0].startNum)
  1577. // {
  1578. // if (null != lastlastOpenCode && (lastlastOpenCode.Contains(itemValue.ToInt() + 2) || lastlastOpenCode.Contains(itemValue.ToInt() - 2)))
  1579. // //根据上上期开奖号码判断当前是否为斜跳号
  1580. // {
  1581. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1582. // }
  1583. // if (null != nextnextOpenCode && (nextnextOpenCode.Contains(itemValue.ToInt() + 2) || nextnextOpenCode.Contains(itemValue.ToInt() - 2)))
  1584. // //根据下下期开奖号码判断当前是否为斜跳号
  1585. // {
  1586. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1587. // }
  1588. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1589. // }
  1590. // }
  1591. // else
  1592. // {
  1593. // if (index == i - css.ChildList[0].startNum)
  1594. // {
  1595. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  1596. // }
  1597. // }
  1598. // }
  1599. // }
  1600. // }
  1601. // }
  1602. // break;
  1603. //}
  1604. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  1605. }
  1606. /// <summary>
  1607. /// 多值多列竖三连号
  1608. /// </summary>
  1609. /// <param name="isValue"></param>
  1610. /// <param name="fomart"></param>
  1611. /// <param name="attr"></param>
  1612. /// <param name="css"></param>
  1613. /// <param name="itemValue"></param>
  1614. /// <param name="index"></param>
  1615. /// <returns></returns>
  1616. public static string MultiValue_ShuSanLianHaoNumber<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  1617. {
  1618. //IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1619. ////上一期数据 ,下一期数据
  1620. //IList<int> lastOpenCode = null, nextOpenCode = null, lastlastOpenCode = null, nextnextOpenCode = null; ;
  1621. ////根据Cid判断_彩种
  1622. //switch (ItemConfig.Cid)
  1623. //{
  1624. // case 4: //双色球
  1625. // IList<FCSSQInfo> FCSSQlastList = FCSSQService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  1626. // if (null != FCSSQlastList && FCSSQlastList[0].Term == LocalEntity.Term && FCSSQlastList.Count == 2)
  1627. // {
  1628. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1629. // IList<FCSSQInfo> FCSSQlastlastList = FCSSQService.ToListForTrend(FCSSQlastList[1].Term, null);//获取前一期开奖数据
  1630. // if (null != FCSSQlastlastList && FCSSQlastlastList[0].Term == FCSSQlastList[1].Term && FCSSQlastlastList.Count == 2)
  1631. // {
  1632. // lastlastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQlastlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1633. // }
  1634. // }
  1635. // IList<FCSSQInfo> FCSSQnextList = FCSSQService.ToListForNextTrend(LocalEntity.Term, null);
  1636. // if (null != FCSSQnextList && FCSSQnextList[0].Term == LocalEntity.Term && FCSSQnextList.Count == 2)//获取后一期开奖数据
  1637. // {
  1638. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1639. // IList<FCSSQInfo> FCSSQnextnextList = FCSSQService.ToListForNextTrend(FCSSQnextList[1].Term, null);//获取前一期开奖数据
  1640. // if (null != FCSSQnextnextList && FCSSQnextnextList[0].Term == FCSSQnextList[1].Term && FCSSQnextnextList.Count == 2)
  1641. // {
  1642. // nextnextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(FCSSQnextnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1643. // }
  1644. // }
  1645. // if (css != null) //有样式
  1646. // {
  1647. // if (css.ChildList == null) //没有子样式
  1648. // {
  1649. // if (isValue) //项值
  1650. // {
  1651. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1652. // }
  1653. // else //遗漏
  1654. // {
  1655. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  1656. // }
  1657. // }
  1658. // else //有子样式
  1659. // {
  1660. // foreach (var item in css.ChildList)
  1661. // {
  1662. // for (int i = item.endNum; i >= item.startNum; i--)
  1663. // {
  1664. // if (isValue)
  1665. // {
  1666. // if (index == i - css.ChildList[0].startNum)
  1667. // {
  1668. // if (null != lastOpenCode && null != nextOpenCode &&
  1669. // lastOpenCode.Contains(itemValue.ToInt()) &&
  1670. // nextOpenCode.Contains(itemValue.ToInt())) //根据上下期开奖号码判断当前是否为竖三连号
  1671. // {
  1672. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1673. // }
  1674. // if (null != lastlastOpenCode && null != lastOpenCode && lastOpenCode.Contains(itemValue.ToInt()) && lastlastOpenCode.Contains(itemValue.ToInt())) //根据上期和上上期开奖号码判断当前是否为竖三连号
  1675. // {
  1676. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1677. // }
  1678. // if (null != nextnextOpenCode && null != nextOpenCode && nextOpenCode.Contains(itemValue.ToInt()) && nextnextOpenCode.Contains(itemValue.ToInt())) //根据下期和下下期开奖号码判断当前是否为竖三连号
  1679. // {
  1680. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1681. // }
  1682. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1683. // }
  1684. // }
  1685. // else
  1686. // {
  1687. // if (index == i - css.ChildList[0].startNum)
  1688. // {
  1689. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  1690. // }
  1691. // }
  1692. // }
  1693. // }
  1694. // }
  1695. // }
  1696. // break;
  1697. //}
  1698. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  1699. }
  1700. /// <summary>
  1701. /// 多值多列竖跳号
  1702. /// </summary>
  1703. /// <param name="isValue"></param>
  1704. /// <param name="fomart"></param>
  1705. /// <param name="attr"></param>
  1706. /// <param name="css"></param>
  1707. /// <param name="itemValue"></param>
  1708. /// <param name="index"></param>
  1709. /// <returns></returns>
  1710. public static string MultiValue_ShuTiaoHaoNumber<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  1711. {
  1712. //IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1713. ////上一期数据 ,下一期数据
  1714. //IList<int> lastOpenCode = null, nextOpenCode = null, lastlastOpenCode = null, nextnextOpenCode = null; ;
  1715. ////根据Cid判断_彩种
  1716. //switch (ItemConfig.Cid)
  1717. //{
  1718. // case 12: //大乐透
  1719. // IList<TCDLTInfo> TCDLTlastList = TCDLTService.ToListForTrend(LocalEntity.Term, null);//获取前一期开奖数据
  1720. // if (null != TCDLTlastList && TCDLTlastList[0].Term == LocalEntity.Term && TCDLTlastList.Count == 2)
  1721. // {
  1722. // lastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1723. // IList<TCDLTInfo> TCDLTlastlastList = TCDLTService.ToListForTrend(TCDLTlastList[1].Term, null);//获取前一期开奖数据
  1724. // if (null != TCDLTlastlastList && TCDLTlastlastList[0].Term == TCDLTlastList[1].Term && TCDLTlastlastList.Count == 2)
  1725. // {
  1726. // lastlastOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTlastlastList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1727. // }
  1728. // }
  1729. // IList<TCDLTInfo> TCDLTnextList = TCDLTService.ToListForNextTrend(LocalEntity.Term, null);
  1730. // if (null != TCDLTnextList && TCDLTnextList[0].Term == LocalEntity.Term && TCDLTnextList.Count == 2)//获取后一期开奖数据
  1731. // {
  1732. // nextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1733. // IList<TCDLTInfo> TCDLTnextnextList = TCDLTService.ToListForNextTrend(TCDLTnextList[1].Term, null);//获取前一期开奖数据
  1734. // if (null != TCDLTnextnextList && TCDLTnextnextList[0].Term == TCDLTnextList[1].Term && TCDLTnextnextList.Count == 2)
  1735. // {
  1736. // nextnextOpenCode = LotteryUtils.GetOpenCodeList<TEntity>(TCDLTnextnextList[1] as TEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1737. // }
  1738. // }
  1739. // if (css != null) //有样式
  1740. // {
  1741. // if (css.ChildList == null) //没有子样式
  1742. // {
  1743. // if (isValue) //项值
  1744. // {
  1745. // return string.Format(fomart, css.NumberCssName, attr, itemValue);
  1746. // }
  1747. // else //遗漏
  1748. // {
  1749. // return string.Format(fomart, css.MissCssName, attr, itemValue);
  1750. // }
  1751. // }
  1752. // else //有子样式
  1753. // {
  1754. // foreach (var item in css.ChildList)
  1755. // {
  1756. // for (int i = item.endNum; i >= item.startNum; i--)
  1757. // {
  1758. // if (isValue)
  1759. // {
  1760. // if (index == i - css.ChildList[0].startNum)
  1761. // {
  1762. // if (null != lastlastOpenCode && lastlastOpenCode.Contains(itemValue.ToInt())) //根据上上期开奖号码判断当前是否为竖跳号
  1763. // {
  1764. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1765. // }
  1766. // if (null != nextnextOpenCode && nextnextOpenCode.Contains(itemValue.ToInt())) //根据下下期开奖号码判断当前是否为竖跳号
  1767. // {
  1768. // return string.Format(fomart, item.Extend1, attr, itemValue);
  1769. // }
  1770. // return string.Format(fomart, item.NumberCssName, attr, itemValue);
  1771. // }
  1772. // }
  1773. // else
  1774. // {
  1775. // if (index == i - css.ChildList[0].startNum)
  1776. // {
  1777. // return string.Format(fomart, item.MissCssName, attr, itemValue);
  1778. // }
  1779. // }
  1780. // }
  1781. // }
  1782. // }
  1783. // }
  1784. // break;
  1785. //}
  1786. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  1787. }
  1788. #endregion
  1789. #region 特殊
  1790. /// <summary>
  1791. /// 福彩3D 012路走势图4
  1792. /// </summary>
  1793. /// <typeparam name="TEntity"></typeparam>
  1794. /// <param name="LocalEntity"></param>
  1795. /// <param name="ItemConfig"></param>
  1796. /// <param name="isValue"></param>
  1797. /// <param name="fomart"></param>
  1798. /// <param name="attr"></param>
  1799. /// <param name="css"></param>
  1800. /// <param name="itemValue"></param>
  1801. /// <param name="index"></param>
  1802. /// <returns></returns>
  1803. public static string SpecialValue_FC3D012_4<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  1804. {
  1805. StringBuilder table = new StringBuilder(1000);
  1806. IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1807. table.Append("<table id=\"zstable\" class=\"zstable\">");
  1808. table.Append("<tbody>");
  1809. table.Append("<tr>");
  1810. for (int i = 0; i < 10; i = i + 3)
  1811. {
  1812. if (list.Count(s => s == i) == 3)
  1813. {
  1814. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend2, i));
  1815. table.Append("</td>");
  1816. }
  1817. if (list.Count(s => s == i) == 2)
  1818. {
  1819. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend1, i));
  1820. table.Append("</td>");
  1821. }
  1822. if (list.Count(s => s == i) == 1)
  1823. {
  1824. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.NumberCssName, i));
  1825. table.Append("</td>");
  1826. }
  1827. if (list.Count(s => s == i) == 0)
  1828. {
  1829. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, i));
  1830. table.Append("</td>");
  1831. }
  1832. }
  1833. table.Append("</tr>");
  1834. table.Append("<tr>");
  1835. for (int i = 1; i < 10; i = i + 3)
  1836. {
  1837. if (list.Count(s => s == i) == 3)
  1838. {
  1839. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend2, i));
  1840. table.Append("</td>");
  1841. }
  1842. if (list.Count(s => s == i) == 2)
  1843. {
  1844. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend1, i));
  1845. table.Append("</td>");
  1846. }
  1847. if (list.Count(s => s == i) == 1)
  1848. {
  1849. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.NumberCssName, i));
  1850. table.Append("</td>");
  1851. }
  1852. if (list.Count(s => s == i) == 0)
  1853. {
  1854. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, i));
  1855. table.Append("</td>");
  1856. }
  1857. }
  1858. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, ""));
  1859. table.Append("</td>");
  1860. table.Append("</tr>");
  1861. table.Append("<tr>");
  1862. for (int i = 2; i < 10; i = i + 3)
  1863. {
  1864. if (list.Count(s => s == i) == 3)
  1865. {
  1866. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend2, i));
  1867. table.Append("</td>");
  1868. }
  1869. if (list.Count(s => s == i) == 2)
  1870. {
  1871. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend1, i));
  1872. table.Append("</td>");
  1873. }
  1874. if (list.Count(s => s == i) == 1)
  1875. {
  1876. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.NumberCssName, i));
  1877. table.Append("</td>");
  1878. }
  1879. if (list.Count(s => s == i) == 0)
  1880. {
  1881. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, i));
  1882. table.Append("</td>");
  1883. }
  1884. }
  1885. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, ""));
  1886. table.Append("</td>");
  1887. table.Append("</tr>");
  1888. table.Append("<tr>");
  1889. table.Append(string.Format("<td colspan=\"4\" class=\"{0}\">{1}", css.MissCssName, LocalEntity.Term.ToString() + " 期"));
  1890. table.Append("</td>");
  1891. table.Append("</tr>");
  1892. table.Append("</tbody>");
  1893. table.Append("</table>");
  1894. return string.Format(fomart, "", attr, table.ToString());
  1895. }
  1896. /// <summary>
  1897. /// 体彩P3 012路走势图4
  1898. /// </summary>
  1899. /// <typeparam name="TEntity"></typeparam>
  1900. /// <param name="LocalEntity"></param>
  1901. /// <param name="ItemConfig"></param>
  1902. /// <param name="isValue"></param>
  1903. /// <param name="fomart"></param>
  1904. /// <param name="attr"></param>
  1905. /// <param name="css"></param>
  1906. /// <param name="itemValue"></param>
  1907. /// <param name="index"></param>
  1908. /// <returns></returns>
  1909. public static string SpecialValue_TCP3012_4<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  1910. {
  1911. StringBuilder table = new StringBuilder(1000);
  1912. IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  1913. table.Append("<table id=\"zstable\" class=\"zstable\">");
  1914. table.Append("<tbody>");
  1915. table.Append("<tr>");
  1916. for (int i = 0; i < 10; i = i + 3)
  1917. {
  1918. if (list.Count(s => s == i) == 3)
  1919. {
  1920. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend2, i));
  1921. table.Append("</td>");
  1922. }
  1923. if (list.Count(s => s == i) == 2)
  1924. {
  1925. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend1, i));
  1926. table.Append("</td>");
  1927. }
  1928. if (list.Count(s => s == i) == 1)
  1929. {
  1930. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.NumberCssName, i));
  1931. table.Append("</td>");
  1932. }
  1933. if (list.Count(s => s == i) == 0)
  1934. {
  1935. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, i));
  1936. table.Append("</td>");
  1937. }
  1938. }
  1939. table.Append("</tr>");
  1940. table.Append("<tr>");
  1941. for (int i = 1; i < 10; i = i + 3)
  1942. {
  1943. if (list.Count(s => s == i) == 3)
  1944. {
  1945. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend2, i));
  1946. table.Append("</td>");
  1947. }
  1948. if (list.Count(s => s == i) == 2)
  1949. {
  1950. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend1, i));
  1951. table.Append("</td>");
  1952. }
  1953. if (list.Count(s => s == i) == 1)
  1954. {
  1955. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.NumberCssName, i));
  1956. table.Append("</td>");
  1957. }
  1958. if (list.Count(s => s == i) == 0)
  1959. {
  1960. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, i));
  1961. table.Append("</td>");
  1962. }
  1963. }
  1964. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, ""));
  1965. table.Append("</td>");
  1966. table.Append("</tr>");
  1967. table.Append("<tr>");
  1968. for (int i = 2; i < 10; i = i + 3)
  1969. {
  1970. if (list.Count(s => s == i) == 3)
  1971. {
  1972. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend2, i));
  1973. table.Append("</td>");
  1974. }
  1975. if (list.Count(s => s == i) == 2)
  1976. {
  1977. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.Extend1, i));
  1978. table.Append("</td>");
  1979. }
  1980. if (list.Count(s => s == i) == 1)
  1981. {
  1982. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.NumberCssName, i));
  1983. table.Append("</td>");
  1984. }
  1985. if (list.Count(s => s == i) == 0)
  1986. {
  1987. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, i));
  1988. table.Append("</td>");
  1989. }
  1990. }
  1991. table.Append(string.Format("<td width=\"48px\" class=\"{0}\">{1}", css.MissCssName, ""));
  1992. table.Append("</td>");
  1993. table.Append("</tr>");
  1994. table.Append("<tr>");
  1995. table.Append(string.Format("<td colspan=\"4\" class=\"{0}\">{1}", css.MissCssName, LocalEntity.Term.ToString() + " 期"));
  1996. table.Append("</td>");
  1997. table.Append("</tr>");
  1998. table.Append("</tbody>");
  1999. table.Append("</table>");
  2000. return string.Format(fomart, "", attr, table.ToString());
  2001. }
  2002. /// <summary>
  2003. /// 福彩 双色球出号频率
  2004. /// </summary>
  2005. /// <typeparam name="TEntity"></typeparam>
  2006. /// <param name="LocalEntity"></param>
  2007. /// <param name="ItemConfig"></param>
  2008. /// <param name="isValue"></param>
  2009. /// <param name="fomart"></param>
  2010. /// <param name="attr"></param>
  2011. /// <param name="css"></param>
  2012. /// <param name="itemValue"></param>
  2013. /// <param name="index"></param>
  2014. /// <returns></returns>
  2015. public static string SpecialValue_FCSSQ_ChuHaoPL<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, ChartCssConfigInfo css, int[] ItemIndex, string fomart) where TEntity : LotteryOpenCode
  2016. {
  2017. StringBuilder sp = new StringBuilder();
  2018. if (ItemConfig.ItemCount == 33) //红球
  2019. {
  2020. sp.Append("<tr>");
  2021. sp.Append("<td class=\"white pl\">150</td>");
  2022. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2023. {
  2024. sp.Append(string.Format("<td rowspan=\"16\" style=\"vertical-align: bottom;\" class=\"{0} \">", GetCssName(true, css, i)));
  2025. sp.Append(string.Format("<span>{0}</span><br>", ItemConfig.ItemString[i]));
  2026. sp.Append(string.Format("<img src=\"http://www.55128.cn/images/zst/redline.gif\" style=\"vertical-align: bottom;\" width=\"8\" height=\"{0}\">", (3 * ItemIndex[i]).ToString()));
  2027. sp.Append("</td>");
  2028. }
  2029. sp.Append("@Row1");
  2030. sp.Append("<tr><td class=\"pl\">140</td></tr><tr><td class=\"pl\">130</td></tr><tr><td class=\"pl\">120</td></tr><tr><td class=\"pl\">110</td></tr><tr><td class=\"pl\">100</td></tr><tr><td class=\"pl\">90</td></tr><tr><td class=\"pl\">80</td></tr><tr><td class=\"pl\">70</td></tr><tr><td class=\"pl\">60</td></tr><tr><td class=\"pl\">50</td></tr><tr><td class=\"pl\">40</td></tr><tr><td class=\"pl\">30</td></tr><tr><td class=\"pl\">20</td></tr><tr><td class=\"pl\">10</td></tr><tr><td class=\"pl\">0</td></tr>");
  2031. sp.Append("<tr>");
  2032. sp.Append("<td class=\"white\">出现次数</td>");
  2033. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2034. {
  2035. sp.Append(GetCssValue(true, fomart, "", css, ItemIndex[i].ToString(), i));
  2036. }
  2037. sp.Append("@Row2");
  2038. sp.Append("<tr>");
  2039. sp.Append("<td class=\"white\">出现频率(%)</td>");
  2040. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2041. {
  2042. sp.Append(GetCssValue(true, fomart, "", css, string.Format("{0:F1}", (double)ItemIndex[i] * 100 / ItemIndex.Sum()), i));
  2043. }
  2044. sp.Append("@Row3");
  2045. }
  2046. if (ItemConfig.ItemCount == 16) //蓝球
  2047. {
  2048. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2049. {
  2050. sp.Append(string.Format("<td rowspan=\"16\" style=\"vertical-align: bottom;\" class=\"{0}\">", GetCssName(true, css, i)));
  2051. sp.Append(string.Format("<span>{0}</span><br>", ItemConfig.ItemString[i]));
  2052. sp.Append(string.Format("<img src=\"http://www.55128.cn/images/zst/blueline.gif\" style=\"vertical-align: bottom;\" width=\"8\" height=\"{0}\">", (3 * ItemIndex[i]).ToString()));
  2053. sp.Append("</td>");
  2054. }
  2055. sp.Append("</tr>");
  2056. sp.Append("~");
  2057. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2058. {
  2059. sp.Append(GetCssValue(true, fomart, "", css, ItemIndex[i].ToString(), i));
  2060. }
  2061. sp.Append("</tr>");
  2062. sp.Append("~");
  2063. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2064. {
  2065. sp.Append(GetCssValue(true, fomart, "", css, string.Format("{0:F1}", (double)ItemIndex[i] * 100 / ItemIndex.Sum()), i));
  2066. }
  2067. sp.Append("</tr>");
  2068. }
  2069. return sp.ToString();
  2070. }
  2071. /// <summary>
  2072. /// 体彩 大乐透出号频率
  2073. /// </summary>
  2074. /// <typeparam name="TEntity"></typeparam>
  2075. /// <param name="LocalEntity"></param>
  2076. /// <param name="ItemConfig"></param>
  2077. /// <param name="isValue"></param>
  2078. /// <param name="fomart"></param>
  2079. /// <param name="attr"></param>
  2080. /// <param name="css"></param>
  2081. /// <param name="itemValue"></param>
  2082. /// <param name="index"></param>
  2083. /// <returns></returns>
  2084. public static string SpecialValue_TCDLT_ChuHaoPL<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, ChartCssConfigInfo css, int[] ItemIndex, string fomart) where TEntity : LotteryOpenCode
  2085. {
  2086. StringBuilder sp = new StringBuilder();
  2087. if (ItemConfig.ItemCount == 35) //红球
  2088. {
  2089. sp.Append("<tr>");
  2090. sp.Append("<td class=\"white pl\">150</td>");
  2091. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2092. {
  2093. sp.Append(string.Format("<td rowspan=\"16\" style=\"vertical-align: bottom;\" class=\"{0} \">", GetCssName(true, css, i)));
  2094. sp.Append(string.Format("<span>{0}</span><br>", ItemConfig.ItemString[i]));
  2095. sp.Append(string.Format("<img src=\"http://www.55128.cn/images/zst/redline.gif\" style=\"vertical-align: bottom;\" width=\"8\" height=\"{0}\">", (3 * ItemIndex[i]).ToString()));
  2096. sp.Append("</td>");
  2097. }
  2098. sp.Append("@Row1");
  2099. sp.Append("<tr><td class=\"pl\">140</td></tr><tr><td class=\"pl\">130</td></tr><tr><td class=\"pl\">120</td></tr><tr><td class=\"pl\">110</td></tr><tr><td class=\"pl\">100</td></tr><tr><td class=\"pl\">90</td></tr><tr><td class=\"pl\">80</td></tr><tr><td class=\"pl\">70</td></tr><tr><td class=\"pl\">60</td></tr><tr><td class=\"pl\">50</td></tr><tr><td class=\"pl\">40</td></tr><tr><td class=\"pl\">30</td></tr><tr><td class=\"pl\">20</td></tr><tr><td class=\"pl\">10</td></tr><tr><td class=\"pl\">0</td></tr>");
  2100. sp.Append("<tr>");
  2101. sp.Append("<td class=\"white\">出现次数</td>");
  2102. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2103. {
  2104. sp.Append(GetCssValue(true, fomart, "", css, ItemIndex[i].ToString(), i));
  2105. }
  2106. sp.Append("@Row2");
  2107. sp.Append("<tr>");
  2108. sp.Append("<td class=\"white\">出现频率(%)</td>");
  2109. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2110. {
  2111. sp.Append(GetCssValue(true, fomart, "", css, string.Format("{0:F1}", (double)ItemIndex[i] * 100 / ItemIndex.Sum()), i));
  2112. }
  2113. sp.Append("@Row3");
  2114. }
  2115. if (ItemConfig.ItemCount == 12) //蓝球
  2116. {
  2117. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2118. {
  2119. sp.Append(string.Format("<td rowspan=\"16\" style=\"vertical-align: bottom;\" class=\"{0}\">", GetCssName(true, css, i)));
  2120. sp.Append(string.Format("<span>{0}</span><br>", ItemConfig.ItemString[i]));
  2121. sp.Append(string.Format("<img src=\"http://www.55128.cn/images/zst/blueline.gif\" style=\"vertical-align: bottom;\" width=\"8\" height=\"{0}\">", (3 * ItemIndex[i]).ToString()));
  2122. sp.Append("</td>");
  2123. }
  2124. sp.Append("</tr>");
  2125. sp.Append("~");
  2126. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2127. {
  2128. sp.Append(GetCssValue(true, fomart, "", css, ItemIndex[i].ToString(), i));
  2129. }
  2130. sp.Append("</tr>");
  2131. sp.Append("~");
  2132. for (int i = 0; i < ItemConfig.ItemCount; i++)
  2133. {
  2134. sp.Append(GetCssValue(true, fomart, "", css, string.Format("{0:F1}", (double)ItemIndex[i] * 100 / ItemIndex.Sum()), i));
  2135. }
  2136. sp.Append("</tr>");
  2137. }
  2138. return sp.ToString();
  2139. }
  2140. #endregion
  2141. #region 高频
  2142. /// <summary>
  2143. /// 多值多列快乐12开奖号码分布
  2144. /// </summary>
  2145. /// <param name="isValue"></param>
  2146. /// <param name="fomart"></param>
  2147. /// <param name="attr"></param>
  2148. /// <param name="css"></param>
  2149. /// <param name="itemValue"></param>
  2150. /// <param name="index"></param>
  2151. /// <returns></returns>
  2152. public static string MultiValue_KL12<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2153. {
  2154. IList<int> list = LotteryUtils.GetOpenCodeList<TEntity>(LocalEntity, ItemConfig.IndexStart, ItemConfig.IndexEnd);
  2155. //根据Cid判断_彩种
  2156. switch (ItemConfig.Cid)
  2157. {
  2158. case 5000: //快乐12
  2159. if (list[0].ToString() == itemValue)
  2160. {
  2161. return GetCssValueExtend1(isValue, fomart, attr, css, itemValue, index);
  2162. }
  2163. else
  2164. {
  2165. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2166. }
  2167. }
  2168. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2169. }
  2170. #endregion
  2171. /// <summary>
  2172. /// 获取应该调用哪个CSS名称
  2173. /// </summary>
  2174. /// <param name="isValue"></param>
  2175. /// <param name="fomart"></param>
  2176. /// <param name="attr"></param>
  2177. /// <param name="css"></param>
  2178. /// <param name="itemValue"></param>
  2179. /// <param name="index"></param>
  2180. /// <returns></returns>
  2181. public static string GetCssName(bool isValue, ChartCssConfigInfo css, int index)
  2182. {
  2183. if (css != null) //有样式
  2184. {
  2185. if (css.ChildList == null)//没有子样式
  2186. {
  2187. if (isValue) //项值
  2188. {
  2189. return css.NumberCssName;
  2190. }
  2191. else //遗漏
  2192. {
  2193. return css.MissCssName;
  2194. }
  2195. }
  2196. else //有子样式
  2197. {
  2198. foreach (var item in css.ChildList)
  2199. {
  2200. for (int i = item.endNum; i >= item.startNum; i--)
  2201. {
  2202. if (isValue)
  2203. {
  2204. if (index == i - css.ChildList[0].startNum)
  2205. {
  2206. return item.NumberCssName;
  2207. }
  2208. }
  2209. else
  2210. {
  2211. if (index == i - css.ChildList[0].startNum)
  2212. {
  2213. return item.MissCssName;
  2214. }
  2215. }
  2216. }
  2217. }
  2218. }
  2219. }
  2220. return ""; //没有样式(填充默认颜色)
  2221. }
  2222. /// <summary>
  2223. /// 设置样式通用方法
  2224. /// </summary>
  2225. /// <param name="isValue"></param>
  2226. /// <param name="fomart"></param>
  2227. /// <param name="attr"></param>
  2228. /// <param name="css"></param>
  2229. /// <param name="itemValue"></param>
  2230. /// <param name="index"></param>
  2231. /// <returns></returns>
  2232. public static string GetCssValue(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  2233. {
  2234. if (css != null) //有样式
  2235. {
  2236. if (css.ChildList == null)//没有子样式
  2237. {
  2238. if (isValue) //项值
  2239. {
  2240. return string.Format(fomart, css.NumberCssName, attr, itemValue);
  2241. }
  2242. else //遗漏
  2243. {
  2244. return string.Format(fomart, css.MissCssName, attr, itemValue);
  2245. }
  2246. }
  2247. else //有子样式
  2248. {
  2249. foreach (var item in css.ChildList)
  2250. {
  2251. for (int i = item.endNum; i >= item.startNum; i--)
  2252. {
  2253. if (isValue)
  2254. {
  2255. if (index == i - css.ChildList[0].startNum)
  2256. {
  2257. return string.Format(fomart, item.NumberCssName, attr, itemValue);
  2258. }
  2259. }
  2260. else
  2261. {
  2262. if (index == i - css.ChildList[0].startNum)
  2263. {
  2264. return string.Format(fomart, item.MissCssName, attr, itemValue);
  2265. }
  2266. }
  2267. }
  2268. }
  2269. }
  2270. }
  2271. return string.Format(fomart, "", attr, itemValue); //没有样式(填充默认颜色)
  2272. }
  2273. /// <summary>
  2274. /// 设置样式通用方法(使用扩展样式1)
  2275. /// </summary>
  2276. /// <param name="isValue"></param>
  2277. /// <param name="fomart"></param>
  2278. /// <param name="attr"></param>
  2279. /// <param name="css"></param>
  2280. /// <param name="itemValue"></param>
  2281. /// <param name="index"></param>
  2282. /// <returns></returns>
  2283. private static string GetCssValueExtend1(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  2284. {
  2285. if (css != null) //有样式
  2286. {
  2287. if (css.ChildList == null)//没有子样式
  2288. {
  2289. if (isValue) //项值
  2290. {
  2291. return string.Format(fomart, css.Extend1, attr, itemValue);
  2292. }
  2293. else //遗漏
  2294. {
  2295. return string.Format(fomart, css.MissCssName, attr, itemValue);
  2296. }
  2297. }
  2298. else //有子样式
  2299. {
  2300. foreach (var item in css.ChildList)
  2301. {
  2302. for (int i = item.endNum; i >= item.startNum; i--)
  2303. {
  2304. if (isValue)
  2305. {
  2306. if (index == i - css.ChildList[0].startNum)
  2307. {
  2308. return string.Format(fomart, item.Extend1, attr, itemValue);
  2309. }
  2310. }
  2311. else //遗漏
  2312. {
  2313. if (index == i - css.ChildList[0].startNum)
  2314. {
  2315. return string.Format(fomart, item.MissCssName, attr, itemValue);
  2316. }
  2317. }
  2318. }
  2319. }
  2320. }
  2321. }
  2322. return string.Format(fomart, "", attr, itemValue); //没有样式(填充默认颜色)
  2323. }
  2324. /// <summary>
  2325. /// 设置样式通用方法(使用扩展样式2)
  2326. /// </summary>
  2327. /// <param name="isValue"></param>
  2328. /// <param name="fomart"></param>
  2329. /// <param name="attr"></param>
  2330. /// <param name="css"></param>
  2331. /// <param name="itemValue"></param>
  2332. /// <param name="index"></param>
  2333. /// <returns></returns>
  2334. private static string GetCssValueExtend2(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  2335. {
  2336. if (css != null) //有样式
  2337. {
  2338. if (css.ChildList == null)//没有子样式
  2339. {
  2340. if (isValue) //项值
  2341. {
  2342. return string.Format(fomart, css.Extend2, attr, itemValue);
  2343. }
  2344. else //遗漏
  2345. {
  2346. return string.Format(fomart, css.MissCssName, attr, itemValue);
  2347. }
  2348. }
  2349. else //有子样式
  2350. {
  2351. foreach (var item in css.ChildList)
  2352. {
  2353. for (int i = item.endNum; i >= item.startNum; i--)
  2354. {
  2355. if (isValue)
  2356. {
  2357. if (index == i - css.ChildList[0].startNum)
  2358. {
  2359. return string.Format(fomart, item.Extend2, attr, itemValue);
  2360. }
  2361. }
  2362. else //遗漏
  2363. {
  2364. if (index == i - css.ChildList[0].startNum)
  2365. {
  2366. return string.Format(fomart, item.MissCssName, attr, itemValue);
  2367. }
  2368. }
  2369. }
  2370. }
  2371. }
  2372. }
  2373. return string.Format(fomart, "", attr, itemValue); //没有样式(填充默认颜色)
  2374. }
  2375. /// <summary>
  2376. /// 设置样式通用方法(使用扩展样式3)
  2377. /// </summary>
  2378. /// <param name="isValue"></param>
  2379. /// <param name="fomart"></param>
  2380. /// <param name="attr"></param>
  2381. /// <param name="css"></param>
  2382. /// <param name="itemValue"></param>
  2383. /// <param name="index"></param>
  2384. /// <returns></returns>
  2385. private static string GetCssValueExtend3(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  2386. {
  2387. if (css != null) //有样式
  2388. {
  2389. if (css.ChildList == null)//没有子样式
  2390. {
  2391. if (isValue) //项值
  2392. {
  2393. return string.Format(fomart, css.Extend3, attr, itemValue);
  2394. }
  2395. else //遗漏
  2396. {
  2397. return string.Format(fomart, css.MissCssName, attr, itemValue);
  2398. }
  2399. }
  2400. else //有子样式
  2401. {
  2402. foreach (var item in css.ChildList)
  2403. {
  2404. for (int i = item.endNum; i >= item.startNum; i--)
  2405. {
  2406. if (isValue)
  2407. {
  2408. if (index == i - css.ChildList[0].startNum)
  2409. {
  2410. return string.Format(fomart, item.Extend3, attr, itemValue);
  2411. }
  2412. }
  2413. else //遗漏
  2414. {
  2415. if (index == i - css.ChildList[0].startNum)
  2416. {
  2417. return string.Format(fomart, item.MissCssName, attr, itemValue);
  2418. }
  2419. }
  2420. }
  2421. }
  2422. }
  2423. }
  2424. return string.Format(fomart, "", attr, itemValue); //没有样式(填充默认颜色)
  2425. }
  2426. /// <summary>
  2427. /// 设置样式通用方法(使用扩展样式2)
  2428. /// </summary>
  2429. /// <param name="isValue"></param>
  2430. /// <param name="fomart"></param>
  2431. /// <param name="attr"></param>
  2432. /// <param name="css"></param>
  2433. /// <param name="itemValue"></param>
  2434. /// <param name="index"></param>
  2435. /// <returns></returns>
  2436. private static string GetCssValueExtend4(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  2437. {
  2438. if (css != null) //有样式
  2439. {
  2440. if (css.ChildList == null)//没有子样式
  2441. {
  2442. if (isValue) //项值
  2443. {
  2444. return string.Format(fomart, css.Extend4, attr, itemValue);
  2445. }
  2446. else //遗漏
  2447. {
  2448. return string.Format(fomart, css.MissCssName, attr, itemValue);
  2449. }
  2450. }
  2451. else //有子样式
  2452. {
  2453. foreach (var item in css.ChildList)
  2454. {
  2455. for (int i = item.endNum; i >= item.startNum; i--)
  2456. {
  2457. if (isValue)
  2458. {
  2459. if (index == i - css.ChildList[0].startNum)
  2460. {
  2461. return string.Format(fomart, item.Extend4, attr, itemValue);
  2462. }
  2463. }
  2464. else //遗漏
  2465. {
  2466. if (index == i - css.ChildList[0].startNum)
  2467. {
  2468. return string.Format(fomart, item.MissCssName, attr, itemValue);
  2469. }
  2470. }
  2471. }
  2472. }
  2473. }
  2474. }
  2475. return string.Format(fomart, "", attr, itemValue); //没有样式(填充默认颜色)
  2476. }
  2477. /// <summary>
  2478. /// 设置样式通用方法(使用扩展样式2)
  2479. /// </summary>
  2480. /// <param name="isValue"></param>
  2481. /// <param name="fomart"></param>
  2482. /// <param name="attr"></param>
  2483. /// <param name="css"></param>
  2484. /// <param name="itemValue"></param>
  2485. /// <param name="index"></param>
  2486. /// <returns></returns>
  2487. private static string GetCssValueExtend5(bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index)
  2488. {
  2489. if (css != null) //有样式
  2490. {
  2491. if (css.ChildList == null)//没有子样式
  2492. {
  2493. if (isValue) //项值
  2494. {
  2495. return string.Format(fomart, css.Extend5, attr, itemValue);
  2496. }
  2497. else //遗漏
  2498. {
  2499. return string.Format(fomart, css.MissCssName, attr, itemValue);
  2500. }
  2501. }
  2502. else //有子样式
  2503. {
  2504. foreach (var item in css.ChildList)
  2505. {
  2506. for (int i = item.endNum; i >= item.startNum; i--)
  2507. {
  2508. if (isValue)
  2509. {
  2510. if (index == i - css.ChildList[0].startNum)
  2511. {
  2512. return string.Format(fomart, item.Extend5, attr, itemValue);
  2513. }
  2514. }
  2515. else //遗漏
  2516. {
  2517. if (index == i - css.ChildList[0].startNum)
  2518. {
  2519. return string.Format(fomart, item.MissCssName, attr, itemValue);
  2520. }
  2521. }
  2522. }
  2523. }
  2524. }
  2525. }
  2526. return string.Format(fomart, "", attr, itemValue); //没有样式(填充默认颜色)
  2527. }
  2528. /// <summary>
  2529. /// 回摆
  2530. /// </summary>
  2531. /// <typeparam name="TEntity"></typeparam>
  2532. /// <param name="LocalEntity"></param>
  2533. /// <param name="ItemConfig"></param>
  2534. /// <param name="isValue"></param>
  2535. /// <param name="fomart"></param>
  2536. /// <param name="attr"></param>
  2537. /// <param name="css"></param>
  2538. /// <param name="itemValue"></param>
  2539. /// <param name="index"></param>
  2540. /// <returns></returns>
  2541. public static string SingleValue_HB<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2542. {
  2543. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2544. }
  2545. /// <summary>
  2546. /// 振幅
  2547. /// </summary>
  2548. /// <param name="isValue"></param>
  2549. /// <param name="fomart"></param>
  2550. /// <param name="attr"></param>
  2551. /// <param name="chartCssConfigInfo"></param>
  2552. /// <param name="itemValue"></param>
  2553. /// <param name="index"></param>
  2554. /// <returns></returns>
  2555. public static string SingleCell_ZF(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2556. {
  2557. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2558. }
  2559. /// <summary>
  2560. /// 福建31选7三区比
  2561. /// </summary>
  2562. /// <typeparam name="TEntity"></typeparam>
  2563. /// <param name="LocalEntity"></param>
  2564. /// <param name="isValue"></param>
  2565. /// <param name="fomart"></param>
  2566. /// <param name="attr"></param>
  2567. /// <param name="css"></param>
  2568. /// <param name="itemValue"></param>
  2569. /// <param name="index"></param>
  2570. /// <returns></returns>
  2571. public static string SingleCell_FJ31X7SanQu<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2572. {
  2573. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2574. }
  2575. /// <summary>
  2576. /// 福建31选7三区比
  2577. /// </summary>
  2578. /// <typeparam name="TEntity"></typeparam>
  2579. /// <param name="LocalEntity"></param>
  2580. /// <param name="isValue"></param>
  2581. /// <param name="fomart"></param>
  2582. /// <param name="attr"></param>
  2583. /// <param name="css"></param>
  2584. /// <param name="itemValue"></param>
  2585. /// <param name="index"></param>
  2586. /// <returns></returns>
  2587. public static string SingleCell_FJ36X7SanQu<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2588. {
  2589. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2590. }
  2591. /// <summary>
  2592. /// 和尾大小
  2593. /// </summary>
  2594. /// <typeparam name="TEntity"></typeparam>
  2595. /// <param name="LocalEntity"></param>
  2596. /// <param name="isValue"></param>
  2597. /// <param name="fomart"></param>
  2598. /// <param name="attr"></param>
  2599. /// <param name="css"></param>
  2600. /// <param name="itemValue"></param>
  2601. /// <param name="index"></param>
  2602. /// <returns></returns>
  2603. public static string SingleValue_HeWeiDx<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2604. {
  2605. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2606. }
  2607. /// <summary>
  2608. /// 生肖
  2609. /// </summary>
  2610. /// <typeparam name="TEntity"></typeparam>
  2611. /// <param name="LocalEntity"></param>
  2612. /// <param name="isValue"></param>
  2613. /// <param name="fomart"></param>
  2614. /// <param name="attr"></param>
  2615. /// <param name="css"></param>
  2616. /// <param name="itemValue"></param>
  2617. /// <param name="index"></param>
  2618. /// <returns></returns>
  2619. public static string SingleValue_ShengXiao(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2620. {
  2621. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2622. }
  2623. /// <summary>
  2624. /// 华东15选5三区比
  2625. /// </summary>
  2626. /// <typeparam name="TEntity"></typeparam>
  2627. /// <param name="LocalEntity"></param>
  2628. /// <param name="isValue"></param>
  2629. /// <param name="fomart"></param>
  2630. /// <param name="attr"></param>
  2631. /// <param name="css"></param>
  2632. /// <param name="itemValue"></param>
  2633. /// <param name="index"></param>
  2634. /// <returns></returns>
  2635. public static string SingleCell_HD15X5SanQu<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2636. {
  2637. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2638. }
  2639. /// <summary>
  2640. /// 华东15选5一区个数
  2641. /// </summary>
  2642. /// <param name="isValue"></param>
  2643. /// <param name="fomart"></param>
  2644. /// <param name="attr"></param>
  2645. /// <param name="chartCssConfigInfo"></param>
  2646. /// <param name="itemValue"></param>
  2647. /// <param name="index"></param>
  2648. /// <returns></returns>
  2649. public static string SingleValue_Hd11x5Yq(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2650. {
  2651. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2652. }
  2653. /// <summary>
  2654. /// 华东15选5二区个数
  2655. /// </summary>
  2656. /// <param name="isValue"></param>
  2657. /// <param name="fomart"></param>
  2658. /// <param name="attr"></param>
  2659. /// <param name="chartCssConfigInfo"></param>
  2660. /// <param name="itemValue"></param>
  2661. /// <param name="index"></param>
  2662. /// <returns></returns>
  2663. public static string SingleValue_Hd11x5Eq(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2664. {
  2665. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2666. }
  2667. /// <summary>
  2668. /// 华东15选5三区个数
  2669. /// </summary>
  2670. /// <param name="isValue"></param>
  2671. /// <param name="fomart"></param>
  2672. /// <param name="attr"></param>
  2673. /// <param name="chartCssConfigInfo"></param>
  2674. /// <param name="itemValue"></param>
  2675. /// <param name="index"></param>
  2676. /// <returns></returns>
  2677. public static string SingleValue_Hd11x5Sq(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2678. {
  2679. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2680. }
  2681. /// <summary>
  2682. /// 南粤36选7三区比
  2683. /// </summary>
  2684. /// <typeparam name="TEntity"></typeparam>
  2685. /// <param name="LocalEntity"></param>
  2686. /// <param name="isValue"></param>
  2687. /// <param name="fomart"></param>
  2688. /// <param name="attr"></param>
  2689. /// <param name="css"></param>
  2690. /// <param name="itemValue"></param>
  2691. /// <param name="index"></param>
  2692. /// <returns></returns>
  2693. public static string SingleCell_NY36x7SanQu<TEntity>(TEntity LocalEntity, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2694. {
  2695. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2696. }
  2697. /// <summary>
  2698. /// 和值012路
  2699. /// </summary>
  2700. /// <param name="isValue"></param>
  2701. /// <param name="fomart"></param>
  2702. /// <param name="attr"></param>
  2703. /// <param name="chartCssConfigInfo"></param>
  2704. /// <param name="itemValue"></param>
  2705. /// <param name="index"></param>
  2706. /// <returns></returns>
  2707. public static string SingleCell_Hz012(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2708. {
  2709. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2710. }
  2711. /// <summary>
  2712. /// 快3三不同走势
  2713. /// </summary>
  2714. /// <param name="isValue"></param>
  2715. /// <param name="fomart"></param>
  2716. /// <param name="attr"></param>
  2717. /// <param name="chartCssConfigInfo"></param>
  2718. /// <param name="itemValue"></param>
  2719. /// <param name="index"></param>
  2720. /// <returns></returns>
  2721. public static string SingleCell_K3sbt(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2722. {
  2723. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2724. }
  2725. /// <summary>
  2726. /// 快三二不同走势
  2727. /// </summary>
  2728. /// <typeparam name="TEntity"></typeparam>
  2729. /// <param name="LocalEntity"></param>
  2730. /// <param name="ItemConfig"></param>
  2731. /// <param name="isValue"></param>
  2732. /// <param name="fomart"></param>
  2733. /// <param name="attr"></param>
  2734. /// <param name="css"></param>
  2735. /// <param name="itemValue"></param>
  2736. /// <param name="index"></param>
  2737. /// <returns></returns>
  2738. public static string SetK3ebtItemValue<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2739. {
  2740. return GetCssValueExtend1(isValue, fomart, attr, css, itemValue, index);
  2741. }
  2742. /// <summary>
  2743. /// 快3二不同走势
  2744. /// </summary>
  2745. /// <param name="isValue"></param>
  2746. /// <param name="fomart"></param>
  2747. /// <param name="attr"></param>
  2748. /// <param name="chartCssConfigInfo"></param>
  2749. /// <param name="itemValue"></param>
  2750. /// <param name="index"></param>
  2751. /// <returns></returns>
  2752. public static string SingleCell_K3ebt(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2753. {
  2754. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2755. }
  2756. public static string SingleValue_JoValue(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2757. {
  2758. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2759. }
  2760. public static string SingleValue_DxValue(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2761. {
  2762. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2763. }
  2764. public static string SingleValue_ZhValue(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2765. {
  2766. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2767. }
  2768. public static string SetSbtxtItemValue<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2769. {
  2770. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2771. }
  2772. public static string SetEbtxtItemValue<TEntity>(TEntity LocalEntity, TrendChartItemInfo ItemConfig, bool isValue, string fomart, string attr, ChartCssConfigInfo css, string itemValue, int index) where TEntity : LotteryOpenCode
  2773. {
  2774. return GetCssValue(isValue, fomart, attr, css, itemValue, index);
  2775. }
  2776. public static string SingleValue_DxJoValue(bool isValue, string fomart, string attr, ChartCssConfigInfo chartCssConfigInfo, string itemValue, int index)
  2777. {
  2778. return GetCssValue(isValue, fomart, attr, chartCssConfigInfo, itemValue, index);
  2779. }
  2780. }
  2781. }