mirror of
https://github.com/miawinter98/just-short-it.git
synced 2024-11-25 01:19:53 +00:00
fixed: inspect not properly displaying deletion
This commit is contained in:
parent
61fba41cd6
commit
2f6f77baf6
|
@ -11,13 +11,13 @@
|
||||||
<div class="grid place-items-center h-full">
|
<div class="grid place-items-center h-full">
|
||||||
<section class="w-full md:max-w-lg flex flex-col gap-4">
|
<section class="w-full md:max-w-lg flex flex-col gap-4">
|
||||||
@if (Model is null) {
|
@if (Model is null) {
|
||||||
|
<MessageComponent Message="@Message" Type="Type" />
|
||||||
<h1 class="text-3xl lg:text-5xl text-error text-center mb-6">
|
<h1 class="text-3xl lg:text-5xl text-error text-center mb-6">
|
||||||
URL not found
|
URL not found
|
||||||
</h1>
|
</h1>
|
||||||
<h2 class="text-2xl lg:text-4xl text-secondary-content text-center mb-3">
|
<h2 class="text-2xl lg:text-4xl text-secondary-content text-center mb-3">
|
||||||
The given ID does not exist, it may have expired or been deleted.
|
The given ID does not exist, it may have expired or been deleted.
|
||||||
</h2>
|
</h2>
|
||||||
<MessageComponent Message="@Message" Type="Type" />
|
|
||||||
} else {
|
} else {
|
||||||
<h1 class="text-3xl lg:text-5xl text-primary-content text-center mb-6">Inspect</h1>
|
<h1 class="text-3xl lg:text-5xl text-primary-content text-center mb-6">Inspect</h1>
|
||||||
|
|
||||||
|
@ -68,10 +68,12 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
await Db.RemoveAsync(Id);
|
await Db.RemoveAsync(Id);
|
||||||
|
|
||||||
Type = MessageComponent.AlertType.Success;
|
Type = MessageComponent.AlertType.Success;
|
||||||
Message = $"Id '{Id}' successfully deleted.";
|
Message = $"Id '{Id}' successfully deleted.";
|
||||||
return;
|
|
||||||
|
Id = null;
|
||||||
|
Model = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue