From ffe427564b4bc0e215c8c1e17624edf73a3bed30 Mon Sep 17 00:00:00 2001 From: Eli Ribble Date: Mon, 27 Apr 2026 16:23:31 +0000 Subject: [PATCH] Add email and phone display to communications workbench --- platform/types/contact.go | 10 ++++++++++ ts/components/PublicreportCard.vue | 6 ++++++ 2 files changed, 16 insertions(+) diff --git a/platform/types/contact.go b/platform/types/contact.go index c25c63af..c7b07bef 100644 --- a/platform/types/contact.go +++ b/platform/types/contact.go @@ -22,6 +22,16 @@ func (c Contact) MarshalJSON() ([]byte, error) { to_marshal["name"] = c.Name to_marshal["has_email"] = (c.Email != nil && *c.Email != "") to_marshal["has_phone"] = (c.Phone != nil && *c.Phone != "") + if c.Email != nil { + to_marshal["email"] = *c.Email + } else { + to_marshal["email"] = "" + } + if c.Phone != nil { + to_marshal["phone"] = *c.Phone + } else { + to_marshal["phone"] = "" + } //log.Debug().Msg("marshaling contact") return json.Marshal(to_marshal) } diff --git a/ts/components/PublicreportCard.vue b/ts/components/PublicreportCard.vue index 43bf2e10..e375e21e 100644 --- a/ts/components/PublicreportCard.vue +++ b/ts/components/PublicreportCard.vue @@ -58,12 +58,18 @@ class="form-label text-muted small mb-0" > + {{ + report.reporter.email + }}