wx-starlock/pages/webview/webview.vue
范鹏 c9a7c24672 1. tabbar
2. 我的页面
3. 用户信息页面
4. 更新头像、更新昵称、更新邮箱、重置密码
2024-08-20 19:54:37 +08:00

37 lines
722 B
Vue

<template>
<view>
<web-view :src="url"></web-view>
</view>
</template>
<script>
import baseConfig from '@/config/env'
export default {
data() {
return {
url: ''
}
},
onLoad: function (options) {
console.log(baseConfig.webviewBaseUrl)
const officialAccounts = {
default: {
url: '/app/introduce',
name: '介绍'
},
userAgreement: {
url: '/app/userAgreement',
name: '用户协议'
}
}
const item = officialAccounts[options?.type] || officialAccounts['default']
this.url = baseConfig.webviewBaseUrl + item['url']
console.log(this.url)
uni.setNavigationBarTitle({
title: item['name']
})
}
}
</script>