index4.js 69 KB

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