Closed Legion112 closed 5 years ago
I have found solution
new Event([
'start' => $plan->date_execution,
'title' => $plan->description,
'color' => $plan->isPayment ? 'green' : '#01c0ef',
'nonstandard' => [
'description' => "$model->typeText № $model->number от $contractDate {$model->contractor->title}",
],
'url' => Url::to(['fact', 'id' => $model->id]),
]);
echo \yii2fullcalendar\yii2fullcalendar::widget([
'events' => $events,
'eventRender' => new JsExpression(<<< 'JS'
(eventObj, $el)=>{
$el.popover({
title: eventObj.title,
content: eventObj.description,
trigger: 'hover',
placement: 'top',
container: 'body'
});
}
JS
)
]);
Thanks - and thanks for sharing ;)
I understand I need to user nonstandard fields instead but I can't understand how to implement it.
Could you please show a simple tooltip.