mirror of
https://github.com/d0zingcat/alert-message-center.git
synced 2026-05-29 15:10:10 +00:00
fix(topic): correct 'make global' API call and improve UI
- Change 'make global' API method from POST to PUT in AdminView.tsx - Refine backend update logic for 'isGlobal' to correctly handle boolean values - Improve 'make global' and 'private' UI with icons and better styling in AdminView.tsx and TopicsView.tsx
This commit is contained in:
@@ -180,7 +180,7 @@ api.put(
|
||||
.update(topics)
|
||||
.set({
|
||||
...body,
|
||||
isGlobal: body.isGlobal ?? (undefined as any),
|
||||
isGlobal: body.isGlobal !== undefined ? body.isGlobal : undefined,
|
||||
})
|
||||
.where(eq(topics.id, id))
|
||||
.returning();
|
||||
|
||||
Reference in New Issue
Block a user