index.vue 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. <template>
  2. <div class="footer">
  3. <div class="container">
  4. <div class="footer__header">
  5. <div class="title">友情链接:</div>
  6. <div class="links">
  7. <a
  8. v-for="(item, index) in showList(links)"
  9. :key="index"
  10. :href="item.url ? item.url : 'javascript:;'"
  11. target="_blank"
  12. >{{ item.name }}</a
  13. >
  14. </div>
  15. </div>
  16. <div class="footer__body">
  17. <p v-for="(item, index) in footer" :key="index">{{ item.name }}</p>
  18. </div>
  19. <div class="footer__footer">
  20. <p>
  21. Copyright©2016-2022 广东省中正建设职业培训学校 版权所有
  22. <a href="https://beian.miit.gov.cn/" target="_blank">
  23. 粤ICP备15087219号-2</a
  24. >
  25. </p>
  26. <p>技术支持:广东中正教育科技有限公司</p>
  27. </div>
  28. </div>
  29. </div>
  30. </template>
  31. <script>
  32. import { mapGetters } from "vuex";
  33. export default {
  34. name: "Footer",
  35. data() {
  36. return {};
  37. },
  38. computed: {
  39. ...mapGetters(["footer", "links"]),
  40. showList: function () {
  41. return function (list) {
  42. let showList = [];
  43. if (list) {
  44. showList = list.filter((item) => {
  45. return item.status == 1;
  46. });
  47. }
  48. return showList;
  49. };
  50. },
  51. },
  52. };
  53. </script>
  54. <!-- Add "scoped" attribute to limit CSS to this component only -->
  55. <style scoped lang="scss">
  56. .footer {
  57. background: #f8fafc;
  58. &__header {
  59. .title {
  60. height: 40px;
  61. line-height: 40px;
  62. font-size: 12px;
  63. font-family: Microsoft YaHei;
  64. font-weight: 400;
  65. color: #999999;
  66. border-bottom: 1px solid #eeeeee;
  67. }
  68. .links {
  69. padding-bottom: 14px;
  70. border-bottom: 1px solid #eeeeee;
  71. a {
  72. line-height: 14px;
  73. display: inline-block;
  74. margin-top: 14px;
  75. margin-right: 40px;
  76. font-size: 12px;
  77. font-family: Microsoft YaHei;
  78. font-weight: 400;
  79. color: #999999;
  80. }
  81. }
  82. }
  83. &__body {
  84. padding: 14px 0;
  85. p {
  86. font-size: 14px;
  87. font-family: Microsoft YaHei;
  88. font-weight: 400;
  89. color: #999999;
  90. line-height: 24px;
  91. }
  92. }
  93. &__footer {
  94. padding: 22px 0;
  95. p {
  96. text-align: center;
  97. font-size: 14px;
  98. font-family: Microsoft YaHei;
  99. font-weight: 400;
  100. color: #999999;
  101. line-height: 24px;
  102. }
  103. a {
  104. color: #999999;
  105. }
  106. }
  107. }
  108. </style>