don't show delete button on primary names
This commit is contained in:
@@ -53,7 +53,7 @@ pub async fn page(Path(id): Path<Uuid>, req: Request) -> Result<Response, AuthEr
|
||||
@if name.is_primary {
|
||||
span class="text-xs text-neutral-500" {"(primary)"}
|
||||
}
|
||||
@if let Ok(0) = name.times_attributed(&conn) {
|
||||
@if let Ok(0) = name.times_attributed(&conn) && !name.is_primary {
|
||||
form action=(format!("/names/{}/delete", name.id)) method="post" class="flex items-center ml-1" {
|
||||
button type="submit" class="text-neutral-500 hover:text-red-400 flex items-center justify-center cursor-pointer" title="Delete" {
|
||||
"✕"
|
||||
|
||||
Reference in New Issue
Block a user