hello i want to check if color has color css('#FF7F50') : show an alert message i try but no succes can i find someone help
function GenerateCalender(events) {
$('#calender').fullCalendar('destroy');
$('#calender').fullCalendar({
contentHeight: 400,
defaultDate: new Date(),
timeFormat: 'h(:mm)a',
header: {
left: 'prev,next today',
center: 'title',
right: 'month,basicWeek,basicDay,agenda'
},
eventLimit: true,
eventColor: '#FF7F50',
events: events,
this my function
/******Check Color *******/
eventClick: function (calEvent, jsEvent, view) {
if (calEvent.eventColor == "#FF7F50") {
return alert("tttt");
}
this my controller :
public JsonResult Check(string ThemeColor)
{
return Json(db.Events.Any(c => c.ThemeColor == "NULL"));
}
this my scripts :
eventClick: function (calEvent, jsEvent, view) {
//return $.ajax({
// type: "POST",
// url: "/Home/Check",
// data: "ThemeColor",
// contentType: "application/json; charset=utf-8",
// dataType: "json",
// success: function (response) {
// if (response) {
// alert("tttt");
// }
// else {
// alert("tttt222222");
// }
// }
//});
how i can call the eventcolor to chec if color is NULL or not