This commit is contained in:
bipproduction
2025-11-24 10:32:38 +08:00
parent fdd0388168
commit 0a8969280e

View File

@@ -39,7 +39,7 @@ function CreateApiKey() {
try {
setLoading(true);
if (!name || !description || !expiredAt) {
if (!name || !description ) {
showNotification({
title: "Error",
message: "All fields are required",
@@ -48,10 +48,11 @@ function CreateApiKey() {
return;
}
const res = await apiFetch.api.apikey.create.post({
name,
description,
expiredAt,
expiredAt: expiredAt ? new Date(expiredAt).toISOString() : new Date().toISOString(),
});
if (res.status === 200) {