footer.vue 4.4 KB

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