Commit 15fec4f5 authored by Juan Manuel Solaro's avatar Juan Manuel Solaro

(fix) show scheduled banner to just posted activities

1 merge request!494WIP: epic/post-scheduler
Pipeline #80012520 passed with stages
in 56 minutes and 46 seconds
......@@ -516,3 +516,11 @@
>
This post is awaiting moderation.
</div>
<!-- Pending block -->
<div
class="mdl-card__supporting-text m-activity--pending"
*ngIf="isScheduled(activity.time_created)"
>
This is a scheduled post.
</div>
......@@ -485,6 +485,10 @@ export class Activity implements OnInit {
return activity && activity.pending && activity.pending !== '0';
}
isScheduled(time_created) {
return time_created && time_created * 1000 > Date.now();
}
toggleMatureVisibility() {
this.activity.mature_visibility = !this.activity.mature_visibility;
......
......@@ -76,6 +76,10 @@ export class ActivityPreview {
return false;
}
isScheduled(time_created) {
return false;
}
save() {
/* NOOP */
}
......
......@@ -138,6 +138,10 @@ export class Remind {
return activity && activity.pending && activity.pending !== '0';
}
isScheduled(time_created) {
return false;
}
openComments() {
/* NOOP */
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment