index.vue 9.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446
  1. <template>
  2. <div class="main">
  3. <el-row>
  4. <el-col :span="24" class="animate__animated animate__backInRight" v-loading="loading">
  5. <div class="head clearfix">
  6. <h1 class="pulll_left">产业孵化大脑</h1>
  7. <div class="menu menu2 pulll_left">
  8. <ul>
  9. <li><a @click="toChange" href="#">返回</a></li>
  10. <li><a @click="selectMenu('four')" href="#">信息检索</a></li>
  11. <li><a @click="selectMenu('five')" href="#">双创活动</a></li>
  12. <li><a @click="selectMenu('six')" href="#">中试平台</a></li>
  13. <li><a @click="selectMenu('seven')" href="#">服务支撑</a></li>
  14. <li><a @click="selectMenu('eight')" href="#">产业集群</a></li>
  15. <li><a @click="selectMenu('nine')" href="#">成果展示</a></li>
  16. <li><a @click="selectMenu('ten')" href="#">信息库</a></li>
  17. <li><a @click="selectMenu('eleven')" href="#">孵化器</a></li>
  18. </ul>
  19. </div>
  20. <div class="time">{{ formattedTime }}</div>
  21. </div>
  22. <div class="mainbox">
  23. <el-row :gutter="20">
  24. <el-col :span="6">
  25. <div class="center_1">
  26. <div class="box">
  27. <div class="tit">各类用户人数</div>
  28. <div class="boxnav" style="height: 340px">
  29. <div class="yqlist">
  30. <ul class="clearfix">
  31. <li>
  32. <div class="yq" id="yq">2634</div>
  33. <span>正在线人数(1)</span>
  34. </li>
  35. <li>
  36. <div class="yq">567</div>
  37. <span>对接人数(2)</span>
  38. </li>
  39. <li>
  40. <div class="yq">56345</div>
  41. <span>浏览人数(3)</span>
  42. </li>
  43. <li>
  44. <div class="yq">721</div>
  45. <span>用户总数(4)</span>
  46. </li>
  47. </ul>
  48. </div>
  49. </div>
  50. </div>
  51. <div class="box">
  52. <div class="tit">专家分布地区</div>
  53. <div class="boxnav">
  54. <echarts1></echarts1>
  55. </div>
  56. </div>
  57. </div>
  58. </el-col>
  59. <el-col :span="12">
  60. <div class="center_1">
  61. <div class="box">
  62. <div class="boxnav mapc" style="position: relative">
  63. <map1 class="map"></map1>
  64. </div>
  65. </div>
  66. </div>
  67. </el-col>
  68. <el-col :span="6">
  69. <div class="center_1">
  70. <div class="box">
  71. <div class="tit">赛事总数及各阶段数量</div>
  72. <echarts3></echarts3>
  73. </div>
  74. <div class="box">
  75. <div class="tit">数据统计</div>
  76. <echarts4></echarts4>
  77. </div>
  78. </div>
  79. </el-col>
  80. </el-row>
  81. </div>
  82. </el-col>
  83. </el-row>
  84. </div>
  85. </template>
  86. <script setup>
  87. const toChange = inject('toChange')
  88. const selectMenu = inject('selectMenu')
  89. import echarts1 from './path/echarts1.vue'
  90. // import echarts2 from './path/echarts2.vue'
  91. import map1 from './path/map.vue'
  92. import echarts3 from './path/echarts3.vue'
  93. import echarts4 from './path/echarts4.vue'
  94. // 加载中
  95. const loading = ref(false)
  96. // 时间
  97. const formattedTime = ref('')
  98. // 请求
  99. onMounted(async () => {
  100. loading.value = true
  101. await updateTime()
  102. loading.value = false
  103. })
  104. // 创建一个函数来格式化时间并更新状态
  105. const updateTime = () => {
  106. const now = new Date()
  107. const options = {
  108. year: 'numeric',
  109. month: '2-digit',
  110. day: '2-digit',
  111. hour: '2-digit',
  112. minute: '2-digit',
  113. second: '2-digit',
  114. hour12: false
  115. }
  116. formattedTime.value = now.toLocaleString('zh-CN', options)
  117. }
  118. const timer = setInterval(updateTime, 1000)
  119. onMounted(() => {
  120. timer // 开始计时器
  121. })
  122. onBeforeUnmount(() => {
  123. clearInterval(timer) // 组件卸载前清除计时器
  124. })
  125. </script>
  126. <style scoped lang="scss">
  127. .main {
  128. height: 100vh;
  129. width: 100%;
  130. position: relative;
  131. background: url('./images/bg.png');
  132. background-size: 100% 100%;
  133. padding: 0px;
  134. margin: 0px;
  135. color: #fff;
  136. font-family: '微软雅黑';
  137. cursor: default; /* 将鼠标样式更改为箭头 */
  138. /* CSS Document */
  139. * {
  140. -webkit-box-sizing: border-box;
  141. -moz-box-sizing: border-box;
  142. box-sizing: border-box;
  143. }
  144. li {
  145. list-style-type: none;
  146. }
  147. i {
  148. margin: 0px;
  149. padding: 0px;
  150. text-indent: 0px;
  151. }
  152. img {
  153. border: none;
  154. max-width: 100%;
  155. }
  156. a {
  157. text-decoration: none;
  158. color: #fff;
  159. }
  160. a.active,
  161. a:focus {
  162. outline: none !important;
  163. text-decoration: none;
  164. }
  165. ol,
  166. ul,
  167. p,
  168. h1,
  169. h2,
  170. h3,
  171. h4,
  172. h5,
  173. h6 {
  174. padding: 0;
  175. margin: 0;
  176. }
  177. a:hover {
  178. color: #06c;
  179. text-decoration: none !important;
  180. }
  181. .clearfix:after,
  182. .clearfix:before {
  183. display: table;
  184. content: ' ';
  185. }
  186. .clearfix:after {
  187. clear: both;
  188. }
  189. .pulll_left {
  190. float: left;
  191. }
  192. .pulll_right {
  193. float: right;
  194. }
  195. i {
  196. font-style: normal;
  197. }
  198. .text-w {
  199. color: #ffe400;
  200. }
  201. .text-d {
  202. color: #ff6316;
  203. }
  204. .text-s {
  205. color: #14e144;
  206. }
  207. .text-b {
  208. color: #07e5ff;
  209. }
  210. .head {
  211. position: relative;
  212. height: 4rem;
  213. margin: 0 15px;
  214. }
  215. .head h1 {
  216. text-align: center;
  217. line-height: 4rem;
  218. padding-right: 35px;
  219. color: #daf9ff;
  220. }
  221. .head .menu ul {
  222. font-size: 0;
  223. }
  224. .head .menu {
  225. margin: 10px 0 0 0;
  226. }
  227. .head .menu li {
  228. display: inline-block;
  229. position: relative;
  230. margin: 10px 15px;
  231. }
  232. .head .menu li a {
  233. display: block;
  234. font-size: $global-font-size-20;
  235. color: #fff;
  236. line-height: 30px;
  237. padding: 0 10px;
  238. }
  239. .head .time {
  240. position: absolute;
  241. right: 0;
  242. line-height: 4rem;
  243. top: 0;
  244. color: #fff;
  245. }
  246. .menu li:before,
  247. .menu li:after {
  248. position: absolute;
  249. width: 10px;
  250. height: 5px;
  251. opacity: 0.4;
  252. content: '';
  253. border-top: 2px solid #02a6b5;
  254. top: -1px;
  255. border-radius: 2px;
  256. }
  257. .menu li:before,
  258. .menu li a:before {
  259. border-left: 2px solid #02a6b5;
  260. left: -1px;
  261. }
  262. .menu li:after,
  263. .menu li a:after {
  264. border-right: 2px solid #02a6b5;
  265. right: -1px;
  266. }
  267. .menu li a {
  268. position: relative;
  269. }
  270. .menu li a:before,
  271. .menu li a:after {
  272. position: absolute;
  273. width: 10px;
  274. height: 5px;
  275. opacity: 0.4;
  276. content: '';
  277. border-bottom: 2px solid #02a6b5;
  278. bottom: -1px;
  279. border-radius: 2px;
  280. }
  281. .head .menu li a:hover {
  282. color: #f4e925;
  283. }
  284. .menu li a:hover:before,
  285. .menu li a:hover:after,
  286. .menu li:hover:before,
  287. .menu li:hover:after {
  288. border-color: #f4e925;
  289. opacity: 1;
  290. }
  291. .mainbox {
  292. padding: 10px 10px 0 10px;
  293. }
  294. .nav1 {
  295. margin-left: -6px;
  296. margin-right: -6px;
  297. }
  298. .nav1 > li {
  299. padding: 0 6px;
  300. float: left;
  301. }
  302. .box {
  303. border: 1px solid rgba(7, 118, 181, 0.5);
  304. box-shadow: inset 0 0 10px rgba(7, 118, 181, 0.4);
  305. margin-bottom: 12px;
  306. position: relative;
  307. }
  308. .tit {
  309. padding: 10px 10px 10px 25px;
  310. border-bottom: 1px solid rgba(7, 118, 181, 0.7);
  311. font-size: $global-font-size-18;
  312. font-weight: 500;
  313. position: relative;
  314. }
  315. .tit:before,
  316. .tit01:before {
  317. position: absolute;
  318. content: '';
  319. width: 6px;
  320. height: 6px;
  321. background: rgba(22, 214, 255, 0.9);
  322. box-shadow: 0 0 5px rgba(22, 214, 255, 0.9);
  323. border-radius: 10px;
  324. left: 10px;
  325. top: 18px;
  326. }
  327. .tit:after,
  328. .box:before {
  329. width: 100%;
  330. height: 1px;
  331. content: '';
  332. position: absolute;
  333. left: 0;
  334. bottom: -1px;
  335. background: linear-gradient(to right, #076ead, #4ba6e0, #076ead);
  336. box-shadow: 0 0 5px rgba(131, 189, 227, 1);
  337. opacity: 0.6;
  338. }
  339. .box:before {
  340. top: -1px;
  341. }
  342. .boxnav {
  343. padding: 0 10px;
  344. }
  345. .tit01 {
  346. font-size: $global-font-size-18;
  347. font-weight: 500;
  348. position: relative;
  349. padding-left: 15px;
  350. }
  351. .tit01:before {
  352. left: 3px;
  353. top: 8px;
  354. }
  355. .mapc {
  356. background: url('./images/bg3.png') no-repeat center center;
  357. background-size: 100% 100%;
  358. }
  359. .map {
  360. position: relative;
  361. top: 0;
  362. left: -8%;
  363. width: 100%;
  364. }
  365. .mapnav {
  366. position: absolute;
  367. z-index: 10;
  368. }
  369. .yqlist li {
  370. float: left;
  371. width: 50%;
  372. padding: 10px 0;
  373. text-align: center;
  374. margin: 20px 0 0 0;
  375. }
  376. .yq {
  377. width: 80px;
  378. height: 80px;
  379. margin: 0 auto 5px auto;
  380. position: relative;
  381. display: flex;
  382. justify-content: center;
  383. align-items: center;
  384. font-size: $global-font-size-25;
  385. font-family: electronicFont;
  386. color: #fff32b;
  387. }
  388. .yqlist li span {
  389. opacity: 0.6;
  390. font-size: $global-font-size-16;
  391. }
  392. .yq:before {
  393. position: absolute;
  394. width: 100%;
  395. height: 100%;
  396. content: '';
  397. background: url('./images/img1.png') center center;
  398. border-radius: 100px;
  399. background-size: 100% 100%;
  400. opacity: 0.3;
  401. left: 0;
  402. top: 0;
  403. animation: myfirst2 15s infinite linear;
  404. }
  405. .yq:after {
  406. position: absolute;
  407. width: 86%;
  408. background: url('./images/img2.png') center center;
  409. border-radius: 100px;
  410. background-size: 100% 100%;
  411. opacity: 0.3;
  412. height: 86%;
  413. content: '';
  414. left: 7%;
  415. top: 7%;
  416. animation: myfirst 15s infinite linear;
  417. }
  418. @keyframes myfirst {
  419. to {
  420. transform: rotate(-360deg);
  421. }
  422. }
  423. @keyframes myfirst2 {
  424. to {
  425. transform: rotate(360deg);
  426. }
  427. }
  428. }
  429. </style>