index.vue 38 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520
  1. <template>
  2. <div class="portal-home min-h-screen bg-[#eef3f9] text-[#17345f]">
  3. <Header />
  4. <main class="mx-auto max-w-[1400px] px-6 pb-8 pt-20">
  5. <section class="hero-banner overflow-hidden rounded-[6px] relative">
  6. <div class="">
  7. <!-- 轮播容器 -->
  8. <div class="carousel-container relative h-full">
  9. <!-- 轮播项 -->
  10. <div
  11. class="carousel-slide absolute inset-0 transition-opacity duration-500 ease-in-out"
  12. v-for="(slide, index) in slides"
  13. :key="index"
  14. v-show="currentIndex === index"
  15. :class="{
  16. 'opacity-100': currentIndex === index,
  17. 'opacity-0': currentIndex !== index,
  18. 'z-10': currentIndex === index,
  19. 'z-0 pointer-events-none': currentIndex !== index,
  20. }"
  21. >
  22. <div class="hero-copy carousel-caption">
  23. <div class="hero-script text-[68px] font-italic text-[#0c4eb5]">
  24. HELLO
  25. </div>
  26. <p class="hero-text mt-6 text-[24px] text-[#5f6f83]">
  27. {{ slide.text }}
  28. </p>
  29. </div>
  30. <!-- 轮播背景图 -->
  31. <div class="hero-visual absolute inset-0">
  32. <img
  33. :src="slide.image"
  34. alt="Banner"
  35. class="w-full h-full object-cover"
  36. />
  37. </div>
  38. </div>
  39. <!-- 指示器 -->
  40. <div
  41. class="carousel-indicators absolute bottom-4 left-1/2 z-30 flex transform -translate-x-1/2 space-x-2"
  42. >
  43. <span
  44. v-for="(_, i) in slides"
  45. :key="i"
  46. @click="currentIndex = i"
  47. :class="{
  48. 'bg-[#0c4eb5]': currentIndex === i,
  49. 'bg-[#2f333c]/50': currentIndex !== i,
  50. }"
  51. class="w-3 h-3 rounded-full transition-colors"
  52. ></span>
  53. </div>
  54. </div>
  55. </div>
  56. </section>
  57. <section class="portal-mobile-shortcuts mt-3 md:hidden!">
  58. <button
  59. type="button"
  60. class="portal-mobile-shortcut"
  61. @click="router.push('/flow')"
  62. >
  63. 流程门户
  64. </button>
  65. <button
  66. type="button"
  67. class="portal-mobile-shortcut"
  68. @click="router.push('/drive')"
  69. >
  70. 驾驶舱门户
  71. </button>
  72. <button type="button" class="portal-mobile-shortcut">报表门户</button>
  73. </section>
  74. <section class="mt-3 grid gap-4 xl:grid-cols-[1.74fr_0.74fr]">
  75. <div class="space-y-4">
  76. <article
  77. v-for="section in portalSections"
  78. :key="section.code"
  79. class="platform-block"
  80. :style="{ minHeight: section.height }"
  81. >
  82. <div class="platform-block__header">
  83. <div class="platform-block__title-wrap">
  84. <p class="platform-block__title">{{ section.title }}</p>
  85. <span class="platform-block__subtitle">{{
  86. section.subtitle
  87. }}</span>
  88. </div>
  89. <span class="platform-block__watermark">{{ section.code }}</span>
  90. </div>
  91. <div
  92. v-if="section.apps?.length"
  93. class="grid grid-cols-[repeat(2,minmax(0,1fr))] gap-2 p-6 px-3 md:px-6 md:grid-cols-[repeat(4,minmax(0,1fr))]"
  94. >
  95. <button
  96. v-for="(app, appIndex) in section.apps"
  97. :key="`${section.code}-${appIndex}-${app.label}`"
  98. type="button"
  99. :class="[
  100. 'platform-app',
  101. boldLabes.includes(app.label)
  102. ? 'platform-app--active'
  103. : 'platform-app--ghost',
  104. ]"
  105. @click="handlePortalAppClick(app)"
  106. >
  107. <span class="platform-app__icon">
  108. <img
  109. v-if="app.image"
  110. :src="app.image"
  111. :alt="app.label"
  112. class="h-7 w-7 object-contain rounded-md"
  113. />
  114. <Icon
  115. v-else
  116. :icon="app.icon || 'mdi:dots-grid'"
  117. class="text-[24px]"
  118. />
  119. </span>
  120. <span
  121. class="platform-app__label text-[#004098] md:text-sm text-[12px] text-left"
  122. >{{ app.label }}</span
  123. >
  124. </button>
  125. </div>
  126. </article>
  127. </div>
  128. <aside class="space-y-4">
  129. <section class="side-card side-card--notice rounded-md p-2">
  130. <div class="side-card__header w-[95%] ml-[8px]">
  131. <div class="notice-tabs">
  132. <button
  133. v-for="tab in noticeTabs"
  134. :key="tab.key"
  135. type="button"
  136. :class="[
  137. 'notice-tab',
  138. activeNoticeTab === tab.key ? 'notice-tab--active' : '',
  139. ]"
  140. @click="handleNoticeTabChange(tab.key)"
  141. >
  142. {{ tab.label }}
  143. </button>
  144. </div>
  145. <button type="button" class="side-card__more">
  146. <Icon
  147. icon="mdi:dots-horizontal"
  148. class="text-[22px]"
  149. @click="handleNoticeMoreClick"
  150. />
  151. </button>
  152. </div>
  153. <div class="space-y-2 p-2 pt-3">
  154. <div
  155. v-if="!userStore.getUser.username"
  156. class="flex h-full items-center justify-center"
  157. >
  158. <div class="text-[#8a9ab0] pt-5">登录后查看</div>
  159. </div>
  160. <div
  161. v-if="!currentNoticeList.length && userStore.getUser.username"
  162. class="flex h-[120px] items-center justify-center text-[#8a9ab0]"
  163. >
  164. 暂无数据
  165. </div>
  166. <article
  167. v-if="userStore.getUser.username"
  168. v-for="notice in currentNoticeList"
  169. :key="notice.id"
  170. class="notice-item cursor-pointer"
  171. @click="handleNoticeItemClick(notice)"
  172. >
  173. <div class="notice-item__desc">{{ notice.docsubject }}</div>
  174. <div class="date text-[12px] text-[#9cadc0]">
  175. {{ notice.docvaliddate }}
  176. </div>
  177. </article>
  178. </div>
  179. </section>
  180. <section
  181. class="side-card side-card--notice rounded-md p-2"
  182. :style="{ minHeight: '190px' }"
  183. >
  184. <div class="side-card__header w-[91%] ml-[15px]">
  185. <div class="notice-badge px-2">{{ todoPanelTitle }}</div>
  186. <button
  187. type="button"
  188. class="side-card__more"
  189. @click="router.push('/todo-list')"
  190. >
  191. 全部任务
  192. </button>
  193. </div>
  194. <div class="space-y-2 p-4 pt-2">
  195. <div
  196. v-if="!userStore.getUser.username"
  197. class="flex h-full items-center justify-center"
  198. >
  199. <div class="text-[#8a9ab0] pt-10">登录后查看</div>
  200. </div>
  201. <div
  202. v-if="!oaTasks.length && userStore.getUser.username"
  203. class="flex h-full items-center justify-center"
  204. >
  205. <div class="text-[#8a9ab0] pt-10">暂无待办</div>
  206. </div>
  207. <article
  208. v-if="userStore.getUser.username"
  209. v-for="task in oaTasks"
  210. :key="task.requestId"
  211. @click="handleTask(task)"
  212. class="todo-item rounded-md cursor-pointer"
  213. >
  214. <div class="flex min-w-0 items-start justify-between gap-3">
  215. <div class="min-w-0">
  216. <div
  217. class="truncate text-[14px] font-semibold text-[#0d4a9d]"
  218. >
  219. {{ task.requestName }}
  220. </div>
  221. <div class="mt-1 text-[12px] text-[#8a9ab0]">
  222. 创建人:{{ task.creatorName }} · {{ task.createTime }}
  223. </div>
  224. </div>
  225. <span
  226. :class="['todo-item__tag', getTagClass(task.requesLevel)]"
  227. >{{ getTagName(task.requesLevel) }}</span
  228. >
  229. </div>
  230. </article>
  231. </div>
  232. </section>
  233. <section
  234. class="side-card side-card--content p-2 rounded-md"
  235. :style="{ minHeight: '180px' }"
  236. >
  237. <div class="side-card__header w-[90%] ml-[15px]">
  238. <div class="notice-badge">{{ newsPanelTitle }}</div>
  239. <button type="button" class="side-card__more" @click="goNews">
  240. <Icon icon="mdi:dots-horizontal" class="text-[22px]" />
  241. </button>
  242. </div>
  243. <div class="space-y-2 p-4 pt-2">
  244. <div
  245. v-if="!userStore.getUser.username"
  246. class="flex h-full items-center justify-center"
  247. >
  248. <div class="text-[#8a9ab0] pt-10">登录后查看</div>
  249. </div>
  250. <div
  251. v-if="!newsList.length && userStore.getUser.username"
  252. class="flex h-full items-center justify-center"
  253. >
  254. <div class="text-[#8a9ab0] pt-10">暂无新闻</div>
  255. </div>
  256. <article
  257. v-for="news in newsList"
  258. :key="news.id"
  259. class="news-mini cursor-pointer rounded-md"
  260. @click="handleNoticeItemClick(news)"
  261. >
  262. <div class="min-w-0 flex-1">
  263. <div
  264. class="line-clamp-1 text-[13px] font-semibold leading-[1.45] text-[#41597d]"
  265. >
  266. {{ news.docsubject }}
  267. </div>
  268. <div class="mt-2 text-[12px] text-[#9cadc0]">
  269. {{ news.docvaliddate }}
  270. </div>
  271. </div>
  272. </article>
  273. </div>
  274. </section>
  275. <section
  276. v-if="userStore.getUser.username"
  277. class="side-card side-card--placeholder rounded-md"
  278. :style="{ minHeight: '78px', backgroundColor: '#3575e4' }"
  279. >
  280. <div class="placeholder-panel flex flex-col text-left">
  281. <!-- <div class="text-sm">需要帮助?</div> -->
  282. <div class="text-[10px]">需要帮助?遇到系统操作问题?</div>
  283. <div
  284. class="bg-white text-sm text-center text-[#004098] py-1 px-2 rounded-full mt-2 w-[30%] cursor-pointer"
  285. @click="openConsult"
  286. >
  287. 立即咨询
  288. </div>
  289. </div>
  290. </section>
  291. </aside>
  292. </section>
  293. </main>
  294. <Footer />
  295. </div>
  296. </template>
  297. <script setup lang="ts">
  298. import { computed, onMounted, onUnmounted, reactive, ref } from "vue";
  299. import * as authUtil from "@/utils/auth";
  300. import * as dd from "dingtalk-jsapi";
  301. import Header from "@components/home/header.vue";
  302. import Footer from "@components/home/Footer.vue";
  303. import { useRouter } from "vue-router";
  304. import axios from "axios";
  305. import { Icon } from "@iconify/vue";
  306. import { ElLoading } from "element-plus";
  307. import {
  308. getMCSsoToken,
  309. ssoLogin,
  310. zentaoSsoLogin,
  311. getOATasks,
  312. getNotices,
  313. getRedHeadFiles,
  314. getNews,
  315. } from "@/api/user";
  316. import { useUserStore } from "@/stores/useUserStore";
  317. import { getAccessToken } from "@/utils/auth";
  318. import { deleteUserCache } from "@hooks/useCache";
  319. import { manualLogoutKey, reloginCancelKey } from "@/config/axios/service";
  320. import banner1 from "@/assets/images/banner1.png";
  321. import banner2 from "@/assets/images/banner2.jpg";
  322. import banner3 from "@/assets/images/banner3.jpg";
  323. import oaimage from "@/assets/images/oa.jpg";
  324. import crmimage from "@/assets/images/crm.jpg";
  325. import ehrimage from "@/assets/images/ehr.jpg";
  326. import scmimage from "@/assets/images/scm.png";
  327. import erpimage from "@/assets/images/fm.jpg";
  328. import driveimage from "@/assets/images/drive.jpg";
  329. import pmsimage from "@/assets/images/pms.jpeg";
  330. import zhonghangimage from "@/assets/images/中航.png";
  331. import lianyouimage from "@/assets/images/lianyou.jpeg";
  332. import qhseimage from "@/assets/images/qhse.jpg";
  333. import zuanjingimage from "@/assets/images/zuanjing.jpeg";
  334. import yalieimage from "@/assets/images/yalie.png";
  335. import zhuqiimage from "@/assets/images/zhuqi.png";
  336. import pmimage from "@/assets/images/pm.jpg";
  337. import dataimage from "@/assets/images/data.jpg";
  338. import thinkimage from "@/assets/images/think.jpg";
  339. import aiimage from "@/assets/images/ai.png";
  340. import agentimage from "@/assets/images/agent.jpeg";
  341. import videoimage from "@/assets/images/video.png";
  342. import fileagent from "@/assets/images/fileagent.png";
  343. import zhiduagent from "@/assets/images/zhiduagent.png";
  344. import jishuimage2 from "@/assets/images/jishuimage.png";
  345. import zhanlueimage from "@/assets/images/zhanlue.jpg"; // 战略解码
  346. import safeimage from "@/assets/images/safe.png"; // 安全合规管理
  347. import zuzhiimage from "@/assets/images/zuzhi.jpg";
  348. import youimage from "@/assets/images/youcnag.png"; // ai智能体
  349. import hongpan from "@/assets/images/鸿盘.jpg"; // ai智能体
  350. type PortalApp = {
  351. label: string;
  352. icon?: string;
  353. image?: string;
  354. active?: boolean;
  355. };
  356. type PortalSection = {
  357. code: string;
  358. title: string;
  359. subtitle: string;
  360. height: string;
  361. apps?: PortalApp[];
  362. };
  363. type NoticeItem = {
  364. id?: string | number;
  365. title?: string;
  366. desc?: string;
  367. docsubject?: string;
  368. };
  369. const router = useRouter();
  370. const userStore = useUserStore();
  371. const todoPanelTitle = "待办中心";
  372. const newsPanelTitle = "新闻中心";
  373. const noticeTabs = [
  374. { key: "redHead", label: "红头文件" },
  375. { key: "notice", label: "通知公告" },
  376. ] as const;
  377. type NoticeTabKey = (typeof noticeTabs)[number]["key"];
  378. const portalSections: PortalSection[] = [
  379. {
  380. code: "数",
  381. title: "数字化运营平台",
  382. subtitle: "高效协同 · 战略洞察",
  383. height: "220px",
  384. apps: [
  385. {
  386. label: "OA办公",
  387. image: oaimage,
  388. active: true,
  389. },
  390. { label: "客户管理(CRM)", image: crmimage },
  391. { label: "经营驾驶舱(MC)", image: driveimage },
  392. { label: "项目管理(PM)", image: pmimage },
  393. { label: "开发需求管理", image: jishuimage2 },
  394. { label: "鸿盘", image: hongpan },
  395. { label: "人力资源(EHR)", image: ehrimage },
  396. { label: "供应商管理(SRM)", image: scmimage },
  397. { label: "财务管理(FM)", image: erpimage },
  398. { label: "技术研发管理(R&D)", image: jishuimage2 },
  399. { label: "战略解码与执行", image: zhanlueimage },
  400. { label: "组织资产管理", image: zuzhiimage },
  401. { label: "风控合规管理", image: safeimage },
  402. ],
  403. },
  404. {
  405. code: "智",
  406. title: "智慧指挥平台",
  407. subtitle: "高效协同 · 战略洞察",
  408. height: "210px",
  409. apps: [
  410. { label: "设备管理(PMS)", image: pmsimage, active: true },
  411. { label: "中航北斗", image: zhonghangimage },
  412. { label: "质量安全管理(QHSE)", image: qhseimage },
  413. { label: "智慧连油", image: lianyouimage },
  414. { label: "智慧注气", image: zhuqiimage },
  415. { label: "视频中心(VCS)", image: videoimage },
  416. { label: "智能钻井", image: zuanjingimage },
  417. { label: "智慧压裂", image: yalieimage },
  418. { label: "数字油藏", image: youimage },
  419. ],
  420. },
  421. {
  422. code: "AI",
  423. title: "Chat BI平台",
  424. subtitle: "高效协同 · 战略洞察",
  425. height: "160px",
  426. apps: [
  427. { label: "全局数据治理(数据中台)", image: dataimage, active: true },
  428. { label: "智能决策", image: thinkimage },
  429. { label: "行业AI大模型", image: aiimage },
  430. { label: "AI智能体(智能交互)", image: agentimage },
  431. { label: "工艺文件智能体", image: fileagent },
  432. { label: "集团制度智能体", image: zhiduagent },
  433. ],
  434. },
  435. ];
  436. let boldLabes = ref([
  437. "OA办公",
  438. "客户管理(CRM)",
  439. "设备管理(PMS)",
  440. "中航北斗",
  441. "智慧连油",
  442. "质量安全管理(QHSE)",
  443. "智慧注气",
  444. "视频中心(VCS)",
  445. "开发需求管理",
  446. "经营驾驶舱(MC)",
  447. "项目管理(PM)",
  448. "鸿盘",
  449. "智能钻井",
  450. ]);
  451. const getGreeting = () => {
  452. const hour = new Date().getHours();
  453. if (hour < 12) return "早上好";
  454. if (hour < 18) return "下午好";
  455. return "晚上好";
  456. };
  457. // 添加轮播数据
  458. const slides = ref([
  459. {
  460. image: banner1,
  461. text: getGreeting() + ",保持热爱,奔赴目标!",
  462. },
  463. {
  464. image: banner2,
  465. text: "数字化转型,驱动未来增长",
  466. },
  467. {
  468. image: banner3,
  469. text: "智慧平台,赋能高效协同",
  470. },
  471. ]);
  472. // 当前索引
  473. const currentIndex = ref(0);
  474. let slideTimer: ReturnType<typeof setInterval> | null = null;
  475. // 下一页
  476. const nextSlide = () => {
  477. currentIndex.value = (currentIndex.value + 1) % slides.value.length;
  478. };
  479. const activeNoticeTab = ref<NoticeTabKey>("redHead");
  480. const noticeListMap = ref<Record<NoticeTabKey, NoticeItem[]>>({
  481. notice: [],
  482. redHead: [],
  483. });
  484. const newsList = ref([]);
  485. const currentNoticeList = computed(
  486. () => noticeListMap.value[activeNoticeTab.value] ?? [],
  487. );
  488. const loadHomeData = async () => {
  489. await loadNoticeList(activeNoticeTab.value);
  490. if (!userStore.getUser.username) return;
  491. const [oaRes, newsRes] = await Promise.all([
  492. getOATasks({
  493. id: userStore.getUser.username,
  494. pageNum: 1,
  495. pageSize: 10,
  496. }),
  497. getNews({
  498. pageNum: 1,
  499. pageSize: 10,
  500. }),
  501. ]);
  502. oaTasks.value = oaRes.todoList.slice(0, 3);
  503. newsList.value = newsRes.list.slice(0, 3);
  504. };
  505. const loadNoticeList = async (tabKey: NoticeTabKey) => {
  506. const requestApi = tabKey === "notice" ? getNotices : getRedHeadFiles;
  507. const res = await requestApi({
  508. pageNum: 1,
  509. pageSize: 10,
  510. });
  511. noticeListMap.value[tabKey] = (res?.list || []).slice(0, 3);
  512. };
  513. let currentTabKey = ref<NoticeTabKey>("redHead");
  514. const handleNoticeTabChange = async (tabKey: NoticeTabKey) => {
  515. activeNoticeTab.value = tabKey;
  516. currentTabKey.value = tabKey;
  517. // if (noticeListMap.value[tabKey].length) return;
  518. if (userStore.getUser.username) {
  519. await loadNoticeList(tabKey);
  520. }
  521. };
  522. const handleNoticeMoreClick = () => {
  523. router.push({
  524. path: "/notice-redhead",
  525. query: {
  526. tabKey: currentTabKey.value,
  527. },
  528. });
  529. };
  530. const protectedOpen = (url: string) => {
  531. if (userStore.getUser.username && getAccessToken()) {
  532. window.open(url, "_blank");
  533. } else {
  534. router.push({ path: "/login" });
  535. }
  536. };
  537. const handlePortalAppClick = async (app: PortalApp) => {
  538. if (!app.label) return;
  539. if (app.label === "项目管理(PM)") {
  540. protectedOpen(
  541. `${import.meta.env.VITE_PMS_URL}/portalLogin?username=${userStore.getUser.username}&source=yyhy`,
  542. );
  543. }
  544. if (app.label === "OA办公") {
  545. if (userStore.getUser.username && getAccessToken()) {
  546. const res = await ssoLogin({ username: userStore.getUser.username });
  547. if (res) {
  548. window.open(
  549. `https://yfoa.keruioil.com/wui/index.html?ssoToken=${res}#/main`,
  550. "_blank",
  551. );
  552. }
  553. } else {
  554. router.push({ path: "/login" });
  555. }
  556. }
  557. if (app.label === "客户管理(CRM)") {
  558. protectedOpen(
  559. `https://crm-tencent.xiaoshouyi.com/global/sso/callback/00APEB9EEEA9B2E338B686B7ECFA8585808C.action?token=${getAccessToken()}`,
  560. );
  561. }
  562. if (app.label === "设备管理(PMS)") {
  563. protectedOpen(
  564. `${import.meta.env.VITE_PMS_URL}/portalLogin?username=${userStore.getUser.username}`,
  565. );
  566. }
  567. if (app.label === "中航北斗") {
  568. protectedOpen("https://zhbdgps.cn");
  569. }
  570. if (app.label === "智慧连油") {
  571. protectedOpen(
  572. `${import.meta.env.VITE_PMS_URL}/portalLogin?username=${userStore.getUser.username}&source=zhly`,
  573. );
  574. }
  575. if (app.label === "智慧注气") {
  576. protectedOpen(
  577. `${import.meta.env.VITE_PMS_URL}/portalLogin?username=${userStore.getUser.username}&source=znzq`,
  578. );
  579. }
  580. if (app.label === "视频中心(VCS)") {
  581. protectedOpen(
  582. `${import.meta.env.VITE_PMS_URL}/portalLogin?username=${userStore.getUser.username}&source=spzx`,
  583. );
  584. }
  585. if (app.label === "质量安全管理(QHSE)") {
  586. protectedOpen(
  587. `${import.meta.env.VITE_PMS_URL}/portalLogin?username=${userStore.getUser.username}&source=qhse`,
  588. );
  589. }
  590. if (app.label === "经营驾驶舱(MC)") {
  591. if (userStore.getUser.username && getAccessToken()) {
  592. const res = await getMCSsoToken();
  593. if (res) {
  594. window.open(
  595. `https://report.deepoil.cc/webroot/decision/v10/entry/access/9fb42908-894a-4373-a6be-ce046a42851d?preview=true&page_number=1&ssoToken=${res}`,
  596. "_blank",
  597. );
  598. }
  599. } else {
  600. router.push({ path: "/login" });
  601. }
  602. }
  603. if (app.label === "开发需求管理") {
  604. if (userStore.getUser.username && getAccessToken()) {
  605. const res = await zentaoSsoLogin({
  606. username: userStore.getUser.username,
  607. });
  608. if (res) {
  609. window.open(
  610. `http://project.deepoil.cc/zentao/api.php?m=user&f=apilogin&account=${res.jobNumber}&code=${res.code}&time=${res.timestamp}&token=${res.token}`,
  611. "_blank",
  612. );
  613. }
  614. } else {
  615. router.push({ path: "/login" });
  616. }
  617. }
  618. if (app.label === "智能钻井") {
  619. if (userStore.getUser.username && getAccessToken()) {
  620. window.open(`http://172.21.0.224:8001/#/login`, "_blank");
  621. } else {
  622. router.push({ path: "/login" });
  623. }
  624. }
  625. if (app.label === "鸿盘") {
  626. if (userStore.getUser.username && getAccessToken()) {
  627. window.open(`https://pan.keruioil.com:52180`, "_blank");
  628. } else {
  629. router.push({ path: "/login" });
  630. }
  631. }
  632. };
  633. async function loginWithDingTalk() {
  634. const ddCorpId = import.meta.env.VITE_DD_CORPID;
  635. const ddClientId = import.meta.env.VITE_DD_CLIENTID;
  636. if (!ddCorpId || !ddClientId) return false;
  637. return await new Promise<boolean>((resolve) => {
  638. dd.requestAuthCode({
  639. corpId: ddCorpId,
  640. clientId: ddClientId,
  641. success: async (res: any) => {
  642. try {
  643. const { code } = res;
  644. const response = await axios.post(
  645. import.meta.env.BASE_URL + "/admin-api/system/auth/h5SocialLogin",
  646. {
  647. code,
  648. type: 20,
  649. state: new Date().getTime(),
  650. },
  651. {
  652. headers: {
  653. "Content-Type": "application/json",
  654. "tenant-id": 1,
  655. },
  656. },
  657. );
  658. deleteUserCache();
  659. userStore.resetState();
  660. authUtil.setToken(response.data.data);
  661. sessionStorage.removeItem(manualLogoutKey);
  662. sessionStorage.removeItem(reloginCancelKey);
  663. await userStore.setUserInfoAction();
  664. resolve(true);
  665. } catch (error) {
  666. console.log("dingTalk login error :>> ", error);
  667. resolve(false);
  668. }
  669. },
  670. fail: (err: any) => {
  671. console.log("err :>> ", err);
  672. resolve(false);
  673. },
  674. });
  675. });
  676. }
  677. async function dingTalkAutoLogin() {
  678. const ua = window.navigator.userAgent.toLowerCase();
  679. if (
  680. (ua.includes("dingtalk") || ua.includes("dingtalkwork")) &&
  681. !userStore.getUser.username &&
  682. !getAccessToken()
  683. ) {
  684. return await loginWithDingTalk();
  685. }
  686. return false;
  687. }
  688. const getTagClass = (tag: string) => {
  689. return tag === "0"
  690. ? "bg-[#dbe8ff] text-[#3f74ff]"
  691. : tag === "1"
  692. ? "bg-[#ffe1e3] text-[#ff5d66]"
  693. : tag === "2"
  694. ? "bg-[#dfe8f3] text-[#6f7f94]"
  695. : "bg-[#dbe8ff] text-[#3f74ff]";
  696. };
  697. const getTagName = (tag: string) => {
  698. return tag === "0"
  699. ? "正常"
  700. : tag === "1"
  701. ? "重要"
  702. : tag === "2"
  703. ? "紧急"
  704. : "正常";
  705. };
  706. let oaTasks = ref([]);
  707. onMounted(async () => {
  708. slideTimer = setInterval(nextSlide, 5000);
  709. await dingTalkAutoLogin();
  710. await loadHomeData();
  711. });
  712. const handleNoticeItemClick = async (notice) => {
  713. const res = await ssoLogin({
  714. username: userStore.getUser.username,
  715. });
  716. if (res) {
  717. const ua = window.navigator.userAgent.toLowerCase();
  718. if (ua.includes("dingtalk") || ua.includes("dingtalkwork")) {
  719. dd.biz.util.openLink({
  720. url:
  721. "https://yfoa.keruioil.com/wui/index.html" +
  722. "?ssoToken=" +
  723. res +
  724. "#/main", // 先跳你的 SSO 链接
  725. onSuccess: () => {
  726. // 延迟跳目标业务地址(和你原来 setTimeout 逻辑一致)
  727. setTimeout(() => {
  728. dd.biz.util.openLink({
  729. url: `https://yfoa.keruioil.com/spa/document/index.jsp?openAttachment=0&id=${notice.id}`,
  730. });
  731. }, 100);
  732. },
  733. });
  734. } else {
  735. const loading = ElLoading.service({
  736. lock: true,
  737. text: "正在跳转,请稍候...",
  738. background: "rgba(0, 0, 0, 0.7)",
  739. });
  740. const newTab = window.open("", "_blank");
  741. newTab.location.href =
  742. "https://yfoa.keruioil.com/wui/index.html" +
  743. "?ssoToken=" +
  744. res +
  745. "#/main";
  746. setTimeout(function () {
  747. newTab.location.href = `https://yfoa.keruioil.com/spa/document/index.jsp?openAttachment=0&id=${notice.id}`;
  748. setTimeout(() => {
  749. loading.close();
  750. }, 500);
  751. }, 100);
  752. }
  753. }
  754. };
  755. const handleTask = async (row) => {
  756. const res = await ssoLogin({
  757. username: userStore.getUser.username,
  758. });
  759. if (res) {
  760. const ua = window.navigator.userAgent.toLowerCase();
  761. if (ua.includes("dingtalk") || ua.includes("dingtalkwork")) {
  762. dd.biz.util.openLink({
  763. url:
  764. "https://yfoa.keruioil.com/wui/index.html" +
  765. "?ssoToken=" +
  766. res +
  767. "#/main", // 先跳你的 SSO 链接
  768. onSuccess: () => {
  769. // 延迟跳目标业务地址(和你原来 setTimeout 逻辑一致)
  770. setTimeout(() => {
  771. dd.biz.util.openLink({
  772. url: `https://yfoa.keruioil.com/spa/workflow/static4form/index.html?_rdm=1776063595284#/main/workflow/req?requestid=${row.requestId}`,
  773. });
  774. }, 100);
  775. },
  776. });
  777. } else {
  778. const loading = ElLoading.service({
  779. lock: true,
  780. text: "正在跳转,请稍候...",
  781. background: "rgba(0, 0, 0, 0.7)",
  782. });
  783. const newTab = window.open("", "_blank");
  784. newTab.location.href =
  785. "https://yfoa.keruioil.com/wui/index.html" +
  786. "?ssoToken=" +
  787. res +
  788. "#/main";
  789. setTimeout(function () {
  790. newTab.location.href = `https://yfoa.keruioil.com/spa/workflow/static4form/index.html?_rdm=1776063595284#/main/workflow/req?requestid=${row.requestId}`;
  791. setTimeout(() => {
  792. loading.close();
  793. }, 500);
  794. }, 100);
  795. }
  796. }
  797. };
  798. const openConsult = async () => {
  799. const res = await ssoLogin({
  800. username: userStore.getUser.username,
  801. });
  802. if (res) {
  803. const ua = window.navigator.userAgent.toLowerCase();
  804. if (ua.includes("dingtalk") || ua.includes("dingtalkwork")) {
  805. dd.biz.util.openLink({
  806. url:
  807. "https://yfoa.keruioil.com/wui/index.html" +
  808. "?ssoToken=" +
  809. res +
  810. "#/main", // 先跳你的 SSO 链接
  811. onSuccess: () => {
  812. // 延迟跳目标业务地址(和你原来 setTimeout 逻辑一致)
  813. setTimeout(() => {
  814. dd.biz.util.openLink({
  815. url: `https://yfoa.keruioil.com/spa/workflow/static4form/index.html?_rdm=1778289187850#/main/workflow/req?iscreate=1&workflowid=488`,
  816. });
  817. }, 100);
  818. },
  819. });
  820. } else {
  821. const loading = ElLoading.service({
  822. lock: true,
  823. text: "正在跳转,请稍候...",
  824. background: "rgba(0, 0, 0, 0.7)",
  825. });
  826. const newTab = window.open("", "_blank");
  827. newTab.location.href =
  828. "https://yfoa.keruioil.com/wui/index.html" +
  829. "?ssoToken=" +
  830. res +
  831. "#/main";
  832. setTimeout(function () {
  833. newTab.location.href = `https://yfoa.keruioil.com/spa/workflow/static4form/index.html?_rdm=1778289187850#/main/workflow/req?iscreate=1&workflowid=488`;
  834. setTimeout(() => {
  835. loading.close();
  836. }, 500);
  837. }, 100);
  838. }
  839. }
  840. };
  841. const goNews = () => {
  842. router.push("/news");
  843. };
  844. onUnmounted(() => {
  845. if (slideTimer) {
  846. clearInterval(slideTimer);
  847. slideTimer = null;
  848. }
  849. });
  850. </script>
  851. <style scoped>
  852. .portal-home {
  853. --portal-blue: #2f6fdb;
  854. --portal-blue-dark: #1b57bc;
  855. --portal-blue-soft: #d7e7ff;
  856. --portal-panel: #deebfb;
  857. --portal-panel-soft: #edf5ff;
  858. --portal-line: #a8c4f2;
  859. background-color: #eef3f9;
  860. background-image: url("../assets//images/bg666.png");
  861. background-position: center bottom;
  862. background-repeat: no-repeat;
  863. background-size: 100% auto;
  864. background-attachment: fixed;
  865. }
  866. .hero-banner {
  867. position: relative;
  868. min-height: 220px;
  869. background: linear-gradient(
  870. 90deg,
  871. rgba(255, 255, 255, 0.96) 0%,
  872. rgba(241, 247, 255, 0.92) 36%,
  873. rgba(223, 237, 255, 0.95) 100%
  874. );
  875. box-shadow: 0 16px 34px rgba(59, 112, 190, 0.08);
  876. }
  877. .hero-banner::before {
  878. content: "";
  879. position: absolute;
  880. inset: 0;
  881. background:
  882. linear-gradient(140deg, rgba(206, 223, 247, 0.25) 0%, transparent 28%),
  883. radial-gradient(
  884. circle at 74% 24%,
  885. rgba(83, 146, 255, 0.14),
  886. transparent 18%
  887. ),
  888. radial-gradient(
  889. circle at 88% 16%,
  890. rgba(255, 255, 255, 0.94),
  891. transparent 14%
  892. );
  893. pointer-events: none;
  894. }
  895. .hero-banner__inner {
  896. position: relative;
  897. z-index: 1;
  898. display: grid;
  899. min-height: 220px;
  900. grid-template-columns: minmax(260px, 1fr) minmax(360px, 1.3fr);
  901. align-items: center;
  902. gap: 24px;
  903. padding: 22px 36px 18px 58px;
  904. }
  905. .hero-copy {
  906. /* padding-top: 10px; */
  907. }
  908. .hero-script {
  909. color: #0c4eb5;
  910. font-size: 68px;
  911. font-style: italic;
  912. font-weight: 500;
  913. letter-spacing: 0.04em;
  914. line-height: 1;
  915. font-family: "Comic Sans MS", "Segoe Script", cursive;
  916. }
  917. .hero-text {
  918. margin-top: 18px;
  919. color: #5f6f83;
  920. font-size: 24px;
  921. letter-spacing: 0.1em;
  922. }
  923. .hero-progress {
  924. margin-top: 48px;
  925. display: flex;
  926. align-items: center;
  927. gap: 12px;
  928. }
  929. .hero-progress__active {
  930. height: 4px;
  931. width: 56px;
  932. border-radius: 999px;
  933. background: #1f67d1;
  934. }
  935. .hero-progress__line {
  936. height: 3px;
  937. width: 64px;
  938. border-radius: 999px;
  939. background: rgba(49, 113, 207, 0.18);
  940. }
  941. .hero-visual {
  942. position: relative;
  943. min-height: 180px;
  944. }
  945. .hero-orb,
  946. .hero-cube,
  947. .hero-ring {
  948. position: absolute;
  949. }
  950. .hero-orb {
  951. display: flex;
  952. align-items: center;
  953. justify-content: center;
  954. border-radius: 28px;
  955. background: linear-gradient(
  956. 180deg,
  957. rgba(255, 255, 255, 0.98),
  958. rgba(226, 239, 255, 0.95)
  959. );
  960. color: #65a4ff;
  961. box-shadow:
  962. 0 18px 35px rgba(65, 122, 206, 0.14),
  963. inset 0 1px 0 rgba(255, 255, 255, 0.88);
  964. }
  965. .hero-orb::after {
  966. content: "";
  967. position: absolute;
  968. inset: auto 16px 10px;
  969. height: 10px;
  970. border-radius: 999px;
  971. background: rgba(93, 154, 255, 0.12);
  972. filter: blur(8px);
  973. }
  974. .hero-orb--cloud {
  975. left: 10%;
  976. top: 28px;
  977. height: 106px;
  978. width: 126px;
  979. transform: rotate(-10deg);
  980. }
  981. .hero-orb--shield {
  982. left: 46%;
  983. top: 64px;
  984. height: 118px;
  985. width: 120px;
  986. transform: rotate(8deg);
  987. }
  988. .hero-orb--chart {
  989. right: 4%;
  990. top: 0;
  991. height: 138px;
  992. width: 150px;
  993. transform: rotate(6deg);
  994. }
  995. .hero-cube {
  996. background: linear-gradient(
  997. 180deg,
  998. rgba(255, 255, 255, 0.94),
  999. rgba(226, 239, 255, 0.9)
  1000. );
  1001. box-shadow: 0 18px 35px rgba(65, 122, 206, 0.1);
  1002. }
  1003. .hero-cube--one {
  1004. left: 26%;
  1005. top: -2px;
  1006. height: 46px;
  1007. width: 46px;
  1008. transform: rotate(36deg);
  1009. }
  1010. .hero-cube--two {
  1011. left: 33%;
  1012. top: 18px;
  1013. height: 34px;
  1014. width: 34px;
  1015. transform: rotate(32deg);
  1016. }
  1017. .hero-ring {
  1018. left: 13%;
  1019. top: 108px;
  1020. height: 42px;
  1021. width: 128px;
  1022. border-radius: 999px;
  1023. background: rgba(83, 146, 255, 0.1);
  1024. box-shadow: inset 0 0 0 10px rgba(238, 245, 255, 0.72);
  1025. }
  1026. .platform-block {
  1027. overflow: hidden;
  1028. background: linear-gradient(180deg, #dce9fb 0%, #d9e8fb 100%);
  1029. box-shadow: 0 12px 28px rgba(58, 110, 187, 0.08);
  1030. }
  1031. .platform-block__header {
  1032. display: flex;
  1033. align-items: center;
  1034. justify-content: space-between;
  1035. min-height: 44px;
  1036. padding: 0 24px 0 34px;
  1037. background: linear-gradient(90deg, #316fd8 0%, #82aef0 100%);
  1038. }
  1039. .platform-block__title-wrap {
  1040. display: flex;
  1041. align-items: baseline;
  1042. gap: 28px;
  1043. min-width: 0;
  1044. }
  1045. .platform-block__title {
  1046. color: #fff;
  1047. font-size: 18px;
  1048. min-width: 0;
  1049. flex: 0 1 auto;
  1050. white-space: nowrap;
  1051. overflow: hidden;
  1052. text-overflow: ellipsis;
  1053. letter-spacing: 0.03em;
  1054. }
  1055. .platform-block__subtitle {
  1056. color: rgba(255, 255, 255, 0.95);
  1057. font-size: 13px;
  1058. font-weight: 600;
  1059. flex: 0 0 auto;
  1060. white-space: nowrap;
  1061. }
  1062. .platform-block__watermark {
  1063. color: rgba(255, 255, 255, 0.4);
  1064. font-size: 44px;
  1065. font-weight: 800;
  1066. line-height: 1;
  1067. letter-spacing: 0.04em;
  1068. }
  1069. .platform-app {
  1070. display: flex;
  1071. width: 100%;
  1072. min-width: 0;
  1073. min-height: 34px;
  1074. align-items: center;
  1075. justify-content: flex-start;
  1076. gap: 5px;
  1077. border-radius: 8px;
  1078. padding: 0 5px;
  1079. font-size: 14px;
  1080. cursor: pointer;
  1081. transition:
  1082. transform 0.2s ease,
  1083. box-shadow 0.2s ease,
  1084. background 0.2s ease;
  1085. }
  1086. .platform-app:hover {
  1087. transform: translateY(-1px);
  1088. }
  1089. .platform-app--active {
  1090. background: rgba(255, 255, 255, 0.66);
  1091. font-weight: bold;
  1092. }
  1093. .platform-app--ghost {
  1094. background: rgba(255, 255, 255, 0.66);
  1095. color: #53719b;
  1096. }
  1097. .platform-app__icon {
  1098. display: inline-flex;
  1099. align-items: center;
  1100. justify-content: center;
  1101. color: currentColor;
  1102. }
  1103. .platform-app__label {
  1104. min-width: 0;
  1105. flex: 1;
  1106. white-space: nowrap;
  1107. overflow: hidden;
  1108. text-overflow: ellipsis;
  1109. }
  1110. .portal-mobile-shortcuts {
  1111. display: grid;
  1112. grid-template-columns: repeat(3, minmax(0, 1fr));
  1113. gap: 8px;
  1114. }
  1115. .portal-mobile-shortcut {
  1116. min-width: 0;
  1117. border: 0;
  1118. border-radius: 10px;
  1119. padding: 10px 8px;
  1120. background: linear-gradient(180deg, #ffffff 0%, #eaf2ff 100%);
  1121. color: #0d4a9d;
  1122. font-size: 13px;
  1123. font-weight: 600;
  1124. box-shadow: 0 6px 16px rgba(58, 110, 187, 0.08);
  1125. }
  1126. .side-card {
  1127. overflow: hidden;
  1128. background: #e8f1f8;
  1129. /* box-shadow: 0 12px 28px rgba(58, 110, 187, 0.06); */
  1130. }
  1131. .side-card--content {
  1132. padding-top: 10px;
  1133. }
  1134. .side-card__header {
  1135. display: flex;
  1136. align-items: center;
  1137. justify-content: space-between;
  1138. min-height: 20px;
  1139. padding-right: 10px;
  1140. border-radius: 100px;
  1141. background: #d5e6fc;
  1142. }
  1143. .notice-badge {
  1144. position: relative;
  1145. display: inline-flex;
  1146. align-items: center;
  1147. justify-content: center;
  1148. height: 25px;
  1149. min-width: 70px;
  1150. /* padding: 0 5px 0 10px; */
  1151. background: #004098;
  1152. color: #fff;
  1153. font-size: 14px;
  1154. font-weight: bold;
  1155. border-radius: 100px;
  1156. }
  1157. .notice-tabs {
  1158. display: inline-flex;
  1159. align-items: center;
  1160. gap: 8px;
  1161. }
  1162. .notice-tab {
  1163. height: 25px;
  1164. min-width: 68px;
  1165. padding: 0 14px;
  1166. border: 0;
  1167. border-radius: 999px;
  1168. background: transparent;
  1169. color: #4d6f98;
  1170. font-size: 14px;
  1171. font-weight: 700;
  1172. cursor: pointer;
  1173. transition:
  1174. background 0.2s ease,
  1175. color 0.2s ease;
  1176. }
  1177. .notice-tab--active {
  1178. background: #004098;
  1179. color: #fff;
  1180. }
  1181. .notice-badge::after {
  1182. content: "";
  1183. position: absolute;
  1184. top: 0;
  1185. right: -15px;
  1186. }
  1187. .side-card__more {
  1188. display: inline-flex;
  1189. align-items: center;
  1190. justify-content: center;
  1191. border: 0;
  1192. background: transparent;
  1193. color: #0f53b4;
  1194. cursor: pointer;
  1195. font-size: 12px;
  1196. }
  1197. .notice-item {
  1198. background: #fff;
  1199. padding: 8px 14px;
  1200. box-shadow: 0 8px 22px rgba(63, 107, 169, 0.06);
  1201. border-radius: 10px;
  1202. }
  1203. .notice-item:hover {
  1204. box-shadow: 0 12px 28px rgba(63, 107, 169, 0.1);
  1205. transition: all 0.2s ease;
  1206. transform: translateY(-1px);
  1207. }
  1208. .notice-item__title,
  1209. .notice-item__desc {
  1210. color: #507698;
  1211. font-size: 13px;
  1212. line-height: 1.5;
  1213. display: -webkit-box;
  1214. -webkit-box-orient: vertical;
  1215. -webkit-line-clamp: 1;
  1216. overflow: hidden;
  1217. }
  1218. .panel-title {
  1219. padding: 0 16px;
  1220. color: #2f4d79;
  1221. font-size: 15px;
  1222. font-weight: 700;
  1223. }
  1224. .todo-item {
  1225. background: rgba(255, 255, 255, 0.88);
  1226. padding: 8px 14px;
  1227. box-shadow: 0 8px 22px rgba(63, 107, 169, 0.05);
  1228. }
  1229. .todo-item__tag {
  1230. display: inline-flex;
  1231. align-items: center;
  1232. border-radius: 999px;
  1233. padding: 2px 8px;
  1234. font-size: 11px;
  1235. font-weight: 600;
  1236. white-space: nowrap;
  1237. }
  1238. .news-mini {
  1239. display: flex;
  1240. align-items: center;
  1241. gap: 12px;
  1242. background: rgba(255, 255, 255, 0.88);
  1243. padding: 5px 12px;
  1244. box-shadow: 0 8px 22px rgba(63, 107, 169, 0.05);
  1245. border: none;
  1246. }
  1247. .news-mini:hover {
  1248. box-shadow: 0 12px 28px rgba(63, 107, 169, 0.1);
  1249. transition: all 0.2s ease;
  1250. transform: translateY(-1px);
  1251. }
  1252. .placeholder-panel {
  1253. display: flex;
  1254. height: 100%;
  1255. /* align-items: center; */
  1256. padding: 16px;
  1257. justify-content: start;
  1258. color: #fff;
  1259. font-size: 16px;
  1260. font-weight: 600;
  1261. letter-spacing: 0.08em;
  1262. }
  1263. @media (max-width: 1279px) {
  1264. .hero-banner__inner {
  1265. grid-template-columns: 1fr;
  1266. padding: 28px 28px 20px;
  1267. }
  1268. .hero-script {
  1269. font-size: 52px;
  1270. }
  1271. .hero-text {
  1272. font-size: 18px;
  1273. }
  1274. .hero-progress {
  1275. margin-top: 28px;
  1276. }
  1277. .hero-visual {
  1278. min-height: 220px;
  1279. }
  1280. }
  1281. @media (max-width: 767px) {
  1282. .platform-block__header {
  1283. padding: 0 16px 0 18px;
  1284. }
  1285. .platform-block__title-wrap {
  1286. gap: 12px;
  1287. flex-wrap: wrap;
  1288. }
  1289. .platform-block__title {
  1290. font-size: 16px;
  1291. }
  1292. .platform-block__subtitle {
  1293. font-size: 12px;
  1294. }
  1295. .platform-block__watermark {
  1296. font-size: 34px;
  1297. }
  1298. .hero-banner__inner {
  1299. padding: 24px 18px 20px;
  1300. }
  1301. .hero-script {
  1302. font-size: 44px;
  1303. }
  1304. .hero-progress {
  1305. margin-top: 22px;
  1306. }
  1307. }
  1308. .carousel-container {
  1309. position: relative;
  1310. height: 220px;
  1311. overflow: hidden;
  1312. }
  1313. .carousel-slide {
  1314. position: relative;
  1315. background-size: cover;
  1316. background-position: center;
  1317. }
  1318. .hero-visual img {
  1319. width: 100%;
  1320. height: 100%;
  1321. object-fit: cover;
  1322. }
  1323. .carousel-caption {
  1324. position: absolute;
  1325. left: 40px;
  1326. top: 40%;
  1327. z-index: 2;
  1328. transform: translateY(-50%);
  1329. text-align: left;
  1330. }
  1331. .carousel-indicators {
  1332. display: flex;
  1333. gap: 8px;
  1334. z-index: 30;
  1335. }
  1336. .carousel-indicators button {
  1337. width: 12px;
  1338. height: 12px;
  1339. border-radius: 50%;
  1340. cursor: pointer;
  1341. transition: all 0.3s ease;
  1342. box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.8);
  1343. }
  1344. .consult-dialog :deep(.el-dialog__header) {
  1345. margin-right: 0;
  1346. padding-bottom: 12px;
  1347. }
  1348. .consult-dialog :deep(.el-dialog__body) {
  1349. padding-top: 8px;
  1350. }
  1351. .consult-dialog :deep(.el-upload--picture-card) {
  1352. --el-upload-picture-card-size: 92px;
  1353. }
  1354. @media (max-width: 640px) {
  1355. .consult-dialog :deep(.el-dialog) {
  1356. width: calc(100vw - 24px) !important;
  1357. margin-top: 8vh !important;
  1358. }
  1359. }
  1360. </style>