footer.vue 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182
  1. <template>
  2. <div id="proginn-footer">
  3. <div id="friend-links">
  4. <div class="links">
  5. <a href="/">
  6. <img class="logo" :src="baseUrl+'/Public/image/common/logo_new.png'" />
  7. </a>
  8. <div class="items">
  9. <div class="item-box" v-for="(link, index) of links" :key="index">
  10. <span class="name">{{link.name}}</span>
  11. <div class="item">
  12. <div class="list" :class="{expand: link.expand}">
  13. <a
  14. v-for="(item, ii) of link.data"
  15. :key="ii"
  16. :href="item.url"
  17. target="_blank"
  18. >{{item.name}}</a>
  19. </div>
  20. <span
  21. class="more"
  22. style="display: inline;"
  23. @click="clickMore(link, index)"
  24. >{{link.expand ? '收起' : '更多'}}</span>
  25. </div>
  26. </div>
  27. </div>
  28. </div>
  29. </div>
  30. <div class="footer" id="footer">
  31. <div class="footer-container">
  32. <div class="footer-links">
  33. <a class="item" :href="baseUrl+'/index/app'" rel="nofollow">APP下载</a>
  34. <a class="item" href="http://support.proginn.com/" rel="nofollow">帮助</a>
  35. <a class="item" :href="baseUrl+'/about'" rel="nofollow">关于我们</a>
  36. <a class="item" :href="baseUrl+'/about/mediareports'" rel="nofollow">媒体报道</a>
  37. <a class="item" :href="baseUrl+'/sites/'" rel="nofollow">合作伙伴</a>
  38. <a class="item" :href="baseUrl+'/about/suggestion'" rel="nofollow">意见反馈</a>
  39. <span style="color: rgb(204, 204, 204);" class="ui item">© 程序员客栈</span>
  40. </div>
  41. <div class="safe">
  42. <a href="http://www.miibeian.gov.cn" target="_blank" rel="nofollow">浙ICP备15029175号</a>
  43. <div>
  44. <a
  45. style="display: flex;"
  46. target="_blank"
  47. href="http://www.beian.gov.cn/portal/registerSystemInfo?recordcode=33011002011566"
  48. rel="nofollow"
  49. >
  50. <img width="20" height="20" :src="baseUrl+'/Public/image/common/badge.png'" />
  51. <span
  52. style="height:20px;line-height:20px;margin: 0px 0px 0px 5px;"
  53. >浙公网安备 33011002011566号</span>
  54. </a>
  55. </div>
  56. </div>
  57. </div>
  58. </div>
  59. </div>
  60. </template>
  61. <script>
  62. export default {
  63. data() {
  64. return {
  65. baseUrl: "",
  66. jishuBaseUrl: "",
  67. isCity: false,
  68. isBusiness: false,
  69. isDirection: false,
  70. isRecommend: false,
  71. links: []
  72. };
  73. },
  74. mounted() {
  75. this.getLinks();
  76. },
  77. methods: {
  78. clickMore(link, index) {
  79. link.expand = !link.expand;
  80. this.$set(this.links, index, link);
  81. },
  82. async getLinks() {
  83. let res = await this.$axios.$post(
  84. "https://www.proginn.com/api/public_config/get_seo_footer_links"
  85. );
  86. if (res) {
  87. this.links = res.data.links;
  88. }
  89. }
  90. },
  91. created() {
  92. this.baseUrl = this.$store.state.domainConfig.siteUrl;
  93. this.jishuBaseUrl = this.$store.state.domainConfig.jishuinUrl;
  94. }
  95. };
  96. </script>
  97. <style scoped>
  98. #proginn-footer {
  99. width: 100%;
  100. }
  101. #friend-links,
  102. #footer {
  103. display: flex;
  104. justify-content: center;
  105. background: white;
  106. }
  107. #friend-links {
  108. padding: 50px 0 40px;
  109. }
  110. .links,
  111. .footer-container {
  112. display: flex;
  113. justify-content: space-between;
  114. width: 1000px;
  115. font-size: 12px;
  116. color: #4a4a4a;
  117. }
  118. .logo {
  119. width: 115px;
  120. height: 38px;
  121. margin-top: 10px;
  122. }
  123. .items {
  124. display: flex;
  125. flex-direction: column;
  126. align-items: center;
  127. width: 840px;
  128. }
  129. .item {
  130. display: flex;
  131. }
  132. .name {
  133. line-height: 30px;
  134. font-weight: 800;
  135. }
  136. .list {
  137. --height: 30px;
  138. flex: 1;
  139. height: var(--height);
  140. line-height: var(--height);
  141. overflow: hidden;
  142. }
  143. .list a {
  144. display: inline-block;
  145. margin: 0 15px 0 0;
  146. }
  147. .expand {
  148. height: auto;
  149. }
  150. .footer-container a,
  151. .list a {
  152. color: #4a4a4a;
  153. }
  154. .footer-container {
  155. display: flex;
  156. align-items: center;
  157. border-top: 1px solid #ddd;
  158. padding: 20px 0 10px;
  159. }
  160. .footer-links {
  161. display: flex;
  162. align-items: center;
  163. }
  164. .footer-container a {
  165. margin: 0 30px 0 0;
  166. }
  167. .safe {
  168. text-align: right;
  169. }
  170. .safe a {
  171. margin: 0;
  172. }
  173. .more {
  174. line-height: 30px;
  175. cursor: pointer;
  176. }
  177. .more:hover {
  178. color: #1782d9;
  179. }
  180. </style>