diff --git a/src/app/components/shared/comment-list/comment-list.component.ts b/src/app/components/shared/comment-list/comment-list.component.ts index 1e96bd17925ddacdebbdb06b40284654b465134b..3679ef7e62e2508ebe3cd9660604c2ed4970b224 100644 --- a/src/app/components/shared/comment-list/comment-list.component.ts +++ b/src/app/components/shared/comment-list/comment-list.component.ts @@ -29,6 +29,7 @@ export enum Period { THREEHOURS = 'time-3h', ONEDAY = 'time-1d', ONEWEEK = 'time-1w', + TWOWEEKS = 'time-2w', ALL = 'time-all' } @@ -487,6 +488,10 @@ export class CommentListComponent implements OnInit, OnDestroy { break; case Period.ONEWEEK: periodInSeconds = hourInSeconds * 168; + break; + case Period.TWOWEEKS: + periodInSeconds = hourInSeconds * 336; + break; } this.commentsFilteredByTime = this.comments .filter(c => new Date(c.timestamp).getTime() >= (currentTime.getTime() - periodInSeconds)); diff --git a/src/app/components/shared/questionwall/question-wall/question-wall.component.ts b/src/app/components/shared/questionwall/question-wall/question-wall.component.ts index d330f6a442ad207b242bac790d1dce62e2d12a68..2b3c480ebd30729e29a1d632ea9a3b30276d5e5a 100644 --- a/src/app/components/shared/questionwall/question-wall/question-wall.component.ts +++ b/src/app/components/shared/questionwall/question-wall/question-wall.component.ts @@ -344,6 +344,10 @@ export class QuestionWallComponent implements OnInit, AfterViewInit, OnDestroy { break; case Period.ONEWEEK: periodInSeconds = hourInSeconds * 168; + break; + case Period.TWOWEEKS: + periodInSeconds = hourInSeconds * 336; + break; } this.commentsFilteredByTime = this.comments .filter(c => new Date(c.date).getTime() >= (currentTime.getTime() - periodInSeconds)); diff --git a/src/assets/i18n/creator/de.json b/src/assets/i18n/creator/de.json index 83dc24425636417f3e2637d9b7da93ba5add4fe0..fb3db316cae05c2355c5bccf9e8b1c737fc198c4 100644 --- a/src/assets/i18n/creator/de.json +++ b/src/assets/i18n/creator/de.json @@ -20,6 +20,7 @@ "a11y-select-time-3h": "Zeige alle Kommentare der letzten 3 Stunden an", "a11y-select-time-1d": "Zeige alle Kommentare der letzten 24 Stunden an", "a11y-select-time-1w": "Zeige alle kommentare der letzten 7 Tage an", + "a11y-select-time-2w": "Zeige alle kommentare der letzten 14 Tage an", "a11y-select-time-all": "Zeige alle Kommentare an", "add-comment": "Frage oder Mitteilung ans Publikum schreiben …", "answered": "Beantwortete Fragen", @@ -59,6 +60,7 @@ "select-time-3h": "Letzte 2 Stunden", "select-time-1d": "Letzte 24 Stunden", "select-time-1w": "Letzte 7 Tage", + "select-time-2w": "Letzte 14 Tage", "select-time-all": "Unbegrenzt" }, "comment-page": { diff --git a/src/assets/i18n/creator/en.json b/src/assets/i18n/creator/en.json index a3c038b0469896c71ba61acde87459b04685b7df..bccb3f8163df3f1f280e232c75d4617a9aff99e0 100644 --- a/src/assets/i18n/creator/en.json +++ b/src/assets/i18n/creator/en.json @@ -19,7 +19,8 @@ "a11y-select-time-1h": "Show all comments of the last hour", "a11y-select-time-3h": "Show all comments of the last 3 hours", "a11y-select-time-1d": "Show all comments of the last day", - "a11y-select-time-1w": "Show all comments of the last week", + "a11y-select-time-1w": "Show all comments of the last 7 days", + "a11y-select-time-2w": "Show all comments of the last 14 days", "a11y-select-time-all": "Show all comments", "answered": "Answered questions", "add-comment": "Ask a question or write a message to the audience.", @@ -60,6 +61,7 @@ "select-time-3h": "Last 2 hours", "select-time-1d": "Last 24 hours", "select-time-1w": "Last 7 days", + "select-time-2w": "Last 14 days", "select-time-all": "Unlimited" }, "comment-page": { diff --git a/src/assets/i18n/participant/de.json b/src/assets/i18n/participant/de.json index 688a49c4d2d08180faa7ae30614fd51e2be2ba99..e145c77bf40343a714ea8bc6543d6abce3d3a035 100644 --- a/src/assets/i18n/participant/de.json +++ b/src/assets/i18n/participant/de.json @@ -20,6 +20,7 @@ "a11y-select-time-3h": "Zeige alle Kommentare der letzten 3 Stunden an", "a11y-select-time-1d": "Zeige alle Kommentare der letzten 24 Stunden an", "a11y-select-time-1w": "Zeige alle kommentare der letzten 7 Tage an", + "a11y-select-time-2w": "Zeige alle kommentare der letzten 14 Tage an", "a11y-select-time-all": "Zeige alle Kommentare an", "answered": "Beantwortete Fragen", "add-comment": "Stell deine Frage!", @@ -60,6 +61,7 @@ "select-time-3h": "Letzte 2 Stunden", "select-time-1d": "Letzte 24 Stunden", "select-time-1w": "Letzte 7 Tage", + "select-time-2w": "Letzte 14 Tage", "select-time-all": "Unbegrenzt" }, "content": { diff --git a/src/assets/i18n/participant/en.json b/src/assets/i18n/participant/en.json index 405ef0b006f605791ac782f18e24c8d5364fb0ed..da22d3b836e0a04e383c17909d85c36855152273 100644 --- a/src/assets/i18n/participant/en.json +++ b/src/assets/i18n/participant/en.json @@ -29,7 +29,8 @@ "a11y-select-time-1h": "Show all comments of the last hour", "a11y-select-time-3h": "Show all comments of the last 3 hours", "a11y-select-time-1d": "Show all comments of the last day", - "a11y-select-time-1w": "Show all comments of the last week", + "a11y-select-time-1w": "Show all comments of the last 7 days", + "a11y-select-time-2w": "Show all comments of the last 14 days", "a11y-select-time-all": "Show all comments", "answered": "Answered questions", "add-comment": "Ask a question!", @@ -70,6 +71,7 @@ "select-time-3h": "Last 2 hours", "select-time-1d": "Last 24 hours", "select-time-1w": "Last 7 days", + "select-time-2w": "Last 14 days", "select-time-all": "Unlimited" }, "content": {