index2.js 74 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412
  1. let barImg =
  2. 'data:image/png;base64,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'
  3. let app = new Vue({
  4. el: '#app',
  5. data () {
  6. return {
  7. touch: true,
  8. timeCommon: '',
  9. echartC1:{
  10. national:'',
  11. province:''
  12. },
  13. echartC2:{
  14. national:'',
  15. province:''
  16. },
  17. titleName: '',
  18. access_token: '',
  19. orgNumber: '', // 上级的id
  20. twinkle7: [],
  21. twinkle8: [],
  22. twinkleR6: [],
  23. showTip: false,
  24. tipNum: '',
  25. time: '',
  26. year: '2022',
  27. config1: {
  28. number: [100],
  29. content: '{nt}个',
  30. },
  31. centerData: '',
  32. storageRecordConfig: {
  33. header: ['', '公司名称', '工作情况'],
  34. headerBGC: '#05507b33',
  35. oddRowBGC: '#69c0ff0f',
  36. evenRowBGC: '',
  37. headerHeight: '50',
  38. rowNum: 4,
  39. align: ['center', 'center', 'center', 'center'],
  40. data: [],
  41. },
  42. storageRecordConfig2: {
  43. header: ['', '预警内容', '累计未获取数据日期'],
  44. headerBGC: '#05507b33',
  45. oddRowBGC: '#05507b33',
  46. evenRowBGC: '',
  47. headerHeight: '50',
  48. rowNum: 4,
  49. align: ['center', 'center', 'center', 'center'],
  50. data: [],
  51. },
  52. companyList: companyList,
  53. companyListTitle: companyListTitle,
  54. commonOption:[]
  55. }
  56. },
  57. beforeMount () {
  58. },
  59. mounted () {
  60. this.getUrlParams()
  61. this.time = formatDate()
  62. this.timer = setInterval(() => {
  63. this.time = formatDate()
  64. }, 1000)
  65. this.centerData = data
  66. },
  67. beforeDestroy () {
  68. clearInterval(this.timer);
  69. clearInterval(this.timeCommon);
  70. },
  71. methods: {
  72. judgeCarousel () {
  73. let that = this
  74. let a = {
  75. title: {
  76. text: 'xxx',
  77. x: 'center',
  78. y: '3%',
  79. textStyle: {
  80. color: '#69C0FF',
  81. fontSize: 24,
  82. },
  83. },
  84. tooltip: {
  85. trigger: 'axis',
  86. axisPointer: {
  87. type: 'shadow',
  88. },
  89. },
  90. grid: {
  91. top: '22%',
  92. right: '5%',
  93. left: '8%',
  94. bottom: '25%',
  95. },
  96. legend: {
  97. data: '',
  98. top: '12%',
  99. right: '5%',
  100. textStyle: {
  101. color: 'rgba(250,250,250,0.6)',
  102. fontSize: 16,
  103. },
  104. },
  105. xAxis: {
  106. // data: companyList.map(item => item.name),
  107. data: '',
  108. axisLine: {
  109. show: true, //隐藏X轴轴线
  110. lineStyle: {
  111. color: '#005094',
  112. width: 1,
  113. },
  114. },
  115. axisTick: {
  116. show: false, //隐藏X轴刻度
  117. },
  118. axisLabel: {
  119. show: true,
  120. rotate: 15,
  121. textStyle: {
  122. color: 'rgba(255,255,255,0.6)', //X轴文字颜色
  123. fontSize: 16,
  124. },
  125. },
  126. },
  127. yAxis: [
  128. {
  129. type: 'value',
  130. nameTextStyle: {
  131. color: '#ebf8ac',
  132. fontSize: 16,
  133. },
  134. splitLine: {
  135. show: true,
  136. lineStyle: {
  137. color: '#68b4dd66',
  138. type: 'dashed',
  139. },
  140. },
  141. axisLine: {
  142. show: false,
  143. },
  144. axisLabel: {
  145. show: true,
  146. textStyle: {
  147. color: 'rgba(250,250,250,0.6)',
  148. fontSize: 16,
  149. },
  150. },
  151. },
  152. ],
  153. }
  154. a.xAxis.data = this.companyList.map(item => item.name)
  155. if (this.companyList.length > 18) {
  156. a.dataZoom = [
  157. {
  158. // start: 9,//默认为@
  159. // end: 100,//黑认认为1@0
  160. type: "slider",
  161. show: false,
  162. // xAxisIndex: [0]
  163. handlesize: 0,//滑动条的 左右2个滑动条的大小
  164. startValue: 17,// 初始显示值
  165. endValue: 0,// 结束显示值
  166. height: 10,//组件高度
  167. left: "5%",
  168. right: "4%",//右边的距离
  169. bottom: "25%",//底边的距离
  170. borderColor: "#939",
  171. fillerColor: "#269cdb",
  172. borderRadius: 5,
  173. backgroundColor: "#33384b",//两边未选中的滑动条区域的额色
  174. showDataShadow: false,//是否显示数据阴影
  175. showDetail: false,//即拖拽时候是否显示详细数值信息
  176. truerealtime: true,//是否实时更新
  177. filterMode: "filter"
  178. }, {
  179. type: 'inside',
  180. show: true,
  181. start: 1,
  182. end: 100
  183. }
  184. ]
  185. }
  186. this.commonOption = a
  187. this.getData()
  188. },
  189. // 生成图表
  190. generateEcharts () {
  191. this.initChartL1()
  192. // this.initChartL2()
  193. this.initChartL3()
  194. // this.initChartL4()
  195. // this.initChartL5()
  196. this.initChartL6()
  197. // this.initChartL7()
  198. // this.initChartL8()
  199. // 中间图表
  200. this.initChartC1()
  201. this.initChartC2()
  202. // 右侧图表
  203. // this.initChartR1()
  204. // this.initChartR2()
  205. // this.initChartR3()
  206. this.initChartR4()
  207. this.initChartR5()
  208. // this.initChartR6()
  209. this.initChartR7()
  210. // this.initChartR8()
  211. },
  212. getData () {
  213. let that = this
  214. return new Promise((resolve, err) => {
  215. let value = {
  216. access_token: this.access_token,
  217. "Data": {
  218. "paramType": "DATA",
  219. "orgNumber": this.orgNumber
  220. }
  221. }
  222. post('/ierp/kapi/v2/mdnb/mdnb_das/Data/CockpitScreen', value).then(res => {
  223. res.orgData = res.data[0]
  224. // 定机构
  225. // 弹窗
  226. // return
  227. // 左侧图表
  228. tipData.analysis[0] = res.orgData.area1.intAnalysis.map(item => item.analysis)
  229. //各二级企业本部机构数
  230. dataL1[0] = []
  231. dataL1[1] = []
  232. dataL1[2] = []
  233. res.orgData.area1.card1.forEach(item => {
  234. dataL1[0].push(item['ZBPZ0010'])
  235. dataL1[1].push(item['ZBPZ0088'])
  236. dataL1[2].push(item['ZBPZ0089'])
  237. })
  238. // 各二级企业所属架构数
  239. dataL2[0] = []
  240. res.orgData.area1.card2.forEach(item => {
  241. dataL2[0].push(item['ZBPZ0024'])
  242. })
  243. // 定职数
  244. // 弹窗
  245. // 左侧图表
  246. tipData.analysis[2] = res.orgData.area2.intAnalysis.map(item => item.analysis)
  247. //各二级企业本部中层管理人数
  248. dataL3[0] = []
  249. res.orgData.area2.card1.forEach(item => {
  250. dataL3[0].push(item['ZBPZ0091'])
  251. })
  252. // 各二级企业管理人员数
  253. dataL4[1] = []
  254. dataL4[0] = []
  255. dataL4[2] = []
  256. res.orgData.area2.card1.forEach(item => {
  257. dataL4[1].push(item['ZBPZ0091'])
  258. dataL4[0].push(item['ZBPZ0093'])
  259. dataL4[2].push(item['ZBPZ0092'])
  260. })
  261. // 定员额
  262. // 弹窗
  263. tipData.analysis[1] = res.orgData.area3.intAnalysis.map(item => item.analysis)
  264. // 各二级企业总人数
  265. dataL5[0] = []
  266. dataL5[1] = []
  267. dataL5[2] = []
  268. res.orgData.area3.card1.forEach(item => {
  269. dataL5[0].push(item['ZBPZ0006'])
  270. dataL5[1].push(item['ZBPZ0050'])
  271. dataL5[2].push(item['ZBPZ0051'])
  272. })
  273. // 各二级企业本部员额数
  274. dataL6[0] = []
  275. dataL6[2] = []
  276. dataL6[1] = []
  277. res.orgData.area3.card2.forEach(item => {
  278. dataL6[0].push(item['ZBPZ0031'])
  279. dataL6[2].push(item['ZBPZ0094'])
  280. dataL6[1].push(item['ZBPZ0095'])
  281. })
  282. // 人数变化和全员劳动生产率变化率分析
  283. dataL7[0] = []
  284. dataL7[1] = []
  285. res.orgData.area3.card3.forEach(item => {
  286. dataL7[0].push(item['ZBPZ0050'])
  287. dataL7[1].push(item['ZBPZ0039'])
  288. })
  289. // 人数变化和人工利润率变化分析
  290. dataL8[0] = []
  291. dataL8[1] = []
  292. res.orgData.area3.card4.forEach(item => {
  293. dataL8[0].push(item['ZBPZ0050'])
  294. dataL8[1].push(item['ZBPZ0041'])
  295. })
  296. // 定机制
  297. // 弹窗
  298. tipData.analysis[6] = res.orgData.area4.intAnalysis.map(item => item.analysis)
  299. // 各二级企业招聘需求公告人次情况
  300. dataR1[0] = []
  301. dataR1[1] = []
  302. res.orgData.area4.card1.forEach(item => {
  303. dataR1[0].push(item['ZBPZ0057'])
  304. dataR1[1].push(item['ZBPZ0058'])
  305. })
  306. // 各二级企业录用结果公示人次
  307. dataR2[0] = []
  308. dataR2[1] = []
  309. res.orgData.area4.card2.forEach(item => {
  310. dataR2[0].push(item['ZBPZ0059'])
  311. dataR2[1].push(item['ZBPZ0060'])
  312. })
  313. // 各二级企业年利润与招聘情况分析
  314. dataR3[0] = []
  315. dataR3[1] = []
  316. res.orgData.area4.card3.forEach(item => {
  317. dataR3[0].push(item['ZBPZ0054'])
  318. dataR3[1].push(item['ZBPZ0055'])
  319. })
  320. // 各二级企业"退二进一"完成情况
  321. dataR4[0] = []
  322. dataR4[1] = []
  323. res.orgData.area4.card4.forEach(item => {
  324. dataR4[0].push(item['ZBPZ0056'])
  325. dataR4[1].push(item['ZBPZ0055'])
  326. })
  327. // 定薪酬
  328. // 弹窗
  329. tipData.analysis[5] = res.orgData.area5.intAnalysis.map(item => item.analysis)
  330. // 各二级企业在岗职工平均薪酬
  331. dataR5[0] = []
  332. dataR5[1] = []
  333. res.orgData.area5.card1.forEach(item => {
  334. dataR5[0].push(item['ZBPZ0063'])
  335. dataR5[1].push(item['ZBPZ0064'])
  336. })
  337. // 各二级企业利润与薪酬变动情况
  338. dataR6[0] = []
  339. dataR6[1] = []
  340. res.orgData.area5.card2.forEach(item => {
  341. dataR6[0].push(item['ZBPZ0061'])
  342. dataR6[1].push(item['ZBPZ0062'])
  343. })
  344. // 定任期
  345. // 弹窗
  346. tipData.analysis[6] = res.orgData.area6.intAnalysis.map(item => item.analysis)
  347. // 各二级企业全员绩效考核
  348. dataR7[0] = []
  349. res.orgData.area6.card1.forEach(item => {
  350. dataR7[0].push(item['ZBPZ0066'])
  351. })
  352. // 各二级企业任期制契约化完成率
  353. dataR8[0] = []
  354. res.orgData.area6.card2.forEach(item => {
  355. dataR8[0].push(item['ZBPZ0065'])
  356. })
  357. // 中间
  358. // 架岗人员
  359. this.centerData.info.value1 = res.orgData.area7.ZBPZ0037
  360. this.centerData.info.value2 = res.orgData.area7.ZBPZ0038
  361. this.centerData.info.value3 = res.orgData.area7.ZBPZ0006
  362. // 六定改革成效
  363. this.centerData.changeInfo[0].value1 = res.orgData.area8.ZBPZ0067
  364. this.centerData.changeInfo[0].value2 = res.orgData.area8.ZBPZ0068
  365. this.centerData.changeInfo[0].value3 = res.orgData.area8.ZBPZ0069
  366. this.centerData.changeInfo[2].value1 = res.orgData.area8.ZBPZ0074
  367. this.centerData.changeInfo[2].value2 = res.orgData.area8.ZBPZ0075
  368. this.centerData.changeInfo[2].value3 = res.orgData.area8.ZBPZ0076
  369. this.centerData.changeInfo[1].value1 = res.orgData.area8.ZBPZ0071
  370. this.centerData.changeInfo[1].value2 = res.orgData.area8.ZBPZ0072
  371. this.centerData.changeInfo[1].value3 = res.orgData.area8.ZBPZ0073
  372. // 核心指标监测
  373. // 弹窗
  374. tipData.analysis[3] = res.orgData.area9.intAnalysis.map(item => item.analysis)
  375. // 各二级企业全员劳动生产率
  376. dataC1[0] = []
  377. dataC1[1] = []
  378. res.orgData.area9.card1.forEach(item => {
  379. dataC1[0].push(item['ZBPZ0035'])
  380. dataC1[1].push(item['ZBPZ0039'])
  381. })
  382. // 各二级企业人工成本利润率
  383. dataC2[1] = []
  384. dataC2[0] = []
  385. res.orgData.area9.card2.forEach(item => {
  386. dataC2[1].push(item['ZBPZ0040'])
  387. dataC2[0].push(item['ZBPZ0041'])
  388. })
  389. this.echartC1.national = res.orgData.area9.card1[0].ZBPZ0097
  390. this.echartC1.province = res.orgData.area9.card1[0].ZBPZ0096
  391. this.echartC2.national = res.orgData.area9.card2[0].ZBPZ0099
  392. this.echartC2.province = res.orgData.area9.card2[0].ZBPZ0098
  393. // 分析预警中心
  394. // 工作台分析
  395. this.storageRecordConfig.data = []
  396. res.orgData.area10.card1.forEach(item => {
  397. this.storageRecordConfig.data.push(['<span class="lightOut"><span class="light ' + (item.lightsup === '0' ? 'red' : item.lightsup === '1' ? 'yellow' : 'green') + '"></span></span>', item.enterprise, item.work])
  398. })
  399. this.storageRecordConfig = { ...this.storageRecordConfig }
  400. // 数据库预警
  401. // this.storageRecordConfig2.data = []
  402. // res.orgData.area10.card2.forEach(item => {
  403. // this.storageRecordConfig.data.push(['<span class="lightOut"><span class="light ' + (item.lightsup === '0' ? 'red' : item.lightsup === '1' ? 'yellow' : 'green') + '"></span></span>', item.warning, item.date])
  404. // })
  405. // 数据整理
  406. dataL7[0].forEach((item, index) => {
  407. if (dataL7[1][index] < 0 && dataL7[0][index] > 0) {
  408. let obj = { value: [this.companyList[index].name, dataL7[0][index]], symbolSize: 15 }
  409. this.twinkle7.push(obj)
  410. }
  411. })
  412. // if (dataL8[1][params.dataIndex] < 0 && params.value > 0) {
  413. dataL8[0].forEach((item, index) => {
  414. if (dataL8[1][index] < 0 && dataL8[0][index] > 0) {
  415. let obj = { value: [this.companyList[index].name, dataL8[0][index]], symbolSize: 15 }
  416. this.twinkle8.push(obj)
  417. }
  418. })
  419. // params.value > 0 && fjxdataL2[0][params.dataIndex] < 0
  420. dataR6[0].forEach((item, index) => {
  421. if (dataR6[1][index] > 0 && dataR6[0][index] < 0) {
  422. let obj = { value: [this.companyList[index].name, dataR6[1][index]], symbolSize: 15 }
  423. this.twinkleR6.push(obj)
  424. }
  425. })
  426. this.generateEcharts()
  427. if (this.companyList.length > 18) {
  428. this.timeCommon = setInterval(() => {
  429. if (that.touch) {
  430. if (that.commonOption.dataZoom[0].startValue < that.companyList.length) {
  431. that.commonOption.dataZoom[0].endValue += 18
  432. that.commonOption.dataZoom[0].startValue += 18
  433. } else {
  434. that.commonOption.dataZoom[0].endValue = 0
  435. that.commonOption.dataZoom[0].startValue = 18
  436. }
  437. that.generateEcharts()
  438. }
  439. }, 15000)
  440. }
  441. resolve(1)
  442. })
  443. });
  444. },
  445. // 获取地址栏参数
  446. getUrlParams (id) {
  447. let url = window.location.href
  448. // 通过 ? 分割获取后面的参数字符串
  449. let urlStr = url.split('?')[1]
  450. // 创建空对象存储参数
  451. let obj = {};
  452. // 再通过 & 将每一个参数单独分割出来
  453. let paramsArr = urlStr.split('&')
  454. for (let i = 0, len = paramsArr.length; i < len; i++) {
  455. // 再通过 = 将每一个参数分割为 key:value 的形式
  456. let arr = paramsArr[i].split('=')
  457. obj[arr[0]] = arr[1];
  458. }
  459. this.access_token = obj.access_token
  460. this.orgNumber = obj.id
  461. this.titleName = decodeURIComponent(obj.name)
  462. // Promise.all([this.getData(), this.getInstitutional()])
  463. // .then((arr) => {
  464. // this.generateEcharts()
  465. // })
  466. // .catch((err) => console.log(err));
  467. this.getInstitutional()
  468. },
  469. // 获取组织机构
  470. getInstitutional () {
  471. return new Promise((resolve, err) => {
  472. let value = {
  473. access_token: this.access_token,
  474. "Data": {
  475. "paramType": "ORG",
  476. "orgNumber": this.orgNumber
  477. // "orgNumber": '1494979736584079360'
  478. }
  479. }
  480. post('/ierp/kapi/v2/mdnb/mdnb_das/Data/CockpitScreen', value).then(res => {
  481. this.companyList = res.data.map(item => {
  482. return { name: item.orgName, id: item.orgNumber }
  483. })
  484. this.judgeCarousel()
  485. resolve(1);
  486. })
  487. });
  488. },
  489. handleShowTip (index) {
  490. this.showTip = true
  491. this.tipNum = index
  492. },
  493. handleGoPage (id, name) {
  494. if (name == '山西煤炭运销集团长治有限公司') {
  495. window.location.href = './index3MT.html?id=' + id + `&access_token=${this.access_token}` + `&name=${name}`
  496. }else{
  497. window.location.href = './index3.html?id=' + id + `&access_token=${this.access_token}` + `&name=${name}`
  498. }
  499. },
  500. handleGoBack () {
  501. window.history.go(-1)
  502. },
  503. numFormat (value) {
  504. if (!value) return '0'
  505. // var intPart = Number(value).toFixed(0) // 获取整数部分
  506. var intPart = parseInt(value)// 获取整数部分
  507. var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,') // 将整数部分逢三一断
  508. var floatPart = '.00' // 预定义小数部分
  509. var value2Array = value.toString().split('.')
  510. // =2表示数据有小数位
  511. if (value2Array.length === 2) {
  512. floatPart = value2Array[1].toString() // 拿到小数部分
  513. if (floatPart.length === 1) {
  514. // 补0
  515. return intPartFormat + '.' + floatPart + '0'
  516. } else {
  517. return intPartFormat + '.' + floatPart
  518. }
  519. } else {
  520. return intPartFormat
  521. }
  522. },
  523. initChartL1 () {
  524. let myChart = echarts.init(this.$refs['echartL1'])
  525. let option = {
  526. ..._.cloneDeep(this.commonOption),
  527. color: [
  528. {
  529. x: 0,
  530. y: 0,
  531. x2: 0,
  532. y2: 1,
  533. colorStops: [{
  534. offset: 0,
  535. color: '#5e7ae9',
  536. },
  537. {
  538. offset: 1,
  539. color: '#082550',
  540. },],
  541. }
  542. ],
  543. series: [
  544. {
  545. name: '六个二级企业本部机构数核定上限',
  546. type: 'line',
  547. // yAxisIndex: 1, //使用的 y 轴的 index,在单个图表实例中存在多个 y轴的时候有用
  548. smooth: true, //平滑曲线显示
  549. showAllSymbol: true, //显示所有图形。
  550. symbol: 'circle', //标记的图形为实心圆
  551. symbolSize: 8, //标记的大小
  552. smooth: false,
  553. itemStyle: {
  554. //折线拐点标志的样式
  555. color: '#fbe138',
  556. borderColor: '#fbe138',
  557. width: 2,
  558. shadowColor: '#fbe138',
  559. shadowBlur: 4,
  560. },
  561. lineStyle: {
  562. color: '#fbe138',
  563. width: 2,
  564. },
  565. data: dataL1[2],
  566. },
  567. {
  568. name: '六定改革前各二级企业本部机构数',
  569. type: 'bar',
  570. barWidth: 15,
  571. itemStyle: {
  572. normal: {
  573. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  574. {
  575. offset: 0,
  576. color: '#43ede3',
  577. },
  578. {
  579. offset: 1,
  580. color: '#082550',
  581. },
  582. ]),
  583. },
  584. },
  585. data: dataL1[0],
  586. },
  587. {
  588. name: '当前各二级企业本部机构数',
  589. type: 'bar',
  590. barWidth: 15,
  591. itemStyle: {
  592. normal: {
  593. color: params => {
  594. if (params.value > dataL1[2][params.dataIndex]) {
  595. return 'yellow'
  596. } else {
  597. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  598. {
  599. offset: 0,
  600. color: '#5e7ae9',
  601. },
  602. {
  603. offset: 1,
  604. color: '#082550',
  605. },
  606. ])
  607. }
  608. },
  609. },
  610. },
  611. data: dataL1[1],
  612. },
  613. ],
  614. // tooltip: {
  615. // trigger: 'item',
  616. // position: 'top'
  617. // },
  618. }
  619. option.title.text = '本部机构数'
  620. option.legend.data = ['六定改革前各二级企业本部机构数', '当前各二级企业本部机构数', '六个二级企业本部机构数核定上限']
  621. option.yAxis.push({
  622. splitLine: {
  623. show: false,
  624. },
  625. axisLine: {
  626. show: false,
  627. },
  628. })
  629. myChart.setOption(option)
  630. },
  631. initChartL2 () {
  632. let myChart = echarts.init(this.$refs['echartL2'])
  633. let option = {
  634. ..._.cloneDeep(this.commonOption),
  635. color: [
  636. {
  637. x: 0,
  638. y: 0,
  639. x2: 0,
  640. y2: 1,
  641. colorStops: [{
  642. offset: 0,
  643. color: '#69c0ff',
  644. },
  645. {
  646. offset: 1,
  647. color: '#082550',
  648. },],
  649. }
  650. ],
  651. series: [
  652. {
  653. name: '当前各二级企业所属架构数',
  654. type: 'bar',
  655. barWidth: 15,
  656. itemStyle: {
  657. normal: {
  658. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  659. {
  660. offset: 0,
  661. color: '#69c0ff',
  662. },
  663. {
  664. offset: 1,
  665. color: '#082550',
  666. },
  667. ]),
  668. },
  669. },
  670. data: dataL2[0]
  671. }
  672. ],
  673. }
  674. option.title.text = '各二级企业所属架构数'
  675. option.legend.data = ['当前各二级企业所属架构数']
  676. option.yAxis.push({
  677. splitLine: {
  678. show: false,
  679. },
  680. axisLine: {
  681. show: false,
  682. },
  683. })
  684. myChart.setOption(option)
  685. },
  686. initChartL3 () {
  687. let myChart = echarts.init(this.$refs['echartL3'])
  688. let option = {
  689. ..._.cloneDeep(this.commonOption),
  690. color: [
  691. {
  692. x: 0,
  693. y: 0,
  694. x2: 0,
  695. y2: 1,
  696. colorStops: [{
  697. offset: 0,
  698. color: '#6480f3',
  699. },
  700. {
  701. offset: 1,
  702. color: '#082550',
  703. },],
  704. }
  705. ],
  706. series: [
  707. {
  708. name: '六定改革前各二级中层管理人数',
  709. type: 'bar',
  710. barWidth: 15,
  711. label: {
  712. normal: {
  713. show: true,
  714. position: 'top',
  715. textStyle: {
  716. color: '#69c0ff',
  717. fontStyle: 'normal',
  718. textAlign: 'left',
  719. fontSize: 16,
  720. },
  721. formatter: function (data) {
  722. if (data.name == '云时代') {
  723. return data.value
  724. } else {
  725. return ''
  726. }
  727. }
  728. }
  729. },
  730. itemStyle: {
  731. normal: {
  732. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  733. {
  734. offset: 0,
  735. color: '#6480f3',
  736. },
  737. {
  738. offset: 1,
  739. color: '#082550',
  740. },
  741. ]),
  742. },
  743. },
  744. data: dataL4[0],
  745. },
  746. {
  747. name: '当前各二级中层管理人数',
  748. type: 'bar',
  749. barWidth: 15,
  750. label: {
  751. normal: {
  752. show: true,
  753. position: 'top',
  754. textStyle: {
  755. color: '#6480f3',
  756. fontStyle: 'normal',
  757. textAlign: 'left',
  758. fontSize: 16,
  759. },
  760. formatter: function (data) {
  761. if (data.name == '云时代') {
  762. return data.value
  763. } else {
  764. return ''
  765. }
  766. }
  767. }
  768. },
  769. itemStyle: {
  770. normal: {
  771. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  772. {
  773. offset: 0,
  774. color: '#43ede3',
  775. },
  776. {
  777. offset: 1,
  778. color: '#082550',
  779. },
  780. ]),
  781. },
  782. },
  783. data: dataL4[1],
  784. },
  785. {
  786. name: '各二级中层管理人数核定上限',
  787. type: 'line',
  788. // yAxisIndex: 1,
  789. smooth: true, //平滑曲线显示
  790. showAllSymbol: true, //显示所有图形。
  791. symbol: 'circle', //标记的图形为实心圆
  792. symbolSize: 8, //标记的大小
  793. smooth: false,
  794. label: {
  795. normal: {
  796. show: true,
  797. position: 'top',
  798. textStyle: {
  799. color: '#fbe138',
  800. fontStyle: 'normal',
  801. textAlign: 'left',
  802. fontSize: 16,
  803. },
  804. formatter: function (data) {
  805. if (data.name == '云时代') {
  806. return data.value
  807. } else {
  808. return ''
  809. }
  810. }
  811. }
  812. },
  813. itemStyle: {
  814. //折线拐点标志的样式
  815. color: '#fbe138',
  816. borderColor: '#fbe138',
  817. width: 2,
  818. shadowColor: '#fbe138',
  819. shadowBlur: 4,
  820. },
  821. lineStyle: {
  822. color: '#fbe138',
  823. width: 2,
  824. },
  825. data: dataL4[2],
  826. },
  827. ],
  828. }
  829. option.title.text = '各二级企业本部中层管理人数'
  830. option.legend.data = ['六定改革前各二级中层管理人数', '当前各二级中层管理人数', '各二级中层管理人数核定上限']
  831. option.yAxis.push({
  832. type: 'value',
  833. axisLine: {
  834. show: false,
  835. },
  836. splitLine: {
  837. show: false,
  838. },
  839. })
  840. myChart.setOption(option)
  841. },
  842. initChartL4 () {
  843. let myChart = echarts.init(this.$refs['echartL4'])
  844. let option = {
  845. ..._.cloneDeep(this.commonOption),
  846. color: [
  847. {
  848. x: 0,
  849. y: 0,
  850. x2: 0,
  851. y2: 1,
  852. colorStops: [{
  853. offset: 0,
  854. color: '#6480f3',
  855. },
  856. {
  857. offset: 1,
  858. color: '#082550',
  859. },],
  860. }
  861. ],
  862. series: [
  863. {
  864. name: '六定改革前各二级企业本部中层管理人数',
  865. type: 'bar',
  866. barWidth: 15,
  867. label: {
  868. normal: {
  869. show: true,
  870. position: 'top',
  871. textStyle: {
  872. color: '#69c0ff',
  873. fontStyle: 'normal',
  874. textAlign: 'left',
  875. fontSize: 16,
  876. },
  877. formatter: function (data) {
  878. if (data.name == '云时代') {
  879. return data.value
  880. } else {
  881. return ''
  882. }
  883. }
  884. }
  885. },
  886. itemStyle: {
  887. normal: {
  888. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  889. {
  890. offset: 0,
  891. color: '#69c0ff',
  892. },
  893. {
  894. offset: 1,
  895. color: '#082550',
  896. },
  897. ]),
  898. },
  899. },
  900. data: dataL4[0],
  901. },
  902. {
  903. name: '当前各二级企业本部中层管理人数',
  904. type: 'bar',
  905. barWidth: 15,
  906. label: {
  907. normal: {
  908. show: true,
  909. position: 'top',
  910. textStyle: {
  911. color: '#6480f3',
  912. fontStyle: 'normal',
  913. textAlign: 'left',
  914. fontSize: 16,
  915. },
  916. formatter: function (data) {
  917. if (data.name == '云时代') {
  918. return data.value
  919. } else {
  920. return ''
  921. }
  922. }
  923. }
  924. },
  925. itemStyle: {
  926. normal: {
  927. color: params => {
  928. if (params.value > dataL4[2][params.dataIndex] || params.value > dataL4[0][params.dataIndex]) {
  929. return 'red'
  930. } else {
  931. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  932. {
  933. offset: 0,
  934. color: '#6480f3',
  935. },
  936. {
  937. offset: 1,
  938. color: '#082550',
  939. },
  940. ])
  941. }
  942. },
  943. },
  944. },
  945. data: dataL4[1],
  946. },
  947. {
  948. name: '各二级企业本部中层管理人数核定上限',
  949. type: 'line',
  950. // yAxisIndex: 1,
  951. smooth: true, //平滑曲线显示
  952. showAllSymbol: true, //显示所有图形。
  953. symbol: 'circle', //标记的图形为实心圆
  954. symbolSize: 8, //标记的大小
  955. smooth: false,
  956. label: {
  957. normal: {
  958. show: true,
  959. position: 'top',
  960. textStyle: {
  961. color: '#fbe138',
  962. fontStyle: 'normal',
  963. textAlign: 'left',
  964. fontSize: 16,
  965. },
  966. formatter: function (data) {
  967. if (data.name == '云时代') {
  968. return data.value
  969. } else {
  970. return ''
  971. }
  972. }
  973. }
  974. },
  975. itemStyle: {
  976. //折线拐点标志的样式
  977. color: '#fbe138',
  978. borderColor: '#fbe138',
  979. width: 2,
  980. shadowColor: '#fbe138',
  981. shadowBlur: 4,
  982. },
  983. lineStyle: {
  984. color: '#fbe138',
  985. width: 2,
  986. },
  987. data: dataL4[2],
  988. },
  989. ],
  990. }
  991. option.title.text = '各二级企业本部中层管理人数'
  992. option.legend.data = ['六定改革前各二级企业本部中层管理人数', '当前各二级企业本部中层管理人数', '各二级企业本部中层管理人数核定上限']
  993. option.legend.show = true
  994. // option.yAxis.push({
  995. // splitLine: {
  996. // show: false,
  997. // },
  998. // axisLine: {
  999. // show: false,
  1000. // },
  1001. // })
  1002. myChart.setOption(option)
  1003. },
  1004. initChartL5 () {
  1005. let myChart = echarts.init(this.$refs['echartL5'])
  1006. let option = {
  1007. ..._.cloneDeep(this.commonOption),
  1008. color: [
  1009. {
  1010. x: 0,
  1011. y: 0,
  1012. x2: 0,
  1013. y2: 1,
  1014. colorStops: [{
  1015. offset: 0,
  1016. color: '#69c0ff',
  1017. },
  1018. {
  1019. offset: 1,
  1020. color: '#082550',
  1021. },],
  1022. }
  1023. ],
  1024. series: [
  1025. {
  1026. name: '各二级企业总人数',
  1027. type: 'bar',
  1028. barWidth: 15,
  1029. itemStyle: {
  1030. normal: {
  1031. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1032. {
  1033. offset: 0,
  1034. color: '#69c0ff',
  1035. },
  1036. {
  1037. offset: 1,
  1038. color: '#082550',
  1039. },
  1040. ]),
  1041. },
  1042. },
  1043. data: dataL5[0],
  1044. },
  1045. {
  1046. name: '去年同期人数变化率',
  1047. type: 'line',
  1048. yAxisIndex: 1, //使用的 y 轴的 index,在单个图表实例中存在多个 y轴的时候有用
  1049. smooth: true, //平滑曲线显示
  1050. showAllSymbol: true, //显示所有图形。
  1051. symbol: 'circle', //标记的图形为实心圆
  1052. symbolSize: 8, //标记的大小
  1053. smooth: false,
  1054. itemStyle: {
  1055. //折线拐点标志的样式
  1056. color: '#b889ea',
  1057. borderColor: '#b889ea',
  1058. width: 2,
  1059. shadowColor: '#b889ea',
  1060. shadowBlur: 4,
  1061. },
  1062. lineStyle: {
  1063. color: '#b889ea',
  1064. width: 2,
  1065. },
  1066. data: dataL5[1],
  1067. },
  1068. ],
  1069. }
  1070. option.title.text = '各二级企业总人数'
  1071. option.legend.data = ['各二级企业总人数', '去年同期人数变化率']
  1072. option.legend.show = true
  1073. option.tooltip = {
  1074. trigger: 'axis',
  1075. formatter: '{a0}:{c0}' + '<br/>' + '{a1}:{c1}' + '%'
  1076. }
  1077. option.yAxis.push({
  1078. type: 'value',
  1079. axisLine: {
  1080. show: false,
  1081. },
  1082. splitLine: {
  1083. show: false,
  1084. },
  1085. axisLabel: {
  1086. show: true,
  1087. formatter: '{value} %',
  1088. textStyle: {
  1089. color: 'rgba(250,250,250,0.6)',
  1090. },
  1091. },
  1092. })
  1093. myChart.setOption(option)
  1094. },
  1095. initChartL6 () {
  1096. let myChart = echarts.init(this.$refs['echartL6'])
  1097. let option = {
  1098. ..._.cloneDeep(this.commonOption),
  1099. color: [
  1100. {
  1101. x: 0,
  1102. y: 0,
  1103. x2: 0,
  1104. y2: 1,
  1105. colorStops: [{
  1106. offset: 0,
  1107. color: '#43ede3',
  1108. },
  1109. {
  1110. offset: 1,
  1111. color: '#082550',
  1112. },],
  1113. }
  1114. ],
  1115. series: [
  1116. {
  1117. name: '各二级员额数',
  1118. type: 'bar',
  1119. barWidth: 15,
  1120. itemStyle: {
  1121. color: params => {
  1122. if (params.value > dataL6[1][params.dataIndex]) {
  1123. return 'red'
  1124. } else {
  1125. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1126. {
  1127. offset: 0,
  1128. color: '#43ede3',
  1129. },
  1130. {
  1131. offset: 1,
  1132. color: '#082550',
  1133. },
  1134. ])
  1135. }
  1136. },
  1137. },
  1138. data: dataL6[0],
  1139. },
  1140. {
  1141. name: '六定改革前各二级员额数',
  1142. type: 'bar',
  1143. barWidth: 15,
  1144. itemStyle: {
  1145. normal: {
  1146. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1147. {
  1148. offset: 0,
  1149. color: '#5e7ae9',
  1150. },
  1151. {
  1152. offset: 1,
  1153. color: '#082550',
  1154. },
  1155. ]),
  1156. },
  1157. },
  1158. data: dataL6[2],
  1159. },
  1160. {
  1161. name: '各二级员额数核定上限',
  1162. type: 'line',
  1163. yAxisIndex: 1, //使用的 y 轴的 index,在单个图表实例中存在多个 y轴的时候有用
  1164. smooth: true, //平滑曲线显示
  1165. showAllSymbol: true, //显示所有图形。
  1166. symbol: 'circle', //标记的图形为实心圆
  1167. symbolSize: 8, //标记的大小
  1168. smooth: false,
  1169. itemStyle: {
  1170. //折线拐点标志的样式
  1171. color: '#fbe138',
  1172. borderColor: '#fbe138',
  1173. width: 2,
  1174. shadowColor: '#fbe138',
  1175. shadowBlur: 4,
  1176. },
  1177. lineStyle: {
  1178. color: '#fbe138',
  1179. width: 2,
  1180. },
  1181. data: dataL6[1],
  1182. },
  1183. ],
  1184. }
  1185. option.title.text = '各二级企业本部员额数'
  1186. option.legend.data = ['各二级员额数', '六定改革前各二级员额数', '各二级员额数核定上限']
  1187. option.legend.show = true
  1188. option.yAxis.push({
  1189. splitLine: {
  1190. show: false,
  1191. },
  1192. axisLine: {
  1193. show: false,
  1194. },
  1195. })
  1196. myChart.setOption(option)
  1197. },
  1198. initChartL7 () {
  1199. let myChart = echarts.init(this.$refs['echartL7'])
  1200. let option = {
  1201. ..._.cloneDeep(this.commonOption),
  1202. color: ['#43ede3'],
  1203. series: [
  1204. {
  1205. name: '人数变化',
  1206. type: 'line',
  1207. barWidth: 15,
  1208. showAllSymbol: true, //显示所有图形。
  1209. symbol: 'circle', //标记的图形为实心圆
  1210. symbolSize: 15, //标记的大小
  1211. smooth: false,
  1212. itemStyle: {
  1213. color: params => {
  1214. if (dataL7[1][params.dataIndex] < 0 && params.value > 0) {
  1215. return 'red'
  1216. } else {
  1217. return '#43ede3'
  1218. }
  1219. },
  1220. },
  1221. lineStyle: {
  1222. color: '#43ede3',
  1223. width: 2,
  1224. },
  1225. // markLine: {
  1226. // data: [{ type: 'average', name: 'Avg' }],
  1227. // },
  1228. data: dataL7[0],
  1229. },
  1230. {
  1231. name: '全员劳动生产率同比变化',
  1232. type: 'line',
  1233. barWidth: 15,
  1234. // yAxisIndex: 1,
  1235. showAllSymbol: true, //显示所有图形。
  1236. symbol: 'circle', //标记的图形为实心圆
  1237. symbolSize: 15, //标记的大小
  1238. itemStyle: {
  1239. //折线拐点标志的样式
  1240. color: '#b889ea',
  1241. borderColor: '#b889ea',
  1242. width: 2,
  1243. shadowColor: '#b889ea',
  1244. shadowBlur: 4,
  1245. },
  1246. // itemStyle: {
  1247. // normal: {
  1248. // color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1249. // {
  1250. // offset: 0,
  1251. // color: '#b889ea',
  1252. // },
  1253. // {
  1254. // offset: 1,
  1255. // color: '#b889ea',
  1256. // },
  1257. // ]),
  1258. // },
  1259. // },
  1260. data: dataL7[1],
  1261. },
  1262. {
  1263. type: 'effectScatter',
  1264. coordinateSystem: 'cartesian2d',
  1265. showEffectOn: 'render',
  1266. rippleEffect: {
  1267. period: 10,
  1268. scale: 4,
  1269. brushType: 'stroke'
  1270. },
  1271. hoverAnimation: true,
  1272. itemStyle: {
  1273. color: 'red'
  1274. },
  1275. lineStyle: {
  1276. color: '#43ede3',
  1277. width: 2,
  1278. },
  1279. data: this.twinkle7,
  1280. },
  1281. ],
  1282. }
  1283. option.title.text = '人数变化和全员劳动生产率变化率分析'
  1284. option.legend.data = ['人数变化', '全员劳动生产率同比变化']
  1285. option.legend.show = true
  1286. option.tooltip = {
  1287. trigger: 'axis',
  1288. formatter: '{a0}:{c0}' + '%' + '<br/>' + '{a1}:{c1}' + '%'
  1289. }
  1290. option.yAxis = [
  1291. {
  1292. type: 'value',
  1293. axisLine: {
  1294. show: false,
  1295. },
  1296. splitLine: {
  1297. show: true,
  1298. lineStyle: {
  1299. color: '#68b4dd66',
  1300. type: 'dashed',
  1301. },
  1302. },
  1303. axisLabel: {
  1304. show: true,
  1305. formatter: '{value} %',
  1306. textStyle: {
  1307. color: 'rgba(250,250,250,0.6)',
  1308. },
  1309. },
  1310. },
  1311. {
  1312. type: 'value',
  1313. axisLine: {
  1314. show: false,
  1315. },
  1316. splitLine: {
  1317. show: false,
  1318. },
  1319. axisLabel: {
  1320. show: true,
  1321. formatter: '{value} %',
  1322. textStyle: {
  1323. color: 'rgba(250,250,250,0.6)',
  1324. },
  1325. },
  1326. }
  1327. ]
  1328. myChart.setOption(option)
  1329. },
  1330. initChartL8 () {
  1331. let myChart = echarts.init(this.$refs['echartL8'])
  1332. let option = {
  1333. ..._.cloneDeep(this.commonOption),
  1334. color: ['#43ede3'],
  1335. series: [
  1336. {
  1337. name: '人数变化',
  1338. type: 'line',
  1339. barWidth: 15,
  1340. showAllSymbol: true, //显示所有图形。
  1341. symbol: 'circle', //标记的图形为实心圆
  1342. symbolSize: 15, //标记的大小
  1343. smooth: false,
  1344. itemStyle: {
  1345. color: params => {
  1346. if (dataL8[1][params.dataIndex] < 0 && params.value > 0) {
  1347. return 'red'
  1348. } else {
  1349. return '#43ede3'
  1350. }
  1351. },
  1352. },
  1353. lineStyle: {
  1354. color: '#43ede3',
  1355. width: 2,
  1356. },
  1357. // markLine: {
  1358. // data: [{ type: 'average', name: 'Avg' }],
  1359. // },
  1360. data: dataL8[0],
  1361. },
  1362. {
  1363. name: '人工成本利润率同比变化',
  1364. type: 'line',
  1365. barWidth: 15,
  1366. // yAxisIndex: 1,
  1367. showAllSymbol: true, //显示所有图形。
  1368. symbol: 'circle', //标记的图形为实心圆
  1369. symbolSize: 15, //标记的大小
  1370. smooth: false,
  1371. itemStyle: {
  1372. //折线拐点标志的样式
  1373. color: '#b889ea',
  1374. borderColor: '#b889ea',
  1375. width: 2,
  1376. shadowColor: '#b889ea',
  1377. shadowBlur: 4,
  1378. },
  1379. data: dataL8[1],
  1380. },
  1381. {
  1382. type: 'effectScatter',
  1383. coordinateSystem: 'cartesian2d',
  1384. showEffectOn: 'render',
  1385. rippleEffect: {
  1386. period: 10,
  1387. scale: 4,
  1388. brushType: 'stroke'
  1389. },
  1390. hoverAnimation: true,
  1391. itemStyle: {
  1392. color: 'red'
  1393. },
  1394. lineStyle: {
  1395. color: '#43ede3',
  1396. width: 2,
  1397. },
  1398. data: this.twinkle8,
  1399. },
  1400. ],
  1401. }
  1402. option.title.text = '人数变化和人工利润率变化分析'
  1403. option.legend.data = ['人数变化', '人工成本利润率同比变化']
  1404. option.legend.show = true
  1405. option.tooltip = {
  1406. trigger: 'axis',
  1407. formatter: '{a0}:{c0}' + '%' + '<br/>' + '{a1}:{c1}' + '%'
  1408. }
  1409. option.yAxis = [
  1410. {
  1411. type: 'value',
  1412. axisLine: {
  1413. show: false,
  1414. },
  1415. splitLine: {
  1416. show: true,
  1417. lineStyle: {
  1418. color: '#68b4dd66',
  1419. type: 'dashed',
  1420. },
  1421. },
  1422. axisLabel: {
  1423. show: true,
  1424. formatter: '{value} %',
  1425. textStyle: {
  1426. color: 'rgba(250,250,250,0.6)',
  1427. },
  1428. },
  1429. },
  1430. {
  1431. type: 'value',
  1432. axisLine: {
  1433. show: false,
  1434. },
  1435. splitLine: {
  1436. show: false,
  1437. },
  1438. axisLabel: {
  1439. show: true,
  1440. formatter: '{value} %',
  1441. textStyle: {
  1442. color: 'rgba(250,250,250,0.6)',
  1443. },
  1444. },
  1445. }
  1446. ]
  1447. myChart.setOption(option)
  1448. },
  1449. // 中间图表---------------------------------------------开始
  1450. initChartC1 () {
  1451. let myChart = echarts.init(this.$refs['echartC1'])
  1452. let option = {
  1453. ..._.cloneDeep(this.commonOption),
  1454. color: [
  1455. {
  1456. x: 0,
  1457. y: 0,
  1458. x2: 0,
  1459. y2: 1,
  1460. colorStops: [{
  1461. offset: 0,
  1462. color: '#69c0ff',
  1463. },
  1464. {
  1465. offset: 1,
  1466. color: '#082550',
  1467. },],
  1468. }
  1469. ],
  1470. series: [
  1471. {
  1472. name: '全员劳动生产率(万/人)',
  1473. type: 'bar',
  1474. barWidth: 12,
  1475. smooth: true, //平滑曲线显示
  1476. showAllSymbol: true, //显示所有图形。
  1477. symbol: 'circle', //标记的图形为实心圆
  1478. symbolSize: 8, //标记的大小
  1479. smooth: false,
  1480. itemStyle: {
  1481. color: params => {
  1482. if (params.value < 0 && dataC1[1][params.dataIndex] < 0) {
  1483. return 'red'
  1484. } else if (params.value > this.echartC1.province) {
  1485. return 'green'
  1486. } else {
  1487. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1488. {
  1489. offset: 0,
  1490. color: '#69c0ff',
  1491. },
  1492. {
  1493. offset: 1,
  1494. color: '#082550',
  1495. },
  1496. ])
  1497. }
  1498. },
  1499. },
  1500. lineStyle: {
  1501. color: '#B889EA',
  1502. width: 2,
  1503. },
  1504. markLine: {
  1505. data: [
  1506. {
  1507. name: '省属企业平均水平',
  1508. yAxis: this.echartC1.national,
  1509. lineStyle: {
  1510. color: '#fff',
  1511. },
  1512. label: {
  1513. formatter: '{b}',
  1514. position: 'end',
  1515. padding: [20, 100, 10, 30],
  1516. color: '#fff',
  1517. },
  1518. },
  1519. {
  1520. name: '央企平均水平',
  1521. yAxis: this.echartC1.province,
  1522. lineStyle: {
  1523. color: '#fff',
  1524. },
  1525. label: {
  1526. formatter: '{b}',
  1527. position: 'end',
  1528. padding: [-4, 150, 10, 30],
  1529. color: '#fff',
  1530. },
  1531. },
  1532. ],
  1533. label: {
  1534. distance: [20, 8],
  1535. },
  1536. },
  1537. data: dataC1[0],
  1538. },
  1539. {
  1540. name: '全员劳动生产率同比变化',
  1541. yAxisIndex: 1, //使用的 y 轴的 index,在单个图表实例中存在多个 y轴的时候有用
  1542. type: 'line',
  1543. itemStyle: {
  1544. normal: {
  1545. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1546. {
  1547. offset: 0,
  1548. color: '#69c0ff',
  1549. },
  1550. {
  1551. offset: 1,
  1552. color: '#082550',
  1553. },
  1554. ]),
  1555. },
  1556. },
  1557. data: dataC1[1],
  1558. },
  1559. ],
  1560. }
  1561. option.title.text = '各二级企业全员劳动生产率'
  1562. option.legend.data = ['全员劳动生产率同比变化', '全员劳动生产率(万/人)']
  1563. option.legend.show = true
  1564. option.grid.right = '15%'
  1565. option.tooltip = {
  1566. trigger: 'axis',
  1567. formatter: '{a0}:{c0}' + '<br/>' + '{a1}:{c1}' + '%'
  1568. }
  1569. option.yAxis.push({
  1570. type: 'value',
  1571. axisLine: {
  1572. show: false,
  1573. },
  1574. splitLine: {
  1575. show: false,
  1576. },
  1577. axisLabel: {
  1578. show: true,
  1579. formatter: '{value} %',
  1580. textStyle: {
  1581. color: 'rgba(250,250,250,0.6)',
  1582. },
  1583. },
  1584. })
  1585. myChart.setOption(option)
  1586. tools.loopShowTooltip(myChart, option, {
  1587. nterval: 2000,
  1588. loopSeries: true,
  1589. });
  1590. },
  1591. initChartC2 () {
  1592. let myChart = echarts.init(this.$refs['echartC2'])
  1593. let option = {
  1594. ..._.cloneDeep(this.commonOption),
  1595. color: [
  1596. {
  1597. x: 0,
  1598. y: 0,
  1599. x2: 0,
  1600. y2: 1,
  1601. colorStops: [{
  1602. offset: 0,
  1603. color: '#69c0ff',
  1604. },
  1605. {
  1606. offset: 1,
  1607. color: '#082550',
  1608. },],
  1609. }
  1610. ],
  1611. series: [
  1612. {
  1613. name: '人工成本利润率同比变化',
  1614. type: 'line',
  1615. yAxisIndex: 1, //使用的 y 轴的 index,在单个图表实例中存在多个 y轴的时候有用
  1616. smooth: true, //平滑曲线显示
  1617. showAllSymbol: true, //显示所有图形。
  1618. symbol: 'circle', //标记的图形为实心圆
  1619. symbolSize: 8, //标记的大小
  1620. smooth: false,
  1621. itemStyle: {
  1622. //折线拐点标志的样式
  1623. color: '#B889EA',
  1624. borderColor: '#B889EA',
  1625. width: 2,
  1626. shadowColor: '#B889EA',
  1627. shadowBlur: 4,
  1628. },
  1629. lineStyle: {
  1630. color: '#B889EA',
  1631. width: 2,
  1632. },
  1633. data: dataC2[0],
  1634. },
  1635. {
  1636. name: '人工成本利润率',
  1637. type: 'bar',
  1638. barWidth: 15,
  1639. itemStyle: {
  1640. color: params => {
  1641. if (params.value < 0 && dataC2[1][params.dataIndex] < 0) {
  1642. return 'red'
  1643. } else if (params.value > this.echartC2.province) {
  1644. return 'green'
  1645. } else {
  1646. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1647. {
  1648. offset: 0,
  1649. color: '#69c0ff',
  1650. },
  1651. {
  1652. offset: 1,
  1653. color: '#082550',
  1654. },
  1655. ])
  1656. }
  1657. },
  1658. },
  1659. data: dataC2[1],
  1660. markLine: {
  1661. data: [
  1662. {
  1663. name: '省属企业平均水平',
  1664. yAxis: this.echartC2.province,
  1665. lineStyle: {
  1666. color: '#fff',
  1667. },
  1668. label: {
  1669. formatter: '{b}',
  1670. position: 'end',
  1671. padding: [24, 100, 10, 30],
  1672. color: '#fff',
  1673. },
  1674. },
  1675. {
  1676. name: '央企平均水平',
  1677. yAxis: this.echartC2.national,
  1678. lineStyle: {
  1679. color: '#fff',
  1680. },
  1681. label: {
  1682. formatter: '{b}',
  1683. position: 'end',
  1684. padding: [-24, 200, 10, 30],
  1685. color: '#fff',
  1686. },
  1687. },
  1688. ],
  1689. label: {
  1690. distance: [20, 8],
  1691. },
  1692. },
  1693. },
  1694. ],
  1695. }
  1696. option.title.text = '各二级企业人工成本利润率'
  1697. option.legend.data = ['人工成本利润率同比变化', '人工成本利润率']
  1698. option.legend.show = true
  1699. option.tooltip = {
  1700. trigger: 'axis',
  1701. formatter: '{a0}:{c0}' + '%' + '<br/>' + '{a1}:{c1}' + '%'
  1702. }
  1703. option.grid.right = '15%'
  1704. option.yAxis = [
  1705. {
  1706. axisLine: {
  1707. show: false,
  1708. },
  1709. splitLine: {
  1710. show: true,
  1711. lineStyle: {
  1712. color: '#68b4dd66',
  1713. type: 'dashed',
  1714. },
  1715. },
  1716. axisLabel: {
  1717. show: true,
  1718. formatter: '{value} %',
  1719. textStyle: {
  1720. color: 'rgba(250,250,250,0.6)',
  1721. },
  1722. },
  1723. },
  1724. {
  1725. splitLine: {
  1726. show: false,
  1727. },
  1728. axisLine: {
  1729. show: false,
  1730. },
  1731. axisLabel: {
  1732. show: true,
  1733. formatter: '{value} %',
  1734. textStyle: {
  1735. color: 'rgba(250,250,250,0.6)',
  1736. },
  1737. },
  1738. }
  1739. ]
  1740. myChart.setOption(option)
  1741. tools.loopShowTooltip(myChart, option, {
  1742. nterval: 2000,
  1743. loopSeries: true,
  1744. });
  1745. },
  1746. // 右侧图表---------------------------------------------开始
  1747. initChartR1 () {
  1748. let myChart = echarts.init(this.$refs['echartR1'])
  1749. let commonOptions = this.commonOption
  1750. commonOptions.yAxis[0].splitNumber = 2
  1751. let option = {
  1752. ..._.cloneDeep(commonOptions),
  1753. series: [
  1754. {
  1755. name: '招聘需求公告次数',
  1756. type: 'bar',
  1757. barWidth: 15,
  1758. itemStyle: {
  1759. normal: {
  1760. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1761. {
  1762. offset: 0,
  1763. color: '#69c0ff',
  1764. },
  1765. {
  1766. offset: 1,
  1767. color: '#082550',
  1768. },
  1769. ]),
  1770. },
  1771. },
  1772. data: dataR1[0],
  1773. },
  1774. {
  1775. name: '招聘需求公告累计招聘人次',
  1776. type: 'bar',
  1777. barWidth: 15,
  1778. itemStyle: {
  1779. normal: {
  1780. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1781. {
  1782. offset: 0,
  1783. color: '#43ede3',
  1784. },
  1785. {
  1786. offset: 1,
  1787. color: '#082550',
  1788. },
  1789. ]),
  1790. },
  1791. },
  1792. data: dataR1[1],
  1793. },
  1794. ],
  1795. }
  1796. option.title.text = '各二级企业招聘需求公告人次情况'
  1797. option.legend.data = ['招聘需求公告次数', '招聘需求公告累计招聘人次']
  1798. option.legend.show = true
  1799. option.yAxis.push({
  1800. type: 'value',
  1801. splitLine: {
  1802. show: false,
  1803. },
  1804. axisLine: {
  1805. show: false,
  1806. },
  1807. })
  1808. myChart.setOption(option)
  1809. },
  1810. initChartR2 () {
  1811. let myChart = echarts.init(this.$refs['echartR2'])
  1812. let commonOptions = this.commonOption
  1813. commonOptions.yAxis[0].splitNumber = 2
  1814. let option = {
  1815. ..._.cloneDeep(commonOptions),
  1816. series: [
  1817. {
  1818. name: '录用结果公示次数',
  1819. type: 'bar',
  1820. barWidth: 15,
  1821. itemStyle: {
  1822. normal: {
  1823. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1824. {
  1825. offset: 0,
  1826. color: '#69c0ff',
  1827. },
  1828. {
  1829. offset: 1,
  1830. color: '#082550',
  1831. },
  1832. ]),
  1833. },
  1834. },
  1835. data: dataR2[0],
  1836. },
  1837. {
  1838. name: '录用结果公示累计公示人数',
  1839. type: 'bar',
  1840. barWidth: 15,
  1841. itemStyle: {
  1842. normal: {
  1843. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1844. {
  1845. offset: 0,
  1846. color: '#45DAD1',
  1847. },
  1848. {
  1849. offset: 1,
  1850. color: '#082550',
  1851. },
  1852. ]),
  1853. },
  1854. },
  1855. data: dataR2[1],
  1856. },
  1857. ],
  1858. }
  1859. option.title.text = '各二级企业录用结果公示人次'
  1860. option.legend.data = ['录用结果公示次数', '录用结果公示累计公示人数']
  1861. option.legend.show = true
  1862. option.yAxis.push({
  1863. type: 'value',
  1864. splitLine: {
  1865. show: false,
  1866. },
  1867. axisLine: {
  1868. show: false,
  1869. },
  1870. })
  1871. myChart.setOption(option)
  1872. },
  1873. initChartR3 () {
  1874. let myChart = echarts.init(this.$refs['echartR3'])
  1875. let commonOptions = this.commonOption
  1876. commonOptions.yAxis[0].splitNumber = 2
  1877. let option = {
  1878. ..._.cloneDeep(commonOptions),
  1879. color: [
  1880. {
  1881. x: 0,
  1882. y: 0,
  1883. x2: 0,
  1884. y2: 1,
  1885. colorStops: [ {
  1886. offset: 0,
  1887. color: '#45DAD1',
  1888. },
  1889. {
  1890. offset: 1,
  1891. color: '#082550',
  1892. },],
  1893. }
  1894. ],
  1895. series: [
  1896. {
  1897. name: '2022年利润(万)',
  1898. type: 'bar',
  1899. barWidth: 15,
  1900. itemStyle: {
  1901. normal: {
  1902. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1903. {
  1904. offset: 0,
  1905. color: '#69c0ff',
  1906. },
  1907. {
  1908. offset: 1,
  1909. color: '#082550',
  1910. },
  1911. ]),
  1912. },
  1913. },
  1914. data: dataR3[0],
  1915. },
  1916. {
  1917. name: '2022年累计招聘数',
  1918. yAxisIndex: 1, //使用的 y 轴的 index,在单个图表实例中存在多个 y轴的时候有用
  1919. type: 'bar',
  1920. barWidth: 15,
  1921. itemStyle: {
  1922. color: params => {
  1923. if (params.value > 0 && dataR3[0][params.dataIndex] < 0) {
  1924. return 'red'
  1925. } else {
  1926. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1927. {
  1928. offset: 0,
  1929. color: '#45DAD1',
  1930. },
  1931. {
  1932. offset: 1,
  1933. color: '#082550',
  1934. },
  1935. ])
  1936. }
  1937. },
  1938. },
  1939. data: dataR3[1],
  1940. },
  1941. ],
  1942. }
  1943. option.title.text = '各二级企业年利润与招聘情况分析'
  1944. option.legend.data = ['2022年利润(万)', '2022年累计招聘数']
  1945. option.legend.show = true
  1946. option.yAxis.push({
  1947. type: 'value',
  1948. splitLine: {
  1949. show: false,
  1950. },
  1951. axisLine: {
  1952. show: false,
  1953. },
  1954. axisLabel: {
  1955. show: true,
  1956. formatter: '{value} ',
  1957. textStyle: {
  1958. color: 'rgba(250,250,250,0.6)',
  1959. },
  1960. },
  1961. })
  1962. myChart.setOption(option)
  1963. },
  1964. initChartR4 () {
  1965. let myChart = echarts.init(this.$refs['echartR4'])
  1966. let commonOptions = this.commonOption
  1967. commonOptions.yAxis[0].splitNumber = 2
  1968. let option = {
  1969. ..._.cloneDeep(commonOptions),
  1970. color: [
  1971. {
  1972. x: 0,
  1973. y: 0,
  1974. x2: 0,
  1975. y2: 1,
  1976. colorStops: [{
  1977. offset: 0,
  1978. color: '#6480f3',
  1979. },
  1980. {
  1981. offset: 1,
  1982. color: '#082550',
  1983. },],
  1984. }
  1985. ],
  1986. series: [
  1987. {
  1988. name: '2022年退出人数和2023年当前累计退出人数之和',
  1989. type: 'bar',
  1990. barWidth: 15,
  1991. itemStyle: {
  1992. normal: {
  1993. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  1994. {
  1995. offset: 0,
  1996. color: '#69c0ff',
  1997. },
  1998. {
  1999. offset: 1,
  2000. color: '#082550',
  2001. },
  2002. ]),
  2003. },
  2004. },
  2005. data: dataR4[0],
  2006. },
  2007. {
  2008. name: '2022年招聘人数和2023年当前累计招聘人数之和',
  2009. type: 'bar',
  2010. barWidth: 15,
  2011. itemStyle: {
  2012. normal: {
  2013. color: params => {
  2014. if (dataR4[0][params.dataIndex] / 2 < params.value) {
  2015. return 'red'
  2016. }
  2017. else {
  2018. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  2019. {
  2020. offset: 0,
  2021. color: '#6480f3',
  2022. },
  2023. {
  2024. offset: 1,
  2025. color: '#082550',
  2026. },
  2027. ])
  2028. }
  2029. },
  2030. },
  2031. },
  2032. data: dataR4[1],
  2033. },
  2034. ],
  2035. }
  2036. option.title.text = '各省属企业"退二进一"完成情况'
  2037. option.legend.data = ['2022年退出人数和2023年当前累计退出人数之和', '2022年招聘人数和2023年当前累计招聘人数之和']
  2038. option.legend.show = true
  2039. option.yAxis[0] = {
  2040. //type: 'log',
  2041. //min: 1,
  2042. //logBase: 3,
  2043. axisLine: {
  2044. show: false,
  2045. },
  2046. splitLine: {
  2047. show: true,
  2048. lineStyle: {
  2049. color: '#68b4dd66',
  2050. type: 'dashed',
  2051. },
  2052. },
  2053. axisLabel: {
  2054. show: true,
  2055. formatter: function (value) {
  2056. return value === 1 ? 0 : value
  2057. },
  2058. textStyle: {
  2059. color: 'rgba(250,250,250,0.6)',
  2060. },
  2061. },
  2062. }
  2063. myChart.setOption(option)
  2064. },
  2065. initChartR5 () {
  2066. let myChart = echarts.init(this.$refs['echartR5'])
  2067. let option = {
  2068. ..._.cloneDeep(this.commonOption),
  2069. series: [
  2070. {
  2071. name: '去年同期在岗职工平均薪酬',
  2072. type: 'bar',
  2073. barWidth: 15,
  2074. itemStyle: {
  2075. normal: {
  2076. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  2077. {
  2078. offset: 0,
  2079. color: '#6682F5',
  2080. },
  2081. {
  2082. offset: 1,
  2083. color: '#082550',
  2084. },
  2085. ]),
  2086. },
  2087. },
  2088. data: dataR5[1],
  2089. },
  2090. {
  2091. name: '在岗职工平均薪酬',
  2092. type: 'bar',
  2093. barWidth: 15,
  2094. itemStyle: {
  2095. normal: {
  2096. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  2097. {
  2098. offset: 0,
  2099. color: '#69c0ff',
  2100. },
  2101. {
  2102. offset: 1,
  2103. color: '#082550',
  2104. },
  2105. ]),
  2106. },
  2107. },
  2108. data: dataR5[0],
  2109. },
  2110. ],
  2111. }
  2112. option.title.text = '各二级企业在岗职工平均薪酬'
  2113. option.legend.data = ['去年同期在岗职工平均薪酬', '在岗职工平均薪酬']
  2114. option.legend.show = true
  2115. option.yAxis.push({
  2116. type: 'value',
  2117. splitLine: {
  2118. show: false,
  2119. },
  2120. axisLine: {
  2121. show: false,
  2122. },
  2123. })
  2124. myChart.setOption(option)
  2125. },
  2126. initChartR6 () {
  2127. let myChart = echarts.init(this.$refs['echartR6'])
  2128. let option = {
  2129. ..._.cloneDeep(this.commonOption),
  2130. color: ['#69c0ff'],
  2131. series: [
  2132. {
  2133. name: '2022年利润累计涨幅率',
  2134. type: 'line',
  2135. smooth: true, //平滑曲线显示
  2136. showAllSymbol: true, //显示所有图形。
  2137. symbol: 'circle', //标记的图形为实心圆
  2138. symbolSize: 8, //标记的大小
  2139. smooth: false,
  2140. itemStyle: {
  2141. //折线拐点标志的样式
  2142. color: '#B889EA',
  2143. borderColor: '#B889EA',
  2144. width: 2,
  2145. shadowColor: '#B889EA',
  2146. shadowBlur: 4,
  2147. },
  2148. lineStyle: {
  2149. color: '#B889EA',
  2150. width: 2,
  2151. },
  2152. data: dataR6[0],
  2153. },
  2154. {
  2155. name: '2022年薪酬累计涨幅率',
  2156. type: 'line',
  2157. barWidth: 15,
  2158. yAxisIndex: 1,
  2159. itemStyle: {
  2160. color: params => {
  2161. if (params.value > 0 && dataR6[0][params.dataIndex] < 0) {
  2162. return 'yellow'
  2163. } else {
  2164. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  2165. {
  2166. offset: 0,
  2167. color: '#69c0ff',
  2168. },
  2169. {
  2170. offset: 1,
  2171. color: '#082550',
  2172. },
  2173. ])
  2174. }
  2175. },
  2176. },
  2177. data: dataR6[1],
  2178. },
  2179. {
  2180. type: 'effectScatter',
  2181. coordinateSystem: 'cartesian2d',
  2182. showEffectOn: 'render',
  2183. rippleEffect: {
  2184. period: 10,
  2185. scale: 4,
  2186. brushType: 'stroke'
  2187. },
  2188. hoverAnimation: true,
  2189. itemStyle: {
  2190. color: 'red'
  2191. },
  2192. lineStyle: {
  2193. color: '#43ede3',
  2194. width: 2,
  2195. },
  2196. data: this.twinkleR6,
  2197. },
  2198. ],
  2199. }
  2200. option.title.text = '各二级企业利润与薪酬变动情况'
  2201. option.legend.data = ['2022年利润累计涨幅率', '2022年薪酬累计涨幅率']
  2202. option.tooltip = {
  2203. trigger: 'axis',
  2204. formatter: '{a0}:{c0}' + '%' + '<br/>' + '{a1}:{c1}' + '%'
  2205. }
  2206. option.yAxis = [
  2207. {
  2208. max: function (value) {
  2209. if (Math.abs(value.max) > Math.abs(value.min)) {
  2210. return (Math.abs(value.max) * 1.2).toFixed(2);
  2211. } else {
  2212. return (Math.abs(value.min) * 1.2).toFixed(2);
  2213. }
  2214. },
  2215. min: function (value) {
  2216. if (Math.abs(value.max) > Math.abs(value.min)) {
  2217. return (-Math.abs(value.max) * 1.2).toFixed(2);
  2218. } else {
  2219. return (-Math.abs(value.min) * 1.2).toFixed(2);
  2220. }
  2221. },
  2222. type: 'value',
  2223. axisLine: {
  2224. show: false,
  2225. },
  2226. splitLine: {
  2227. show: true,
  2228. lineStyle: {
  2229. color: '#68b4dd66',
  2230. type: 'dashed',
  2231. },
  2232. },
  2233. axisLabel: {
  2234. show: true,
  2235. formatter: '{value} %',
  2236. textStyle: {
  2237. color: 'rgba(250,250,250,0.6)',
  2238. },
  2239. },
  2240. },
  2241. {
  2242. max: function (value) {
  2243. if (Math.abs(value.max) > Math.abs(value.min)) {
  2244. return (Math.abs(value.max) * 1.2).toFixed(2);
  2245. } else {
  2246. return (Math.abs(value.min) * 1.2).toFixed(2);
  2247. }
  2248. },
  2249. min: function (value) {
  2250. if (Math.abs(value.max) > Math.abs(value.min)) {
  2251. return (-Math.abs(value.max) * 1.2).toFixed(2);
  2252. } else {
  2253. return (-Math.abs(value.min) * 1.2).toFixed(2);
  2254. }
  2255. },
  2256. type: 'value',
  2257. splitLine: {
  2258. show: false,
  2259. },
  2260. axisLine: {
  2261. show: false,
  2262. },
  2263. axisLabel: {
  2264. show: true,
  2265. formatter: '{value} %',
  2266. textStyle: {
  2267. color: 'rgba(250,250,250,0.6)',
  2268. },
  2269. },
  2270. }
  2271. ]
  2272. myChart.setOption(option)
  2273. },
  2274. initChartR7 () {
  2275. let myChart = echarts.init(this.$refs['echartR7'])
  2276. let option = {
  2277. ..._.cloneDeep(this.commonOption),
  2278. color: [
  2279. {
  2280. x: 0,
  2281. y: 0,
  2282. x2: 0,
  2283. y2: 1,
  2284. colorStops: [{
  2285. offset: 0,
  2286. color: '#B889EA',
  2287. },
  2288. {
  2289. offset: 1,
  2290. color: '#082550',
  2291. },],
  2292. }
  2293. ],
  2294. series: [
  2295. {
  2296. name: '全员绩效考核完成率',
  2297. type: 'bar',
  2298. barWidth: 15,
  2299. itemStyle: {
  2300. normal: {
  2301. color: params => {
  2302. if (params.value < 50) {
  2303. return 'yellow'
  2304. }
  2305. else {
  2306. return new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  2307. {
  2308. offset: 0,
  2309. color: '#B889EA',
  2310. },
  2311. {
  2312. offset: 1,
  2313. color: '#082550',
  2314. },
  2315. ])
  2316. }
  2317. },
  2318. },
  2319. },
  2320. data: dataR7[0],
  2321. },
  2322. ],
  2323. }
  2324. option.title.text = '各二级企业全员绩效考核'
  2325. // option.legend.data = ['劳动合同签约完成率', '目标值']
  2326. option.tooltip = {
  2327. trigger: 'axis',
  2328. formatter: '{a0}:{c0}' + '%'
  2329. },
  2330. option.yAxis[0].axisLabel = {
  2331. show: true,
  2332. formatter: '{value} %',
  2333. textStyle: {
  2334. color: 'rgba(250,250,250,0.6)',
  2335. },
  2336. }
  2337. myChart.setOption(option)
  2338. },
  2339. initChartR8 () {
  2340. let myChart = echarts.init(this.$refs['echartR8'])
  2341. let option = {
  2342. ..._.cloneDeep(this.commonOption),
  2343. color: [
  2344. {
  2345. x: 0,
  2346. y: 0,
  2347. x2: 0,
  2348. y2: 1,
  2349. colorStops: [{
  2350. offset: 0,
  2351. color: '#43ede3',
  2352. },
  2353. {
  2354. offset: 1,
  2355. color: '#082550',
  2356. },],
  2357. }
  2358. ],
  2359. series: [
  2360. {
  2361. name: '任期制考核完成率',
  2362. type: 'bar',
  2363. barWidth: 15,
  2364. itemStyle: {
  2365. normal: {
  2366. color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
  2367. {
  2368. offset: 0,
  2369. color: '#43ede3',
  2370. },
  2371. {
  2372. offset: 1,
  2373. color: '#082550',
  2374. },
  2375. ]),
  2376. },
  2377. },
  2378. data: dataR8[0],
  2379. },
  2380. ],
  2381. }
  2382. option.title.text = '各二级企业任期制契约化完成率'
  2383. option.tooltip = {
  2384. trigger: 'axis',
  2385. formatter: '{a0}:{c0}' + '%'
  2386. },
  2387. option.yAxis[0].axisLabel = {
  2388. show: true,
  2389. formatter: '{value} %',
  2390. textStyle: {
  2391. color: 'rgba(250,250,250,0.6)',
  2392. },
  2393. }
  2394. myChart.setOption(option)
  2395. },
  2396. },
  2397. })