Skip to content

Commit 451b690

Browse files
fix: Fix issue with certificate application failure (#8048)
1 parent a2716ef commit 451b690

File tree

168 files changed

+196
-179
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

168 files changed

+196
-179
lines changed

agent/app/service/website_ssl.go

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -448,15 +448,19 @@ func (w WebsiteSSLService) Delete(ids []uint) error {
448448
if err != nil {
449449
return err
450450
}
451-
acmeAccount, err := websiteAcmeRepo.GetFirst(repo.WithByID(websiteSSL.AcmeAccountID))
452-
if err != nil {
453-
return err
454-
}
455-
client, err := ssl.NewAcmeClient(acmeAccount)
456-
if err != nil {
457-
return err
451+
if websiteSSL.Type != constant.Manual && websiteSSL.Type != constant.SelfSigned {
452+
acmeAccount, err := websiteAcmeRepo.GetFirst(repo.WithByID(websiteSSL.AcmeAccountID))
453+
if err != nil {
454+
return err
455+
}
456+
client, err := ssl.NewAcmeClient(acmeAccount)
457+
if err != nil {
458+
return err
459+
}
460+
go func() {
461+
_ = client.RevokeSSL([]byte(websiteSSL.Pem))
462+
}()
458463
}
459-
_ = client.RevokeSSL([]byte(websiteSSL.Pem))
460464
_ = websiteSSLRepo.DeleteBy(repo.WithByID(id))
461465
}
462466
if len(names) > 0 {

frontend/src/components/backup/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
v-model="backupVisible"
44
:header="$t('commons.button.backup')"
55
:resource="detailName ? name + ' [' + detailName + ']' : name"
6-
:back="handleClose"
6+
@close="handleClose"
77
size="large"
88
>
99
<template #content>

frontend/src/components/compose-log/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<DrawerPro
33
v-model="open"
44
:header="resource"
5-
:back="handleClose"
5+
@close="handleClose"
66
:size="globalStore.isFullScreen ? 'full' : 'large'"
77
:resource="resource"
88
>

frontend/src/components/drawer-pro/index.vue

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<template>
22
<el-drawer
33
v-model="localOpenPage"
4-
@close="closePage"
4+
@close="handleClose"
55
:destroy-on-close="true"
66
:size="size"
77
:close-on-press-escape="true"
@@ -73,8 +73,7 @@ const props = defineProps({
7373
});
7474
7575
const slots = useSlots();
76-
77-
const emit = defineEmits(['update:modelValue']);
76+
const emit = defineEmits(['update:modelValue', 'close']);
7877
7978
const size = computed(() => {
8079
switch (props.size) {
@@ -106,13 +105,14 @@ const handleBack = () => {
106105
if (props.back) {
107106
props.back();
108107
} else {
109-
closePage();
108+
handleClose();
110109
}
111110
};
112111
113-
const closePage = () => {
112+
const handleClose = () => {
114113
localOpenPage.value = false;
115114
globalStore.isFullScreen = false;
115+
emit('close');
116116
};
117117
118118
function toggleFullscreen() {

frontend/src/components/group/change.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<template>
22
<div v-loading="loading">
3-
<DrawerPro v-model="drawerVisible" :header="$t('terminal.groupChange')" :back="handleClose" size="small">
3+
<DrawerPro v-model="drawerVisible" :header="$t('terminal.groupChange')" @close="handleClose" size="small">
44
<el-form @submit.prevent ref="hostInfoRef" label-position="top" :model="dialogData" :rules="rules">
55
<el-form-item :label="$t('commons.table.group')" prop="group">
66
<el-select filterable v-model="dialogData.groupID" clearable style="width: 100%">

frontend/src/components/group/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<DrawerPro v-model="open" :header="$t('commons.table.group')" @close="handleClose" size="large" :back="handleClose">
2+
<DrawerPro v-model="open" :header="$t('commons.table.group')" @close="handleClose" size="large">
33
<template #content>
44
<ComplexTable :data="data" @search="search()">
55
<template #toolbar>

frontend/src/components/log-dialog/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<DrawerPro v-model="open" :header="$t('commons.button.log')" size="large" :back="handleClose">
2+
<DrawerPro v-model="open" :header="$t('commons.button.log')" size="large" @close="handleClose">
33
<LogFile :config="config" :height-diff="config.heightDiff"></LogFile>
44
</DrawerPro>
55
</template>

frontend/src/components/system-upgrade/upgrade/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<DrawerPro
33
v-model="drawerVisible"
44
:header="$t('commons.button.upgrade')"
5-
:back="handleClose"
5+
@close="handleClose"
66
size="large"
77
:key="refresh"
88
>

frontend/src/components/upload/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
v-model="uploadOpen"
55
:header="$t('commons.button.import')"
66
:resource="title"
7-
:back="handleUploadClose"
7+
@close="handleUploadClose"
88
size="large"
99
>
1010
<template #content>

frontend/src/views/ai/model/add/index.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<DrawerPro v-model="drawerVisible" :header="$t('aiTools.model.create')" :back="handleClose">
2+
<DrawerPro v-model="drawerVisible" :header="$t('aiTools.model.create')" @close="handleClose">
33
<el-row type="flex" justify="center">
44
<el-col :span="22">
55
<el-alert type="info" :closable="false">

0 commit comments

Comments
 (0)