Skip to content

Commit

Permalink
Add more useful info to sync report
Browse files Browse the repository at this point in the history
  • Loading branch information
wpf500 committed Aug 1, 2024
1 parent 69408d1 commit b890a3e
Showing 1 changed file with 19 additions and 13 deletions.
32 changes: 19 additions & 13 deletions apps/backend/src/apps/settings/apps/newsletters/views/report.pug
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@

extends /views/base.pug

mixin diff(a, b)
span
if a !== b
| #{a}#{b}
else
| -

block contents
.row
.col-md-12
Expand All @@ -17,7 +24,12 @@ block contents
tbody
each contact in newContactsToUpload
tr
td: a(href='/members/' + contact.id)= contact.fullname
td
a(href='/members/' + contact.id)= contact.fullname || contact.email
if contact.membership.isActive
|
|
span.label.label-success Member
td= contact.email

h4 Contacts to import
Expand All @@ -44,15 +56,9 @@ block contents
each m in mismatchedContacts
tr
td: a(href='/members/' + m.contact.id)= m.contact.fullname
td
= m.contact.profile.newsletterStatus
| <>
= m.status
td
= m.contact.profile.newsletterGroups
| <>
= m.groups
td
= m.contact.membership && m.contact.membership.isActive ? 'Yes' : 'No'
| <>
= m.tags.includes(Options('newsletter-active-member-tag')) ? 'Yes' : 'No'
td: +diff(m.contact.profile.newsletterStatus, m.status)
td: +diff(m.contact.profile.newsletterGroups.toString(), m.groups.toString())
td: +diff(
m.contact.membership && m.contact.membership.isActive ? 'Yes' : 'No',
m.tags.includes(Options('newsletter-active-member-tag')) ? 'Yes' : 'No'
)

0 comments on commit b890a3e

Please sign in to comment.