1
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<script setup lang="ts">
|
||||
import { NSpin, NFlex, NCard, NButton, NIcon, useNotification, NModalProvider } from 'naive-ui'
|
||||
import { PlusSquare } from "@vicons/fa"
|
||||
import { onMounted } from 'vue'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import { type Domain, useDomainStore } from '@/stores/domains'
|
||||
import { getErrorInfo } from '@/apis/api'
|
||||
import DomainInfo from '@/components/domains/DomainInfo.vue'
|
||||
@@ -12,10 +12,10 @@ import DomainEditModal from '@/components/domains/DomainEditModal.vue'
|
||||
const domainStore = useDomainStore()
|
||||
const notification = useNotification()
|
||||
|
||||
const loading = defineModel<boolean>('loading', { default: true });
|
||||
const removeModalShow = defineModel<boolean>('removeModalShow', { default: false })
|
||||
const editModalShow = defineModel<boolean>('editModalShow', { default: false })
|
||||
const operationDomain = defineModel<Domain>('operationDomain', { default: {} as Domain })
|
||||
const loading = ref(true);
|
||||
const removeModalShow = ref(false);
|
||||
const editModalShow = ref(false);
|
||||
const operationDomain = ref({} as Domain)
|
||||
|
||||
onMounted(() => {
|
||||
try {
|
||||
@@ -38,7 +38,13 @@ function showEditModal(domain: Domain) {
|
||||
}
|
||||
|
||||
function addDomain() {
|
||||
const domain = {} as Domain
|
||||
const domain = {
|
||||
refresh_interval: 86400,
|
||||
retry_interval: 7200,
|
||||
expiry_period: 3600000,
|
||||
negative_ttl: 86400,
|
||||
serial_number: 1,
|
||||
} as Domain
|
||||
showEditModal(domain)
|
||||
}
|
||||
</script>
|
||||
|
@@ -1,7 +1,7 @@
|
||||
<script setup lang="tsx">
|
||||
import {
|
||||
NSpin, NPageHeader, useNotification,
|
||||
NFlex, NButton, NIcon, NGrid, NGi,
|
||||
NFlex, NButton, NIcon, NGrid, NGi,
|
||||
NStatistic, NDataTable, NInput,
|
||||
NModalProvider
|
||||
} from 'naive-ui'
|
||||
@@ -18,12 +18,8 @@ const { t } = useI18n()
|
||||
const props = defineProps<{
|
||||
domain: string
|
||||
}>()
|
||||
const loading = defineModel<boolean>('loading', { default: true });
|
||||
const records = defineModel<Record[]>('records');
|
||||
const soa = defineModel<SOARecord | undefined>('soa')
|
||||
const columns = defineModel<DataTableColumns<Record>>('columns')
|
||||
|
||||
columns.value = [
|
||||
const columns = [
|
||||
{
|
||||
key: 'no',
|
||||
title: '#',
|
||||
@@ -56,10 +52,14 @@ columns.value = [
|
||||
return <RecordOps record={row} />
|
||||
}
|
||||
}
|
||||
]
|
||||
] as DataTableColumns<Record>
|
||||
|
||||
const recordStore = useRecordStore()
|
||||
const notification = useNotification()
|
||||
|
||||
const records = ref<Record[] | undefined>([]);
|
||||
const soa = ref<SOARecord>({} as SOARecord)
|
||||
const loading = ref(true);
|
||||
onMounted(() => {
|
||||
try {
|
||||
refreshRecords()
|
||||
|
Reference in New Issue
Block a user