Fix navigation using back/close/cancel buttons

This commit is contained in:
Bubka
2023-11-03 14:47:56 +01:00
parent 929a513ad7
commit a8540b0c04
12 changed files with 47 additions and 35 deletions

View File

@ -4,20 +4,18 @@
import { UseColorMode } from '@vueuse/components'
const $2fauth = inject('2fauth')
const router = useRouter()
const notify = useNotifyStore()
const returnTo = useStorage($2fauth.prefix + 'returnTo', 'accounts')
const { copy } = useClipboard({ legacy: true })
const returnTo = router.options.history.state.back
const infos = ref()
const listInfos = ref(null)
const userPreferences = ref(false)
const listUserPreferences = ref(null)
const adminSettings = ref(false)
const listAdminSettings = ref(null)
const { copy } = useClipboard({ legacy: true })
onMounted(() => {
systemService.getSystemInfos().then(response => {
infos.value = response.data.common
@ -128,7 +126,7 @@
</div>
<!-- footer -->
<VueFooter :showButtons="true">
<ButtonBackCloseCancel action="back" />
<ButtonBackCloseCancel :returnTo="{ path: returnTo }" action="back" />
</VueFooter>
</ResponsiveWidthWrapper>
</template>