mirror of
https://github.com/fantastic-admin/basic.git
synced 2026-10-07 14:57:52 +08:00
21 lines
291 B
Vue
Executable File
21 lines
291 B
Vue
Executable File
<script setup lang="ts">
|
|
defineOptions({
|
|
name: 'AuthAll',
|
|
})
|
|
|
|
const props = defineProps<{
|
|
value: string[]
|
|
}>()
|
|
|
|
function check() {
|
|
return useAuth().authAll(props.value)
|
|
}
|
|
</script>
|
|
|
|
<template>
|
|
<div>
|
|
<slot v-if="check()" />
|
|
<slot v-else name="no-auth" />
|
|
</div>
|
|
</template>
|