{"remainingRequest":"D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\cqlt-fvue\\src\\views\\BigScrenn\\components\\bridgeDiagramAnalysis.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\cqlt-fvue\\src\\views\\BigScrenn\\components\\bridgeDiagramAnalysis.vue","mtime":1693994035633},{"path":"D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\cqlt-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/web.dom.iterable\";\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\nimport * as echarts from 'echarts';\nimport moment from 'moment';\nimport bridgeDiagramAnalysis from '@/api/bigScrenn/bridgeDiagramAnalysis.js';\nimport echartsTitle from '@/views/BigScrenn/investmentTheme/components/echartsTitle.vue';\nexport default {\n name: 'bridgeDiagramAnalysis',\n //桥图分析\n components: {\n echartsTitle: echartsTitle\n },\n data: function data() {\n return {\n visible: false,\n parmas: {\n year: moment().format('YYYY'),\n month: moment().subtract(1, 'months').format('M'),\n targetId: '',\n enterpriseCode: ''\n },\n bridgeList: [],\n monthList: [{\n value: '1',\n label: '1'\n }, {\n value: '2',\n label: '2'\n }, {\n value: '3',\n label: '3'\n }, {\n value: '4',\n label: '4'\n }, {\n value: '5',\n label: '5'\n }, {\n value: '6',\n label: '6'\n }, {\n value: '7',\n label: '7'\n }, {\n value: '8',\n label: '8'\n }, {\n value: '9',\n label: '9'\n }, {\n value: '10',\n label: '10'\n }, {\n value: '11',\n label: '11'\n }, {\n value: '12',\n label: '12'\n }]\n };\n },\n created: function created() {},\n mounted: function mounted() {},\n methods: {\n handleTop: function handleTop() {\n this.getBridgeList();\n },\n initCharts: function initCharts(data, index) {\n var dy = data.map(function (item) {\n return item.value;\n });\n var zt = [];\n var label = [];\n\n for (var i = 0; i < dy.length; i++) {\n var obj = [];\n\n if (i === 0 || i === dy.length - 1) {\n var x = parseFloat(dy[i]);\n\n if (x < 0) {\n label.push({\n value: dy[i],\n coord: [i, x],\n label: {\n position: 'bottom',\n show: true,\n fontSize: 16,\n color: '#fff'\n }\n });\n } else {\n label.push({\n value: dy[i],\n coord: [i, x]\n });\n }\n\n obj.push(0);\n obj.push(dy[i]);\n obj.push(dy[i]);\n obj.push(dy[i]);\n zt.push(obj);\n } else {\n var start = zt[i - 1][1];\n var val = parseFloat(dy[i]);\n var end = start + val;\n\n if (dy[i] < 0) {\n label.push({\n value: dy[i],\n coord: [i, end],\n label: {\n position: 'bottom',\n show: true,\n fontSize: 16,\n color: '#fff'\n }\n });\n } else {\n label.push({\n value: dy[i],\n coord: [i, end]\n });\n }\n\n obj.push(start);\n obj.push(end);\n obj.push(end);\n obj.push(end);\n zt.push(obj);\n }\n }\n\n console.log(document.getElementById('bridgeDiagram' + index));\n var chartDom = echarts.init(document.getElementById('bridgeDiagram' + index));\n var option = {\n title: {\n textStyle: {\n color: 'blue',\n fontWeight: 'bold'\n },\n subtextStyle: {\n color: '#aaa',\n fontStyle: 'italic'\n },\n left: 'center'\n },\n grid: {\n left: '6%',\n right: '6%',\n top: '6%',\n bottom: '14%'\n },\n xAxis: {\n data: data.map(function (item) {\n return item.targetName;\n }),\n axisLabel: {\n rotate: 45,\n margin: 15,\n textStyle: {\n fontSize: 16\n },\n interval: 0\n }\n },\n yAxis: {\n type: 'value',\n scale: true,\n axisLabel: {\n textStyle: {\n fontSize: 16\n }\n }\n },\n series: [{\n type: 'candlestick',\n //开始值、结束值、最大值、最小值\n //[[1,2,3,4]\n data: zt,\n itemStyle: {\n color: '#6379d6',\n color0: '#6379d6',\n borderWidth: 0\n },\n markPoint: {\n symbol: 'rect',\n //图形上面的小头隐藏\n symbolSize: 0.000000000000001,\n label: {\n show: true,\n color: '#fff',\n position: 'top',\n fontSize: 16,\n formatter: function formatter(res) {\n return res.data.value;\n }\n },\n data: label\n },\n emphasis: {\n itemStyle: {\n // color:'yellow',\n // color0:'green',\n borderWidth: 0\n }\n }\n }]\n };\n option && chartDom.setOption(option);\n },\n // 关闭事件\n handleClose: function handleClose() {\n this.visible = false;\n },\n add: function add(val, code) {\n this.parmas.targetId = val.targetId;\n this.parmas.enterpriseCode = code[1];\n this.visible = true;\n this.getBridgeList();\n },\n // 获取桥图数据\n getBridgeList: function getBridgeList() {\n var _this = this;\n\n bridgeDiagramAnalysis.getBridgeList(this.parmas, function (res) {\n console.log(res);\n _this.bridgeList = res.value;\n res.value.forEach(function (it, index) {\n _this.$nextTick(function () {\n _this.initCharts(it.bridgeFigureList, index);\n });\n });\n });\n }\n }\n};",null]}