diaoyanxuanti.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573
  1. <template>
  2. <!-- 页面头部 -->
  3. <HomePageHead></HomePageHead>
  4. <!-- 导航栏 -->
  5. <HomePageNavigation></HomePageNavigation>
  6. <!-- 面包屑导航 -->
  7. <div class="breadcrumb-box">
  8. <div class="inner">
  9. <span class="location">当前位置:</span>
  10. <el-breadcrumb :separator-icon="ArrowRight">
  11. <el-breadcrumb-item>
  12. <NuxtLink to="/">首页</NuxtLink>
  13. </el-breadcrumb-item>
  14. <el-breadcrumb-item class="phone_breadcrumb_text">人员查询</el-breadcrumb-item>
  15. </el-breadcrumb>
  16. </div>
  17. </div>
  18. <!-- 查询 -->
  19. <div class="search-box">
  20. <div class="search-left-box">
  21. <div class="dytlt">
  22. <NuxtLink to="/">所有选题</NuxtLink>
  23. </div>
  24. <ul class="xtlist">
  25. <li>黑龙江建三江管理局前进农场金三角半地下门市污水倒灌问题及责任追溯调研</li>
  26. <li>关于营口仙人岛祥烽旅游开发有限公司员工王勇的死亡赔偿纠纷一事进行调研核实</li>
  27. <li>关于山东省曹县未知名企业漂洗废布废料是否造成污染一事需要调研的申请</li>
  28. <li>关于山西省吕梁市临县城庄镇石盘头村梓腾种养专业合作社2025年12月1日发生一起安全事故致人死亡,涉嫌工伤瞒报进行调研</li>
  29. <li>关于隆回县北山镇小伍村农村自建房违规圈地一事的调研</li>
  30. <li>关于北票龙潭盖宏彦涉嫌在朝阳黄金冶炼厂倒卖氰化尾渣一事进行调研核实</li>
  31. <li>关于唐县黄石口镇一企业违规占地一事的调研</li>
  32. <li>关于怀仁市煤炭企业与生态环境措施相关事宜进行调研</li>
  33. <li>关于荆门市掇刀区团林铺镇人民政府违法强拆何金石房屋,猪场的违法行为和补偿不足一事的调研</li>
  34. <li>关于临湘市桃林镇坪上村农村自建房违规圈地一事的调研</li>
  35. <li>关于大同市恒安街北侧城市棚户区改造项目(s6、s7、s8)拒付高佑工程款相关事宜进行调研</li>
  36. <li>关于开封市杞县马廷进自家宅基地被侵占一事调研核实</li>
  37. <li>关于新乡市原阳县信访局陈庆利涉嫌隐瞒信访事项、打压信访人等违规行为一事进行调研核实</li>
  38. <li>关于洞口县岩山镇陡山村农村自建房违规圈地一事调研</li>
  39. <li>关于洪江市安江镇白虎脑社区一别墅违规圈地一事调研</li>
  40. <li>关于济宁市泗水县石料加工污水外排,环保设置不齐全调研申请</li>
  41. <li>关于济宁市一无名石料加工厂在组织生产期间无视环保要求,污水外排,环保设置不齐全不使用,需要实地调研特申请</li>
  42. <li>关于陕西星火煤业有限责任公司于2025年6月19日发生事故致人死亡,涉嫌公伤瞒报一事进行调研核实</li>
  43. <li>关于中科招商增股中违规操作,致投资者合法权益严重受损等情况进行调研核实</li>
  44. <li>关于山西怀仁中能芦子沟何家堡煤业有限责任公司越界开釆一事进行调研</li>
  45. </ul>
  46. <div class="pagesnav">
  47. <a>更多选题请联系客服</a>
  48. </div>
  49. </div>
  50. <div class="search-right-box">
  51. <!--选题查询-->
  52. <div class="search-right-box-form">
  53. <h3>选题查询</h3>
  54. <div class="search-right-form-text">
  55. 请输入您想要查询的选题
  56. </div>
  57. <div class="search-right-select-box">
  58. 地区:
  59. <el-select v-model="province" placeholder="--" size="large" style="width: 120px" popper-class="custom-select-dropdown">
  60. <el-option v-for="item in provinceList" :key="item.id" :label="item.name"
  61. @click="change(item.id)" :value="item.id" />
  62. </el-select>
  63. <el-select v-model="city" placeholder="--" no-data-text="请先选择省份" size="large"
  64. style="width: 120px" popper-class="custom-select-dropdown">
  65. <el-option v-for="(item, index) in cityList" :key="item.id" :label="item.name"
  66. @click="change1(item.id)" :value="item.id" />
  67. </el-select>
  68. <el-select v-model="region" placeholder="--" no-data-text="请先选择市" size="large"
  69. style="width: 120px" popper-class="custom-select-dropdown">
  70. <el-option v-for="item in regionList" :key="item.id" :label="item.name" :value="item.id" />
  71. </el-select>
  72. </div>
  73. <div class="search-right-input-box">
  74. <el-input v-model="input" placeholder="选题名称" />
  75. </div>
  76. <div class="search-right-button-box">
  77. <button class="submit-button">查询</button>
  78. <button class="reset-button">重置</button>
  79. </div>
  80. </div>
  81. <!--车辆查询-->
  82. <div class="search-right-box-form">
  83. <h3>车辆查询</h3>
  84. <div class="search-right-form-text">请输入相关工作车辆或车牌号</div>
  85. <div class="search-right-input-box">
  86. <el-input v-model="input" placeholder="车牌" />
  87. </div>
  88. <div class="search-right-input-box">
  89. <el-input v-model="input" placeholder="车型" />
  90. </div>
  91. <div class="search-right-button-box">
  92. <button class="submit-button">查询</button>
  93. <button class="reset-button">重置</button>
  94. </div>
  95. </div>
  96. </div>
  97. </div>
  98. <!-- 页面底部 -->
  99. <HomeFoot></HomeFoot>
  100. </template>
  101. <script setup>
  102. //1.页面依赖 start ---------------------------------------->
  103. import { onMounted } from 'vue'
  104. import { ElBreadcrumb, ElBreadcrumbItem,ElMessage,ElInput,ElSelect,ElOption } from 'element-plus'
  105. import { ArrowRight } from '@element-plus/icons-vue'
  106. const nuxtApp = useNuxtApp();
  107. const axios = nuxtApp.$axios;
  108. //1.1 获得跳转过来的id
  109. const route = useRoute();
  110. //获得详情id
  111. const articleId = parseInt(route.params.id); //获得该页面的id
  112. //获得当前的完整路径
  113. const fullPath = route.path;
  114. //拆分,取出来中间这一段,然后提取数字部分
  115. const segments = fullPath.split('/');
  116. const targetSegment = segments[1];
  117. // const numberPart = targetSegment.match(/\d+$/)?.[0];
  118. // let routeId = 20 //排除路径错误可以打开这个
  119. // const routeId = numberPart;
  120. let routeId;
  121. //通过导航路径反向查询导航id
  122. const getRouteId = await requestDataPromise('/web/getWebsiteRoute', {
  123. method: 'GET',
  124. query: {
  125. 'pinyin': targetSegment,
  126. },
  127. });
  128. if(getRouteId.code == 200){
  129. routeId = getRouteId.data.category_id
  130. }else{
  131. console.log("SSR waring ---------- SSR waring ---------- SSR waring ---------->")
  132. console.log("错误位置:通过url路径查询导航池id")
  133. console.log("后端错误反馈:",getRouteId.message)
  134. console.log("SSR waring ---------- SSR waring ---------- SSR waring ---------->")
  135. }
  136. //1.2 获得父级栏目的名称、id
  137. const parent_name = ref([]);
  138. const parent_id = ref([]);
  139. const parent_pinyin = ref("");
  140. const parent_children_count = ref(0)
  141. let getParentNav = async () => {
  142. const listData = await requestDataPromise('/web/getOneWebsiteCategory', {
  143. method: 'GET',
  144. query: {
  145. 'catid': routeId
  146. },
  147. });
  148. console.log("获取父级栏目数据")
  149. console.log(listData)
  150. if (listData.code == 200) {
  151. console.log(listData.data);
  152. parent_name.value = listData.data.alias;
  153. parent_id.value = listData.data.parent_id;
  154. parent_pinyin.value = listData.data.aLIas_pinyin;
  155. parent_children_count.value = listData.data.children_count;
  156. } else {
  157. console.log("SSR waring ---------- SSR waring ---------- SSR waring ---------->")
  158. console.log("错误位置:获取面包屑导航")
  159. console.log("后端错误反馈:", listData.message)
  160. console.log("SSR waring ---------- SSR waring ---------- SSR waring ---------->")
  161. }
  162. }
  163. //获得父级栏目详情
  164. getParentNav();
  165. //1.页面依赖 end ---------------------------------------->
  166. //2.页面数据 start ---------------------------------------->
  167. //2.1 资讯详情
  168. const newsDetail = ref({})
  169. const routeNewsTtitle = ref("");
  170. //2.2 发布日期
  171. const time = ref("");
  172. //2.3 路径
  173. const routLevelTitle = ref("");
  174. const routLevelId = ref("");
  175. //是否展示投票
  176. const articleChoice = ref(false);
  177. //2.4获取详情
  178. async function getPageData() {
  179. const mkdata = await requestDataPromise('/web/selectWebsiteArticleInfo', {
  180. method: 'GET',
  181. query: {
  182. 'articleid': articleId
  183. },
  184. });
  185. if(mkdata.code==200){
  186. //判断是否显示投票
  187. if(mkdata.data.is_survey==1){
  188. console.log("本篇文章含有投票!")
  189. articleChoice.value = true;
  190. getVoteList();
  191. }
  192. //获取内容
  193. newsDetail.value = mkdata.data;
  194. //获取路径
  195. routLevelTitle.value = newsDetail.value.cat_name;
  196. routLevelId.value = newsDetail.value.category_id;
  197. //获取发布时间
  198. time.value = newsDetail.value.updated_at.split(' ')[0];
  199. //修正标题长度
  200. if (newsDetail.value.title.length >= 30) {
  201. routeNewsTtitle.value = newsDetail.value.title.substr(0, 30) + "...";
  202. } else {
  203. routeNewsTtitle.value = newsDetail.value.title
  204. }
  205. }else{
  206. console.log("SSR waring ---------- SSR waring ---------- SSR waring ---------->")
  207. console.log("错误位置:获取详情内容")
  208. console.log("后端错误反馈:",mkdata.message)
  209. console.log("SSR waring ---------- SSR waring ---------- SSR waring ---------->")
  210. }
  211. }
  212. getPageData();
  213. //2.5 获得广告
  214. //广告列表
  215. let adImg1 = ref([]);
  216. onMounted(async () => {
  217. const { $webUrl, $CwebUrl } = useNuxtApp();
  218. //广告1
  219. let url = `${$webUrl}/web/getWebsiteAdvertisement?ad_tag=snzxw_detail_0001`
  220. const responseAd1 = await fetch(url, {
  221. headers: {
  222. 'Content-Type': 'application/json',
  223. 'Userurl': $CwebUrl,
  224. 'Origin': $CwebUrl
  225. }
  226. });
  227. const resultAd1 = await responseAd1.json();
  228. adImg1.value = resultAd1.data[0];
  229. })
  230. //2.页面数据 end ---------------------------------------->
  231. //3.设置seo信息 start---------------------------------------->
  232. //3.1 设置seo信息
  233. const setData = await requestDataPromise('/web/selectWebsiteArticleInfo', {
  234. method: 'GET',
  235. query: {
  236. 'articleid': articleId
  237. },
  238. });
  239. if(setData.code==200){
  240. let seoTitle = setData.data.title;
  241. let seoDescription = setData.data.introduce;
  242. let seoKeywords = setData.data.keyword;
  243. let seoSuffix = setData.data.suffix;
  244. let seoName = setData.data.website_name;
  245. useSeoMeta({
  246. title: seoTitle + "_" + seoName + "_" + seoSuffix,
  247. meta: [
  248. { name: 'description', content: seoDescription + "_" + seoName + "_" + seoSuffix , tagPriority: 10 },
  249. { name: 'keywords', content: seoKeywords + "_" + seoName + "_" + seoSuffix , tagPriority: 10 },
  250. { name: 'viewport', content: 'width=device-width,initial-scale=1,user-scalable=no',tagPriority: 10 }
  251. ]
  252. });
  253. }else{
  254. console.log("SSR waring ---------- SSR waring ---------- SSR waring ---------->")
  255. console.log("错误位置:设置详情页面SEO数据")
  256. console.log("后端错误反馈:",setData.message)
  257. console.log("SSR waring ---------- SSR waring ---------- SSR waring ---------->")
  258. }
  259. //3.设置seo信息 end---------------------------------------->
  260. //4.展示行政区划 start ---------------------------------------->
  261. //let areaList = ref("")
  262. //4.1 省
  263. let province = ref("")
  264. let provinceid = ref("")
  265. let provinceList = ref("")
  266. //4.2 市
  267. let city = ref("")
  268. let cityid = ref("")
  269. let cityList = ref("")
  270. //4.3 县
  271. let region = ref("")
  272. let regionid = ref("")
  273. let regionList = ref("")
  274. //选择市
  275. let change = async (id) => {
  276. provinceid.value = id;
  277. const shengData = await requestDataPromise('/web/selectWebsiteArea', {
  278. method: 'GET',
  279. query: {
  280. 'pid': id,
  281. },
  282. });
  283. cityList.value = shengData.data;
  284. regionList.value = [];// 清空县
  285. }
  286. //选择县
  287. let change1 = async (id) => {
  288. cityid.value = id;
  289. const xianData = await requestDataPromise('/web/selectWebsiteArea', {
  290. method: 'GET',
  291. query: {
  292. 'pid': id,
  293. },
  294. });
  295. regionList.value = xianData.data;
  296. }
  297. let change2 = async (id) => {
  298. regionid.value = id;
  299. }
  300. onMounted(async () => {
  301. //从客户端获取行政区划
  302. try {
  303. const { $webUrl, $CwebUrl } = useNuxtApp();
  304. const response2 = await fetch($webUrl + '/web/selectWebsiteArea', {
  305. headers: {
  306. 'Content-Type': 'application/json',
  307. 'Userurl': $CwebUrl,
  308. 'Origin': $CwebUrl
  309. }
  310. });
  311. const result2 = await response2.json();
  312. provinceList.value = result2.data;
  313. } catch (error) {
  314. console.error('获取行政区划数据失败:', error);
  315. }
  316. const targetElement = document.querySelector('.pc_none li .router-link-exact-active');
  317. const parentElement = document.querySelector('.nav_in');
  318. if (targetElement && parentElement) {
  319. const targetRect = targetElement.getBoundingClientRect();
  320. const parentRect = parentElement.getBoundingClientRect();
  321. const distanceToParentLeft = targetRect.left - parentRect.left;
  322. const navigationElement = document.querySelector('.partOne .navigationOne');
  323. if (navigationElement) {
  324. navigationElement.scrollLeft = distanceToParentLeft - 66;
  325. }
  326. }
  327. })
  328. //4.展示行政区划 end ---------------------------------------->
  329. //5.表单 start---------------------------------------->
  330. let input = ref("");
  331. let value = ref("1");
  332. const submitForm = () => {
  333. console.log(input.value)
  334. console.log(value.value)
  335. }
  336. //5.表单 end---------------------------------------->
  337. </script>
  338. <style lang="less" scoped>
  339. //@import url('@/assets/css/article/pc.less');
  340. //@import url('@/assets/css/article/yd.less');
  341. //面包屑
  342. .breadcrumb-box {
  343. width: 1400px;
  344. margin: 0 auto;
  345. .inner {
  346. width: 100%;
  347. height: 22px;
  348. margin-top: 20px;
  349. margin-bottom: 20px;
  350. font-family: Microsoft YaHei, Microsoft YaHei;
  351. font-weight: 400;
  352. font-size: 20px;
  353. color: #666666;
  354. line-height: 23px;
  355. text-align: left;
  356. font-style: normal;
  357. text-transform: none;
  358. display: flex;
  359. align-items: center;
  360. border-bottom: 1px dashed #ccc;
  361. margin-bottom: 10px;
  362. padding: 20px 20px 20px 0;
  363. box-sizing: border-box;
  364. a {
  365. font-size: 16px;
  366. line-height: 20px;
  367. font-weight: normal!important;
  368. &:hover {
  369. color:#333
  370. }
  371. }
  372. span {
  373. font-size: 16px;
  374. color: #000;
  375. line-height: 20px;
  376. &.location {
  377. line-height: 20px;
  378. }
  379. }
  380. }
  381. }
  382. //搜索
  383. .search-box {
  384. width: 1400px;
  385. margin: 0 auto;
  386. display: flex;
  387. align-items: flex-start;
  388. justify-content: space-between;
  389. .search-left-box {
  390. .dytlt {
  391. width: 100%;
  392. height: 40px;
  393. line-height: 40px;
  394. margin: 0px auto 20px;
  395. border-bottom: 1px solid #ccc;
  396. a {
  397. display: block;
  398. width: 100px;
  399. height: 40px;
  400. background: #007aff;
  401. color: #fff;
  402. font-size: 16px;
  403. text-align: center;
  404. }
  405. }
  406. .xtlist {
  407. width: 100%;
  408. height: auto;
  409. overflow: hidden;
  410. li {
  411. list-style: none;
  412. height: 40px;
  413. line-height: 40px;
  414. overflow: hidden;
  415. border-bottom: 1px solid #ccc;
  416. }
  417. }
  418. .pagesnav {
  419. margin: 20px 0 40px 0;
  420. a {
  421. padding: 6px 12px;
  422. margin-left: -1px;
  423. line-height: 1.42857143;
  424. color: #337ab7;
  425. text-decoration: none;
  426. background-color: #fff;
  427. border: 1px solid #ddd;
  428. font-size: 10px;
  429. border-radius: 4px;
  430. cursor: pointer;
  431. &:hover {
  432. background-color: #eee;
  433. border-color: #ddd;
  434. }
  435. }
  436. }
  437. }
  438. .search-right-box {
  439. width: 38%;
  440. box-sizing: border-box;
  441. .search-right-box-form {
  442. h3 {
  443. width: 100%;
  444. line-height: 40px;
  445. font-size: 18px;
  446. color: #000;
  447. }
  448. .search-right-form-text {
  449. display: block;
  450. width: 100%;
  451. height: 70px;
  452. line-height: 70px;
  453. text-align: center;
  454. font-size: 16px;
  455. color: #333;
  456. }
  457. .search-right-input-box {
  458. margin-bottom: 20px;
  459. :deep(.el-input__wrapper) {
  460. height: 40px;
  461. line-height: 40px;
  462. border:1px solid #000;
  463. box-shadow: none;
  464. border-radius: 2px;
  465. font-size: 16px;
  466. color: #333;
  467. }
  468. :deep(.el-select__wrapper) {
  469. height: 40px;
  470. line-height: 40px;
  471. border:1px solid #000;
  472. box-shadow: none;
  473. border-radius: 2px;
  474. font-size: 16px;
  475. color: #333;
  476. }
  477. :deep(.el-input__inner) {
  478. color: #000;
  479. }
  480. }
  481. .search-right-button-box {
  482. text-align: center;
  483. display: flex;
  484. align-items: center;
  485. justify-content: center;
  486. margin-bottom: 20px;
  487. button:first-child {
  488. margin-right: 20px;
  489. }
  490. .submit-button {
  491. display: block;
  492. width: 90px;
  493. height: 40px;
  494. line-height: 40px;
  495. text-align: center;
  496. font-size: 16px;
  497. color: #fff;
  498. background: #027dc3;
  499. outline: none;
  500. border: none;
  501. cursor: pointer;
  502. }
  503. .reset-button {
  504. display: block;
  505. width: 90px;
  506. height: 40px;
  507. line-height: 40px;
  508. text-align: center;
  509. font-size: 16px;
  510. background: #ccc;
  511. border: 1px solid #027dc3;
  512. color: #027dc3;
  513. outline: none;
  514. cursor: pointer;
  515. }
  516. }
  517. .search-right-select-box {
  518. display: flex;
  519. align-items: center;
  520. justify-content: center;
  521. font-weight: bold;
  522. font-size: 16px;
  523. margin-bottom: 20px;
  524. :deep(.el-select__wrapper) {
  525. margin-left: 10px;
  526. }
  527. :deep(.el-select__placeholder) {
  528. color: #000;
  529. }
  530. }
  531. }
  532. }
  533. .search-form1-submit-button {
  534. text-align: center;
  535. button {
  536. width: 100px;
  537. height: 40px;
  538. line-height: 40px;
  539. text-align: center;
  540. background: #027dc3;
  541. color: #fff;
  542. font-size: 16px;
  543. margin: 0 auto;
  544. display: block;
  545. border: none;
  546. cursor: pointer;
  547. }
  548. }
  549. }
  550. </style>
  551. <style>
  552. .custom-select-dropdown .el-select-dropdown__item {
  553. font-size: 16px;
  554. color: #333;
  555. }
  556. .custom-select-dropdown .el-select-dropdown__item:hover {
  557. background-color: #027dc3;
  558. color: #fff;
  559. }
  560. </style>