|
|
@@ -1,169 +1,173 @@
|
|
|
<template>
|
|
|
<view class="entry-root">
|
|
|
<scroll-view class="entry-page" scroll-y>
|
|
|
- <view class="hero">
|
|
|
- <image class="hero-bg" src="/static/entry/bg.png" mode="widthFix" />
|
|
|
- <view class="hero-mask"></view>
|
|
|
- <view class="hero-content">
|
|
|
- <view class="status-row"></view>
|
|
|
-
|
|
|
- <view class="profile-row">
|
|
|
- <view class="avatar-wrap">
|
|
|
- <image
|
|
|
- style="
|
|
|
- width: 50px;
|
|
|
- height: 50px;
|
|
|
- background-color: transparent;
|
|
|
- border-radius: 50%;
|
|
|
- "
|
|
|
- :src="
|
|
|
- userInfo?.avatar ? userInfo?.avatar : '/static/user/avatar.png'
|
|
|
- "
|
|
|
- ></image>
|
|
|
- </view>
|
|
|
- <view class="profile-main">
|
|
|
- <view class="greeting">{{ greetingText }},{{ displayName }}</view>
|
|
|
- </view>
|
|
|
- <view
|
|
|
- class="notice-wrap"
|
|
|
- @click="navigatorTo('/pages/message/index')"
|
|
|
- >
|
|
|
- <uni-badge :text="messageCount" absolute="rightTop" size="small">
|
|
|
- <view class="notice-button">
|
|
|
- <image
|
|
|
- src="~@/static/home/message.png"
|
|
|
- style="
|
|
|
- width: 15px;
|
|
|
- height: 15px;
|
|
|
- background-color: transparent;
|
|
|
- "
|
|
|
- @click="navigatorTo('/pages/message/index')"
|
|
|
- />
|
|
|
- </view>
|
|
|
- </uni-badge>
|
|
|
+ <view class="hero">
|
|
|
+ <image class="hero-bg" src="/static/entry/bg.png" mode="widthFix" />
|
|
|
+ <view class="hero-mask"></view>
|
|
|
+ <view class="hero-content">
|
|
|
+ <view class="status-row"></view>
|
|
|
+
|
|
|
+ <view class="profile-row">
|
|
|
+ <view class="avatar-wrap">
|
|
|
+ <image
|
|
|
+ style="
|
|
|
+ width: 50px;
|
|
|
+ height: 50px;
|
|
|
+ background-color: transparent;
|
|
|
+ border-radius: 50%;
|
|
|
+ "
|
|
|
+ :src="
|
|
|
+ userInfo?.avatar
|
|
|
+ ? userInfo?.avatar
|
|
|
+ : '/static/user/avatar.png'
|
|
|
+ "
|
|
|
+ ></image>
|
|
|
+ </view>
|
|
|
+ <view class="profile-main">
|
|
|
+ <view class="greeting"
|
|
|
+ >{{ greetingText }},{{ displayName }}</view
|
|
|
+ >
|
|
|
+ </view>
|
|
|
+ <view
|
|
|
+ class="notice-wrap"
|
|
|
+ @click="navigatorTo('/pages/message/index')"
|
|
|
+ >
|
|
|
+ <uni-badge :text="messageCount" absolute="rightTop" size="small">
|
|
|
+ <view class="notice-button">
|
|
|
+ <image
|
|
|
+ src="~@/static/home/message.png"
|
|
|
+ style="
|
|
|
+ width: 15px;
|
|
|
+ height: 15px;
|
|
|
+ background-color: transparent;
|
|
|
+ "
|
|
|
+ @click="navigatorTo('/pages/message/index')"
|
|
|
+ />
|
|
|
+ </view>
|
|
|
+ </uni-badge>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- </view>
|
|
|
-
|
|
|
- <view class="content-shell">
|
|
|
- <view class="hero-title">工作台</view>
|
|
|
- <view class="section-card">
|
|
|
- <view class="section-title">核心功能</view>
|
|
|
- <scroll-view class="core-scroll" scroll-x show-scrollbar="false">
|
|
|
- <view class="core-list">
|
|
|
+
|
|
|
+ <view class="content-shell">
|
|
|
+ <view class="hero-title">工作台</view>
|
|
|
+ <view class="section-card">
|
|
|
+ <view class="section-title">核心功能</view>
|
|
|
+ <scroll-view class="core-scroll" scroll-x show-scrollbar="false">
|
|
|
+ <view class="core-list">
|
|
|
+ <view
|
|
|
+ v-for="item in coreFeatures"
|
|
|
+ :key="item.title"
|
|
|
+ class="core-item"
|
|
|
+ :class="{ active: item.active }"
|
|
|
+ @click="handleCoreFeatureClick(item)"
|
|
|
+ >
|
|
|
+ <view class="core-icon">
|
|
|
+ <image
|
|
|
+ :src="item.iconText"
|
|
|
+ mode="aspectFit"
|
|
|
+ style="
|
|
|
+ width: 40px;
|
|
|
+ height: 40px;
|
|
|
+ background-color: transparent;
|
|
|
+ "
|
|
|
+ />
|
|
|
+ </view>
|
|
|
+ <view class="core-name">{{ item.title }}</view>
|
|
|
+ <view class="core-desc">{{ item.desc }}</view>
|
|
|
+ <view class="core-indicator" v-if="item.active"></view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </scroll-view>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <view class="section-card">
|
|
|
+ <view class="section-title">PMS常用</view>
|
|
|
+ <view class="tool-grid">
|
|
|
<view
|
|
|
- v-for="item in coreFeatures"
|
|
|
+ v-for="item in commonTools"
|
|
|
:key="item.title"
|
|
|
- class="core-item"
|
|
|
- :class="{ active: item.active }"
|
|
|
- @click="handleCoreFeatureClick(item)"
|
|
|
+ class="tool-item"
|
|
|
+ @click="navigatorTo(item.path)"
|
|
|
>
|
|
|
- <view class="core-icon">
|
|
|
- <image
|
|
|
- :src="item.iconText"
|
|
|
- mode="aspectFit"
|
|
|
- style="
|
|
|
- width: 40px;
|
|
|
- height: 40px;
|
|
|
- background-color: transparent;
|
|
|
- "
|
|
|
- />
|
|
|
- </view>
|
|
|
- <view class="core-name">{{ item.title }}</view>
|
|
|
- <view class="core-desc">{{ item.desc }}</view>
|
|
|
- <view class="core-indicator" v-if="item.active"></view>
|
|
|
+ <image class="tool-icon" :src="item.icon" mode="aspectFit" />
|
|
|
+ <view class="tool-title">{{ item.title }}</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- </scroll-view>
|
|
|
- </view>
|
|
|
-
|
|
|
- <view class="section-card">
|
|
|
- <view class="section-title">PMS常用</view>
|
|
|
- <view class="tool-grid">
|
|
|
- <view
|
|
|
- v-for="item in commonTools"
|
|
|
- :key="item.title"
|
|
|
- class="tool-item"
|
|
|
- @click="navigatorTo(item.path)"
|
|
|
- >
|
|
|
- <image class="tool-icon" :src="item.icon" mode="aspectFit" />
|
|
|
- <view class="tool-title">{{ item.title }}</view>
|
|
|
- </view>
|
|
|
</view>
|
|
|
- </view>
|
|
|
|
|
|
- <view class="section-card">
|
|
|
- <view class="section-head">
|
|
|
- <view class="section-title">日报入口</view>
|
|
|
- <view class="section-tip">
|
|
|
- <uni-icons type="personadd" size="16" color="#246BFF" />
|
|
|
- <text>按角色显示</text>
|
|
|
+ <view class="section-card">
|
|
|
+ <view class="section-head">
|
|
|
+ <view class="section-title">日报入口</view>
|
|
|
+ <view class="section-tip">
|
|
|
+ <uni-icons type="personadd" size="16" color="#246BFF" />
|
|
|
+ <text>按角色显示</text>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
- </view>
|
|
|
- <view class="daily-list">
|
|
|
- <view
|
|
|
- v-if="!!userInfo.rhReportFlag"
|
|
|
- class="daily-item"
|
|
|
- @click="navigatorTo('/pages/ruihen/index?type=edit')"
|
|
|
- >
|
|
|
- <image
|
|
|
- class="daily-icon"
|
|
|
- src="/static/entry/ruiheng.png"
|
|
|
- mode="aspectFit"
|
|
|
- />
|
|
|
- <view class="daily-content">
|
|
|
- <view class="daily-title">瑞恒日报</view>
|
|
|
-
|
|
|
- <view class="daily-subtitle-wrap">
|
|
|
- <view class="daily-subtitle">进入瑞恒日报</view>
|
|
|
- <uni-icons type="right" size="12" color="#8090a8" />
|
|
|
+ <view class="daily-list">
|
|
|
+ <view
|
|
|
+ v-if="!!userInfo.rhReportFlag"
|
|
|
+ class="daily-item"
|
|
|
+ @click="navigatorTo('/pages/ruihen/index?type=edit')"
|
|
|
+ >
|
|
|
+ <image
|
|
|
+ class="daily-icon"
|
|
|
+ src="/static/entry/ruiheng.png"
|
|
|
+ mode="aspectFit"
|
|
|
+ />
|
|
|
+ <view class="daily-content">
|
|
|
+ <view class="daily-title">瑞恒日报</view>
|
|
|
+
|
|
|
+ <view class="daily-subtitle-wrap">
|
|
|
+ <view class="daily-subtitle">进入瑞恒日报</view>
|
|
|
+ <uni-icons type="right" size="12" color="#8090a8" />
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- </view>
|
|
|
|
|
|
- <view
|
|
|
- class="daily-item"
|
|
|
- v-if="!!userInfo.rdReportFlag"
|
|
|
- @click="navigatorTo('/pages/ruiDu/index')"
|
|
|
- >
|
|
|
- <image
|
|
|
- class="daily-icon"
|
|
|
- src="/static/entry/ruidu.png"
|
|
|
- mode="aspectFit"
|
|
|
- />
|
|
|
- <view class="daily-content">
|
|
|
- <view class="daily-title">瑞都日报</view>
|
|
|
-
|
|
|
- <view class="daily-subtitle-wrap">
|
|
|
- <view class="daily-subtitle">进入瑞都日报</view>
|
|
|
- <uni-icons type="right" size="12" color="#8090a8" />
|
|
|
+ <view
|
|
|
+ class="daily-item"
|
|
|
+ v-if="!!userInfo.rdReportFlag"
|
|
|
+ @click="navigatorTo('/pages/ruiDu/index')"
|
|
|
+ >
|
|
|
+ <image
|
|
|
+ class="daily-icon"
|
|
|
+ src="/static/entry/ruidu.png"
|
|
|
+ mode="aspectFit"
|
|
|
+ />
|
|
|
+ <view class="daily-content">
|
|
|
+ <view class="daily-title">瑞都日报</view>
|
|
|
+
|
|
|
+ <view class="daily-subtitle-wrap">
|
|
|
+ <view class="daily-subtitle">进入瑞都日报</view>
|
|
|
+ <uni-icons type="right" size="12" color="#8090a8" />
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- </view>
|
|
|
|
|
|
- <view
|
|
|
- class="daily-item"
|
|
|
- v-if="!!userInfo.ryReportFlag"
|
|
|
- @click="navigatorTo('/pages/ruiying/index?type=edit')"
|
|
|
- >
|
|
|
- <image
|
|
|
- class="daily-icon"
|
|
|
- src="/static/entry/ruiying.png"
|
|
|
- mode="aspectFit"
|
|
|
- />
|
|
|
- <view class="daily-content">
|
|
|
- <view class="daily-title">瑞鹰日报</view>
|
|
|
-
|
|
|
- <view class="daily-subtitle-wrap">
|
|
|
- <view class="daily-subtitle">进入瑞鹰日报</view>
|
|
|
- <uni-icons type="right" size="12" color="#8090a8" />
|
|
|
+ <view
|
|
|
+ class="daily-item"
|
|
|
+ v-if="!!userInfo.ryReportFlag"
|
|
|
+ @click="navigatorTo('/pages/ruiying/index?type=edit')"
|
|
|
+ >
|
|
|
+ <image
|
|
|
+ class="daily-icon"
|
|
|
+ src="/static/entry/ruiying.png"
|
|
|
+ mode="aspectFit"
|
|
|
+ />
|
|
|
+ <view class="daily-content">
|
|
|
+ <view class="daily-title">瑞鹰日报</view>
|
|
|
+
|
|
|
+ <view class="daily-subtitle-wrap">
|
|
|
+ <view class="daily-subtitle">进入瑞鹰日报</view>
|
|
|
+ <uni-icons type="right" size="12" color="#8090a8" />
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- </view>
|
|
|
</scroll-view>
|
|
|
<uni-popup
|
|
|
ref="operationMeetingPopup"
|
|
|
@@ -194,8 +198,8 @@
|
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
|
-import { computed, ref } from "vue";
|
|
|
-import { onShow } from "@dcloudio/uni-app";
|
|
|
+import { computed, ref, nextTick } from "vue";
|
|
|
+import { onShow, onLoad } from "@dcloudio/uni-app";
|
|
|
import dayjs from "dayjs";
|
|
|
import { getLoginUserInfo } from "@/api/login";
|
|
|
import { getUnreadMessageCount } from "@/api/message";
|
|
|
@@ -204,6 +208,7 @@ import { getUserInfo } from "@/utils/auth";
|
|
|
|
|
|
const userInfo = ref({});
|
|
|
const messageCount = ref(0);
|
|
|
+let source = ref("");
|
|
|
const todoStats = ref({
|
|
|
maintenance: 0,
|
|
|
fault: 0,
|
|
|
@@ -442,6 +447,10 @@ const navigatorTo = (url) => {
|
|
|
};
|
|
|
|
|
|
const operationMeetingPopup = ref(null);
|
|
|
+const openOperationMeetingPopup = async () => {
|
|
|
+ await nextTick();
|
|
|
+ operationMeetingPopup.value?.open();
|
|
|
+};
|
|
|
|
|
|
const handleCoreFeatureClick = (item) => {
|
|
|
if (item.title === "生产运营双周会") {
|
|
|
@@ -462,6 +471,17 @@ const navigateToOperationMeeting = (url) => {
|
|
|
|
|
|
onShow(() => {
|
|
|
loadPageData();
|
|
|
+ if (source.value === "yyhy") {
|
|
|
+ openOperationMeetingPopup();
|
|
|
+ }
|
|
|
+});
|
|
|
+
|
|
|
+onLoad((options) => {
|
|
|
+ console.log("entry-onload", options);
|
|
|
+ source.value = options?.source || "";
|
|
|
+ if (source.value === "yyhy") {
|
|
|
+ openOperationMeetingPopup();
|
|
|
+ }
|
|
|
});
|
|
|
</script>
|
|
|
|