diff --git a/frontend/src/views/website/website/domain/index.vue b/frontend/src/views/website/website/domain/index.vue new file mode 100644 index 000000000..345439ac2 --- /dev/null +++ b/frontend/src/views/website/website/domain/index.vue @@ -0,0 +1,130 @@ + + + + + diff --git a/frontend/src/views/website/website/index.vue b/frontend/src/views/website/website/index.vue index d757df8a2..655f5b399 100644 --- a/frontend/src/views/website/website/index.vue +++ b/frontend/src/views/website/website/index.vue @@ -89,71 +89,12 @@ show-overflow-tooltip > ([]); const dataRef = ref(); -const domains = ref([]); const columns = ref([]); const hoveredRowIndex = ref(-1); const websiteDir = ref(); @@ -431,6 +372,11 @@ const favoriteWebsite = (row: Website.Website) => { updateWebsitConfig(row); }; +const handleDomainEdit = (row: Website.Website, domain: string) => { + row.primaryDomain = domain; + updateWebsitConfig(row); +}; + const disabledConfig = computed(() => { return nginxStatus.value != 'Running'; }); @@ -647,28 +593,6 @@ const operateWebsite = (op: string, id: number) => { }); }; -const searchDomains = (id: number) => { - listDomains(id).then((res) => { - domains.value = res.data; - }); -}; - -const openUrl = (url: string) => { - window.open(url); -}; - -const getUrl = (domain: Website.Domain, website: Website.Website): string => { - const protocol = website.protocol.toLowerCase(); - let url = protocol + '://' + domain.domain; - if (protocol == 'http' && domain.port != 80) { - url = url + ':' + domain.port; - } - if (protocol == 'https' && domain.ssl) { - url = url + ':' + domain.port; - } - return url; -}; - const updateRemark = (row: Website.Website, bulr: Function) => { bulr(); if (row.remark && row.remark.length > 128) { @@ -702,12 +626,3 @@ onMounted(() => { listGroup(); }); - -