fix: auth race condition on refresh, section edit dialog, time slot duplicate, autocomplete disable
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { defineStore } from 'pinia'
|
||||
import { ref } from 'vue'
|
||||
import { computed, ref } from 'vue'
|
||||
|
||||
const ACTIVE_ORG_KEY = 'crewli_active_org'
|
||||
const ACTIVE_EVENT_KEY = 'crewli_active_event'
|
||||
@@ -7,6 +7,7 @@ const ACTIVE_EVENT_KEY = 'crewli_active_event'
|
||||
export const useOrganisationStore = defineStore('organisation', () => {
|
||||
const activeOrganisationId = ref<string | null>(localStorage.getItem(ACTIVE_ORG_KEY))
|
||||
const activeEventId = ref<string | null>(localStorage.getItem(ACTIVE_EVENT_KEY))
|
||||
const hasOrganisation = computed(() => !!activeOrganisationId.value)
|
||||
|
||||
function setActiveOrganisation(id: string) {
|
||||
activeOrganisationId.value = id
|
||||
@@ -28,6 +29,7 @@ export const useOrganisationStore = defineStore('organisation', () => {
|
||||
return {
|
||||
activeOrganisationId,
|
||||
activeEventId,
|
||||
hasOrganisation,
|
||||
setActiveOrganisation,
|
||||
setActiveEvent,
|
||||
clear,
|
||||
|
||||
Reference in New Issue
Block a user