diff --git a/api/certificate/certificate.go b/api/certificate/certificate.go index 3a10cf2f..094ada4e 100644 --- a/api/certificate/certificate.go +++ b/api/certificate/certificate.go @@ -133,7 +133,7 @@ func AddCert(c *gin.Context) { err = cert.SyncToRemoteServer(certModel) if err != nil { - notification.Error("Sync Certificate Error", err.Error()) + notification.Error("Sync Certificate Error", err.Error(), nil) return } @@ -188,7 +188,7 @@ func ModifyCert(c *gin.Context) { err = cert.SyncToRemoteServer(certModel) if err != nil { - notification.Error("Sync Certificate Error", err.Error()) + notification.Error("Sync Certificate Error", err.Error(), nil) return } diff --git a/api/certificate/notifications.ts b/api/certificate/notifications.ts new file mode 100644 index 00000000..2121916b --- /dev/null +++ b/api/certificate/notifications.ts @@ -0,0 +1,8 @@ +// Auto-generated notification messages +// Do not edit manually + +const notifications: Record = { + "Sync_Certificate_Error_Error": "err.Error()", +}; + +export default notifications; diff --git a/app/src/components/Notification/Notification.vue b/app/src/components/Notification/Notification.vue index b95be9c8..20a9c18c 100644 --- a/app/src/components/Notification/Notification.vue +++ b/app/src/components/Notification/Notification.vue @@ -12,6 +12,7 @@ import { message, notification } from 'ant-design-vue' import dayjs from 'dayjs' import relativeTime from 'dayjs/plugin/relativeTime' import { SSE } from 'sse.js' +import notifications from './notifications' defineProps<{ headerRef: HTMLElement @@ -181,7 +182,7 @@ function viewAll() {