summaryrefslogtreecommitdiffstats
path: root/model/compliance_post.go
diff options
context:
space:
mode:
author=Corey Hulen <corey@hulen.com>2016-03-14 16:07:58 -0700
committer=Corey Hulen <corey@hulen.com>2016-03-15 18:27:45 -0700
commit36b17bf99ddd35c0c223722f8b6f4f1c71b2235e (patch)
tree6bc07d42d19d1d7a5bef26864bb93a1bc91da5f1 /model/compliance_post.go
parentea3f25924ea64a2dd1e73624c0d30824e1efb240 (diff)
downloadchat-36b17bf99ddd35c0c223722f8b6f4f1c71b2235e.tar.gz
chat-36b17bf99ddd35c0c223722f8b6f4f1c71b2235e.tar.bz2
chat-36b17bf99ddd35c0c223722f8b6f4f1c71b2235e.zip
PLT-2115 Adding compliance
Diffstat (limited to 'model/compliance_post.go')
-rw-r--r--model/compliance_post.go18
1 files changed, 15 insertions, 3 deletions
diff --git a/model/compliance_post.go b/model/compliance_post.go
index 636be8f17..ce26a3660 100644
--- a/model/compliance_post.go
+++ b/model/compliance_post.go
@@ -65,6 +65,17 @@ func CompliancePostHeader() []string {
}
func (me *CompliancePost) Row() []string {
+
+ postDeleteAt := ""
+ if me.PostDeleteAt > 0 {
+ postDeleteAt = time.Unix(0, me.PostDeleteAt*int64(1000*1000)).Format(time.RFC3339)
+ }
+
+ postUpdateAt := ""
+ if me.PostUpdateAt != me.PostCreateAt {
+ postUpdateAt = time.Unix(0, me.PostUpdateAt*int64(1000*1000)).Format(time.RFC3339)
+ }
+
return []string{
me.TeamName,
me.TeamDisplayName,
@@ -77,9 +88,10 @@ func (me *CompliancePost) Row() []string {
me.UserNickname,
me.PostId,
- time.Unix(0, me.PostCreateAt*1000).Format(time.RFC3339),
- time.Unix(0, me.PostUpdateAt*1000).Format(time.RFC3339),
- time.Unix(0, me.PostDeleteAt*1000).Format(time.RFC3339),
+ time.Unix(0, me.PostCreateAt*int64(1000*1000)).Format(time.RFC3339),
+ postUpdateAt,
+ postDeleteAt,
+
me.PostRootId,
me.PostParentId,
me.PostOriginalId,