| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950 |
- <template>
- <a-modal
- width="420px"
- :visible="showModal"
- @ok="handleOk"
- @cancel="handleCancel"
- :okText="$t('login.okBtn')"
- :cancelText="$t('login.cancelBtn')"
- unmountOnClose
- >
- <template #title><icon-exclamation-circle-fill class="tips-icon" /> {{ $t('login.tip') }} </template>
- <div>{{ $t('login.okText') }}</div>
- </a-modal>
- </template>
- <script setup>
- import { computed } from 'vue';
- // import { useRouter } from 'vue-router';
- // import { kuky_Authorization } from '../../../base/storage';
- // import { resetHasRouteFlag } from '../../../router';
- import useLogout from '../../account/use-logout';
- const props = defineProps({
- visible: {
- type: Boolean,
- default: false
- }
- });
- const emit = defineEmits(['update:visible']);
- // const router = useRouter();
- const showModal = computed(() => props.visible);
- const logout = useLogout();
- const handleOk = () => {
- logout();
- emit('update:visible', false);
- };
- const handleCancel = () => {
- emit('update:visible', false);
- };
- </script>
- <style scoped lang="css">
- .tips-icon {
- font-size: 20px;
- color: rgb(var(--orange-6));
- }
- </style>
|