django-bootstrap-calendar icon indicating copy to clipboard operation
django-bootstrap-calendar copied to clipboard

Month/Year/Day Labels

Open fablet opened this issue 9 years ago • 4 comments

the current templates do not display the name of the month, year or day you are looking at, as appropriate to month, year or day views. I can see this displayed in demo's for the calendar this was originally based on, but cannot find the means to put this on anywhere in the code.

fablet avatar Jun 25 '15 16:06 fablet

@fablet did you manage to figure out how to solve this?

anderspetersson avatar Sep 20 '15 11:09 anderspetersson

Yes as a matter of fact I did. There is a function in the calendar.js file called getTitle. I created div on the calendar.html page and then set a document.getElementById equal to the getTitle and put it between the this._loadEvents(); and this.render(); calls that instantiate the calendar. You can tweak how the titles display between the getTitle function and the title strings below defaults at the top of the calendar

fablet avatar Sep 21 '15 03:09 fablet

@fablet can you explain a little better the changes that u did , please ? 'Cause my instance is having the same problem :(

daveseco7 avatar Nov 08 '15 04:11 daveseco7

document.getElementById("id of the div you create on calendar.html where you want titles to show up").innerHTML = this.getTitle();

fablet avatar Nov 20 '15 20:11 fablet