fix: skip API calls on customers page when user is guest/unauthenticated

This commit is contained in:
TradeMate Dev
2026-05-14 10:40:16 +08:00
parent aacb53f111
commit 3b181eeae3
@@ -300,6 +300,9 @@ const formData = ref({
const statusOptions = ['lead', 'negotiating', 'customer', 'lost']
onShow(() => {
const token = uni.getStorageSync('token')
const isGuest = uni.getStorageSync('isGuest')
if (!token || isGuest) return
loadCustomers()
loadHealthOverview()
})