This commit is contained in:
@@ -127,6 +127,7 @@
|
||||
|
||||
// 加载套餐流量数据
|
||||
const loadPackageData = async () => {
|
||||
if (userStore.state.loginPending || !userStore.state.token) return;
|
||||
const identifier = props.identifier || userStore.state.identifier;
|
||||
if (!identifier) return;
|
||||
|
||||
@@ -151,8 +152,8 @@
|
||||
};
|
||||
|
||||
// 监听 identifier 变化
|
||||
watch(() => props.identifier || userStore.state.identifier, (newVal) => {
|
||||
if (newVal) {
|
||||
watch(() => [props.identifier || userStore.state.identifier, userStore.state.token, userStore.state.loginPending], ([newVal, token, loginPending]) => {
|
||||
if (newVal && token && !loginPending) {
|
||||
loadPackageData();
|
||||
}
|
||||
}, {
|
||||
|
||||
Reference in New Issue
Block a user