fix: 5 bugs - tab height, collect pay modal, invoice picker in record payment, comment body field, dashboard tickets label

This commit is contained in:
Nemo
2026-03-24 11:44:14 +08:00
parent defacbcc77
commit f8c5402b02
5 changed files with 211 additions and 41 deletions

View File

@@ -69,7 +69,7 @@ export default function TicketDetailScreen() {
// Log status change as a system comment
const who = user?.firstName ?? 'Staff';
await api.post(`/api/v1/tickets/${id}/messages`, {
message: `Status changed to ${status.replace('_', ' ')} by ${who}`,
body: `Status changed to ${status.replace('_', ' ')} by ${who}`,
}).catch(() => {});
},
onSuccess: () => {
@@ -123,7 +123,7 @@ export default function TicketDetailScreen() {
const note = instNotes.trim()
? `Installation confirmed. Location recorded: ${coordStr}. Notes: ${instNotes.trim()}`
: `Installation confirmed. Location recorded: ${coordStr}`;
await api.post(`/api/v1/tickets/${id}/messages`, { message: note }).catch(() => {});
await api.post(`/api/v1/tickets/${id}/messages`, { body: note }).catch(() => {});
setInstNotes('');
setCoords(null);
@@ -145,7 +145,7 @@ export default function TicketDetailScreen() {
const text = comment.trim();
setComment(''); // clear immediately for responsiveness
try {
await api.post(`/api/v1/tickets/${id}/messages`, { message: text });
await api.post(`/api/v1/tickets/${id}/messages`, { body: text });
refetch();
setTimeout(() => scrollRef.current?.scrollToEnd({ animated: true }), 300);
} catch {