| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238 |
- <template>
- <Layout>
- <template #left>
- <div class="left">
- <Box
- :width="1370"
- :height="406"
- :name="'区域流量'"
- class="left-top"
- >
- <Echart
- v-for="(item, index) in leftContent.tCharts"
- :key="index"
- :option="item.option"
- />
- </Box>
- <div class="left-bottom">
- <template
- v-for="(item, index) in leftContent.bCharts"
- :key="index"
- >
- <Box
- :width="438"
- :height="400"
- :name="item.name"
- >
- <Echart
- v-if="!item.isList"
- :option="item.option"
- />
- <div
- v-else
- class="lineList"
- >
- <div
- v-for="line, i in item.list"
- :key="i"
- class="line"
- >
- <div
- :class="'index' + i"
- class="index"
- >
- {{ i + 1 }}
- </div>
- <div class="name">
- {{ line.name }}
- </div>
- <div class="content">
- {{ line.startStation }} → {{ line.endStation }}
- </div>
- </div>
- </div>
- </Box>
- </template>
- </div>
- </div>
- </template>
- <template #center>
- <div>777</div>
- </template>
- <template #right>
- <div class="right">
- <div class="right-top">
- <Box
- :width="460"
- :height="406"
- :name="'客运量排名'"
- >
- <Echart :option="rightContent.top1" />
- </Box>
- <Box
- :width="900"
- :height="406"
- :name="'运能分析'"
- >
- <Echart :option="rightContent.top2" />
- </Box>
- </div>
- <Box
- class="right-center"
- :width="1370"
- :height="406"
- :name="'今日客流'"
- >
- <Echart :option="rightContent.center" />
- </Box>
- <Box
- class="right-bottom"
- :width="1370"
- :height="406"
- :name="'本月客流'"
- >
- <Echart :option="rightContent.bottom" />
- </Box>
- </div>
- </template>
- </Layout>
- </template>
- <script setup lang='ts'>
- import Layout from '@/components/layout.vue'
- import Box from '@/components/box.vue'
- import Echart from '@/components/chart.vue'
- import { ref } from 'vue'
- import { graphic } from 'echarts'
- const leftContent = ref({
- tCharts: [
- {
- name: '客流线路分布',
- option: {
- title: {
- text: '客流总数/万人', // 图标内容文本
- subtext: '10',
- left: 'center', // 图标内容水平居中
- top: 'center', // 图标内容垂直居中
- // 文本样式
- textStyle: {
- color: '#fff', // 图标内容文字颜色
- fontSize: '18px', // 图标内容文字大小
- fontWeight: 'normal'
- },
- subtextStyle: {
- color: '#fff', // 图标内容文字颜色
- fontSize: '18px', // 图标内容文字大小
- fontWeight: 'normal'
- }
- },
- grid: {
- containLabel: true
- },
- // 图表图例
- legend: {
- show: true,
- type: 'scroll',
- orient: 'vertical', // 图例排列方向
- icon: 'circle', // 图例样式为圆形
- itemWidth: 10, // 图例图形的宽度
- itemHeight: 16, // 图例图形的高度
- itemGap: 10, // 图例项之间的间隔
- left: 10, // 图例距离容器右侧的距离
- top: 'center', // 图例垂直居中
- textStyle: {
- color: 'white', // 图例文字颜色
- fontSize: 20
- }
- },
- // color: [ '#6386e0', '#fb9a55', '#6bd98d', '#8dfd15', '#6bd98d', '#fff' ],
- series: [
- {
- type: 'pie', // 图表类型为饼图
- radius: [ '55%', '75%' ], // 控制内外圆环的半径,30%代表内圆,60%代表外圆
- avoidLabelOverlap: true, // 是否启用防止标签重叠策略
- showEmptyCircle: true, // 是否在无数据的日候显示一个占位圆
- label: {
- show: true,
- formatter: '{d}%',
- color: 'white'
- },
- data: [
- { key: 2, name: '雨城区', value: 30619 },
- { key: 2, name: '芦山县', value: 5921 },
- { key: 2, name: '名山县', value: 1153 },
- { key: 2, name: '天全县', value: 266 },
- { key: 2, name: '宝兴县', value: 87 },
- { key: 2, name: '汉源县', value: 999 },
- { key: 2, name: '石棉县', value: 5921 }
- ]
- }
- ]
- }
- },
- {
- name: '客流线路分布',
- option: {
- grid: {
- containLabel: true
- },
- tooltip: {
- trigger: 'axis',
- axisPointer: {
- type: 'shadow'
- }
- },
- legend: {
- top: 10,
- right: '40%',
- itemWidth: 18,
- itemHeight: 18,
- itemGap: 30,
- textStyle: {
- fontSize: 18,
- color: '#C9D2FA'
- }
- },
- xAxis: {
- // name: "班级",
- triggerEvent: true,
- data: [
- '雨城区',
- '芦山县',
- '名山县',
- '天全县',
- '宝兴县',
- '汉源县'
- ],
- axisLabel: {
- interval: 0,
- show: true,
- fontSize: 18,
- color: '#C9D2FA'
- },
- axisLine: {
- show: false,
- lineStyle: {
- show: false,
- color: '#F3F3F3',
- width: 2
- }
- },
- axisTick: {
- show: false
- }
- },
- yAxis: [
- {
- splitNumber: 2,
- axisLabel: {
- show: true,
- fontSize: 18,
- color: '#C9D2FA'
- },
- axisLine: {
- show: false
- },
- axisTick: {
- show: false
- },
- splitLine: {
- lineStyle: {
- type: 'dashed',
- color: '#3E4A82'
- }
- }
- }
- ],
- series: [
- {
- name: '客流量',
- type: 'bar',
- silent: true,
- itemStyle: {
- normal: {
- color: new graphic.LinearGradient(
- 0,
- 0,
- 0,
- 1,
- [ {
- offset: 0,
- color: '#00fdff'// 0% 处的颜色
- },
- {
- offset: 1,
- color: '#00aaff08' // 100% 处的颜色
- }
- ],
- false
- )
- }
- },
- barWidth: 30,
- data: [ 200, 108, 200, 40, 210, 100 ]
- }
- ]
- }
- }
- ],
- bCharts: [
- {
- name: '客流线路分布',
- option: {
- grid: {
- containLabel: true
- },
- // 图表图例
- legend: {
- show: true,
- type: 'scroll',
- orient: 'horizontal', // 图例排列方向
- icon: 'circle', // 图例样式为圆形
- itemWidth: 10, // 图例图形的宽度
- itemHeight: 16, // 图例图形的高度
- itemGap: 10, // 图例项之间的间隔
- left: 'center', // 图例距离容器右侧的距离
- bottom: 0, // 图例垂直居中
- textStyle: {
- color: 'white', // 图例文字颜色
- fontSize: 20
- }
- },
- // color: [ '#6386e0', '#fb9a55', '#6bd98d', '#8dfd15', '#6bd98d', '#fff' ],
- series: [
- {
- type: 'pie', // 图表类型为饼图
- radius: '60%', // 控制内外圆环的半径,30%代表内圆,60%代表外圆
- avoidLabelOverlap: true, // 是否启用防止标签重叠策略
- showEmptyCircle: true, // 是否在无数据的时候显示一个占位圆
- label: {
- show: true,
- formatter: '{b}: {c}条',
- color: 'white'
- },
- data: [
- { key: 2, name: '常规', value: 130 },
- { key: 2, name: '快线', value: 50 },
- { key: 2, name: '特色线路', value: 50 }
- ]
- }
- ]
- }
- },
- {
- name: '消费类型',
- option: {
- title: {
- text: '客流总数/万人', // 图标内容文本
- subtext: '10',
- left: 'center', // 图标内容水平居中
- top: 'center', // 图标内容垂直居中
- // 文本样式
- textStyle: {
- color: '#fff', // 图标内容文字颜色
- fontSize: '18px', // 图标内容文字大小
- fontWeight: 'normal'
- },
- subtextStyle: {
- color: '#fff', // 图标内容文字颜色
- fontSize: '18px', // 图标内容文字大小
- fontWeight: 'normal'
- }
- },
- grid: {
- containLabel: true
- },
- // 图表图例
- legend: {
- show: true,
- type: 'scroll',
- orient: 'horizontal', // 图例排列方向
- icon: 'circle', // 图例样式为圆形
- itemWidth: 10, // 图例图形的宽度
- itemHeight: 16, // 图例图形的高度
- itemGap: 10, // 图例项之间的间隔
- left: 'center', // 图例距离容器右侧的距离
- bottom: 0, // 图例垂直居中
- textStyle: {
- color: 'white', // 图例文字颜色
- fontSize: 20
- }
- },
- // color: [ '#6386e0', '#fb9a55', '#6bd98d', '#8dfd15', '#6bd98d', '#fff' ],
- series: [
- {
- type: 'pie', // 图表类型为饼图
- radius: [ '55%', '75%' ], // 控制内外圆环的半径,30%代表内圆,60%代表外圆
- avoidLabelOverlap: true, // 是否启用防止标签重叠策略
- showEmptyCircle: true, // 是否在无数据的时候显示一个占位圆
- label: {
- show: true,
- formatter: '{d}%',
- color: 'white'
- },
- data: [
- { key: 2, name: '老年卡', value: 180 },
- { key: 2, name: '电子钱包', value: 50 },
- { key: 2, name: '现金', value: 30 },
- { key: 2, name: '学生卡', value: 20 },
- { key: 2, name: '免费', value: 10 }
- ]
- }
- ]
- }
- },
- {
- name: '乘距分布',
- option: {
- grid: {
- containLabel: true
- },
- // 图表图例
- legend: {
- show: true,
- type: 'scroll',
- orient: 'horizontal', // 图例排列方向
- icon: 'circle', // 图例样式为圆形
- itemWidth: 10, // 图例图形的宽度
- itemHeight: 16, // 图例图形的高度
- itemGap: 10, // 图例项之间的间隔
- left: 'center', // 图例距离容器右侧的距离
- bottom: 0, // 图例垂直居中
- textStyle: {
- color: 'white', // 图例文字颜色
- fontSize: 20
- }
- },
- // color: [ '#6386e0', '#fb9a55', '#6bd98d', '#8dfd15', '#6bd98d', '#fff' ],
- series: [
- {
- type: 'pie', // 图表类型为饼图
- radius: '60%', // 控制内外圆环的半径,30%代表内圆,60%代表外圆
- avoidLabelOverlap: true, // 是否启用防止标签重叠策略
- showEmptyCircle: true, // 是否在无数据的时候显示一个占位圆
- label: {
- show: true,
- formatter: '{b}: {c}万人次',
- color: 'white'
- },
- data: [
- { key: 2, name: '2km', value: 5 },
- { key: 2, name: '2-5km', value: 3 },
- { key: 2, name: '5-10km', value: 2 },
- { key: 2, name: '>10km', value: 1 }
- ]
- }
- ]
- }
- },
- {
- name: '通勤时间占比',
- option: {
- grid: {
- containLabel: true
- },
- // 图表图例
- legend: {
- show: true,
- type: 'scroll',
- orient: 'horizontal', // 图例排列方向
- icon: 'circle', // 图例样式为圆形
- itemWidth: 10, // 图例图形的宽度
- itemHeight: 16, // 图例图形的高度
- itemGap: 10, // 图例项之间的间隔
- left: 'center', // 图例距离容器右侧的距离
- bottom: 0, // 图例垂直居中
- textStyle: {
- color: 'white', // 图例文字颜色
- fontSize: 20
- }
- },
- // color: [ '#6386e0', '#fb9a55', '#6bd98d', '#8dfd15', '#6bd98d', '#fff' ],
- series: [
- {
- type: 'pie', // 图表类型为饼图
- radius: '60%', // 控制内外圆环的半径,30%代表内圆,60%代表外圆
- avoidLabelOverlap: true, // 是否启用防止标签重叠策略
- showEmptyCircle: true, // 是否在无数据的时候显示一个占位圆
- label: {
- show: true,
- formatter: '{b}: {c}条',
- color: 'white'
- },
- data: [
- { key: 2, name: '<30分钟', value: 130 },
- { key: 2, name: '30-60分钟', value: 50 },
- { key: 2, name: '60-70分钟', value: 50 },
- { key: 2, name: '>90分钟', value: 50 }
- ]
- }
- ]
- }
- },
- {
- name: '换乘次数占比',
- option: {
- grid: {
- containLabel: true
- },
- // 图表图例
- legend: {
- show: true,
- type: 'scroll',
- orient: 'horizontal', // 图例排列方向
- icon: 'circle', // 图例样式为圆形
- itemWidth: 10, // 图例图形的宽度
- itemHeight: 16, // 图例图形的高度
- itemGap: 10, // 图例项之间的间隔
- left: 'center', // 图例距离容器右侧的距离
- bottom: 0, // 图例垂直居中
- textStyle: {
- color: 'white', // 图例文字颜色
- fontSize: 20
- }
- },
- series: [
- {
- type: 'pie', // 图表类型为饼图
- radius: '60%', // 控制内外圆环的半径,30%代表内圆,60%代表外圆
- avoidLabelOverlap: true, // 是否启用防止标签重叠策略
- showEmptyCircle: true, // 是否在无数据的时候显示一个占位圆
- label: {
- show: true,
- formatter: '{b}: {c}人次',
- color: 'white'
- },
- data: [
- { key: 2, name: '0次', value: 130 },
- { key: 2, name: '1次', value: 30 },
- { key: 2, name: '2次', value: 20 },
- { key: 2, name: '3次以上', value: 10 }
- ]
- }
- ]
- }
- },
- {
- name: '热门出行线路排名',
- isList: true,
- list: [
- {
- name: '1号',
- startStation: '北京',
- endStation: '上海'
- },
- {
- name: '2号',
- startStation: '北京',
- endStation: '上海'
- },
- {
- name: '3号',
- startStation: '北京',
- endStation: '上海'
- },
- {
- name: '4号',
- startStation: '北京',
- endStation: '上海'
- },
- {
- name: '5号',
- startStation: '北京',
- endStation: '上海'
- }
- ]
- }
- ]
- })
- const rightContent = ref({
- top1: {
- grid: {
- containLabel: true,
- bottom: '0'
- },
- tooltip: {
- trigger: 'axis',
- axisPointer: {
- type: 'shadow'
- }
- },
- legend: {
- top: 10,
- right: '40%',
- itemWidth: 18,
- itemHeight: 18,
- itemGap: 30,
- textStyle: {
- fontSize: 18,
- color: '#C9D2FA'
- }
- },
- xAxis: {
- type: 'value',
- splitLine: {
- show: true,
- lineStyle: {
- color: '#232e32'
- }
- },
- axisLine: {
- show: false
- },
- axisLabel: {
- show: true,
- textStyle: {
- color: '#fff',
- fontSize: 16
- }
- },
- data: [ '1路', '2路', '3路', '4路', '5路' ],
- axisTick: {
- show: false
- }
- },
- yAxis: [ {
- type: 'category',
- inverse: true,
- data: [ '1路', '2路', '3路', '4路', '5路' ],
- axisLine: {
- show: false
- },
- axisTick: {
- show: false
- },
- axisLabel: {
- // "margin": 10,
- textStyle: {
- color: '#fff',
- fontSize: 16
- }
- }
- } ],
- series: [ { // 内
- type: 'bar',
- barWidth: 30,
- barGap: 0.5,
- name: '客流量',
- label: {
- show: true,
- position: 'right',
- textStyle: {
- color: '#fff',
- fontSize: 16,
- padding: [ 0, 10 ],
- rich: {
- a: {
- color: '#fff',
- fontSize: 36
- }
- }
- }
- },
- legendHoverLink: false,
- silent: true,
- itemStyle: {
- color: new graphic.LinearGradient(
- 0,
- 0,
- 1,
- 1,
- [ {
- offset: 0,
- color: '#0f224066'// 0% 处的颜色
- },
- {
- offset: 1,
- color: '#625fdf' // 100% 处的颜色
- }
- ],
- false
- )
- },
- data: [ '80', '70', '60', '50', '40' ]
- }
- ]
- },
- top2: {
- grid: {
- containLabel: true,
- right: 30,
- left: 50
- },
- legend: {
- show: true,
- left: 'center',
- top: '10',
- icon: 'stack',
- itemWidth: 15,
- itemHeight: 10,
- textStyle: {
- color: '#646464',
- fontSize: 18
- }
- },
- xAxis: [ {
- type: 'category',
- axisLine: {
- show: false
- },
- axisLabel: {
- color: '#fff',
- fontSize: 18
- // formatter: (value: number) => format( 1'时')
- },
- splitLine: {
- show: false
- },
- axisTick: {
- show: false
- },
- data: [ '1时', '2时', '3时', '4时', '5时', '6时', '7时', '8时', '9时', '10时', '11时', '12时' ]
- } ],
- yAxis: [ {
- name: '人数/人',
- nameLocation: 'center',
- nameGap: 50,
- nameTextStyle: {
- color: '#fff',
- fontSize: 18
- },
- padding: 5,
- // max: 1000,
- splitLine: {
- show: true,
- lineStyle: {
- color: '#A1A7B3'
- // type: 'dashed'
- }
- },
- axisLine: {
- show: false
- },
- axisLabel: {
- show: true,
- margin: 10,
- textStyle: {
- color: '#fff'
- }
- },
- axisTick: {
- show: false
- }
- }
- ],
- series: [ {
- name: '客流',
- type: 'line',
- smooth: true,
- symbolSize: 0,
- itemStyle: {
- normal: {
- // color: '#4293FD',
- lineStyle: {
- // color: '#FFD35D',
- width: 1
- }
- }
- },
- areaStyle: {
- normal: {
- color: new graphic.LinearGradient(0, 0, 0, 1, [
- {
- offset: 0,
- color: '#FFD35D66'
- },
- {
- offset: 0.5,
- color: '#7ec2f366'
- },
- {
- offset: 1,
- color: '#189066'
- }
- ], false)
- }
- },
- data: [ 120, 132, 101, 134, 90, 230, 210, 182, 191, 234, 290, 330 ]
- },
- {
- name: '运能',
- type: 'line',
- smooth: true,
- symbolSize: 0,
- itemStyle: {
- normal: {
- // color: '#23D0C4',
- lineStyle: {
- // color: '#23D0C4',
- width: 1
- }
- }
- },
- areaStyle: {
- normal: {
- color: new graphic.LinearGradient(0, 0, 0, 1, [
- {
- offset: 0,
- color: '#6A5BF066'
- },
- {
- offset: 0.5,
- color: '#7ec2f366'
- },
- {
- offset: 1,
- color: '#1890ff66'
- }
- ], false)
- }
- },
- data: [ 220, 182, 191, 234, 290, 330, 310, 201, 154, 190, 330, 410 ]
- }
- ],
- dataZoom: {}
- },
- center: {
- grid: {
- containLabel: true,
- right: 30,
- left: 50
- },
- legend: {
- show: true,
- left: 'center',
- top: '10',
- icon: 'stack',
- itemWidth: 15,
- itemHeight: 10,
- textStyle: {
- color: '#646464',
- fontSize: 18
- }
- },
- xAxis: [ {
- type: 'category',
- axisLine: {
- show: false
- },
- axisLabel: {
- color: '#fff',
- fontSize: 18
- // formatter: (value: number) => format( 1'时')
- },
- splitLine: {
- show: false
- },
- axisTick: {
- show: false
- },
- data: [ '1时', '2时', '3时', '4时', '5时', '6时', '7时', '8时', '9时', '10时', '11时', '12时' ]
- } ],
- yAxis: [ {
- name: '人数/人',
- nameLocation: 'center',
- nameGap: 50,
- nameTextStyle: {
- color: '#fff',
- fontSize: 18
- },
- padding: 5,
- // max: 1000,
- splitLine: {
- show: true,
- lineStyle: {
- color: '#A1A7B3'
- // type: 'dashed'
- }
- },
- axisLine: {
- show: false
- },
- axisLabel: {
- show: true,
- margin: 10,
- textStyle: {
- color: '#fff'
- }
- },
- axisTick: {
- show: false
- }
- }
- ],
- series: [ {
- name: '当前',
- type: 'line',
- smooth: true,
- symbolSize: 0,
- itemStyle: {
- normal: {
- // color: '#4293FD',
- lineStyle: {
- // color: '#4293FD',
- width: 1
- }
- }
- },
- areaStyle: {
- normal: {
- color: new graphic.LinearGradient(0, 0, 0, 1, [
- {
- offset: 0,
- color: '#FFD35D66'
- },
- {
- offset: 0.5,
- color: '#7ec2f366'
- },
- {
- offset: 1,
- color: '#189066'
- }
- ], false)
- }
- },
- data: [ 120, 132, 101, 134, 90, 230, 210, 182, 191, 234, 290, 330 ]
- },
- {
- name: '环比',
- type: 'line',
- smooth: true,
- symbolSize: 0,
- itemStyle: {
- normal: {
- // color: '#23D0C4',
- lineStyle: {
- // color: '#23D0C4',
- width: 1
- }
- }
- },
- areaStyle: {
- normal: {
- color: new graphic.LinearGradient(0, 0, 0, 1, [
- {
- offset: 0,
- color: '#6A5BF066'
- },
- {
- offset: 0.5,
- color: '#7ec2f366'
- },
- {
- offset: 1,
- color: '#1890ff66'
- }
- ], false)
- }
- },
- data: [ 220, 182, 191, 234, 290, 330, 310, 201, 154, 190, 330, 410 ]
- },
- {
- name: '同比',
- type: 'line',
- smooth: true,
- symbolSize: 0,
- itemStyle: {
- normal: {
- // color: '#23D0C4',
- lineStyle: {
- // color: '#23D0C4',
- width: 1
- }
- }
- },
- areaStyle: {
- normal: {
- color: new graphic.LinearGradient(0, 0, 0, 1, [
- {
- offset: 0,
- color: '#2ECC7166'
- },
- {
- offset: 0.5,
- color: '#7ec2f366'
- },
- {
- offset: 1,
- color: '#1890ff66'
- }
- ], false)
- }
- },
- data: [ 220, 182, 191, 234, 290, 330, 310, 201, 154, 190, 330, 410 ]
- }
- ],
- dataZoom: {}
- },
- bottom: {
- grid: {
- containLabel: true,
- right: 30,
- left: 50
- },
- legend: {
- show: true,
- left: 'center',
- top: '10',
- icon: 'stack',
- itemWidth: 15,
- itemHeight: 10,
- textStyle: {
- color: '#646464',
- fontSize: 18
- }
- },
- xAxis: [ {
- type: 'category',
- axisLine: {
- show: false
- },
- axisLabel: {
- color: '#fff',
- fontSize: 18
- // formatter: (value: number) => format( 1'时')
- },
- splitLine: {
- show: false
- },
- axisTick: {
- show: false
- },
- data: [ '1日', '2日', '3日', '4日', '5日', '6日', '7日', '8日', '9日', '10日', '11日', '12日' ]
- } ],
- yAxis: [ {
- name: '人数/人',
- nameLocation: 'center',
- nameGap: 50,
- nameTextStyle: {
- color: '#fff',
- fontSize: 18
- },
- padding: 5,
- // max: 1000,
- splitLine: {
- show: true,
- lineStyle: {
- color: '#A1A7B3'
- // type: 'dashed'
- }
- },
- axisLine: {
- show: false
- },
- axisLabel: {
- show: true,
- margin: 10,
- textStyle: {
- color: '#fff'
- }
- },
- axisTick: {
- show: false
- }
- }
- ],
- series: [ {
- name: '当前',
- type: 'line',
- smooth: true,
- symbolSize: 0,
- itemStyle: {
- normal: {
- // color: '#4293FD',
- lineStyle: {
- // color: '#4293FD',
- width: 1
- }
- }
- },
- areaStyle: {
- normal: {
- color: new graphic.LinearGradient(0, 0, 0, 1, [
- {
- offset: 0,
- color: '#FFD35D66'
- },
- {
- offset: 0.5,
- color: '#7ec2f366'
- },
- {
- offset: 1,
- color: '#189066'
- }
- ], false)
- }
- },
- data: [ 120, 132, 101, 134, 90, 230, 210, 182, 191, 234, 290, 330 ]
- },
- {
- name: '环比',
- type: 'line',
- smooth: true,
- symbolSize: 0,
- itemStyle: {
- normal: {
- // color: '#23D0C4',
- lineStyle: {
- // color: '#23D0C4',
- width: 1
- }
- }
- },
- areaStyle: {
- normal: {
- color: new graphic.LinearGradient(0, 0, 0, 1, [
- {
- offset: 0,
- color: '#6A5BF066'
- },
- {
- offset: 0.5,
- color: '#7ec2f366'
- },
- {
- offset: 1,
- color: '#1890ff66'
- }
- ], false)
- }
- },
- data: [ 220, 182, 191, 234, 290, 330, 310, 201, 154, 190, 330, 410 ]
- },
- {
- name: '同比',
- type: 'line',
- smooth: true,
- symbolSize: 0,
- itemStyle: {
- normal: {
- // color: '#23D0C4',
- lineStyle: {
- // color: '#23D0C4',
- width: 1
- }
- }
- },
- areaStyle: {
- normal: {
- color: new graphic.LinearGradient(0, 0, 0, 1, [
- {
- offset: 0,
- color: '#2ECC7166'
- },
- {
- offset: 0.5,
- color: '#7ec2f366'
- },
- {
- offset: 1,
- color: '#1890ff66'
- }
- ], false)
- }
- },
- data: [ 220, 182, 191, 234, 290, 330, 310, 201, 154, 190, 330, 410 ]
- }
- ],
- dataZoom: {}
- }
- })
- </script>
- <style lang="scss" scoped>
- .left {
- &-top {
- :deep(.box-content) {
- display: flex;
- justify-content: space-between;
- }
- }
- &-bottom {
- display: flex;
- justify-content: space-between;
- flex-wrap: wrap;
- gap: 10px;
- :deep(.box-content) {
- position: relative;
- }
- .lineList {
- padding: 25px;
- display: flex;
- flex-wrap: wrap;
- gap: 15px;
- height: 335px;
- overflow: scroll;
- .line {
- width: 100%;
- display: flex;
- align-items: center;
- font-size: 24px;
- color: #fff;
- .index {
- width: 45px;
- height: 45px;
- line-height: 45px;
- text-align: center;
- border-radius: 50%;
- border: 1px solid #00FFFF;
- background-color: rgba(0, 191, 191, 0.3);
- &.index0 {
- border: 1px solid #FFFF00;
- background-color: rgba(255, 255, 0, 0.3);
- }
- &.index1 {
- border: 1px solid #F2F2F2;
- background: rgba(242, 242, 242, 0.298);
- }
- &.index2 {
- border: 1px solid #FAAD0E;
- background: rgba(250, 173, 14, 0.298);
- }
- }
- .name {
- margin: 0 50px 0 15px;
- text-shadow: 1px 1px 5px rgba(0, 255, 255, 0.8);
- }
- .content {
- color: #80FFFF;
- font-size: 20px;
- }
- }
- }
- }
- }
- .right {
- &-top {
- display: flex;
- gap: 10px;
- // justify-content: space-between;
- }
- }
- </style>
|