index3.js 71 KB

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