将“农产品供应链智能分析平台”修改为“农产品供应链智能分析” - Follow Up Deployment
Browse files2 unmodified lines34567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544552 unmodified lines<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>苹果园面积监测系统 - 山东省</title><script src="https://cdn.tailwindcss.com"></script><link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"><style>@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700&display=swap');body {font-family: 'Noto Sans SC', sans-serif;background-color: #f5f7fa;}.map-container {background: linear-gradient(145deg, #e0e7ff, #ffffff);box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);}.data-card {backdrop-filter: blur(10px);background: rgba(255, 255, 255, 0.85);box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);transition: all 0.3s ease;}.data-card:hover {transform: translateY(-5px);box-shadow: 0 12px 36px rgba(31, 38, 135, 0.2);}.control-panel {background: rgba(255, 255, 255, 0.9);box-shadow: 0 8px 32px rgba(31, 38, 135, 0.1);}.timeline-slider {-webkit-appearance: none;height: 6px;background: linear-gradient(to right, #4ade80, #22c55e);border-radius: 10px;}.timeline-slider::-webkit-slider-thumb {-webkit-appearance: none;width: 20px;height: 20px;background: #fff;border: 3px solid #22c55e;border-radius: 50%;cursor: pointer;}.orchard-polygon {fill: #22c55e;opacity: 0.7;stroke: #166534;stroke-width: 0.5;transition: all 0.3s ease;}.orchard-polygon:hover {opacity: 0.9;stroke-width: 1.5;filter: drop-shadow(0 0 8px rgba(74, 222, 128, 0.6));}.chart-container {min-height: 200px;}@media (max-width: 768px) {.dashboard-layout {flex-direction: column;}.map-container {height: 400px;}}</style></head><body class="bg-gray-50"><div class="container mx-auto px-4 py-6"><!-- Header --><header class="flex flex-col md:flex-row justify-between items-start md:items-center mb-6"><div><h1 class="text-2xl md:text-3xl font-bold text-gray-800">苹果园面积监测系统</h1><p class="text-gray-600">山东省苹果种植大数据分析平台</p></div><div class="mt-4 md:mt-0 flex items-center space-x-4"><div class="flex items-center"><span class="w-3 h-3 rounded-full bg-green-500 mr-2"></span><span class="text-sm text-gray-600">实时数据更新</span></div><div class="text-sm text-gray-500"><i class="far fa-clock mr-1"></i><span id="current-time">2024-06-15 14:30:25</span></div></div></header><!-- Dashboard Content --><div class="dashboard-layout flex flex-col lg:flex-row gap-6"><!-- Left Control Panel --><div class="control-panel w-full lg:w-64 p-4 rounded-xl"><h2 class="text-lg font-semibold text-gray-800 mb-4 flex items-center"><i class="fas fa-sliders-h text-green-500 mr-2"></i>控制面板</h2><div class="space-y-6"><!-- Region Selector --><div><label class="block text-sm font-medium text-gray-700 mb-1">选择地区</label><div class="relative"><select class="block w-full pl-3 pr-10 py-2 text-base border border-gray-300 focus:outline-none focus:ring-2 focus:ring-green-500 focus:border-green-500 rounded-lg"><option>山东省 > 烟台市 > 栖霞市</option><option>山东省 > 烟台市 > 蓬莱区</option><option>山东省 > 威海市 > 荣成市</option><option>山东省 > 临沂市 > 沂水县</option><option>山东省 > 青岛市 > 莱西市</option></select></div></div><!-- Data Type Selector --><div><label class="block text-sm font-medium text-gray-700 mb-1">数据类型</label><div class="space-y-2"><div class="flex items-center"><input id="type-area" name="data-type" type="radio" class="h-4 w-4 text-green-600 focus:ring-green-500" checked><label for="type-area" class="ml-2 block text-sm text-gray-700">种植面积</label></div><div class="flex items-center"><input id="type-yield" name="data-type" type="radio" class="h-4 w-4 text-green-600 focus:ring-green-500"><label for="type-yield" class="ml-2 block text-sm text-gray-700">预计产��</label></div><div class="flex items-center"><input id="type-health" name="data-type" type="radio" class="h-4 w-4 text-green-600 focus:ring-green-500"><label for="type-health" class="ml-2 block text-sm text-gray-700">生长健康度</label></div></div></div><!-- Time Range Selector --><div><label class="block text-sm font-medium text-gray-700 mb-1">时间范围</label><div class="flex items-center justify-between text-xs text-gray-500 mb-1"><span>2020</span><span>2024</span></div><input type="range" min="2020" max="2024" value="2024" class="timeline-slider w-full"><div class="text-center mt-1"><span class="inline-block px-3 py-1 bg-green-100 text-green-800 rounded-full text-sm font-medium">当前: 2024年</span></div></div><!-- Additional Filters --><div><label class="block text-sm font-medium text-gray-700 mb-2">高级筛选</label><div class="space-y-3"><div><label class="flex items-center"><input type="checkbox" class="h-4 w-4 text-green-600 focus:ring-green-500 rounded"><span class="ml-2 text-sm text-gray-700">仅显示有机种植</span></label></div><div><label class="flex items-center"><input type="checkbox" class="h-4 w-4 text-green-600 focus:ring-green-500 rounded"><span class="ml-2 text-sm text-gray-700">仅显示认证果园</span></label></div></div></div><!-- Action Buttons --><div class="pt-2 space-y-2"><button class="w-full bg-green-600 hover:bg-green-700 text-white py-2 px-4 rounded-lg flex items-center justify-center"><i class="fas fa-sync-alt mr-2"></i>更新数据</button><button class="w-full bg-white border border-gray-300 hover:bg-gray-50 text-gray-700 py-2 px-4 rounded-lg flex items-center justify-center"><i class="fas fa-download mr-2"></i>导出报告</button></div></div></div><!-- Main Map Area --><div class="flex-1"><div class="map-container rounded-xl overflow-hidden shadow-lg h-full"><!-- Map Header --><div class="px-6 py-4 bg-white border-b border-gray-200 flex justify-between items-center"><h3 class="text-lg font-semibold text-gray-800 flex items-center"><i class="fas fa-map-marked-alt text-green-500 mr-2"></i>山东省苹果种植分布图</h3><div class="flex space-x-2"><button class="px-3 py-1 bg-gray-100 hover:bg-gray-200 text-gray-700 rounded-lg text-sm flex items-center"><i class="fas fa-layer-group mr-1"></i>图层</button><button class="px-3 py-1 bg-gray-100 hover:bg-gray-200 text-gray-700 rounded-lg text-sm flex items-center"><i class="fas fa-search mr-1"></i>搜索</button></div></div><!-- Map Visualization --><div class="relative" style="height: 500px;"><!-- This would be replaced with an actual map library like Leaflet or Mapbox in production --><svg id="map-svg" class="w-full h-full" viewBox="0 0 800 500" preserveAspectRatio="xMidYMid meet"><!-- Simplified representation of Shandong Peninsula --><path d="M100,100 L150,80 L200,90 L250,70 L300,100 L350,120 L400,150 L450,180 L500,200 L550,220 L600,230 L650,250 L700,270 L750,250 L700,200 L650,180 L600,150 L550,120 L500,100 L450,80 L400,70 L350,60 L300,50 L250,40 L200,30 L150,20 L100,30 Z"fill="#e0e7ff" stroke="#3b82f6" stroke-width="2"/><!-- Sample orchard polygons - in a real app these would be actual GIS data --><g id="orchards"><path class="orchard-polygon" d="M200,150 L220,140 L240,160 L230,180 L210,170 Z"/><path class="orchard-polygon" d="M300,200 L320,190 L340,210 L330,230 L310,220 Z"/><path class="orchard-polygon" d="M400,250 L420,240 L440,260 L430,280 L410,270 Z"/><path class="orchard-polygon" d="M500,300 L520,290 L540,310 L530,330 L510,320 Z"/><path class="orchard-polygon" d="M250,250 L270,240 L290,260 L280,280 L260,270 Z"/><path class="orchard-polygon" d="M350,300 L370,290 L390,310 L380,330 L360,320 Z"/><path class="orchard-polygon" d="M450,350 L470,340 L490,360 L480,380 L460,370 Z"/><path class="orchard-polygon" d="M150,200 L170,190 L190,210 L180,230 L160,220 Z"/><path class="orchard-polygon" d="M550,150 L570,140 L590,160 L580,180 L560,170 Z"/><path class="orchard-polygon" d="M650,200 L670,190 L690,210 L680,230 L660,220 Z"/></g><!-- City markers --><g id="city-markers"><g class="cursor-pointer" transform="translate(300, 150)"><circle cx="0" cy="0" r="8" fill="#ef4444" stroke="#fff" stroke-width="2"/><text x="0" y="25" text-anchor="middle" class="text-xs font-bold fill-red-600">烟台</text></g><g class="cursor-pointer" transform="translate(450, 100)"><circle cx="0" cy="0" r="8" fill="#3b82f6" stroke="#fff" stroke-width="2"/><text x="0" y="25" text-anchor="middle" class="text-xs font-bold fill-blue-600">威海</text></g><g class="cursor-pointer" transform="translate(200, 250)"><circle cx="0" cy="0" r="8" fill="#f59e0b" stroke="#fff" stroke-width="2"/><text x="0" y="25" text-anchor="middle" class="text-xs font-bold fill-yellow-600">临沂</text></g></g></svg><!-- Map controls overlay --><div class="absolute bottom-4 right-4 flex space-x-2"><button class="p-2 bg-white rounded-lg shadow-md hover:bg-gray-100"><i class="fas fa-plus text-gray-700"></i></button><button class="p-2 bg-white rounded-lg shadow-md hover:bg-gray-100"><i class="fas fa-minus text-gray-700"></i></button><button class="p-2 bg-white rounded-lg shadow-md hover:bg-gray-100"><i class="fas fa-crosshairs text-gray-700"></i></button></div></div></div></div><!-- Right Data Cards --><div class="w-full lg:w-80 space-y-4"><!-- Total Area Card --><div class="data-card p-5 rounded-xl"><div class="flex justify-between items-start mb-3"><h3 class="text-lg font-semibold text-gray-800">苹果种植总面积</h3><span class="px-2 py-1 bg-green-100 text-green-800 rounded-full text-xs font-medium"><i class="fas fa-tree mr-1"></i>2024年</span></div><div class="text-3xl font-bold text-gray-900 mb-2">5,820 平方公里</div><div class="flex items-center text-sm text-gray-600"><span class="text-green-500 mr-1">+2.3%</span><span>较去年增长</span></div><div class="mt-4 pt-4 border-t border-gray-100"><div class="flex justify-between text-sm"><span class="text-gray-600">烟台市</span><span class="font-medium">2,450 km²</span></div><div class="flex justify-between text-sm mt-1"><span class="text-gray-600">威海市</span><span class="font-medium">1,280 km²</span></div><div class="flex justify-between text-sm mt-1"><span class="text-gray-600">临沂市</span><span class="font-medium">980 km²</span></div></div></div><!-- City Ranking Card --><div class="data-card p-5 rounded-xl"><h3 class="text-lg font-semibold text-gray-800 mb-4">各市面积排名</h3><div class="chart-container"><!-- This would be replaced with a real chart library like Chart.js in production --><div class="space-y-3"><div><div class="flex justify-between mb-1"><span class="text-sm font-medium text-gray-700">烟台市</span><span class="text-sm text-gray-500">42.1%</span></div><div class="w-full bg-gray-200 rounded-full h-2.5"><div class="bg-green-500 h-2.5 rounded-full" style="width: 85%"></div></div></div><div><div class="flex justify-between mb-1"><span class="text-sm font-medium text-gray-700">威海市</span><span class="text-sm text-gray-500">22.0%</span></div><div class="w-full bg-gray-200 rounded-full h-2.5"><div class="bg-green-400 h-2.5 rounded-full" style="width: 45%"></div></div></div><div><div class="flex justify-between mb-1"><span class="text-sm font-medium text-gray-700">临沂市</span><span class="text-sm text-gray-500">16.8%</span></div><div class="w-full bg-gray-200 rounded-full h-2.5"><div class="bg-green-300 h-2.5 rounded-full" style="width: 35%"></div></div></div><div><div class="flex justify-between mb-1"><span class="text-sm font-medium text-gray-700">青岛市</span><span class="text-sm text-gray-500">8.2%</span></div><div class="w-full bg-gray-200 rounded-full h-2.5"><div class="bg-green-200 h-2.5 rounded-full" style="width: 20%"></div></div></div><div><div class="flex justify-between mb-1"><span class="text-sm font-medium text-gray-700">其他</span><span class="text-sm text-gray-500">10.9%</span></div><div class="w-full bg-gray-200 rounded-full h-2.5"><div class="bg-green-100 h-2.5 rounded-full" style="width: 15%"></div></div></div></div></div></div><!-- Trend Card --><div class="data-card p-5 rounded-xl"><h3 class="text-lg font-semibold text-gray-800 mb-4">面积年度变化趋势 (2020-2024)</h3><div class="chart-container"><!-- Simplified trend line visualization --><div class="relative h-40"><div class="absolute bottom-0 left-0 right-0 h-px bg-gray-200"></div><div class="absolute left-0 top-0 bottom-0 w-px bg-gray-200"></div><!-- Year markers --><div class="absolute bottom-0 left-0 text-xs text-gray-500">2020</div><div class="absolute bottom-0 left-1/4 text-xs text-gray-500">2021</div><div class="absolute bottom-0 left-2/4 text-xs text-gray-500">2022</div><div class="absolute bottom-0 left-3/4 text-xs text-gray-500">2023</div><div class="absolute bottom-0 right-0 text-xs text-gray-500">2024</div><!-- Trend line --><svg class="w-full h-full" viewBox="0 0 100 40" preserveAspectRatio="none"><path d="M0,30 L25,28 L50,26 L75,24 L100,22"fill="none"stroke="#22c55e"stroke-width="2"stroke-linecap="round"stroke-linejoin="round"/><!-- Data points --><circle cx="0" cy="30" r="3" fill="#22c55e"/><circle cx="25" cy="28" r="3" fill="#22c55e"/><circle cx="50" cy="26" r="3" fill="#22c55e"/><circle cx="75" cy="24" r="3" fill="#22c55e"/><circle cx="100" cy="22" r="3" fill="#22c55e"/></svg><!-- Value markers --><div class="absolute top-0 left-0 text-xs text-gray-600">5,420</div><div class="absolute top-6 left-1/4 text-xs text-gray-600">5,520</div><div class="absolute top-12 left-2/4 text-xs text-gray-600">5,620</div><div class="absolute top-18 left-3/4 text-xs text-gray-600">5,690</div><div class="absolute top-24 right-0 text-xs text-gray-600">5,820</div></div></div></div></div></div><!-- Footer --><footer class="mt-8 pt-6 border-t border-gray-200 text-center text-sm text-gray-500"><p>山东省农业大数据中心 © 2024 苹果产业监测系统 v2.1.5</p><p class="mt-1">数据更新于: 2024-06-15 14:00:00</p></footer></div><script>// Update current timefunction updateCurrentTime() {const now = new Date();const formattedTime = now.toLocaleString('zh-CN', {year: 'numeric',month: '2-digit',day: '2-digit',hour: '2-digit',minute: '2-digit',second: '2-digit',hour12: false}).replace(/\//g, '-');document.getElementById('current-time').textContent = formattedTime;}// Update time immediately and then every secondupdateCurrentTime();setInterval(updateCurrentTime, 1000);// Add hover effects to orchard polygonsdocument.querySelectorAll('.orchard-polygon').forEach(polygon => {polygon.addEventListener('mouseenter', function() {this.style.filter = 'drop-shadow(0 0 8px rgba(74, 222, 128, 0.6))';this.style.opacity = '0.9';this.style.strokeWidth = '1.5';});polygon.addEventListener('mouseleave', function() {this.style.filter = 'none';this.style.opacity = '0.7';this.style.strokeWidth = '0.5';});});// Simple animation for data cards on loaddocument.addEventListener('DOMContentLoaded', function() {const cards = document.querySelectorAll('.data-card');cards.forEach((card, index) => {setTimeout(() => {card.style.opacity = '1';card.style.transform = 'translateY(0)';}, index * 100);});});</script>2 unmodified lines34567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214222 unmodified lines<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>农产品供应链智能分析</title><script src="https://cdn.tailwindcss.com"></script><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/flatpickr/dist/flatpickr.min.css"><script src="https://cdn.jsdelivr.net/npm/flatpickr"></script><script src="https://cdn.jsdelivr.net/npm/chart.js"></script><script src="https://cdn.jsdelivr.net/npm/echarts@5.4.3/dist/echarts.min.js"></script><style>.map-container {background-image: linear-gradient(to bottom, #f0f9ff, #e0f2fe);position: relative;border-radius: 12px;overflow: hidden;}.flow-line {position: absolute;background: linear-gradient(to right, #3b82f6, #10b981);height: 3px;transform-origin: left center;animation: flow 3s infinite ease-in-out;box-shadow: 0 0 10px rgba(59, 130, 246, 0.7);}@keyframes flow {0% { opacity: 0.3; }50% { opacity: 1; }100% { opacity: 0.3; }}.city-dot {position: absolute;width: 12px;height: 12px;border-radius: 50%;background-color: #3b82f6;box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.3);}.info-popup {position: absolute;background-color: white;border-radius: 8px;padding: 12px;box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);z-index: 10;min-width: 150px;}.chart-container {background-color: white;border-radius: 12px;box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);}.select-container {background-color: white;border-radius: 8px;box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);}.dropdown {position: relative;display: inline-block;width: 100%;}.dropdown-content {display: none;position: absolute;background-color: white;width: 100%;box-shadow: 0 8px 16px rgba(0,0,0,0.1);z-index: 1;border-radius: 8px;max-height: 300px;overflow-y: auto;}.dropdown:hover .dropdown-content {display: block;}.multi-select-item {padding: 8px 12px;cursor: pointer;}.multi-select-item:hover {background-color: #f0f9ff;}.multi-select-item.selected {background-color: #3b82f6;color: white;}#sankey-chart, #bar-chart, #line-chart {width: 100%;height: 100%;}</style></head><body class="bg-gray-50 font-sans"><div class="container mx-auto px-4 py-6"><header class="mb-6"><h1 class="text-2xl font-bold text-gray-800">农产品供应链智能分析</h1><p class="text-gray-600">烟台苹果流通数据分析</p></header><div class="grid grid-cols-1 lg:grid-cols-12 gap-6"><!-- 左侧控制面板 --><div class="lg:col-span-3 space-y-4"><div class="select-container p-4"><h3 class="font-medium text-gray-700 mb-2">产区选择</h3><div class="dropdown"><button class="w-full px-4 py-2 text-left border border-gray-200 rounded-lg bg-white flex justify-between items-center"><span>烟台市</span><svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-gray-400" viewBox="0 0 20 20" fill="currentColor"><path fill-rule="evenodd" d="M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z" clip-rule="evenodd" /></svg></button><div class="dropdown-content mt-1"><div class="p-2 hover:bg-blue-50 cursor-pointer">烟台市</div><div class="p-2 hover:bg-blue-50 cursor-pointer">威海市</div><div class="p-2 hover:bg-blue-50 cursor-pointer">青岛市</div></div></div></div><div class="select-container p-4"><h3 class="font-medium text-gray-700 mb-2">销区选择</h3><div class="dropdown"><button class="w-full px-4 py-2 text-left border border-gray-200 rounded-lg bg-white flex justify-between items-center"><span>已选择 4 个城市</span><svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-gray-400" viewBox="0 0 20 20" fill="currentColor"><path fill-rule="evenodd" d="M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z" clip-rule="evenodd" /></svg></button><div class="dropdown-content mt-1 p-2"><div class="multi-select-item selected">北京市</div><div class="multi-select-item selected">上海市</div><div class="multi-select-item selected">广州市</div><div class="multi-select-item selected">成都市</div><div class="multi-select-item">深圳市</div><div class="multi-select-item">杭州市</div><div class="multi-select-item">武汉市</div><div class="multi-select-item">南京市</div></div></div></div><div class="select-container p-4"><h3 class="font-medium text-gray-700 mb-2">时间范围</h3><input type="text" id="date-range" class="w-full px-4 py-2 border border-gray-200 rounded-lg bg-white" placeholder="选择日期范围" readonly></div><div class="select-container p-4"><h3 class="font-medium text-gray-700 mb-2">数据概览</h3><div class="space-y-3"><div class="flex justify-between items-center"><span class="text-gray-600">总流通量</span><span class="font-medium">12.8 万吨</span></div><div class="flex justify-between items-center"><span class="text-gray-600">平均价格</span><span class="font-medium">¥6.5/公斤</span></div><div class="flex justify-between items-center"><span class="text-gray-600">流通效率</span><span class="font-medium">92.4%</span></div></div></div></div><!-- 中间地图区域 --><div class="lg:col-span-6"><div class="map-container h-full p-4"><div class="relative h-full w-full" id="china-map"><!-- 这里放置中国地图和流动线条 --><div class="city-dot" style="top: 30%; left: 40%;" data-city="烟台"></div><div class="city-dot" style="top: 25%; left: 50%;" data-city="北京"></div><div class="city-dot" style="top: 40%; left: 60%;" data-city="上海"></div><div class="city-dot" style="top: 60%; left: 55%;" data-city="广州"></div><div class="city-dot" style="top: 50%; left: 40%;" data-city="成都"></div><div class="flow-line" style="width: 150px; top: 32%; left: 42%; transform: rotate(15deg);"></div><div class="flow-line" style="width: 200px; top: 35%; left: 42%; transform: rotate(25deg);"></div><div class="flow-line" style="width: 180px; top: 40%; left: 42%; transform: rotate(35deg);"></div><div class="flow-line" style="width: 220px; top: 45%; left: 42%; transform: rotate(45deg);"></div><div class="info-popup" style="top: 42%; left: 62%;"><div class="font-medium text-gray-800">上海市</div><div class="text-blue-600">流入总量: 2.5万吨</div><div class="text-sm text-gray-500">同比增长: +12.3%</div></div></div></div></div><!-- 右侧数据可视化 --><div class="lg:col-span-3 space-y-4"><div class="chart-container p-4 h-64"><h3 class="font-medium text-gray-700 mb-2">烟台苹果-主要流向分析</h3><div id="sankey-chart"></div></div><div class="chart-container p-4 h-64"><h3 class="font-medium text-gray-700 mb-2">TOP 10 销往城市</h3><div id="bar-chart"></div></div><div class="chart-container p-4 h-64"><h3 class="font-medium text-gray-700 mb-2">价格关联性分析</h3><div id="line-chart"></div></div></div></div></div><script>// 初始化日期选择器flatpickr("#date-range", {mode: "range",defaultDate: ["2024-01-01", "2024-12-31"],locale: "zh"});// 多选功能document.querySelectorAll('.multi-select-item').forEach(item => {item.addEventListener('click', function() {this.classList.toggle('selected');updateSelectedCount();});});function updateSelectedCount() {const selectedCount = document.querySelectorAll('.multi-select-item.selected').length;document.querySelector('.dropdown button span').textContent = `已选择 ${selectedCount} 个城市`;}// 初始化图表document.addEventListener('DOMContentLoaded', function() {// Sankey 图const sankeyChart = echarts.init(document.getElementById('sankey-chart'));const sankeyOption = {series: [{type: 'sankey',layout: 'none',data: [{name: '烟台市'},{name: '北京市'},{name: '上海市'},{name: '广州市'},{name: '成都市'}],links: [{source: '烟台市', target: '北京市', value: 4.2},{source: '烟台市', target: '上海市', value: 2.5},{source: '烟台市', target: '广州市', value: 3.1},{source: '烟台市', target: '成都市', value: 1.8}],label: {color: '#4b5563'},itemStyle: {color: '#3b82f6'},lineStyle: {color: 'source',opacity: 0.6}}]};sankeyChart.setOption(sankeyOption);// 柱状图const barChart = echarts.init(document.getElementById('bar-chart'));const barOption = {tooltip: {trigger: 'axis',axisPointer: {type: 'shadow'}},grid: {left: '3%',right: '4%',bottom: '3%',containLabel: true},xAxis: {type: 'value',axisLine: {lineStyle: {color: '#9ca3af'}},axisLabel: {color: '#6b7280'}},yAxis: {type: 'category',data: ['北京市', '上海市', '广州市', '成都市', '深圳市', '杭州市', '武汉市', '南京市', '重庆市', '天津市'],axisLine: {lineStyle: {color: '#9ca3af'}},axisLabel: {color: '#6b7280'}},series: [{name: '流通量(万吨)',type: 'bar',data: [4.2, 2.5, 3.1, 1.8, 1.2, 0.9, 0.7, 0.6, 0.5, 0.4],itemStyle: {color: function(params) {const colorList = ['#3b82f6', '#60a5fa', '#93c5fd', '#bfdbfe'];return colorList[params.dataIndex % colorList.length];}}}]};barChart.setOption(barOption);// 折线图const lineChart = echarts.init(document.getElementById('line-chart'));const lineOption = {tooltip: {trigger: 'axis'},legend: {data: ['烟台市(产地)', '北京市', '上海市'],textStyle: {color: '#4b5563'}},grid: {left: '3%',right: '4%',bottom: '3%',containLabel: true},xAxis: {type: 'category',boundaryGap: false,data: ['1月', '2月', '3月', '4月', '5月', '6月', '7月', '8月', '9月', '10月', '11月', '12月'],axisLine: {lineStyle: {color: '#9ca3af'}},axisLabel: {color: '#6b7280'}},yAxis: {type: 'value',axisLine: {lineStyle: {color: '#9ca3af'}},axisLabel: {color: '#6b7280',formatter: '{value} ¥'}},series: [{name: '烟台市(产地)',type: 'line',data: [5.2, 5.5, 5.8, 6.2, 6.5, 6.3, 6.0, 5.8, 5.5, 5.2, 5.0, 4.8],itemStyle: {color: '#3b82f6'},lineStyle: {width: 3}},{name: '北京市',type: 'line',data: [6.5, 6.8, 7.0, 7.2, 7.5, 7.3, 7.0, 6.8, 6.5, 6.2, 6.0, 5.8],itemStyle: {color: '#10b981'},lineStyle: {width: 3}},{name: '上海市',type: 'line',data: [6.8, 7.0, 7.2, 7.5, 7.8, 7.5, 7.2, 7.0, 6.8, 6.5, 6.2, 6.0],itemStyle: {color: '#f59e0b'},lineStyle: {width: 3}}]};lineChart.setOption(lineOption);// 响应式调整图表大小window.addEventListener('resize', function() {sankeyChart.resize();barChart.resize();lineChart.resize();});});</script>
index.html+353-386