FooterBottom.vue 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284
  1. <!--
  2. * @Author: your name
  3. * @Date: 2021-01-09 20:19:.gitignore
  4. * @LastEditTime: 2021-01-13 17:21:02
  5. * @LastEditors: Please set LastEditors
  6. * @Description: In User Settings Edit
  7. * @FilePath: /java-pc/src/components/FooterBottom.vue
  8. -->
  9. <template>
  10. <div>
  11. <div class="footer_service_wrap" v-if="ImgBG">
  12. <div class="footer_service">
  13. <a>
  14. <img :src="ImgBG" alt />
  15. </a>
  16. </div>
  17. </div>
  18. <div class="footer_link">
  19. <div class="link_box" v-if="navList.data.length > 0">
  20. <div class="link_wrap" v-for="(
  21. { categoryName, categoryId, articleList }, index
  22. ) in navList.data" :key="index">
  23. <p @click="toarticle(categoryId)">{{ categoryName }}</p>
  24. <li v-for="({ title, cateId, articleId }, index) in articleList" :key="index">
  25. <!-- <router-link :to="{
  26. path: '/article',
  27. query: { cateId: cateId, articleId: articleId },
  28. }" replace> -->
  29. <a style="cursor:pointer" @click="getContent(articleId)">{{ title }}</a>
  30. <!-- </router-link> -->
  31. </li>
  32. </div>
  33. </div>
  34. <div class="bottom_box">
  35. <div class="footer_bottom">
  36. <ul class="footer_list">
  37. <li v-for="({ linkName, linkUrl }, index) in helpList.data" :key="index">
  38. <a :href="linkUrl" target="_blank">
  39. {{ linkName }}
  40. </a>
  41. </li>
  42. </ul>
  43. <p class="copy_right">
  44. {{ CopyrightData.data[1] }} {{ L["版权所有"] }}
  45. <a style="text-decoration: underline;color:#333;" href="https://beian.miit.gov.cn/" target="_blank">{{ CopyrightData.data[0] }}</a>
  46. </p>
  47. <p class="author">
  48. {{ CopyrightData.data[2] }} {{ L["提供技术支持"] }}
  49. </p>
  50. </div>
  51. </div>
  52. </div>
  53. </div>
  54. </template>
  55. <script setup>
  56. const L = getCurLanguage();
  57. const ImgBG = ref('')
  58. const router = useRouter()
  59. //获取底部合作案例-联系我们等帮助部分的链接list
  60. const helpList = reactive({ data: [] });
  61. const getInitDataList = async () => {
  62. const { data: res } = await useFetch(
  63. apiUrl + "/v3/cms/front/friendLink/list"
  64. );
  65. if (res._rawValue.state == 200) {
  66. helpList.data = res._rawValue.data;
  67. }
  68. };
  69. getInitDataList();
  70. //获取产品列表-新手说明等部分的链接list
  71. const navList = reactive({ data: [] });
  72. const getInitData = async () => {
  73. const { data: res } = await useFetch(
  74. apiUrl + "/v3/cms/front/article/helpList",
  75. {
  76. params: {
  77. cateSize: 6,
  78. articleSize: 5,
  79. },
  80. }
  81. );
  82. if (res._rawValue.state == 200) {
  83. navList.data = res._rawValue.data;
  84. }
  85. };
  86. getInitData();
  87. //跳转判断
  88. const getContent = (articleId) => {
  89. const params = {
  90. articleId: articleId,
  91. };
  92. get("v3/cms/front/article/articleDetail", params).then((res) => {
  93. if (res.state === 200) {
  94. if (res.data.outUrl) {
  95. window.open(res.data.outUrl,'_blank');
  96. return
  97. }else{
  98. router.push({ path: "/article", query: { articleId: articleId }});
  99. }
  100. }
  101. });
  102. }
  103. //获取版权,技术支持信息
  104. const CopyrightData = reactive({ data: [] });
  105. const getCopyrightData = async () => {
  106. const { data: res } = await useFetch(
  107. apiUrl +
  108. "v3/system/front/setting/getSettings?names=basic_site_icp,basic_site_copyright,basic_site_technical_support,pc_home_bottom_adv"
  109. );
  110. if (res._rawValue.state == 200) {
  111. CopyrightData.data = res._rawValue.data;
  112. ImgBG.value = res._rawValue.data[3]
  113. }
  114. };
  115. getCopyrightData();
  116. </script>
  117. <style lang="scss" scoped>
  118. @import "@/assets/style/theme.scss";
  119. .footer_link {
  120. width: 100%;
  121. display: flex;
  122. flex-direction: column;
  123. align-items: center;
  124. justify-content: center;
  125. position: relative;
  126. overflow: hidden;
  127. box-sizing: border-box;
  128. background: #eaeaea;
  129. background: rgb(176 221 204 / 37%);
  130. .link_box {
  131. border-top: 1px dashed #f2f2f2;
  132. padding-top: 50px;
  133. width: 1210px;
  134. margin: 0 auto 50px;
  135. display: flex;
  136. position: relative;
  137. flex-direction: row;
  138. justify-content: space-between;
  139. .link_wrap {
  140. text-align: left;
  141. p {
  142. font-size: 16px;
  143. font-weight: 600;
  144. margin-bottom: 20px;
  145. color: #333333;
  146. }
  147. li {
  148. line-height: 25px;
  149. a {
  150. color: #333333;
  151. &:hover {
  152. color: $colorMain;
  153. }
  154. }
  155. }
  156. }
  157. .link_wrap:nth-child(1) {
  158. /*width: 295px;*/
  159. /*text-align: left;*/
  160. }
  161. .link_wrap:nth-child(2) {
  162. /*width: 270px;*/
  163. }
  164. .link_wrap:nth-child(3) {
  165. /*width: 280px;*/
  166. }
  167. .link_wrap:nth-child(4) {
  168. /*width: 280px;*/
  169. }
  170. .link_wrap:nth-child(5) {
  171. /*width: 280px;*/
  172. }
  173. }
  174. .bottom_box,
  175. .bottom_box_none {
  176. position: relative;
  177. width: 100%;
  178. overflow: hidden;
  179. height: 130px;
  180. }
  181. .bottom_box_none {
  182. width: 100%;
  183. height: 87px;
  184. background-color: #333333;
  185. }
  186. }
  187. </style>
  188. <style lang="scss" scoped>
  189. .footer_bottom {
  190. background: rgba(176, 221, 204, 0.37);
  191. position: absolute;
  192. width: 100%;
  193. overflow: hidden;
  194. bottom: 0;
  195. color: #333;
  196. font-size: 12px;
  197. display: flex;
  198. flex-direction: column;
  199. align-items: center;
  200. padding-bottom: 12px;
  201. padding-top: 12px;
  202. .footer_list {
  203. width: 1200px;
  204. margin: 15px auto;
  205. display: flex;
  206. margin-bottom: 10px;
  207. margin-top: 15px;
  208. flex-wrap: wrap;
  209. justify-content: center;
  210. li {
  211. box-sizing: border-box;
  212. padding: 0 7px;
  213. border-right: 1px solid rgba(255, 255, 255, 0.4);
  214. color: #333;
  215. line-height: 19px;
  216. cursor: pointer;
  217. a {
  218. color: #333;
  219. }
  220. }
  221. }
  222. li:last-child {
  223. border-right: none;
  224. }
  225. .copy_right {
  226. letter-spacing: 1px;
  227. margin-bottom: 10px;
  228. }
  229. }
  230. .footer_service_wrap {
  231. width: 100%;
  232. height: 100%;
  233. .footer_service {
  234. width: 100%;
  235. height: 50px;
  236. overflow: hidden;
  237. a {
  238. display: inline-block;
  239. width: 100%;
  240. height: 100%;
  241. // overflow: hidden;
  242. img {
  243. width: 1920px;
  244. height: 100%;
  245. margin-left: -960px;
  246. left: 50%;
  247. position: relative;
  248. overflow: hidden;
  249. display: block;
  250. }
  251. }
  252. }
  253. }
  254. </style>