mirror of
https://github.com/henrygd/beszel.git
synced 2025-12-17 10:46:16 +01:00
pocketbase js updates
This commit is contained in:
@@ -56,7 +56,7 @@ export function AddSystemButton({ className }: { className?: string }) {
|
||||
e.preventDefault()
|
||||
const formData = new FormData(e.target as HTMLFormElement)
|
||||
const data = Object.fromEntries(formData) as Record<string, any>
|
||||
data.users = pb.authStore.model!.id
|
||||
data.users = pb.authStore.record!.id
|
||||
try {
|
||||
setOpen(false)
|
||||
await pb.collection("systems").create(data)
|
||||
|
||||
@@ -58,7 +58,7 @@ export default function Navbar() {
|
||||
</button>
|
||||
</DropdownMenuTrigger>
|
||||
<DropdownMenuContent align={isReadOnlyUser() ? "end" : "center"} className="min-w-44">
|
||||
<DropdownMenuLabel>{pb.authStore.model?.email}</DropdownMenuLabel>
|
||||
<DropdownMenuLabel>{pb.authStore.record?.email}</DropdownMenuLabel>
|
||||
<DropdownMenuSeparator />
|
||||
<DropdownMenuGroup>
|
||||
{isAdmin() && (
|
||||
|
||||
Reference in New Issue
Block a user