index3MT.js 74 KB

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