class.vue 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938
  1. <template>
  2. <div class="company" v-if="routeType == 6">
  3. <section class="index_1 clearfix phone_none">
  4. <div class="shop_head_1 clearfix">
  5. <div class="shop_head_1_name">{{ secNavTitle }}</div>
  6. </div>
  7. <div class="categ_color_box clearfix">
  8. <div class="categ_color_name clearfix">直达:</div>
  9. <div class="categ_color_in clearfix">
  10. <NuxtLink class="categ_color_a" :href="`/${item.aLIas_pinyin}/list-1.html`" title="item.title"
  11. v-for="(item, index) in companyData" :key="index">
  12. {{ item.alias }}
  13. </NuxtLink>
  14. </div>
  15. </div>
  16. </section>
  17. <div class="phone_nav pc_none">
  18. <div class="phone_nav_in">
  19. <NuxtLink class="phone_nav_a" :href="`/${item.aLIas_pinyin}/list-1.html`"
  20. v-for="(item, index) in companyData" :key="index">
  21. {{ item.alias }}
  22. </NuxtLink>
  23. </div>
  24. </div>
  25. <!-- 三农市场网-商城-资讯列表2 -->
  26. <section class=" ">
  27. <!-- 面包屑导航 -->
  28. <div class="breadcrumb phone_none">
  29. <div class="inner">
  30. <span class="location">当前位置:</span>
  31. <el-breadcrumb :separator-icon="ArrowRight">
  32. <el-breadcrumb-item>
  33. <NuxtLink to="/">首页</NuxtLink>
  34. </el-breadcrumb-item>
  35. <el-breadcrumb-item v-if="parent_name != ''">
  36. <NuxtLink :to="`/${parent_pinyin}/index.html`"> {{ parent_name }}</NuxtLink>
  37. </el-breadcrumb-item>
  38. <el-breadcrumb-item>
  39. <NuxtLink :to="`list-1.html`"> {{ secNavTitle }}</NuxtLink>
  40. </el-breadcrumb-item>
  41. </el-breadcrumb>
  42. </div>
  43. </div>
  44. <div class="breadcrumb_box pc_none">
  45. <span class=" ">当前位置:</span>
  46. <NuxtLink to="/">首页</NuxtLink>
  47. <span class=" " v-if="parent_name != ''">&gt;</span>
  48. <NuxtLink :to="`/${parent_pinyin}/index.html`" v-if="parent_name != ''"> {{ parent_name }}</NuxtLink>
  49. <span class="" >&gt;</span>
  50. <NuxtLink :to="`list-1.html`"> {{ secNavTitle }}</NuxtLink>
  51. </div>
  52. <section class="index_2 clearix phone_none" v-if="companyData.length > 0">
  53. <div class="index_2_left" v-if="companyData[0].data">
  54. <GoodsSwiperSnscShopInfoCateg :data="companyData[0].data"></GoodsSwiperSnscShopInfoCateg>
  55. </div>
  56. <div class="index_2_right">
  57. <div class="shop_head_2 clearfix">
  58. <NuxtLink class="shop_head_2_name" :href="getLinkPath1(companyData[0])">
  59. {{ companyData[0].alias }}
  60. </NuxtLink>
  61. </div>
  62. <div class="shop_ul_1 clearfix" v-if="companyData[0].data2">
  63. <NuxtLink class="shop_li_1 dot1" :href="getLinkPathDetail(item)" :title="item.title"
  64. v-for="(item, index) in companyData[0].data2" :key="index">
  65. {{ item.title }}
  66. </NuxtLink>
  67. </div>
  68. </div>
  69. </section>
  70. <div class="phone_box_1 pc_none" v-if="companyData.length > 0">
  71. <div class="phone_shop_head">
  72. <NuxtLink class=""
  73. :href="getLinkPath1(companyData[0])">
  74. {{ companyData[0].alias }}
  75. </NuxtLink>
  76. </div>
  77. <div class="phone_box_img_ul">
  78. <div class="" >
  79. <NuxtLink class=""
  80. v-for="(item, index) in companyData[0].data.slice(0, 1)"
  81. :href="getLinkPathDetail(item)"
  82. :key="index">
  83. <img class="" :src="item.imgurl" alt="">
  84. <span class="">
  85. {{ item.title }}
  86. </span>
  87. </NuxtLink>
  88. </div>
  89. </div>
  90. <div class="phone_box_ul">
  91. <NuxtLink class=""
  92. :href="getLinkPathDetail(item)"
  93. v-for="(item, index) in companyData[0].data2"
  94. :key="index">
  95. {{ item.title }}
  96. </NuxtLink>
  97. </div>
  98. </div>
  99. <section class="index_3 clearfix phone_none">
  100. <div class="index_3_left clearfix" v-if="companyData.length > 1">
  101. <!-- 农产科教1 -->
  102. <div class="shop_head_2 clearfix">
  103. <NuxtLink class="shop_head_2_name" :href="getLinkPath1(companyData[1])">
  104. {{ companyData[1].alias }}
  105. </NuxtLink>
  106. </div>
  107. <div class=" clearfix" v-if="companyData.length > 1">
  108. <div class="index_3_in clearfix">
  109. <div class="shop_img_ul_1 clearfix" v-if="companyData[1].data">
  110. <div class="shop_img_li_1 clearfix">
  111. <NuxtLink class="shop_img_li_1_a" :href="getLinkPathDetail(item)"
  112. v-for="(item, index) in companyData[1].data" :key="index" :title="item.title">
  113. <img class="shop_img_li_1_img" :src="item.imgurl" :title="item.title" alt="">
  114. <div class="shop_img_li_1_rgba clearfix dot1">
  115. {{ item.title }}
  116. </div>
  117. </NuxtLink>
  118. </div>
  119. </div>
  120. </div>
  121. <div class="index_3_in clearfix" v-if="companyData[1].data2">
  122. <div class="shop_ul_2 clearfix">
  123. <NuxtLink class="shop_li_2 clearfix dot1" :href="getLinkPathDetail(item)"
  124. :title="item.title" v-for="(item, index) in companyData[1].data2" :key="index">
  125. {{ item.title }}
  126. </NuxtLink>
  127. </div>
  128. </div>
  129. </div>
  130. <!-- 农产科教2 -->
  131. <!-- 农产商机1 -->
  132. <div class="shop_head_3 clearfix" v-if="companyData.length > 2">
  133. <NuxtLink class="shop_head_3_name" :href="getLinkPath1(companyData[2])">
  134. {{ companyData[2].alias }}
  135. </NuxtLink>
  136. </div>
  137. <div class=" clearfix">
  138. <div class="index_3_in_2 clearfix" v-if="companyData.length > 2">
  139. <div class="shop_img_ul_2 clearfix">
  140. <div class="shop_img_li_2 clearfix" v-if="companyData[2].data">
  141. <NuxtLink class="shop_img_li_2_a" :href="getLinkPathDetail(item)"
  142. v-for="(item, index) in companyData[2].data" :title="item.title">
  143. <img class="shop_img_li_2_img" :src="item.imgurl" :title="item.title" alt="">
  144. <div class="shop_img_li_2_rgba clearfix dot1">
  145. {{ item.title }}
  146. </div>
  147. </NuxtLink>
  148. </div>
  149. </div>
  150. </div>
  151. <div class="index_3_in_2 clearfix">
  152. <div class="shop_ul_3 clearfix" v-if="companyData[2].data2">
  153. <NuxtLink class="shop_li_3 clearfix dot1" :href="getLinkPathDetail(item)"
  154. :title="item.title" v-for="(item, index) in companyData[2].data2" :key="index">
  155. {{ item.title }}
  156. </NuxtLink>
  157. </div>
  158. </div>
  159. </div>
  160. <!-- 农产商机2 -->
  161. </div>
  162. <!-- 农产会展1 -->
  163. <div class="index_3_right" v-if="companyData.length > 3">
  164. <div class="shop_head_4 clearfix">
  165. <NuxtLink class="shop_head_4_name" :href="getLinkPath1(companyData[3])">
  166. {{ companyData[3].alias }}
  167. </NuxtLink>
  168. </div>
  169. <div class="shop_img_ul_3 clearfix">
  170. <div class="shop_img_li_3 clearfix" v-if="companyData[3].data">
  171. <NuxtLink class="shop_img_li_3_a" :href="getLinkPathDetail(item)"
  172. v-for="(item, index) in companyData[3].data" :key="index" :title="item.title">
  173. <img class="shop_img_li_3_img" :src="item.imgurl" :title="item.title" alt="">
  174. <div class="shop_img_li_3_rgba clearfix dot1">
  175. {{ item.title }}
  176. </div>
  177. </NuxtLink>
  178. </div>
  179. </div>
  180. <div class="shop_ul_4 clearfix" v-if="companyData[2].data2">
  181. <NuxtLink class="shop_li_4 dot1" :href="getLinkPathDetail(item)" :title="item.title"
  182. v-for="(item, index) in companyData[3].data2" :key="index">
  183. <span class="shop_li_4_num">
  184. {{ index + 1 }}
  185. </span>
  186. {{ item.title }}
  187. </NuxtLink>
  188. </div>
  189. </div>
  190. <!-- 农产会展2 -->
  191. </section>
  192. <div class="phone_box_2 pc_none" v-if="companyData.length > 1">
  193. <div class="phone_shop_head">
  194. <NuxtLink class=""
  195. :href="getLinkPath1(companyData[1])">
  196. {{ companyData[1].alias }}
  197. </NuxtLink>
  198. </div>
  199. <div class="phone_box_img_ul">
  200. <div class="" >
  201. <NuxtLink class=""
  202. :href="getLinkPathDetail(item)"
  203. v-for="(item, index) in companyData[1].data.slice(0,1)"
  204. :key="index" >
  205. <img class=" " :src="item.imgurl" alt="">
  206. <span class=" ">
  207. {{ item.title }}
  208. </span>
  209. </NuxtLink>
  210. </div>
  211. </div>
  212. <div class="phone_box_ul" v-if="companyData[1].data2">
  213. <NuxtLink class=""
  214. v-for="(item, index) in companyData[1].data2.slice(0,3)"
  215. :href="getLinkPathDetail(item)"
  216. :key="index">
  217. {{ item.title }}
  218. </NuxtLink>
  219. </div>
  220. </div>
  221. <div class="phone_box_3 pc_none" v-if="companyData.length > 2">
  222. <div class="phone_shop_head">
  223. <NuxtLink
  224. class=""
  225. :href="getLinkPath1(companyData[2])">
  226. {{ companyData[2].alias }}
  227. </NuxtLink>
  228. </div>
  229. <div class="phone_box_img_ul">
  230. <div class="" >
  231. <NuxtLink class=""
  232. :href="getLinkPathDetail(item)"
  233. v-for="(item, index) in companyData[2].data.slice(0,1)" >
  234. <img class="" :src="item.imgurl" alt="">
  235. <div class="">
  236. {{ item.title }}
  237. </div>
  238. </NuxtLink>
  239. </div>
  240. </div>
  241. <div class="phone_box_ul" v-if="companyData[2].data2">
  242. <NuxtLink class=""
  243. :href="getLinkPathDetail(item)"
  244. v-for="(item, index) in companyData[2].data2.slice(0,3)" :key="index">
  245. {{ item.title }}
  246. </NuxtLink>
  247. </div>
  248. </div>
  249. <div class="phone_box_4 pc_none" v-if="companyData.length > 3">
  250. <div class="phone_shop_head">
  251. <NuxtLink class=""
  252. :href="getLinkPath1(companyData[3])">
  253. {{ companyData[3].alias }}
  254. </NuxtLink>
  255. </div>
  256. <div class="phone_box_img_ul">
  257. <div class="" >
  258. <NuxtLink class=""
  259. v-for="(item, index) in companyData[3].data.slice(0,1)"
  260. :href="getLinkPathDetail(item)"
  261. :key="index" >
  262. <img class=" " :src="item.imgurl" alt="">
  263. <span class=" ">
  264. {{ item.title }}
  265. </span>
  266. </NuxtLink>
  267. </div>
  268. </div>
  269. <div class="phone_box_ul" v-if="companyData[2].data2">
  270. <NuxtLink class=""
  271. v-for="(item, index) in companyData[3].data2.slice(0,3)"
  272. :href="getLinkPathDetail(item)"
  273. :key="index">
  274. {{ item.title }}
  275. </NuxtLink>
  276. </div>
  277. </div>
  278. </section>
  279. </div>
  280. </template>
  281. <script setup>
  282. //0.加载页面依赖 start ---------------------------------------->
  283. import { ref, onMounted } from 'vue';
  284. import { ElMessage, ElBreadcrumb, ElBreadcrumbItem } from 'element-plus';
  285. import { ArrowRight } from '@element-plus/icons-vue'
  286. import { NuxtLink } from '#components';
  287. //0.加载页面依赖 end ---------------------------------------->
  288. //1.获得路由id start ---------------------------------------->
  289. const targetSegment2 = getRoutePath(2);
  290. const targetSegment1 = getRoutePath(1);
  291. //1.1 获得当前的路由id
  292. let routeId;
  293. let routeType;
  294. let secNavTitle = ref('')//二级导航标题
  295. //通过导航路径反向查询导航id
  296. const getRouteId = await requestDataPromise('/web/getWebsiteRoute', {
  297. method: 'GET',
  298. query: {
  299. 'pinyin': targetSegment1 + '/' + targetSegment2,
  300. },
  301. });
  302. console.log("getRouteId", getRouteId);
  303. if (getRouteId.code == 200) {
  304. routeId = getRouteId.data.category_id
  305. secNavTitle.value = getRouteId.data.alias
  306. routeType = getRouteId.data.type
  307. } else {
  308. console.log("获得路由id出错!", getRouteId.message)
  309. }
  310. //1.2 获得父级栏目
  311. let parent_name = ref('');//父级名称
  312. let parent_id = ref('');//父级id
  313. let parent_pinyin = ref('');//父级拼音
  314. const getRoutePName = await requestDataPromise('/web/getWebsiteRoute', {
  315. method: 'GET',
  316. query: {
  317. 'pinyin': targetSegment1,
  318. },
  319. });
  320. // console.log("getRoutePName", getRoutePName);
  321. if (getRoutePName.code == 200) {
  322. parent_id.value = getRoutePName.data.category_id
  323. parent_name.value = getRoutePName.data.alias
  324. } else {
  325. console.log("获得路由id出错!", getRoutePName.message)
  326. }
  327. const getParentId = await requestDataPromise('/web/getOneWebsiteCategory', {
  328. method: 'GET',
  329. query: {
  330. 'catid': parent_id.value,
  331. },
  332. });
  333. // console.log("getParentId", getParentId);
  334. if (getParentId.code == 200) {
  335. parent_pinyin.value = getParentId.data.aLIas_pinyin
  336. } else {
  337. console.log("获得路由id出错!", getParentId.message)
  338. }
  339. //1.获得路由id end ---------------------------------------->
  340. //2.选项卡 start ---------------------------------------->
  341. let showTabs = ref(1)
  342. let qhtabs = function (number) {
  343. console.log(number)
  344. showTabs.value = number
  345. }
  346. //2.选项卡 end ---------------------------------------->
  347. //3.广告 start ---------------------------------------->
  348. let adImg1 = ref({})
  349. let adImg2 = ref({})
  350. let adImg3 = ref({})
  351. let adImg4 = ref({})
  352. onMounted(async () => {
  353. //从客户端获取行政职能部门 加快打开速度
  354. const { $webUrl, $CwebUrl } = useNuxtApp();
  355. //广告1
  356. let url = `${$webUrl}/web/getWebsiteAdvertisement?ad_tag=snzxw_category_0001`
  357. const responseAd1 = await fetch(url, {
  358. headers: {
  359. 'Content-Type': 'application/json',
  360. 'Userurl': $CwebUrl,
  361. 'Origin': $CwebUrl
  362. }
  363. });
  364. const resultAd1 = await responseAd1.json();
  365. adImg1.value = resultAd1.data[0];
  366. //广告2
  367. let url2 = `${$webUrl}/web/getWebsiteAdvertisement?ad_tag=snzxw_category_0002`
  368. const responseAd2 = await fetch(url2, {
  369. headers: {
  370. 'Content-Type': 'application/json',
  371. 'Userurl': $CwebUrl,
  372. 'Origin': $CwebUrl
  373. }
  374. });
  375. const resultAd2 = await responseAd2.json();
  376. adImg2.value = resultAd2.data[0];
  377. //广告3
  378. let url3 = `${$webUrl}/web/getWebsiteAdvertisement?ad_tag=snzxw_category_0003`
  379. const responseAd3 = await fetch(url3, {
  380. headers: {
  381. 'Content-Type': 'application/json',
  382. 'Userurl': $CwebUrl,
  383. 'Origin': $CwebUrl
  384. }
  385. });
  386. const resultAd3 = await responseAd3.json();
  387. adImg3.value = resultAd3.data[0];
  388. //广告4
  389. let url4 = `${$webUrl}/web/getWebsiteAdvertisement?ad_tag=snzxw_category_0004`
  390. const responseAd4 = await fetch(url4, {
  391. headers: {
  392. 'Content-Type': 'application/json',
  393. 'Userurl': $CwebUrl,
  394. 'Origin': $CwebUrl
  395. }
  396. });
  397. const resultAd4 = await responseAd4.json();
  398. adImg4.value = resultAd4.data[0];
  399. })
  400. //3.广告 end ---------------------------------------->
  401. //4.页面数据 start ---------------------------------------->
  402. const pageData = ref([
  403. //示例:
  404. // {
  405. // id: 1,
  406. // title: "", //该导航的标题
  407. // data: [], //数据1
  408. // data1: [], //数据2
  409. // data2: [], //数据3
  410. // data3: [], //数据4
  411. // data4: [], //数据5
  412. // category_id1: "", //子导航id1
  413. // category_id2: "",
  414. // category_id3: "",
  415. // category_id4: "",
  416. // title1: "", //子导航标题1
  417. // title2: "",
  418. // title3: "",
  419. // title4: "",
  420. // cid: "" //该导航的id
  421. // },
  422. ])
  423. const companyData = ref([])
  424. //4.1 获取所有导航
  425. try {
  426. const navigateData = await requestDataPromise('/web/getWebsiteModelCategory', {
  427. method: 'GET',
  428. query: {
  429. 'placeid': 1,
  430. 'pid': routeId,
  431. 'num': 8,
  432. 'type': 1
  433. },
  434. });
  435. // console.log('获取三级导航1111111', navigateData);
  436. if (navigateData.code == 200) {
  437. // 遍历可用的导航池放到页面中
  438. for (let index in navigateData.data) {
  439. let data = {
  440. title: navigateData.data[index].name,
  441. cid: navigateData.data[index].category_id,
  442. children_count: navigateData.data[index].children_count,
  443. alias: navigateData.data[index].alias,
  444. aLIas_pinyin: targetSegment1 + "/" + targetSegment2 + "/" + navigateData.data[index].aLIas_pinyin,
  445. type: navigateData.data[index].type,
  446. data: [],
  447. data1: [],
  448. data2: [],
  449. data3: [],
  450. data4: [],
  451. category_id1: "",
  452. category_id2: "",
  453. category_id3: "",
  454. category_id4: "",
  455. title1: "",
  456. title2: "",
  457. title3: "",
  458. title4: ""
  459. };
  460. if (navigateData.data[index].is_url == 1) {
  461. // 处理 URL 的逻辑
  462. } else {
  463. if (navigateData.data[index].type == 6) {
  464. companyData.value.push(data);
  465. }
  466. //每个页面最多8个模块
  467. pageData.value.push(data);
  468. }
  469. }
  470. // console.log('获取三级导航pageData', pageData.value);
  471. console.log('获取三级导航company', companyData.value);
  472. //导航池加载完毕,开始申请模块数据
  473. let getJson = []
  474. for (let i = 0; i < companyData.value.length; i++) {
  475. if (i == 0) {
  476. getJson.push({ "id": companyData.value[0].cid + ",4,9" })
  477. } else if (i == 1) {
  478. getJson.push({ "id": companyData.value[1].cid + ",1,6" })
  479. } else if (i == 2) {
  480. getJson.push({ "id": companyData.value[2].cid + ",1,6" })
  481. } else if (i == 3) {
  482. getJson.push({ "id": companyData.value[3].cid + ",1,6" })
  483. }
  484. }
  485. if (companyData.value.length > 0) {
  486. let jsonString = JSON.stringify(getJson);
  487. getPageAllData(jsonString);
  488. }
  489. } else {
  490. console.log("错误:渲染8个模块环节出错,请检查是否存在没有数据的模块!")
  491. }
  492. } catch (error) {
  493. console.log("错误:导航池渲染执行接口出错!请检查频道页渲染的模块数据是否完整!")
  494. }
  495. async function getPageAllData(jsonString) {
  496. const mkdata = await requestDataPromise('/web/getWebsiteCompany', {
  497. method: 'GET',
  498. query: {
  499. 'id': jsonString
  500. },
  501. });
  502. // console.log('获取模块数据', mkdata);
  503. if (mkdata.code == 200) {
  504. //模块1 顶部大图和列表
  505. companyData.value[0].data = mkdata.data[0].img_num;
  506. companyData.value[0].data2 = mkdata.data[0].text_num;
  507. //模块2
  508. companyData.value[1].data = mkdata.data[1].img_num;
  509. companyData.value[1].data2 = mkdata.data[1].text_num;
  510. //模块3
  511. companyData.value[2].data = mkdata.data[2].img_num;
  512. companyData.value[2].data2 = mkdata.data[2].text_num;
  513. //模块4
  514. companyData.value[3].data = mkdata.data[3].img_num;
  515. companyData.value[3].data2 = mkdata.data[3].text_num;
  516. } else {
  517. ElMessage.error(mkdata.message)
  518. }
  519. }
  520. //4.页面数据 end ---------------------------------------->
  521. //5.设置seo信息 start---------------------------------------->
  522. const setData = await requestDataPromise('/web/getWebsiteCategoryHead', {
  523. method: 'GET',
  524. query: {
  525. 'catid': routeId
  526. },
  527. });
  528. if (setData.code == 200) {
  529. let seoTitle = setData.data.seo_title;
  530. let seoDescription = setData.data.seo_description;
  531. let seoKeywords = setData.data.seo_keywords;
  532. let seoSuffix = setData.data.suffix;
  533. let seoName = setData.data.website_name;
  534. useSeoMeta({
  535. title: seoTitle + "_" + seoSuffix,
  536. meta: [
  537. { name: 'keywords', content: seoKeywords + "_" + seoName + "_" + seoSuffix, tagPriority: 10 },
  538. { name: 'description', content: seoDescription + "_" + seoName + "_" + seoSuffix, tagPriority: 10 },
  539. { name: 'viewport', content: 'width=device-width,initial-scale=1,user-scalable=no',tagPriority: 10 }
  540. ]
  541. });
  542. } else {
  543. console.log("设置频道页SEO出错!", setData.message)
  544. }
  545. //5.设置seo信息 end---------------------------------------->
  546. </script>
  547. <style lang="less" scoped>
  548. @import url("@/assets/css/shop/newsClass.less");
  549. .company {
  550. width: 1200px;
  551. margin: 0 auto;
  552. }
  553. //导航条
  554. .breadcrumb {
  555. width: 100%;
  556. height: 22px;
  557. padding-bottom: 30px;
  558. border-bottom: 1px solid #ccc;
  559. font-family: Microsoft YaHei, Microsoft YaHei;
  560. font-weight: 400;
  561. font-size: 20px;
  562. color: #666666;
  563. line-height: 23px;
  564. text-align: left;
  565. font-style: normal;
  566. text-transform: none;
  567. margin-top: 40px;
  568. :deep(.el-breadcrumb) {
  569. display: inline-block;
  570. vertical-align: -4px;
  571. }
  572. :deep(.el-breadcrumb__inner a),
  573. :deep(.el-breadcrumb__inner.is-link) {
  574. color: #666666;
  575. font-weight: 400;
  576. text-decoration: none;
  577. transition: var(--el-transition-color);
  578. }
  579. span {
  580. font-family: Microsoft YaHei, Microsoft YaHei;
  581. font-weight: 400;
  582. font-size: 20px;
  583. color: #666666;
  584. line-height: 23px;
  585. text-align: left;
  586. font-style: normal;
  587. text-transform: none;
  588. }
  589. span:hover {
  590. color: #666666;
  591. }
  592. .location {
  593. margin-right:5px;
  594. width: 100px;
  595. height: 22px;
  596. font-family: Microsoft YaHei, Microsoft YaHei;
  597. font-weight: 400;
  598. font-size: 20px;
  599. color: #666666;
  600. line-height: 23px;
  601. text-align: left;
  602. font-style: normal;
  603. text-transform: none;
  604. }
  605. }
  606. </style>
  607. <style lang="less" scoped>
  608. @media screen and (min-width:801px){/*pc*/
  609. .index_2{overflow:hidden;}
  610. .pc_none{display:none;}
  611. }
  612. @media screen and (max-width:800px){/*ipad_phone*/
  613. .company{ width: 100%; margin:0px auto 0px;}
  614. .phone_nav{
  615. width:100%; box-sizing:border-box;background:#fafafa;
  616. margin:10px auto;height:33px;
  617. .phone_nav_in{ width:92%;margin:0px auto;
  618. overflow-x:auto;overflow-y:hidden;
  619. word-break: keep-all; white-space: nowrap;
  620. line-height:33px;
  621. height:33px;
  622. }
  623. .phone_nav_in::-webkit-scrollbar{height:0px;}
  624. .phone_nav_a{display:inline-block;line-height:33px;height:33px;
  625. color:#333;font-size:14px;margin:0px 10px;
  626. }
  627. .phone_nav_a:nth-of-type(1){margin-left:0px;}
  628. }
  629. .phone_nav_a.active{
  630. color:#255590;
  631. }
  632. .breadcrumb_box {
  633. height: 22px;
  634. width: 92%;
  635. margin: 10px auto;
  636. word-break: keep-all;
  637. white-space: nowrap;
  638. overflow: hidden;
  639. text-overflow: ellipsis;
  640. font-size: 14px;
  641. color: #666;
  642. * {
  643. font-size: 14px;
  644. display: inline;
  645. color: #666;
  646. line-height: 22px;
  647. height: 22px;
  648. margin-right: 5px;
  649. }
  650. }
  651. .phone_box_1{
  652. width:92%;margin:0px auto 0px;
  653. .phone_shop_head{overflow:hidden;margin-top:15px;
  654. a{ float:left;height:50px;line-height:50px;margin:0;position:relative;
  655. color:#255590;font-size:18px; font-weight:bold;box-sizing:border-box;
  656. padding-left:18px;
  657. background:url(@/public/shop/01.png) no-repeat left center;
  658. background-size:10px 14px;
  659. }
  660. }
  661. .phone_box_img_ul{
  662. height:55vw;overflow:hidden;
  663. div{width:100%;float:none;height:55vw;border-radius:10px;position:relative;overflow:hidden;}
  664. a{display:block;width:100%;height:100%;}
  665. img{display:block;width:100%;height:100%;}
  666. span{
  667. position:absolute;width:100%;height:66px;line-height:90px;color:#fff; font-size:16px;
  668. left:0px;bottom:0px;padding:0px 5%;box-sizing:border-box; display:block;
  669. background:linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, .5));
  670. word-break: keep-all; white-space: nowrap;overflow:hidden;text-overflow:ellipsis;
  671. }
  672. >div:nth-of-type(n+2){display:none;}
  673. }
  674. .phone_box_ul{
  675. overflow:hidden;height:123px;margin:8px auto 0px;
  676. >div{width:100%;height:100%;}
  677. a{
  678. width:100%!important;display:block;height:40px;line-height:40px;
  679. border-bottom:1px solid #E6E6E6;display:block;position:relative;
  680. word-break: keep-all; white-space: nowrap;overflow:hidden;text-overflow:ellipsis;
  681. font-size:16px;color:#333;text-indent:18px;
  682. }
  683. a::after{
  684. content: '';display: block;
  685. position:absolute;left:0px;top:18px;background:#E6E6E6;
  686. width:6px;height:6px;
  687. }
  688. a:nth-of-type(n+4){display:none;}
  689. }
  690. }
  691. .phone_box_2{
  692. width:92%;margin:0px auto 0px;
  693. .phone_shop_head{overflow:hidden;margin-top:15px;
  694. a{ float:left;height:50px;line-height:50px;margin:0;position:relative;
  695. color:#255590;font-size:18px; font-weight:bold;box-sizing:border-box;
  696. padding-left:18px;
  697. background:url(@/public/shop/01.png) no-repeat left center;
  698. background-size:10px 14px;
  699. }
  700. }
  701. .phone_box_img_ul{
  702. height:55vw;overflow:hidden;
  703. div{width:100%;float:none;height:55vw;border-radius:10px;position:relative;overflow:hidden;}
  704. a{display:block;width:100%;height:100%;}
  705. img{display:block;width:100%;height:100%;}
  706. span{
  707. position:absolute;width:100%;height:66px;line-height:90px;color:#fff; font-size:16px;
  708. left:0px;bottom:0px;padding:0px 5%;box-sizing:border-box; display:block;
  709. background:linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, .5));
  710. word-break: keep-all; white-space: nowrap;overflow:hidden;text-overflow:ellipsis;
  711. }
  712. >div:nth-of-type(n+2){display:none;}
  713. }
  714. .phone_box_ul{
  715. overflow:hidden;height:123px;margin:8px auto 0px;
  716. >div{width:100%;height:100%;}
  717. a{
  718. width:100%!important;display:block;height:40px;line-height:40px;
  719. border-bottom:1px solid #E6E6E6;display:block;position:relative;
  720. word-break: keep-all; white-space: nowrap;overflow:hidden;text-overflow:ellipsis;
  721. font-size:16px;color:#333;text-indent:18px;
  722. }
  723. a::after{
  724. content: '';display: block;
  725. position:absolute;left:0px;top:18px;background:#E6E6E6;
  726. width:6px;height:6px;
  727. }
  728. a:nth-of-type(n+4){display:none;}
  729. }
  730. }
  731. .phone_box_3{
  732. width:92%;margin:0px auto 0px;
  733. .phone_shop_head{overflow:hidden;margin-top:15px;
  734. a{ float:left;height:50px;line-height:50px;margin:0;position:relative;
  735. color:#255590;font-size:18px; font-weight:bold;box-sizing:border-box;
  736. padding-left:18px;
  737. background:url(@/public/shop/01.png) no-repeat left center;
  738. background-size:10px 14px;
  739. }
  740. }
  741. .phone_box_img_ul{
  742. height:55vw;overflow:hidden;
  743. div{width:100%;float:none;height:55vw;border-radius:10px;position:relative;overflow:hidden;}
  744. a{display:block;width:100%;height:100%;}
  745. img{display:block;width:100%;height:100%;}
  746. span{
  747. position:absolute;width:100%;height:66px;line-height:90px;color:#fff; font-size:16px;
  748. left:0px;bottom:0px;padding:0px 5%;box-sizing:border-box; display:block;
  749. background:linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, .5));
  750. word-break: keep-all; white-space: nowrap;overflow:hidden;text-overflow:ellipsis;
  751. }
  752. >div:nth-of-type(n+2){display:none;}
  753. }
  754. .phone_box_ul{
  755. overflow:hidden;height:123px;margin:8px auto 0px;
  756. >div{width:100%;height:100%;}
  757. a{
  758. width:100%!important;display:block;height:40px;line-height:40px;
  759. border-bottom:1px solid #E6E6E6;display:block;position:relative;
  760. word-break: keep-all; white-space: nowrap;overflow:hidden;text-overflow:ellipsis;
  761. font-size:16px;color:#333;text-indent:18px;
  762. }
  763. a::after{
  764. content: '';display: block;
  765. position:absolute;left:0px;top:18px;background:#E6E6E6;
  766. width:6px;height:6px;
  767. }
  768. a:nth-of-type(n+4){display:none;}
  769. }
  770. }
  771. .phone_box_4{
  772. width:92%;margin:0px auto 0px;
  773. .phone_shop_head{overflow:hidden;margin-top:15px;
  774. a{ float:left;height:50px;line-height:50px;margin:0;position:relative;
  775. color:#255590;font-size:18px; font-weight:bold;box-sizing:border-box;
  776. padding-left:18px;
  777. background:url(@/public/shop/01.png) no-repeat left center;
  778. background-size:10px 14px;
  779. }
  780. }
  781. .phone_box_img_ul{
  782. height:55vw;overflow:hidden;
  783. div{width:100%;float:none;height:55vw;border-radius:10px;position:relative;overflow:hidden;}
  784. a{display:block;width:100%;height:100%;}
  785. img{display:block;width:100%;height:100%;}
  786. span{
  787. position:absolute;width:100%;height:66px;line-height:90px;color:#fff; font-size:16px;
  788. left:0px;bottom:0px;padding:0px 5%;box-sizing:border-box; display:block;
  789. background:linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, .5));
  790. word-break: keep-all; white-space: nowrap;overflow:hidden;text-overflow:ellipsis;
  791. }
  792. >div:nth-of-type(n+2){display:none;}
  793. }
  794. .phone_box_ul{
  795. overflow:hidden;height:123px;margin:8px auto 0px;
  796. >div{width:100%;height:100%;}
  797. a{
  798. width:100%!important;display:block;height:40px;line-height:40px;
  799. border-bottom:1px solid #E6E6E6;display:block;position:relative;
  800. word-break: keep-all; white-space: nowrap;overflow:hidden;text-overflow:ellipsis;
  801. font-size:16px;color:#333;text-indent:18px;
  802. }
  803. a::after{
  804. content: '';display: block;
  805. position:absolute;left:0px;top:18px;background:#E6E6E6;
  806. width:6px;height:6px;
  807. }
  808. a:nth-of-type(n+4){display:none;}
  809. }
  810. }
  811. .phone_none{display:none;}
  812. }
  813. </style>