home.vue 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556
  1. <template>
  2. <div class="home" :class="userType != 22&&initPage == 'true' ? 'home-class' : ''" >
  3. <home-navbar />
  4. <div class="max-big-home-box" v-if="userType != 22&&initPage == 'true'">
  5. <homeSubPageKYDXNH v-if="versionField() === 'kuangYeDaXue_nanHu'"></homeSubPageKYDXNH>
  6. <homeSubPagePublic v-else></homeSubPagePublic>
  7. </div>
  8. <backAnimation v-if="userType != '22'&&initPage == 'true'"></backAnimation>
  9. </div>
  10. </template>
  11. <script>
  12. import backAnimation from "@/components/backAnimation/backAnimation"
  13. import homeNavbar from './homeNavbar.vue'
  14. import homeSubPagePublic from './differenceComponent/homeSubPagePublic.vue'
  15. import homeSubPageKYDXNH from './differenceComponent/homeSubPageKYDXNH.vue'
  16. export default {
  17. name: "home",
  18. components: {
  19. homeNavbar,
  20. backAnimation,
  21. homeSubPagePublic,
  22. homeSubPageKYDXNH
  23. },
  24. data() {
  25. return {
  26. userType:localStorage.getItem('userType'),
  27. initPage:localStorage.getItem('initPage'),
  28. };
  29. },
  30. created(){
  31. },
  32. mounted(){
  33. let self =this
  34. this.routeData = JSON.parse(localStorage.getItem("routeData"))
  35. if(localStorage.getItem('initPage') == 'true'){
  36. console.log("true")
  37. if(localStorage.getItem('userType') == '22'){
  38. for(let i=0;i<self.routeData.length;i++){
  39. if(!self.routeData[i].hidden&&self.routeData[i].name != 'Https://www.sxitdlc.com'){
  40. if (self.routeData[i].children){
  41. for(let o=0;o<self.routeData[i].children.length;o++){
  42. if(!self.routeData[i].children[o].alwaysShow&&!self.routeData[i].children[o].hidden){
  43. let urlText = self.routeData[i].path + '/' + self.routeData[i].children[o].path;
  44. console.log("urlText",urlText)
  45. this.$router.push({ path: urlText });
  46. return
  47. }else{
  48. if(self.routeData[i].children[o].children){
  49. for(let x=0;x<self.routeData[i].children[o].children.length;x++){
  50. if(!self.routeData[i].children[o].children[x].alwaysShow&&!self.routeData[i].children[o].children[x].hidden){
  51. let urlText = self.routeData[i].path + '/' + self.routeData[i].children[o].path + '/' + self.routeData[i].children[o].children[x].path;
  52. console.log("urlText",urlText)
  53. this.$router.push({ path: urlText });
  54. return
  55. }
  56. }
  57. }
  58. }
  59. }
  60. }
  61. }
  62. }
  63. }
  64. }else{
  65. console.log("false")
  66. for(let i=0;i<self.routeData.length;i++){
  67. if(!self.routeData[i].hidden&&self.routeData[i].name != 'Https://www.sxitdlc.com'){
  68. if (self.routeData[i].children){
  69. for(let o=0;o<self.routeData[i].children.length;o++){
  70. if(!self.routeData[i].children[o].alwaysShow&&!self.routeData[i].children[o].hidden){
  71. let urlText = self.routeData[i].path + '/' + self.routeData[i].children[o].path;
  72. console.log("urlText",urlText)
  73. this.$router.push({ path: urlText });
  74. return
  75. }else{
  76. if(self.routeData[i].children[o].children){
  77. for(let x=0;x<self.routeData[i].children[o].children.length;x++){
  78. if(!self.routeData[i].children[o].children[x].alwaysShow&&!self.routeData[i].children[o].children[x].hidden){
  79. let urlText = self.routeData[i].path + '/' + self.routeData[i].children[o].path + '/' + self.routeData[i].children[o].children[x].path;
  80. console.log("urlText",urlText)
  81. this.$router.push({ path: urlText });
  82. return
  83. }
  84. }
  85. }
  86. }
  87. }
  88. }
  89. }
  90. }
  91. }
  92. },
  93. methods: {
  94. //跳转按钮
  95. goPage(type,title){
  96. let self = this;
  97. if(type == 'null'){
  98. this.$alert(title+'暂未开放', {
  99. confirmButtonText: '确定',
  100. callback: action => {}
  101. });
  102. return
  103. }
  104. if(type == 'Https://www.sxitdlc.com'){
  105. for(let i=0;i<self.routeData.length;i++){
  106. if(type == self.routeData[i].name){
  107. console.log("self.routeData[i].name",self.routeData[i].name)
  108. window.open(localStorage.getItem('screenUrl') + '?identity=' + localStorage.getItem('identity'));
  109. return
  110. }
  111. }
  112. this.$alert('没有"'+title+'"系统权限,如有疑问,请联系管理员', {
  113. confirmButtonText: '确定',
  114. callback: action => {}
  115. });
  116. }
  117. //寻找跳转目标路由
  118. let num = 0;
  119. for(let i=0;i<self.routeData.length;i++){
  120. if(type == self.routeData[i].name){
  121. num++
  122. if(!self.routeData[i].alwaysShow&&!self.routeData[i].hidden){
  123. let urlText = self.routeData[i].path;
  124. this.$router.push({ path: urlText });
  125. console.log("urlText1",urlText)
  126. return
  127. }else if (self.routeData[i].children){
  128. for(let o=0;o<self.routeData[i].children.length;o++){
  129. if(!self.routeData[i].children[o].alwaysShow&&!self.routeData[i].children[o].hidden){
  130. let urlText = self.routeData[i].path + '/' + self.routeData[i].children[o].path;
  131. this.$router.push({ path: urlText });
  132. console.log("urlText2",urlText)
  133. return
  134. }else{
  135. if(self.routeData[i].children[o].children){
  136. for(let x=0;x<self.routeData[i].children[o].children.length;x++){
  137. if(!self.routeData[i].children[o].children[x].alwaysShow&&!self.routeData[i].children[o].children[x].hidden){
  138. let urlText = self.routeData[i].path + '/' + self.routeData[i].children[o].path + '/' + self.routeData[i].children[o].children[x].path;
  139. this.$router.push({ path: urlText });
  140. console.log("urlText3",urlText)
  141. return
  142. }
  143. }
  144. }
  145. }
  146. }
  147. }
  148. }
  149. }
  150. if(num == 0){
  151. this.$alert('没有"'+title+'"系统权限,如有疑问,请联系管理员', {
  152. confirmButtonText: '确定',
  153. callback: action => {}
  154. });
  155. }
  156. },
  157. },
  158. };
  159. </script>
  160. <style scoped lang="scss">
  161. /*@media screen and (min-height:10px){*/
  162. /*.display-none-one{*/
  163. /*display: none;*/
  164. /*}*/
  165. /*.max-bottom-box{*/
  166. /*.top-button-box{*/
  167. /*.top-margin{*/
  168. /*margin-top:20px!important;*/
  169. /*}*/
  170. /*}*/
  171. /*}*/
  172. /*}*/
  173. /*@media screen and (min-height:850px){*/
  174. /*.max-bottom-box{*/
  175. /*.top-button-box{*/
  176. /*.top-margin{*/
  177. /*margin-top:50px!important;*/
  178. /*}*/
  179. /*}*/
  180. /*}*/
  181. /*}*/
  182. /*@media screen and (min-height:900px){*/
  183. /*.max-bottom-box{*/
  184. /*.top-button-box{*/
  185. /*.top-margin{*/
  186. /*margin-top:100px!important;*/
  187. /*}*/
  188. /*}*/
  189. /*}*/
  190. /*}*/
  191. /*@media screen and (min-height:1000px){*/
  192. /*.display-none-one{*/
  193. /*display: block!important;*/
  194. /*}*/
  195. /*}*/
  196. @-webkit-keyframes centerButtonMover {
  197. 0% {
  198. transform:scale(1);
  199. }
  200. 30% {
  201. transform: rotate(0deg) scale(0.9);
  202. }
  203. 40% {
  204. transform: rotate(-5deg) scale(1);
  205. }
  206. 50% {
  207. transform: rotate(5deg) scale(1);
  208. }
  209. 60% {
  210. transform: rotate(-5deg) scale(1.1);
  211. }
  212. 70% {
  213. transform: rotate(0deg) scale(1.2);
  214. }
  215. 100% {
  216. transform: rotate(0deg) scale(1);
  217. }
  218. }
  219. @-webkit-keyframes centerMover {
  220. 0% {
  221. -webkit-transform: translateY(0);
  222. /*transform:scale(0.5px;*/
  223. }
  224. 50% {
  225. -webkit-transform: translateY(20px);
  226. /*transform:scale(0.5px;*/
  227. }
  228. 100% {
  229. -webkit-transform: translateY(0);
  230. /*transform:scale(0.6px;/*/
  231. }
  232. }
  233. @-webkit-keyframes ringMove {
  234. 0% {
  235. -webkit-transform: translateY(0px);
  236. /*transform:scale(0.5px;*/
  237. opacity:1;
  238. }
  239. 50% {
  240. -webkit-transform: translateY(20px);
  241. /*transform:scale(0.5px;*/
  242. opacity:0;
  243. }
  244. 100% {
  245. -webkit-transform: translateY(0);
  246. /*transform:scale(0.6px;/*/
  247. opacity:0;
  248. }
  249. }
  250. @-webkit-keyframes buttonMove{
  251. 50%{
  252. -webkit-transform:scale(0.8);
  253. transform:scale(0.8);
  254. -webkit-filter:brightness(90%)
  255. }
  256. 100%{
  257. -webkit-transform:scale(1);
  258. transform:scale(1);
  259. /*css3滤镜亮度百分比*/
  260. -webkit-filter:brightness(100%)
  261. }
  262. }
  263. .home-class{
  264. background-color: #004d8c;
  265. background-image:url("../assets/ZDimages/home/img_tydlpt_bg.png")!important;
  266. -webkit-background-size: 100%;
  267. background-size: 100%;
  268. }
  269. .home {
  270. height:100%;
  271. width:100%;
  272. flex:1;
  273. display: flex;
  274. flex-direction: column;
  275. overflow: hidden;
  276. position: relative;
  277. *{
  278. margin:0;
  279. }
  280. .max-big-home-box{
  281. position: relative;
  282. flex:1;
  283. overflow: hidden;
  284. .max-home-button-box{
  285. /*width:1462px;*/
  286. width:1300px;
  287. /*height:848px;*/
  288. height:760px;
  289. top:50%;
  290. left:50%;
  291. margin-top:-380px;
  292. margin-left:-650px;
  293. position: absolute;
  294. .max-home-box{
  295. /*background: #E65D6E;*/
  296. /*width:1462px;*/
  297. width:1300px;
  298. /*height:848px;*/
  299. height:760px;
  300. position: relative;
  301. display: flex;
  302. flex-direction: column;
  303. .img-1{
  304. position: absolute;
  305. /*width:863px;*/
  306. width:690px;
  307. /*height:504px;*/
  308. height:403px;
  309. top:191px;
  310. left:50%;
  311. margin-left:- 345px;
  312. -webkit-animation-name: centerMover;
  313. -webkit-animation-duration: 4s;
  314. -webkit-animation-iteration-count: infinite;
  315. -webkit-animation-delay: 0s;
  316. }
  317. .img-2{
  318. position: absolute;
  319. /*width:463px;*/
  320. width:370px;
  321. /*height:106px;*/
  322. height:84px;
  323. top:391px;
  324. left:50%;
  325. margin-left:- 185px;
  326. -webkit-animation-name: ringMove;
  327. -webkit-animation-duration: 2s;
  328. -webkit-animation-iteration-count: infinite;
  329. -webkit-animation-delay: 0s;
  330. }
  331. .img-3{
  332. position: absolute;
  333. /*width:493px;*/
  334. width:394px;
  335. /*height:107px;*/
  336. height:85px;
  337. top:319px;
  338. left:50%;
  339. margin-left:- 197px;
  340. -webkit-animation-name: ringMove;
  341. -webkit-animation-duration: 2s;
  342. -webkit-animation-iteration-count: infinite;
  343. -webkit-animation-delay: 0.2s;
  344. }
  345. .img-4{
  346. position: absolute;
  347. /*width:554px;*/
  348. width:443px;
  349. /*height:118px;*/
  350. height:94px;
  351. top:231px;
  352. left:50%;
  353. margin-left:- 221px;
  354. -webkit-animation-name: ringMove;
  355. -webkit-animation-duration: 2s;
  356. -webkit-animation-iteration-count: infinite;
  357. -webkit-animation-delay: 0.4s;
  358. }
  359. .img-5{
  360. position: absolute;
  361. width:394px;
  362. /*width:493px;*/
  363. /*height:107px;*/
  364. height:85px;
  365. /*width:644px;*/
  366. /*height:118px;*/
  367. top:141px;
  368. left:50%;
  369. //margin-left:-322px;
  370. margin-left:- 197px;
  371. -webkit-animation-name: ringMove;
  372. -webkit-animation-duration: 2s;
  373. -webkit-animation-iteration-count: infinite;
  374. -webkit-animation-delay: 0.6s;
  375. }
  376. .img-6{
  377. position: absolute;
  378. width:354px;
  379. /*width:443px;*/
  380. /*height:106px;*/
  381. height:84px;
  382. /*width:734px;*/
  383. /*height:118px;*/
  384. top:051px;
  385. left:50%;
  386. //margin-left:-367px;
  387. margin-left:- 177px;
  388. -webkit-animation-name: ringMove;
  389. -webkit-animation-duration: 2s;
  390. -webkit-animation-iteration-count: infinite;
  391. -webkit-animation-delay: 0.8s;
  392. }
  393. .max-bottom-box{
  394. width:1300px;
  395. margin:0 auto;
  396. flex:1;
  397. display: flex;
  398. flex-direction: column;
  399. .top-button-box{
  400. display: flex;
  401. .left-box{
  402. .position-button{
  403. width:297px;
  404. height:136px;
  405. cursor: pointer;
  406. position: relative;
  407. z-index:5;
  408. img{
  409. width:297px;
  410. height:136px;
  411. }
  412. p{
  413. position: absolute;
  414. top:43px;
  415. left:142px;
  416. text-align: center;
  417. font-size:18px;
  418. line-height:18px;
  419. background: linear-gradient(to top, #06F6F7 , #FFFFFF );
  420. -webkit-background-clip: text;
  421. color: transparent;
  422. }
  423. }
  424. .position-button:nth-child(1){
  425. margin-top:0;
  426. }
  427. .position-button:nth-child(2){
  428. margin:55px 0 0 40px;
  429. }
  430. .position-button:nth-child(3){
  431. margin:55px 0 0 80px;
  432. }
  433. }
  434. .center-box{
  435. flex:1;
  436. .position-button{
  437. width:147px;
  438. height:105px;
  439. cursor: pointer;
  440. position: relative;
  441. z-index:5;
  442. margin:0 auto 0;
  443. -webkit-animation-name: centerButtonMover;
  444. -webkit-animation-duration: 3s;
  445. -webkit-animation-iteration-count: infinite;
  446. -webkit-animation-delay: 0s;
  447. img{
  448. width:147px;
  449. height:105px;
  450. }
  451. p{
  452. position: absolute;
  453. top:66px;
  454. left:30px;
  455. text-align: center;
  456. font-size:18px;
  457. line-height:18px;
  458. background: linear-gradient(to top, #06F6F7 , #FFFFFF );
  459. -webkit-background-clip: text;
  460. color: transparent;
  461. }
  462. }
  463. }
  464. .right-box{
  465. .position-button{
  466. width:297px;
  467. height:136px;
  468. cursor: pointer;
  469. z-index:5;
  470. position: relative;
  471. img{
  472. width:297px;
  473. height:136px;
  474. }
  475. p{
  476. position: absolute;
  477. top:43px;
  478. left:56px;
  479. text-align: center;
  480. font-size:18px;
  481. line-height:18px;
  482. background: linear-gradient(to top, #06F6F7 , #FFFFFF );
  483. -webkit-background-clip: text;
  484. color: transparent;
  485. }
  486. }
  487. .position-button:nth-child(1){
  488. margin:0 0 0 80px;
  489. }
  490. .position-button:nth-child(2){
  491. margin:55px 0 0 40px;
  492. }
  493. .position-button:nth-child(3){
  494. margin-top:55px;
  495. }
  496. }
  497. }
  498. .center-button-box{
  499. flex:1;
  500. }
  501. .bottom-button-box{
  502. display: flex;
  503. .null-button{
  504. flex:1;
  505. }
  506. .position-button{
  507. width:140px;
  508. height:200px;
  509. cursor: pointer;
  510. z-index:5;
  511. position: relative;
  512. img{
  513. width:140px;
  514. height:230px;
  515. }
  516. p{
  517. position: absolute;
  518. top:154px;
  519. /*left:34px;*/
  520. width:140px;
  521. text-align: center;
  522. font-size:18px;
  523. line-height:18px;
  524. background: linear-gradient(to top, #06F6F7 , #FFFFFF );
  525. -webkit-background-clip: text;
  526. color: transparent;
  527. }
  528. }
  529. .position-button:nth-child(2),
  530. .position-button:nth-child(3),
  531. .position-button:nth-child(4),
  532. .position-button:nth-child(5){
  533. margin-right:95px;
  534. }
  535. }
  536. .position-button:hover{
  537. -webkit-animation-name: buttonMove;
  538. -webkit-animation-duration: 1.5s;
  539. -webkit-animation-iteration-count: infinite;
  540. -webkit-animation-delay: 0s;
  541. }
  542. }
  543. }
  544. }
  545. }
  546. .bottom-null-box{
  547. height:60px;
  548. }
  549. }
  550. </style>