init
This commit is contained in:
64 files changed
+17178
No files matched your search
@@ -0,0 +1,25 @@
|
||||
import NovaTenancy from './pages/NovaTenancy.vue'
|
||||
import TenantAppLogo from './components/TenantAppLogo.vue'
|
||||
|
||||
Nova.inertia('NovaTenancy', NovaTenancy)
|
||||
|
||||
Nova.booting(app => {
|
||||
if (Nova.config('novaTenancy')?.branding?.enabled !== false) {
|
||||
app.component('AppLogo', TenantAppLogo)
|
||||
}
|
||||
})
|
||||
|
||||
Nova.request().interceptors.response.use(
|
||||
response => response,
|
||||
error => {
|
||||
if (
|
||||
error.response?.status === 409 &&
|
||||
error.response?.data?.code === 'tenant_selection_required'
|
||||
) {
|
||||
const selectorPath = Nova.config('novaTenancy')?.selectorPath || '/nova-tenancy'
|
||||
Nova.visit(selectorPath)
|
||||
}
|
||||
|
||||
return Promise.reject(error)
|
||||
}
|
||||
)
|
||||
Reference in new issue
Block a user