From 1aca43d401a2911fedbcd31005b488f903475427 Mon Sep 17 00:00:00 2001 From: catalintomai <56169943+catalintomai@users.noreply.github.com> Date: Tue, 19 Nov 2019 00:56:52 -0800 Subject: [PATCH] MM 17466 : Add custom post types to compliance exports (#13149) Automatic Merge --- store/sqlstore/compliance_store.go | 3 ++- templates/globalrelay_compliance_export_message.html | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/store/sqlstore/compliance_store.go b/store/sqlstore/compliance_store.go index b41884d3a1..7f04e458b0 100644 --- a/store/sqlstore/compliance_store.go +++ b/store/sqlstore/compliance_store.go @@ -216,6 +216,7 @@ func (s SqlComplianceStore) MessageExport(after int64, limit int) ([]*model.Mess Posts.DeleteAt AS PostDeleteAt, Posts.Message AS PostMessage, Posts.Type AS PostType, + Posts.Props AS PostProps, Posts.OriginalId AS PostOriginalId, Posts.RootId AS PostRootId, Posts.Props AS PostProps, @@ -243,7 +244,7 @@ func (s SqlComplianceStore) MessageExport(after int64, limit int) ([]*model.Mess LEFT JOIN Bots ON Bots.UserId = Posts.UserId WHERE (Posts.CreateAt > :StartTime OR Posts.EditAt > :StartTime OR Posts.DeleteAt > :StartTime) AND - Posts.Type = '' + Posts.Type NOT LIKE 'system_%' ORDER BY PostUpdateAt LIMIT :Limit` diff --git a/templates/globalrelay_compliance_export_message.html b/templates/globalrelay_compliance_export_message.html index ff3bcd9fdf..27de9cf80d 100644 --- a/templates/globalrelay_compliance_export_message.html +++ b/templates/globalrelay_compliance_export_message.html @@ -2,6 +2,7 @@
  • {{.Props.SentTime}} @{{.Props.Username}} + {{.Props.PostUsername}} {{.Props.UserType}} ({{.Props.Email}}): {{.Props.Message}}