From e3d4c3426c86392e27df63300b601507b32f5c7e Mon Sep 17 00:00:00 2001 From: zhengyiming <540361168@qq.com> Date: 星期三, 13 八月 2025 14:26:51 +0800 Subject: [PATCH] fix: 灵工管理 --- apps/bMiniApp/src/subpackages/businessCard/businessCard/businessCard.vue | 2 apps/cMiniApp/src/assets/icon-developing.png | 0 apps/bMiniApp/src/subpackages/authentication/authenticationHome/authenticationHome.vue | 2 apps/cMiniApp/src/components/Layout/PageLayoutWithBg.vue | 1 apps/bMiniApp/src/assets/icon-developing.png | 0 packages/components/src/Layout/DevelopingLayout.vue | 48 ++++++++++++ apps/bMiniApp/src/components/Layout/PageLayoutWithBg.vue | 1 apps/bMiniApp/src/subpackages/authentication/hooks/index.ts | 56 +++++++------- packages/hooks/setting.ts | 47 +++++++---- packages/utils/index.ts | 1 types/api.d.ts | 13 +++ packages/utils/developing.ts | 5 + apps/bMiniApp/src/hooks/user.ts | 2 packages/components/src/index.ts | 1 apps/bMiniApp/src/pages/mine/index.vue | 24 +++-- packages/utils/link.ts | 1 apps/bMiniApp/src/subpackages/mine/mineContactRecord/mineContactRecord.vue | 2 packages/components/assets/icon-developing.png | 0 apps/cMiniApp/src/components/Layout/PageLayout.vue | 12 ++ apps/bMiniApp/src/components/Layout/PageLayout.vue | 12 ++ 20 files changed, 166 insertions(+), 64 deletions(-) diff --git a/apps/bMiniApp/src/assets/icon-developing.png b/apps/bMiniApp/src/assets/icon-developing.png new file mode 100644 index 0000000..c721f31 --- /dev/null +++ b/apps/bMiniApp/src/assets/icon-developing.png Binary files differ diff --git a/apps/bMiniApp/src/components/Layout/PageLayout.vue b/apps/bMiniApp/src/components/Layout/PageLayout.vue index 474d352..7149940 100644 --- a/apps/bMiniApp/src/components/Layout/PageLayout.vue +++ b/apps/bMiniApp/src/components/Layout/PageLayout.vue @@ -16,8 +16,10 @@ </slot> <div class="page-layout-scroll-view-wrapper" :style="{ height: scrollViewHeight }"> - <slot :scrollViewHeight="scrollViewHeight" v-if="isAuth"></slot> - <!-- <template v-if="isAuth"> + <DevelopingLayout v-if="developing"></DevelopingLayout> + <template v-else> + <slot :scrollViewHeight="scrollViewHeight" v-if="isAuth"></slot> + <!-- <template v-if="isAuth"> <slot v-if="useView" :scrollViewHeight="scrollViewHeight"></slot> <scroll-view v-else @@ -28,6 +30,7 @@ <slot :scrollViewHeight="scrollViewHeight"></slot> </scroll-view> </template> --> + </template> </div> <div v-if="!pageHeightWithTabBar" class="safe-area-bottom"></div> </div> @@ -45,6 +48,7 @@ import { useAuth } from '@/hooks'; import { Portal } from 'senin-mini/components'; import { usePickProps } from 'senin-mini/hooks'; +import { DevelopingLayout } from '@12333/components'; defineOptions({ name: 'PageLayout', @@ -69,6 +73,10 @@ type: Number, default: 388, }, + developing: { + type: Boolean, + default: false, + }, }); const _commonNavigationBarProps = usePickProps(props, commonNavigationBarProps); diff --git a/apps/bMiniApp/src/components/Layout/PageLayoutWithBg.vue b/apps/bMiniApp/src/components/Layout/PageLayoutWithBg.vue index 5456a67..8a72a3a 100644 --- a/apps/bMiniApp/src/components/Layout/PageLayoutWithBg.vue +++ b/apps/bMiniApp/src/components/Layout/PageLayoutWithBg.vue @@ -28,6 +28,7 @@ type Props = { title?: string; + developing?: boolean; }; const props = withDefaults(defineProps<Props>(), {}); diff --git a/apps/bMiniApp/src/hooks/user.ts b/apps/bMiniApp/src/hooks/user.ts index 6488550..28b1083 100644 --- a/apps/bMiniApp/src/hooks/user.ts +++ b/apps/bMiniApp/src/hooks/user.ts @@ -31,7 +31,7 @@ // }); const isCertified = computed(() => { - return userDetail.value?.frontStatus === UserCertificationFrontStatus.Certified; + return false; }); return { diff --git a/apps/bMiniApp/src/pages/mine/index.vue b/apps/bMiniApp/src/pages/mine/index.vue index c5c3a21..eeabb24 100644 --- a/apps/bMiniApp/src/pages/mine/index.vue +++ b/apps/bMiniApp/src/pages/mine/index.vue @@ -26,16 +26,16 @@ </div> <div class="user-info-item"> <template v-if="isCertified"> - <div class="user-info-unCertified-text">鏈璇�</div> - <div class="user-info-unCertified-btn" @click.stop="goAuthentication"> - 绔嬪嵆璁よ瘉 - </div> - </template> - <template v-else> <div class="user-info-certified-text"> {{ userDetail?.customerName ?? '123' }} </div> <div class="user-info-certified-btn">宸茶璇�</div> + </template> + <template v-else> + <div class="user-info-unCertified-text">鏈璇�</div> + <div class="user-info-unCertified-btn" @click.stop="goAuthentication"> + 绔嬪嵆璁よ瘉 + </div> </template> </div> </div> @@ -48,7 +48,7 @@ <div class="mine-business-card-item-text">鎴戠殑鐢靛瓙鍚嶇墖</div> </div> <div class="mine-business-card-btn"> - <nut-button type="info">閫掑悕鐗�</nut-button> + <nut-button type="info" @click="goBusinessCard">閫掑悕鐗�</nut-button> </div> </div> </UserHomeTopView> @@ -56,13 +56,13 @@ <div class="mine-content-record"> <div class="mine-content-record-item" @click="goMineFavorites"> <img class="mine-content-record-item-icon" :src="IconCollect" alt="" /> - <nut-badge top="0" right="0" :value="8" color="#FF7D00"> + <nut-badge top="0" right="0" :value="8" color="#FF7D00" hidden> <div class="mine-content-record-item-text">鎴戠殑鏀惰棌</div> </nut-badge> </div> <div class="mine-content-record-item" @click="goMineContactRecord"> <img class="mine-content-record-item-icon" :src="IconRecord" alt="" /> - <nut-badge top="0" right="0" :value="8" color="#FF7D00"> + <nut-badge top="0" right="0" :value="8" color="#FF7D00" hidden> <div class="mine-content-record-item-text">鑱旂郴璁板綍</div> </nut-badge> </div> @@ -70,7 +70,11 @@ <Cell :title="'鏇村鏈嶅姟'" class="mine-content-service"> <div class="mine-content-service-list"> <TaskDetailWelfareItem :icon="IconFinance" text="璐㈠姟绠$悊"></TaskDetailWelfareItem> - <TaskDetailWelfareItem :icon="IconRealName" text="浼佷笟瀹炲悕"></TaskDetailWelfareItem> + <TaskDetailWelfareItem + :icon="IconRealName" + text="浼佷笟瀹炲悕" + @click.stop="goAuthentication" + ></TaskDetailWelfareItem> <TaskDetailWelfareItem :icon="IconSetting" text="璁剧疆" diff --git a/apps/bMiniApp/src/subpackages/authentication/authenticationHome/authenticationHome.vue b/apps/bMiniApp/src/subpackages/authentication/authenticationHome/authenticationHome.vue index ac39fb5..d27e9b9 100644 --- a/apps/bMiniApp/src/subpackages/authentication/authenticationHome/authenticationHome.vue +++ b/apps/bMiniApp/src/subpackages/authentication/authenticationHome/authenticationHome.vue @@ -1,5 +1,5 @@ <template> - <PageLayout class="authenticationHome-page-wrapper"> + <PageLayout class="authenticationHome-page-wrapper" developing> <template #navigationBar> <TransparentNavigationBar title="瀹炲悕璁よ瘉" :is-absolute="false"></TransparentNavigationBar> </template> diff --git a/apps/bMiniApp/src/subpackages/authentication/hooks/index.ts b/apps/bMiniApp/src/subpackages/authentication/hooks/index.ts index 6cae857..39dfccd 100644 --- a/apps/bMiniApp/src/subpackages/authentication/hooks/index.ts +++ b/apps/bMiniApp/src/subpackages/authentication/hooks/index.ts @@ -10,7 +10,7 @@ UserCertificationPayType, } from '@12333/constants'; import { FormValidator, Message } from '@12333/utils'; -// import { useUserCertificationSetting } from '@12333/hooks'; +import { useUserCertificationSetting } from '@12333/hooks'; import Taro from '@tarojs/taro'; type UseAuthenticationFlowOptions = { @@ -158,32 +158,32 @@ }; } -// export function useDownloadPowerAttorneyTemplate() { -// // const { userCertificationSetting } = useUserCertificationSetting(); +export function useDownloadPowerAttorneyTemplate() { + const { userCertificationSetting } = useUserCertificationSetting(); -// function downloadPowerAttorneyTemplate() { -// Taro.showLoading({ -// title: '涓嬭浇涓�', -// }); -// Taro.downloadFile({ -// url: userCertificationSetting.value.enterprisePowerAttorneyTempPath, -// success: function (res) { -// Taro.hideLoading(); -// // Message.success('涓嬭浇鎴愬姛'); -// var filePath = res.tempFilePath; -// Taro.openDocument({ -// filePath: filePath, -// showMenu: true, -// }); -// }, -// fail: function (error: any) { -// Taro.hideLoading(); -// Message.error('涓嬭浇澶辫触'); -// }, -// }); -// } + function downloadPowerAttorneyTemplate() { + Taro.showLoading({ + title: '涓嬭浇涓�', + }); + Taro.downloadFile({ + url: userCertificationSetting.value.enterprisePowerAttorneyTempPath, + success: function (res) { + Taro.hideLoading(); + // Message.success('涓嬭浇鎴愬姛'); + var filePath = res.tempFilePath; + Taro.openDocument({ + filePath: filePath, + showMenu: true, + }); + }, + fail: function (error: any) { + Taro.hideLoading(); + Message.error('涓嬭浇澶辫触'); + }, + }); + } -// return { -// downloadPowerAttorneyTemplate, -// }; -// } + return { + downloadPowerAttorneyTemplate, + }; +} diff --git a/apps/bMiniApp/src/subpackages/businessCard/businessCard/businessCard.vue b/apps/bMiniApp/src/subpackages/businessCard/businessCard/businessCard.vue index e435389..f63da9e 100644 --- a/apps/bMiniApp/src/subpackages/businessCard/businessCard/businessCard.vue +++ b/apps/bMiniApp/src/subpackages/businessCard/businessCard/businessCard.vue @@ -1,5 +1,5 @@ <template> - <PageLayoutWithBg class="businessCard-page-wrapper" :title="'鐢靛瓙鍚嶇墖'"> + <PageLayoutWithBg class="businessCard-page-wrapper" :title="'鐢靛瓙鍚嶇墖'" developing> <InnerPage></InnerPage> </PageLayoutWithBg> </template> diff --git a/apps/bMiniApp/src/subpackages/mine/mineContactRecord/mineContactRecord.vue b/apps/bMiniApp/src/subpackages/mine/mineContactRecord/mineContactRecord.vue index 44dae4f..e0e3e03 100644 --- a/apps/bMiniApp/src/subpackages/mine/mineContactRecord/mineContactRecord.vue +++ b/apps/bMiniApp/src/subpackages/mine/mineContactRecord/mineContactRecord.vue @@ -1,5 +1,5 @@ <template> - <PageLayoutWithBg class="mineContactRecord-page-wrapper" :title="'鑱旂郴璁板綍'"> + <PageLayoutWithBg class="mineContactRecord-page-wrapper" :title="'鑱旂郴璁板綍'" developing> <InnerPage></InnerPage> </PageLayoutWithBg> </template> diff --git a/apps/cMiniApp/src/assets/icon-developing.png b/apps/cMiniApp/src/assets/icon-developing.png new file mode 100644 index 0000000..c721f31 --- /dev/null +++ b/apps/cMiniApp/src/assets/icon-developing.png Binary files differ diff --git a/apps/cMiniApp/src/components/Layout/PageLayout.vue b/apps/cMiniApp/src/components/Layout/PageLayout.vue index 474d352..7149940 100644 --- a/apps/cMiniApp/src/components/Layout/PageLayout.vue +++ b/apps/cMiniApp/src/components/Layout/PageLayout.vue @@ -16,8 +16,10 @@ </slot> <div class="page-layout-scroll-view-wrapper" :style="{ height: scrollViewHeight }"> - <slot :scrollViewHeight="scrollViewHeight" v-if="isAuth"></slot> - <!-- <template v-if="isAuth"> + <DevelopingLayout v-if="developing"></DevelopingLayout> + <template v-else> + <slot :scrollViewHeight="scrollViewHeight" v-if="isAuth"></slot> + <!-- <template v-if="isAuth"> <slot v-if="useView" :scrollViewHeight="scrollViewHeight"></slot> <scroll-view v-else @@ -28,6 +30,7 @@ <slot :scrollViewHeight="scrollViewHeight"></slot> </scroll-view> </template> --> + </template> </div> <div v-if="!pageHeightWithTabBar" class="safe-area-bottom"></div> </div> @@ -45,6 +48,7 @@ import { useAuth } from '@/hooks'; import { Portal } from 'senin-mini/components'; import { usePickProps } from 'senin-mini/hooks'; +import { DevelopingLayout } from '@12333/components'; defineOptions({ name: 'PageLayout', @@ -69,6 +73,10 @@ type: Number, default: 388, }, + developing: { + type: Boolean, + default: false, + }, }); const _commonNavigationBarProps = usePickProps(props, commonNavigationBarProps); diff --git a/apps/cMiniApp/src/components/Layout/PageLayoutWithBg.vue b/apps/cMiniApp/src/components/Layout/PageLayoutWithBg.vue index 3706ecb..99b4aaa 100644 --- a/apps/cMiniApp/src/components/Layout/PageLayoutWithBg.vue +++ b/apps/cMiniApp/src/components/Layout/PageLayoutWithBg.vue @@ -28,6 +28,7 @@ type Props = { title?: string; + developing?: boolean; }; const props = withDefaults(defineProps<Props>(), {}); diff --git a/packages/components/assets/icon-developing.png b/packages/components/assets/icon-developing.png new file mode 100644 index 0000000..c721f31 --- /dev/null +++ b/packages/components/assets/icon-developing.png Binary files differ diff --git a/packages/components/src/Layout/DevelopingLayout.vue b/packages/components/src/Layout/DevelopingLayout.vue new file mode 100644 index 0000000..6d63c13 --- /dev/null +++ b/packages/components/src/Layout/DevelopingLayout.vue @@ -0,0 +1,48 @@ +<template> + <div class="developing-layout"> + <div class="developing-layout-inner"> + <img :src="IconDeveloping" class="developing-layout-icon" /> + <div class="developing-layout-text">鍔熻兘寮�鍙戜腑...</div> + </div> + </div> +</template> + +<script setup lang="ts"> +import IconDeveloping from '@/assets/icon-developing.png'; + +defineOptions({ + name: 'DevelopingLayout', +}); + +// type Props = {}; + +// const props = withDefaults(defineProps<Props>(), {}); +</script> + +<style lang="scss"> +@import '@/styles/common.scss'; + +.developing-layout { + height: 100%; + display: flex; + align-items: center; + justify-content: center; + + .developing-layout-inner { + display: flex; + flex-direction: column; + align-items: center; + + .developing-layout-icon { + width: 240px; + height: 240px; + margin-bottom: 26px; + } + + .developing-layout-text { + font-size: 32px; + color: boleGetCssVar('text-color', 'primary'); + } + } +} +</style> diff --git a/packages/components/src/index.ts b/packages/components/src/index.ts index e05bd94..a98cb48 100644 --- a/packages/components/src/index.ts +++ b/packages/components/src/index.ts @@ -38,3 +38,4 @@ export { default as JobTagList } from './Tag/JobTagList.vue'; export { default as CommonInputField } from './Input/CommonInputField.vue'; export { default as PositionSelectView } from './AreaTreeSelect/PositionSelectView.vue'; +export { default as DevelopingLayout } from './Layout/DevelopingLayout.vue'; diff --git a/packages/hooks/setting.ts b/packages/hooks/setting.ts index 1ec28eb..8830255 100644 --- a/packages/hooks/setting.ts +++ b/packages/hooks/setting.ts @@ -1,5 +1,5 @@ import { useQuery } from '@tanstack/vue-query'; -import { MaybeRef, Ref, unref } from 'vue'; +import { MaybeRef, Ref, unref, ref } from 'vue'; import { BusinessSettingType, TempFolderPath } from '@12333/constants'; type UseBusinessSettingByTypeOptions<T extends object = object, TData = T> = { @@ -44,19 +44,32 @@ offlinePayEndDays: number; }; -// export function useUserCertificationSetting() { -// const { businessSetting } = useBusinessSettingByType<UserCertificationSetting>({ -// type: BusinessSettingType.UserCertification, -// select(data: any) { -// return { -// ...data, -// enterprisePowerAttorneyTempPath: `${TempFolderPath}${data.enterprisePowerAttorneyTempPath}`, -// idPhoteTempPath: `${TempFolderPath}${data.idPhoteTempPath}`, -// payAmount: data.userCertificationAmount, -// }; -// }, -// }); -// return { -// userCertificationSetting: businessSetting, -// }; -// } +export function useUserCertificationSetting() { + // const { businessSetting } = useBusinessSettingByType<UserCertificationSetting>({ + // type: BusinessSettingType.UserCertification, + // select(data: any) { + // return { + // ...data, + // enterprisePowerAttorneyTempPath: `${TempFolderPath}${data.enterprisePowerAttorneyTempPath}`, + // idPhoteTempPath: `${TempFolderPath}${data.idPhoteTempPath}`, + // payAmount: data.userCertificationAmount, + // }; + // }, + // }); + + const businessSetting = ref({ + authenticationHelpUrl: '', + receivingAccount: '', + receivingCompanyName: '', + receivingBankName: '', + offlinePayEndTime: '', + offlinePayEndDays: 1, + enterprisePowerAttorneyTempPath: `${TempFolderPath}`, + idPhoteTempPath: `${TempFolderPath}`, + payAmount: 123, + }); + + return { + userCertificationSetting: businessSetting, + }; +} diff --git a/packages/utils/developing.ts b/packages/utils/developing.ts new file mode 100644 index 0000000..b26b615 --- /dev/null +++ b/packages/utils/developing.ts @@ -0,0 +1,5 @@ +import { Message } from './message'; + +export function hanldeDeveloping() { + Message.warning('璇ュ姛鑳芥鍦ㄥ紑鍙戜腑,鏁鏈熷緟~'); +} diff --git a/packages/utils/index.ts b/packages/utils/index.ts index a626aa0..505a35e 100644 --- a/packages/utils/index.ts +++ b/packages/utils/index.ts @@ -15,3 +15,4 @@ export * from './location'; export * from './encrypt'; export * from './task'; +export * from './developing'; diff --git a/packages/utils/link.ts b/packages/utils/link.ts index f7d56de..66dcffc 100644 --- a/packages/utils/link.ts +++ b/packages/utils/link.ts @@ -11,7 +11,6 @@ }; export function setOSSLink(url: string) { - console.log('url: ', url, OSSBaseURL); if (!url) { return ''; } diff --git a/types/api.d.ts b/types/api.d.ts index cd91077..f610eb0 100644 --- a/types/api.d.ts +++ b/types/api.d.ts @@ -61,4 +61,17 @@ interface GetTaskInfoQueryResult{ enterpriseName?:string } + + interface IntroInfo { + /** 绫诲瀷锛�0涓烘枃鏈紝1涓哄浘鐗囷紝2涓鸿棰戯紱榛樿涓烘枃鏈� */ + type?: number; + /** 鎽樿 */ + contentSummary?: string; + /** 鏂囨湰鍐呭 */ + content?: string; + /** 鍥剧墖/瑙嗛璺緞 */ + path?: string; + /** 鎺掑簭 */ + sequence?: number; + } } -- Gitblit v1.9.1