File tree Expand file tree Collapse file tree 3 files changed +23
-10
lines changed
server/src/modules/web/config/controllers
app/profile/personal-rights Expand file tree Collapse file tree 3 files changed +23
-10
lines changed Original file line number Diff line number Diff line change @@ -37,13 +37,7 @@ export class ConfigController extends BaseController {
3737 @BuildFileUrl ( [ "**.logo" , "**.icon" ] )
3838 @Public ( )
3939 async getConfig ( ) {
40- const fullConfig = await this . websiteService . getConfig ( ) ;
41-
42- return {
43- webinfo : fullConfig . webinfo ,
44- copyright : fullConfig . copyright ,
45- statistics : fullConfig . statistics ,
46- } ;
40+ return await this . websiteService . getConfig ( ) ;
4741 }
4842
4943 /**
Original file line number Diff line number Diff line change @@ -23,6 +23,8 @@ interface PaymentMethod {
2323 icon: string ;
2424}
2525
26+ const appStore = useAppStore ();
27+
2628// 组合式函数
2729const { t } = useI18n ();
2830const toast = useMessage ();
@@ -293,15 +295,20 @@ definePageMeta({
293295 t("web-personal-rights.rechargeCenter.agreement")
294296 }}</span >
295297 <UButton variant =" link" class =" p-0" @click =" toServiceTerms" >
296- 《{{ t("web-personal-rights.rechargeCenter.payment") }}》
298+ 《{{
299+ appStore.siteConfig?.agreement.paymentTitle ||
300+ t("web-personal-rights.rechargeCenter.payment")
301+ }}》
297302 </UButton >
298303 </div >
299304 <div class =" flex items-center gap-4" >
300- <div class =" text-xl font-bold" >¥ {{ currentOption?.sellPrice }}</div >
305+ <div v-if =" currentOption" class =" text-xl font-bold" >
306+ ¥ {{ currentOption?.sellPrice }}
307+ </div >
301308 <UButton
302309 color =" primary"
303310 size =" lg"
304- :disabled =" !rechargeCenterInfo?.rechargeStatus "
311+ :disabled =" !rechargeCenterInfo?.rechargeRule.length "
305312 @click =" handleRecharge"
306313 >
307314 {{ t("web-personal-rights.rechargeCenter.immediatelyPurchase") }}
Original file line number Diff line number Diff line change @@ -8,6 +8,18 @@ export interface SiteConfig {
88 copyright : WebsiteCopyright ;
99 /** 统计信息 */
1010 statistics : WebsiteStatistics ;
11+ /** 协议 */
12+ agreement : Agreement ;
13+ }
14+
15+ export interface Agreement {
16+ paymentTitle : string ;
17+ paymentContent : string ;
18+ privacyTitle : string ;
19+ privacyContent : string ;
20+ serviceTitle : string ;
21+ serviceContent : string ;
22+ updateAt : string ;
1123}
1224
1325/** 协议项接口 */
You can’t perform that action at this time.
0 commit comments