index4.js 74 KB

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