indexsyyg.html 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <title>四园一港</title>
  7. <!-- 引入 Vue -->
  8. <script src="https://unpkg.com/vue@2.6.14/dist/vue.min.js"></script>
  9. <!-- 引入样式 -->
  10. <link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
  11. <!-- 引入组件库 -->
  12. <script src="https://unpkg.com/element-ui/lib/index.js"></script>
  13. <!-- jquery-->
  14. <script src="js/jquery-3.5.1.min.js"></script>
  15. <script src="js/urljson.js"></script>
  16. <style>
  17. * {
  18. padding: 0;
  19. margin: 0;
  20. }
  21. ul {
  22. list-style-type: none;
  23. }
  24. li {
  25. list-style: none;
  26. }
  27. body {
  28. min-width: 1370px;
  29. margin: 0;
  30. overflow: hidden;
  31. /* 确保视频覆盖整个页面 */
  32. }
  33. video {
  34. position: absolute;
  35. top: 0;
  36. left: 0;
  37. width: 100%;
  38. height: 100%;
  39. object-fit: cover;
  40. /* 确保视频按比例填充整个页面 */
  41. z-index: -1;
  42. /* 将视频置于所有内容之下 */
  43. }
  44. .indexcot {
  45. height: 100vh;
  46. /* background-image: url(images/indexsyyg.png); */
  47. /* background-size: 100% 100%; */
  48. font-family: Microsoft YaHei;
  49. color: #FFFFFF;
  50. padding-top: 1.875rem;
  51. box-sizing: border-box;
  52. }
  53. .indexcot .top {
  54. width: 69%;
  55. display: flex;
  56. margin: auto;
  57. justify-content: space-between;
  58. }
  59. .indexcot .logo {
  60. display: flex;
  61. align-items: center;
  62. font-size: 1.25rem;
  63. margin-right: 10%;
  64. white-space: nowrap;
  65. cursor: pointer;
  66. }
  67. .indexcot .logo img {
  68. width: 3.5rem;
  69. height: 3.5rem;
  70. }
  71. .indexcot .menu {
  72. width: 60%;
  73. max-width: 620px;
  74. font-size: 1rem;
  75. display: flex;
  76. justify-content: space-evenly;
  77. align-items: center;
  78. }
  79. .indexcot .menu li {
  80. cursor: pointer;
  81. white-space: nowrap;
  82. }
  83. .indexcot .menu .active {
  84. font-size: 1.25rem;
  85. padding-bottom: 0.3125rem;
  86. box-sizing: border-box;
  87. border-bottom: 1px solid #fff;
  88. }
  89. .indexcot .title {
  90. display: flex;
  91. width: 69%;
  92. margin: auto;
  93. align-items: center;
  94. justify-content: center;
  95. margin-top: 25vh;
  96. }
  97. .indexcot .title .left {
  98. font-size: 2.375rem;
  99. color: #FFFFFF;
  100. display: flex;
  101. flex-direction: column;
  102. white-space: nowrap;
  103. }
  104. .indexcot .right {
  105. font-size: 5rem;
  106. color: #FFFFFF;
  107. white-space: nowrap;
  108. margin-left: 30px;
  109. }
  110. #titleTabs {
  111. width: 80%;
  112. max-width: 1500px;
  113. margin: 0 auto;
  114. font-size: 1.25rem;
  115. display: flex;
  116. justify-content: center;
  117. margin-top: 3.125rem;
  118. }
  119. #titleTabs .tab {
  120. width: 100%;
  121. display: flex;
  122. justify-content: space-between;
  123. }
  124. #titleTabs .tab-contents {
  125. display: none;
  126. }
  127. #titleTabs .active .tab-contents {
  128. display: flex;
  129. flex-direction: column;
  130. height: 24vh;
  131. background: rgb(116 175 244 / 40%);
  132. }
  133. .tab-items {
  134. /* width: 16%; */
  135. width: 14.25rem;
  136. height: 4.1875rem;
  137. cursor: pointer;
  138. }
  139. .tab-items>.name {
  140. height: 4.1875rem;
  141. background: #5598E7;
  142. margin-left: 0.9375rem;
  143. display: flex;
  144. align-items: center;
  145. justify-content: center;
  146. white-space: nowrap;
  147. padding: 0 0.625rem;
  148. }
  149. .tab-items.active>.name {
  150. background: #206AC2;
  151. font-size: 1.375rem;
  152. }
  153. .tab-contents {
  154. margin-left: 0.9375rem;
  155. }
  156. .tab-contents li {
  157. display: flex;
  158. align-items: center;
  159. height: 2.5rem;
  160. padding-left: 1.25rem;
  161. box-sizing: border-box;
  162. margin-top: 0.625rem;
  163. }
  164. .tab-contents li img {
  165. margin-right: 0.9375rem;
  166. }
  167. .tab-contents .more {
  168. padding-left: 2.6875rem;
  169. font-size: 0.875rem;
  170. color: #FFFFFF;
  171. line-height: 3rem;
  172. text-decoration-line: underline;
  173. cursor: pointer;
  174. }
  175. @media screen and (max-width:1600px) {
  176. html,
  177. body {
  178. font-size: 14px;
  179. }
  180. }
  181. @media screen and (max-width:1300px) {
  182. html,
  183. body {
  184. font-size: 10px;
  185. }
  186. }
  187. </style>
  188. </head>
  189. <body>
  190. <div class="indexcot" id="indexcot">
  191. <video autoplay loop muted playsinline>
  192. <source src="media/业.ecabc222.mp4" type="video/mp4">
  193. Your browser does not support the video tag.
  194. </video>
  195. <div class="top">
  196. <div class="logo">
  197. <img src="images/nalogo.png" alt="">
  198. <span>重庆市南岸区人民政府</span>
  199. </div>
  200. <ul class="menu">
  201. <li class="active" @click="golink('indexsyyg.html')">首页</li>
  202. <li @click="golink('indexcygyy.html?id=1')">园区概况</li>
  203. <li>产业布局</li>
  204. <li>政策计算</li>
  205. <li @click=" golink('tsfw.html?id=1')">特色服务</li>
  206. <li @click="golink('ztcrlist.html?id=-1')">载体租售</li>
  207. <li>党群服务</li>
  208. </ul>
  209. </div>
  210. <div class="title">
  211. <div class="left">
  212. <span style="letter-spacing: 4px; width: 230px;">重庆市南岸区</span>
  213. <span style="letter-spacing: 13px; width: 230px;">重庆经开区</span>
  214. </div>
  215. <div class="right">
  216. 园区服务平台
  217. </div>
  218. </div>
  219. <div id="titleTabs">
  220. <div class="tab">
  221. <div class="tab-items" :class="{ active: currentTab === tab.id }"
  222. v-for="(tab, index) in this.titleList" :key="index" @mouseenter="currentTab = tab.id"
  223. @mouseleave="currentTab = -1">
  224. <div class="name" @click="tsmore(tab.id)">
  225. {{tab.title}}
  226. </div>
  227. <div class="tab-contents">
  228. <ul class="">
  229. <li v-for="(tabl, indexl) in tab.subtitleList" :key="indexl">
  230. <img src="images/listlogo.png" alt="" />
  231. <div class="name">{{tabl}}</div>
  232. </li>
  233. </ul>
  234. <div class="more" @click="tsmore(tab.id)" v-if="tab.subtitleList.length">
  235. 探索更多>>
  236. </div>
  237. </div>
  238. </div>
  239. </div>
  240. </div>
  241. </div>
  242. </div>
  243. </body>
  244. <script>
  245. // 初始化Vue实例
  246. new Vue({
  247. el: '#indexcot',
  248. data: function () {
  249. return {
  250. currentTab: -1,
  251. titleList: [
  252. ],
  253. // parkData: {
  254. // id:[],
  255. // title:[],
  256. // subtitle:[]
  257. // },
  258. };
  259. },
  260. methods: {
  261. tsmore(id) {
  262. window.location.href = "indexcygyy.html?id=" + this.currentTab;
  263. },
  264. golink(hrf) {
  265. console.log(11)
  266. window.location.href = hrf;
  267. },
  268. getParkData() {
  269. let that = this;
  270. $.ajax({
  271. url: conpath + "/parkData/",
  272. type: "get",
  273. dataType: "json",
  274. success: function (data) {
  275. data.forEach(function (item) {
  276. item.subtitleList = item.subtitle ? item.subtitle.split(",").slice(0, 3) : [];
  277. })
  278. that.titleList = data;
  279. }
  280. })
  281. }
  282. },
  283. mounted() {
  284. this.getParkData();
  285. }
  286. });
  287. </script>
  288. </html>