twinssbc / Ionic-Calendar

A calendar directive for Ionic framework
http://twinssbc.github.io/Ionic-Calendar/demo
MIT License
159 stars 73 forks source link

is it possible to show title inside cell bellow date? #133

Closed kunalailani closed 7 years ago

kunalailani commented 7 years ago

Hey, Thanks for this Awesome calendar ! I want to show the title for a specific dates inside cell (bellow date) that are passed in eventSource Array, but i m not able to find any options related to it.

is there any way to accomplish this ?

twinssbc commented 7 years ago

@kunalailani You can refer to the View Customization Options to display the events using your own template.

iamsim commented 6 years ago

My Custom cell template in month view is this -

<div>{{view.dates[row*7+col].label}}</div>
<div>{{event.title}}</div>

it does not display event title. How do i access event's title in the template?

kunalailani commented 6 years ago

@iamsim Did you check that event object contains the title property? I think you want to show the title according to date right? If so, You have to access the title like this {{view.dates[row*7+col].events[0].title}} I've wrap the title inside the parent <div> and access the event's title property from the dates array. Below is the code which displays the event title, Hope it will help you.


<div>
    {{view.dates[row*7+col].label}} 
   <p>{{view.dates[row*7+col].events[0].title}}</p>
</div>```