feat: auth user feedbacks

This commit is contained in:
Krispire Admin
2026-07-14 18:26:03 +05:30
parent 47b3a6d96e
commit 4553725d4e
5 changed files with 76 additions and 2 deletions
+6
View File
@@ -92,6 +92,12 @@ func (s *FeedbackService) Submit(ctx context.Context, userID *string, category,
return f, nil
}
// ListForUser returns the signed-in user's own submissions (newest
// first) with status and any admin reply, for the "My feedback" page.
func (s *FeedbackService) ListForUser(ctx context.Context, userID string, limit int) ([]model.Feedback, error) {
return s.repo.ListByUser(ctx, userID, limit)
}
// ErrAlreadyResolved is returned by Resolve when the row was already
// closed (or doesn't exist). The handler maps it to a benign redirect
// rather than an error — the end state the admin wanted is already true.