auto-sync: 2026-05-18 12:55:38
This commit is contained in:
@@ -582,6 +582,16 @@ export const useStore = create<AppStore>((set, get) => ({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
loadMails: async () => {
|
||||||
|
try {
|
||||||
|
const res = await fetch('/api/mail');
|
||||||
|
if (res.ok) {
|
||||||
|
const data = await res.json();
|
||||||
|
set({ mails: data.mails || [], mailUnread: (data.mails || []).filter((m: any) => !m.is_read).length });
|
||||||
|
}
|
||||||
|
} catch { /* silently fail */ }
|
||||||
|
},
|
||||||
|
|
||||||
loadOfficials: async () => {
|
loadOfficials: async () => {
|
||||||
try {
|
try {
|
||||||
const data = await api.officialsStats();
|
const data = await api.officialsStats();
|
||||||
|
|||||||
Reference in New Issue
Block a user