Commit 80d50bf2 authored by Sébastiaan Versteeg's avatar Sébastiaan Versteeg Committed by Thom Wiggers
Browse files

Switch calendar listview to 1 week and add 'empty' state message

parent 64690e47
......@@ -7,8 +7,8 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-10-01 10:31+0200\n"
"PO-Revision-Date: 2018-10-01 10:32+0200\n"
"POT-Creation-Date: 2018-10-18 14:35+0200\n"
"PO-Revision-Date: 2018-10-18 14:36+0200\n"
"Last-Translator: Sébastiaan Versteeg <se_bastiaan@outlook.com>\n"
"Language-Team: \n"
"Language: nl\n"
......@@ -16,7 +16,11 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 2.1.1\n"
"X-Generator: Poedit 2.2\n"
#: static/events/js/calendarlistview.js
msgid "No events planned in the selected period."
msgstr "Er zijn geen evenementen gepland in de geselecteerde periode."
#: static/events/js/calendarlistview.js
msgid "Go to event"
......
......@@ -10,6 +10,10 @@ ListView = View.extend({
return a.start < b.start ? -1 : a.start > b.start ? 1 : 0;
});
if (events.length === 0) {
this.el.html('<div class="alert alert-info">' + gettext('No events planned in the selected period.') +'</div>');
}
for (var i = 0; i < events.length; i++) {
var e = events[i];
if (e.is_birthday) {
......@@ -29,7 +33,7 @@ ListView = View.extend({
cardHead.append(eventIndicator);
cardHead.append("<div class=\"title\">" + e.title + " " +
"(<span class=\"date\">" + date + "</span>)</div>");
"(<span class=\"date\">" + date + "</span>)</div>");
var cardContent = $("<div>")
.addClass("collapse")
......
......@@ -102,7 +102,7 @@
views: {
list: {
buttonText: '{% trans "list" %}',
duration: {years: 1}
duration: {weeks: 1}
}
},
defaultDate:
......
Supports Markdown
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