index3MT.js 74 KB

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