index.vue 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928
  1. <template>
  2. <view class="entry-root">
  3. <scroll-view class="entry-page" scroll-y>
  4. <view class="hero">
  5. <image class="hero-bg" src="/static/entry/bg.png" mode="widthFix" />
  6. <view class="hero-mask"></view>
  7. <view class="hero-content">
  8. <view class="status-row"></view>
  9. <view class="profile-row">
  10. <view class="avatar-wrap">
  11. <image
  12. style="
  13. width: 50px;
  14. height: 50px;
  15. background-color: transparent;
  16. border-radius: 50%;
  17. "
  18. :src="
  19. userInfo?.avatar
  20. ? userInfo?.avatar
  21. : '/static/user/avatar.png'
  22. "
  23. ></image>
  24. </view>
  25. <view class="profile-main">
  26. <view class="greeting"
  27. >{{ greetingText }},{{ displayName }}</view
  28. >
  29. </view>
  30. <view
  31. class="notice-wrap"
  32. @click="navigatorTo('/pages/message/index')"
  33. >
  34. <uni-badge :text="messageCount" absolute="rightTop" size="small">
  35. <view class="notice-button">
  36. <image
  37. src="~@/static/home/message.png"
  38. style="
  39. width: 15px;
  40. height: 15px;
  41. background-color: transparent;
  42. "
  43. @click="navigatorTo('/pages/message/index')"
  44. />
  45. </view>
  46. </uni-badge>
  47. </view>
  48. </view>
  49. </view>
  50. </view>
  51. <view class="content-shell">
  52. <view class="hero-title">工作台</view>
  53. <view class="section-card">
  54. <view class="section-title">核心功能</view>
  55. <scroll-view class="core-scroll" scroll-x show-scrollbar="false">
  56. <view class="core-list">
  57. <view
  58. v-for="item in coreFeatures"
  59. :key="item.title"
  60. class="core-item"
  61. :class="{ active: item.active }"
  62. @click="handleCoreFeatureClick(item)"
  63. >
  64. <view class="core-icon">
  65. <image
  66. :src="item.iconText"
  67. mode="aspectFit"
  68. style="
  69. width: 40px;
  70. height: 40px;
  71. background-color: transparent;
  72. "
  73. />
  74. </view>
  75. <view class="core-name">{{ item.title }}</view>
  76. <view class="core-desc">{{ item.desc }}</view>
  77. <view class="core-indicator" v-if="item.active"></view>
  78. </view>
  79. </view>
  80. </scroll-view>
  81. </view>
  82. <view class="section-card">
  83. <view class="section-title">PMS常用</view>
  84. <view class="tool-grid">
  85. <view
  86. v-for="item in commonTools"
  87. :key="item.title"
  88. class="tool-item"
  89. @click="navigatorTo(item.path)"
  90. >
  91. <image class="tool-icon" :src="item.icon" mode="aspectFit" />
  92. <view class="tool-title">{{ item.title }}</view>
  93. </view>
  94. </view>
  95. </view>
  96. <view class="section-card">
  97. <view class="section-head">
  98. <view class="section-title">日报入口</view>
  99. <view class="section-tip">
  100. <uni-icons type="personadd" size="16" color="#246BFF" />
  101. <text>按角色显示</text>
  102. </view>
  103. </view>
  104. <view class="daily-list">
  105. <view
  106. v-if="!!userInfo.rhReportFlag"
  107. class="daily-item"
  108. @click="navigatorTo('/pages/ruihen/index?type=edit')"
  109. >
  110. <image
  111. class="daily-icon"
  112. src="/static/entry/ruiheng.png"
  113. mode="aspectFit"
  114. />
  115. <view class="daily-content">
  116. <view class="daily-title">瑞恒日报</view>
  117. <view class="daily-subtitle-wrap">
  118. <view class="daily-subtitle">进入瑞恒日报</view>
  119. <uni-icons type="right" size="12" color="#8090a8" />
  120. </view>
  121. </view>
  122. </view>
  123. <view
  124. class="daily-item"
  125. v-if="!!userInfo.rdReportFlag"
  126. @click="navigatorTo('/pages/ruiDu/index')"
  127. >
  128. <image
  129. class="daily-icon"
  130. src="/static/entry/ruidu.png"
  131. mode="aspectFit"
  132. />
  133. <view class="daily-content">
  134. <view class="daily-title">瑞都日报</view>
  135. <view class="daily-subtitle-wrap">
  136. <view class="daily-subtitle">进入瑞都日报</view>
  137. <uni-icons type="right" size="12" color="#8090a8" />
  138. </view>
  139. </view>
  140. </view>
  141. <view
  142. class="daily-item"
  143. v-if="!!userInfo.ryReportFlag"
  144. @click="navigatorTo('/pages/ruiying/index?type=edit')"
  145. >
  146. <image
  147. class="daily-icon"
  148. src="/static/entry/ruiying.png"
  149. mode="aspectFit"
  150. />
  151. <view class="daily-content">
  152. <view class="daily-title">瑞鹰日报</view>
  153. <view class="daily-subtitle-wrap">
  154. <view class="daily-subtitle">进入瑞鹰日报</view>
  155. <uni-icons type="right" size="12" color="#8090a8" />
  156. </view>
  157. </view>
  158. </view>
  159. </view>
  160. </view>
  161. </view>
  162. </scroll-view>
  163. <uni-popup
  164. ref="operationMeetingPopup"
  165. type="bottom"
  166. background-color="#fff"
  167. border-radius="10px 10px 0 0"
  168. >
  169. <view class="report-popup">
  170. <view class="report-popup-header">请选择生产运营双周会功能</view>
  171. <view
  172. class="report-popup-item"
  173. @click="navigateToOperationMeeting('/pages/swh/index')"
  174. >
  175. 数据填报
  176. </view>
  177. <view
  178. class="report-popup-item"
  179. @click="navigateToOperationMeeting('/pages/swh/summary')"
  180. >
  181. 数据汇总
  182. </view>
  183. <view class="report-popup-cancel" @click="closeOperationMeetingPopup">
  184. 取消
  185. </view>
  186. </view>
  187. </uni-popup>
  188. </view>
  189. </template>
  190. <script setup>
  191. import { computed, ref, nextTick } from "vue";
  192. import { onShow, onLoad } from "@dcloudio/uni-app";
  193. import dayjs from "dayjs";
  194. import { getLoginUserInfo } from "@/api/login";
  195. import { getUnreadMessageCount } from "@/api/message";
  196. import { getOvertimeTaskList } from "@/api/task";
  197. import { getUserInfo } from "@/utils/auth";
  198. const userInfo = ref({});
  199. const messageCount = ref(0);
  200. let source = ref("");
  201. const todoStats = ref({
  202. maintenance: 0,
  203. fault: 0,
  204. });
  205. const coreFeatures = [
  206. {
  207. title: "PMS",
  208. desc: "设备生命周期管理",
  209. iconText: "/static/entry/pms.png",
  210. iconBg: "linear-gradient(135deg, #eaf2ff 0%, #d8e7ff 100%)",
  211. iconColor: "#246BFF",
  212. active: true,
  213. path: "/pages/home/index",
  214. },
  215. {
  216. title: "生产运营双周会",
  217. desc: "双周会管理与跟踪",
  218. iconText: "/static/entry/yunying.png",
  219. iconBg: "linear-gradient(135deg, #fff3e8 0%, #ffe3cc 100%)",
  220. iconColor: "#ff8a1f",
  221. path: "/pages/swh/index",
  222. },
  223. {
  224. title: "组态管理",
  225. desc: "流程与仪表组态",
  226. iconText: "/static/entry/zutai.png",
  227. iconBg: "linear-gradient(135deg, #f1edff 0%, #e0d9ff 100%)",
  228. iconColor: "#6d5efc",
  229. path: "/pages/zutai/index",
  230. },
  231. {
  232. title: "QHSE",
  233. desc: "质量健康安全环保",
  234. iconText: "/static/entry/qhse.png",
  235. iconBg: "linear-gradient(135deg, #ecfff7 0%, #d8f8ea 100%)",
  236. iconColor: "#1eb980",
  237. path: "/pages/qhse/index",
  238. },
  239. {
  240. title: "智慧连油",
  241. desc: "润滑管理平台",
  242. iconText: "/static/entry/lianyou.png",
  243. iconBg: "linear-gradient(135deg, #e7fbff 0%, #d4f7fb 100%)",
  244. iconColor: "#10a8c6",
  245. path: "/pages/lianyou/index",
  246. },
  247. ];
  248. const commonTools = [
  249. {
  250. title: "运行记录",
  251. icon: "/static/entry/record.png",
  252. path: "/pages/recordFilling/list",
  253. },
  254. {
  255. title: "保养工单",
  256. icon: "/static/entry/baoyang.png",
  257. path: "/pages/maintenance/index",
  258. },
  259. {
  260. title: "设备维修",
  261. icon: "/static/entry/weixiu.png",
  262. path: "/pages/repair/index",
  263. },
  264. {
  265. title: "巡检工单",
  266. icon: "/static/entry/xunjian.png",
  267. path: "/pages/inspection/index",
  268. },
  269. {
  270. title: "故障上报",
  271. icon: "/static/entry/guzhang.png",
  272. path: "/pages/fault/index",
  273. },
  274. {
  275. title: "库存管理",
  276. icon: "/static/entry/kucun.png",
  277. path: "/pages/inventory/index",
  278. },
  279. {
  280. title: "保养查询",
  281. icon: "/static/entry/byquery.png",
  282. path: "/pages/maintenance/search",
  283. },
  284. {
  285. title: "设备台账",
  286. icon: "/static/entry/taizhang.png",
  287. path: "/pages/ledger/index",
  288. },
  289. {
  290. title: "设备状态变更",
  291. icon: "/static/entry/status.png",
  292. path: "/pages/statusChange/index",
  293. },
  294. {
  295. title: "设备责任人",
  296. icon: "/static/entry/zeren.png",
  297. path: "/pages/deviceUser/index",
  298. },
  299. ];
  300. const dailyEntries = computed(() => [
  301. {
  302. title: "瑞恒日报",
  303. subtitle: "进入瑞恒日报",
  304. path: "/pages/ruihen/index?type=edit",
  305. icon: "/static/entry/ruiheng.png",
  306. visible: !!userInfo.value.rhReportFlag,
  307. },
  308. {
  309. title: "瑞都日报",
  310. subtitle: "进入瑞都日报",
  311. path: "/pages/ruiDu/index",
  312. icon: "/static/entry/ruidu.png",
  313. visible: !!userInfo.value.rdReportFlag,
  314. },
  315. {
  316. title: "瑞鹰日报",
  317. subtitle: "进入瑞鹰日报",
  318. path: "/pages/ruiying/index?type=edit",
  319. icon: "/static/entry/ruiying.png",
  320. visible: !!userInfo.value.ryReportFlag,
  321. },
  322. ]);
  323. const visibleDailyEntries = computed(() => {
  324. const list = dailyEntries.value.filter((item) => item.visible);
  325. if (list.length) return list.slice(0, 3);
  326. return dailyEntries.value
  327. .map((item) => ({ ...item, visible: true }))
  328. .slice(0, 3);
  329. });
  330. const todoCards = computed(() => [
  331. {
  332. title: "保养工单",
  333. icon: "/static/home/baoyang.png",
  334. count: todoStats.value.maintenance,
  335. color: "#1eb980",
  336. },
  337. {
  338. title: "故障上报",
  339. icon: "/static/home/guzhang.png",
  340. count: todoStats.value.fault,
  341. color: "#ff4d4f",
  342. },
  343. ]);
  344. const currentTimeText = computed(() => dayjs().format("H:mm"));
  345. const greetingText = computed(() => {
  346. const hour = dayjs().hour();
  347. if (hour < 12) return "上午好";
  348. if (hour < 18) return "下午好";
  349. return "晚上好";
  350. });
  351. const displayName = computed(
  352. () => userInfo.value.nickname || userInfo.value.username || "张工",
  353. );
  354. const avatarText = computed(() =>
  355. String(displayName.value || "张").slice(0, 1),
  356. );
  357. const projectName = computed(
  358. () =>
  359. userInfo.value.deptName ||
  360. userInfo.value.postGroup ||
  361. userInfo.value.stationName ||
  362. "智慧工厂示例项目",
  363. );
  364. const parseCachedUserInfo = () => {
  365. const cache = getUserInfo();
  366. if (!cache) return {};
  367. try {
  368. const parsed = typeof cache === "string" ? JSON.parse(cache) : cache;
  369. if (typeof parsed === "string") {
  370. return JSON.parse(parsed)?.user || {};
  371. }
  372. return parsed?.user || parsed || {};
  373. } catch (error) {
  374. return {};
  375. }
  376. };
  377. const buildTodoStats = (list) => {
  378. const stats = {
  379. maintenance: 0,
  380. fault: 0,
  381. };
  382. list.forEach((item) => {
  383. const typeText = String(item?.type || "");
  384. if (typeText.includes("保养")) {
  385. stats.maintenance += 1;
  386. }
  387. if (typeText.includes("故障")) {
  388. stats.fault += 1;
  389. }
  390. });
  391. return stats;
  392. };
  393. const loadPageData = async () => {
  394. userInfo.value = parseCachedUserInfo();
  395. try {
  396. const [userRes, messageRes, todoRes] = await Promise.all([
  397. getLoginUserInfo(),
  398. getUnreadMessageCount(),
  399. getOvertimeTaskList({ pageNo: 1, pageSize: 50 }),
  400. ]);
  401. if (userRes?.code === 0 && userRes.data) {
  402. userInfo.value = userRes.data;
  403. }
  404. if (messageRes?.code === 0) {
  405. messageCount.value = messageRes.data || 0;
  406. }
  407. if (todoRes?.code === 0) {
  408. const todoList = todoRes.data?.list || [];
  409. todoStats.value = buildTodoStats(todoList);
  410. }
  411. } catch (error) {
  412. messageCount.value = messageCount.value || 0;
  413. }
  414. };
  415. const navigatorTo = (url) => {
  416. if (!url) return;
  417. uni.navigateTo({ url });
  418. };
  419. const operationMeetingPopup = ref(null);
  420. const openOperationMeetingPopup = async () => {
  421. await nextTick();
  422. operationMeetingPopup.value?.open();
  423. };
  424. const handleCoreFeatureClick = (item) => {
  425. if (item.title === "生产运营双周会") {
  426. operationMeetingPopup.value?.open();
  427. return;
  428. }
  429. navigatorTo(item.path);
  430. };
  431. const closeOperationMeetingPopup = () => {
  432. operationMeetingPopup.value?.close();
  433. };
  434. const navigateToOperationMeeting = (url) => {
  435. closeOperationMeetingPopup();
  436. uni.navigateTo({ url });
  437. };
  438. onShow(() => {
  439. loadPageData();
  440. if (source.value === "yyhy") {
  441. openOperationMeetingPopup();
  442. }
  443. });
  444. onLoad((options) => {
  445. console.log("entry-onload", options);
  446. source.value = options?.source || "";
  447. if (source.value === "yyhy") {
  448. openOperationMeetingPopup();
  449. }
  450. });
  451. </script>
  452. <style lang="scss" scoped>
  453. .entry-page {
  454. height: 100vh;
  455. background: linear-gradient(180deg, #edf4ff 0%, #f7f9fc 28%, #f6f8fb 100%);
  456. padding-bottom: 30rpx;
  457. }
  458. .report-popup {
  459. padding-bottom: env(safe-area-inset-bottom);
  460. }
  461. .report-popup-header {
  462. padding: 32rpx 30rpx 22rpx;
  463. color: #8a94a6;
  464. font-size: 26rpx;
  465. text-align: center;
  466. }
  467. .report-popup-item,
  468. .report-popup-cancel {
  469. padding: 30rpx;
  470. border-top: 1rpx solid #eef1f5;
  471. color: #246bff;
  472. font-size: 32rpx;
  473. text-align: center;
  474. }
  475. .report-popup-cancel {
  476. margin-top: 14rpx;
  477. border-top: 14rpx solid #f5f6f8;
  478. color: #334155;
  479. }
  480. .hero {
  481. position: relative;
  482. height: 640rpx;
  483. overflow: hidden;
  484. padding-bottom: 20rpx;
  485. }
  486. .hero-bg {
  487. position: absolute;
  488. inset: 0;
  489. width: 100%;
  490. height: 100%;
  491. }
  492. .hero-mask {
  493. position: absolute;
  494. inset: 0;
  495. height: 55%;
  496. background: linear-gradient(
  497. to bottom,
  498. rgba(255, 255, 255, 0) 0%,
  499. rgb(45, 114, 212, 0.4) 88%,
  500. rgb(45, 114, 212, 0.4) 89%,
  501. rgb(45, 114, 212, 0.7) 91%,
  502. rgb(41, 113, 214, 0.2) 95%,
  503. #f9fbfd 100%
  504. );
  505. pointer-events: none;
  506. }
  507. .hero-content {
  508. position: relative;
  509. z-index: 2;
  510. padding: calc(var(--status-bar-height) + 24rpx) 28rpx 0;
  511. }
  512. .hero-title {
  513. position: absolute;
  514. left: 0%;
  515. top: -8%;
  516. // bottom: -110%;
  517. // background: #f7f9fc;
  518. background: linear-gradient(
  519. to right,
  520. #f7f9fc 0%,
  521. #f7f9fc 50%,
  522. rgba(253, 253, 254, 0.3) 85%,
  523. rgba(253, 253, 254, 0.2) 90%,
  524. rgba(253, 253, 254, 0) 100%
  525. );
  526. border-radius: 16rpx 0rpx 0rpx 0rpx;
  527. padding-top: 20rpx;
  528. padding-bottom: 50rpx;
  529. padding-left: 28rpx;
  530. width: 50%;
  531. height: 80rpx;
  532. font-size: 40rpx;
  533. font-weight: 700;
  534. z-index: -3;
  535. }
  536. .status-row {
  537. display: flex;
  538. align-items: center;
  539. justify-content: space-between;
  540. margin-bottom: 42rpx;
  541. }
  542. .profile-row {
  543. display: flex;
  544. align-items: center;
  545. }
  546. .avatar-wrap {
  547. width: 82rpx;
  548. height: 82rpx;
  549. border-radius: 50%;
  550. display: flex;
  551. align-items: center;
  552. justify-content: center;
  553. backdrop-filter: blur(8px);
  554. }
  555. .avatar-text {
  556. color: #ffffff;
  557. font-size: 34rpx;
  558. font-weight: 700;
  559. }
  560. .profile-main {
  561. flex: 1;
  562. min-width: 0;
  563. margin-left: 22rpx;
  564. }
  565. .greeting {
  566. color: #ffffff;
  567. font-size: 30rpx;
  568. font-weight: 700;
  569. line-height: 1.2;
  570. text-shadow: 0 6rpx 18rpx rgba(0, 31, 90, 0.18);
  571. }
  572. .project-pill {
  573. display: inline-flex;
  574. align-items: center;
  575. gap: 12rpx;
  576. max-width: 100%;
  577. margin-top: 18rpx;
  578. padding: 8rpx 18rpx;
  579. border-radius: 15rpx;
  580. background: rgba(255, 255, 255, 0.18);
  581. color: #ffffff;
  582. backdrop-filter: blur(8px);
  583. }
  584. .project-name {
  585. max-width: 360rpx;
  586. overflow: hidden;
  587. text-overflow: ellipsis;
  588. white-space: nowrap;
  589. font-size: 20rpx;
  590. }
  591. .notice-wrap {
  592. margin-left: 12rpx;
  593. padding-right: 28rpx;
  594. }
  595. .notice-button {
  596. width: 30rpx;
  597. height: 30rpx;
  598. display: flex;
  599. align-items: center;
  600. justify-content: center;
  601. }
  602. .notice-glyph {
  603. font-size: 32rpx;
  604. line-height: 1;
  605. }
  606. .content-shell {
  607. position: relative;
  608. z-index: 2;
  609. margin-top: -325rpx;
  610. padding: 0 24rpx calc(env(safe-area-inset-bottom) + 34rpx);
  611. }
  612. .page-title {
  613. margin: 0 6rpx 22rpx;
  614. color: #071426;
  615. font-size: 72rpx;
  616. font-weight: 800;
  617. letter-spacing: 1rpx;
  618. }
  619. .section-card {
  620. margin-bottom: 22rpx;
  621. padding: 26rpx 22rpx 24rpx;
  622. border-radius: 20rpx;
  623. background: rgba(255, 255, 255, 0.94);
  624. box-shadow: 0 14rpx 24rpx rgba(13, 43, 91, 0.02);
  625. border: 1rpx solid #eef3fc;
  626. }
  627. .section-head {
  628. display: flex;
  629. align-items: center;
  630. justify-content: space-between;
  631. gap: 16rpx;
  632. }
  633. .section-title {
  634. color: #101c2e;
  635. font-size: 36rpx;
  636. font-weight: 700;
  637. }
  638. .section-tip {
  639. display: flex;
  640. align-items: center;
  641. gap: 8rpx;
  642. color: #5572a3;
  643. font-size: 24rpx;
  644. }
  645. .core-scroll {
  646. margin-top: 22rpx;
  647. white-space: nowrap;
  648. }
  649. .core-list {
  650. display: inline-flex;
  651. gap: 18rpx;
  652. padding-bottom: 4rpx;
  653. }
  654. .core-item {
  655. position: relative;
  656. width: 188rpx;
  657. min-height: 238rpx;
  658. padding: 24rpx 18rpx 20rpx;
  659. border-radius: 22rpx;
  660. background: #f9fbfd;
  661. border: 1rpx solid #e5edf8;
  662. box-sizing: border-box;
  663. display: flex;
  664. flex-direction: column;
  665. align-items: center;
  666. }
  667. .core-item.active {
  668. border-color: #246bff;
  669. background: linear-gradient(180deg, #ffffff 0%, #dfebfd 100%);
  670. box-shadow: inset 0 0 0 2rpx rgba(36, 107, 255, 0.08);
  671. .core-name {
  672. color: #0b57f6;
  673. }
  674. }
  675. .core-icon {
  676. width: 84rpx;
  677. height: 84rpx;
  678. border-radius: 24rpx;
  679. display: flex;
  680. align-items: center;
  681. justify-content: center;
  682. text {
  683. font-size: 42rpx;
  684. font-weight: 800;
  685. }
  686. }
  687. .core-name {
  688. margin-top: 22rpx;
  689. color: #111d2f;
  690. font-size: 20rpx;
  691. font-weight: 700;
  692. white-space: normal;
  693. }
  694. .core-desc {
  695. margin-top: 10rpx;
  696. color: #6f7f96;
  697. font-size: 18rpx;
  698. line-height: 1.5;
  699. white-space: normal;
  700. }
  701. .core-indicator {
  702. position: absolute;
  703. left: 50%;
  704. bottom: 16rpx;
  705. width: 34rpx;
  706. height: 8rpx;
  707. margin-left: -17rpx;
  708. border-radius: 999rpx;
  709. background: #246bff;
  710. }
  711. .tool-grid {
  712. display: grid;
  713. grid-template-columns: repeat(5, minmax(0, 1fr));
  714. gap: 18rpx;
  715. margin-top: 22rpx;
  716. }
  717. .tool-item {
  718. min-height: 140rpx;
  719. padding: 22rpx 10rpx 18rpx;
  720. border-radius: 20rpx;
  721. background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
  722. border: 1rpx solid #e5edf8;
  723. display: flex;
  724. flex-direction: column;
  725. align-items: center;
  726. justify-content: center;
  727. box-sizing: border-box;
  728. }
  729. .tool-icon {
  730. width: 54rpx;
  731. height: 54rpx;
  732. }
  733. .tool-title {
  734. margin-top: 16rpx;
  735. color: #111d2f;
  736. font-size: 22rpx;
  737. line-height: 1.3;
  738. text-align: center;
  739. }
  740. .daily-list {
  741. display: grid;
  742. grid-template-columns: repeat(3, minmax(0, 1fr));
  743. gap: 5rpx;
  744. margin-top: 22rpx;
  745. }
  746. .daily-item {
  747. padding: 30rpx 0rpx;
  748. border-radius: 16rpx;
  749. background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
  750. border: 1rpx solid #e5edf8;
  751. display: flex;
  752. // flex-direction: column;
  753. // align-items: center;
  754. gap: 10rpx;
  755. // min-width: 0;
  756. }
  757. .daily-subtitle-wrap {
  758. display: flex;
  759. align-items: center;
  760. margin-top: 8rpx;
  761. gap: 8rpx;
  762. }
  763. .daily-icon {
  764. width: 64rpx;
  765. height: 64rpx;
  766. flex-shrink: 0;
  767. }
  768. .daily-content {
  769. flex: 1;
  770. min-width: 0;
  771. }
  772. .daily-title {
  773. color: #111d2f;
  774. font-size: 22rpx;
  775. font-weight: 700;
  776. }
  777. .daily-subtitle {
  778. // margin-top: 8rpx;
  779. color: #6f7f96;
  780. font-size: 16rpx;
  781. white-space: nowrap;
  782. overflow: hidden;
  783. text-overflow: ellipsis;
  784. }
  785. .todo-list {
  786. display: grid;
  787. grid-template-columns: repeat(2, minmax(0, 1fr));
  788. gap: 18rpx;
  789. margin-top: 22rpx;
  790. }
  791. .todo-item {
  792. min-width: 0;
  793. padding: 22rpx 20rpx;
  794. border-radius: 22rpx;
  795. background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
  796. border: 1rpx solid #e5edf8;
  797. display: flex;
  798. align-items: center;
  799. gap: 16rpx;
  800. }
  801. .todo-icon {
  802. width: 58rpx;
  803. height: 58rpx;
  804. flex-shrink: 0;
  805. }
  806. .todo-content {
  807. flex: 1;
  808. min-width: 0;
  809. }
  810. .todo-title {
  811. color: #111d2f;
  812. font-size: 26rpx;
  813. font-weight: 700;
  814. }
  815. .todo-subtitle {
  816. margin-top: 8rpx;
  817. color: #6f7f96;
  818. font-size: 22rpx;
  819. }
  820. .todo-right {
  821. display: flex;
  822. align-items: flex-end;
  823. gap: 6rpx;
  824. }
  825. .todo-count {
  826. font-size: 48rpx;
  827. font-weight: 800;
  828. line-height: 1;
  829. }
  830. .todo-unit {
  831. margin-bottom: 6rpx;
  832. color: #6f7f96;
  833. font-size: 22rpx;
  834. }
  835. </style>