Name | Type | Default | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
appointmentOpacity | Boolean | false | ||||||||||||
Sets or gets the appointments opacity. Code example
Set the
Get the
Try it: appointmentOpacity is set to 0.7
|
||||||||||||||
appointmentsMinHeight | Number | 18 | ||||||||||||
Sets or gets the minimum height of appointments in the all day area, month view and timeline views. Code example
Set the
Get the
|
||||||||||||||
appointmentDataFields | Object |
|
||||||||||||
Sets or gets the appointments data fields. A data field should match a field defined in the dataAdapter's source object. For example: If your have a data field called "start" in your source object, you should add 'from: "start"' in the appointmentDataFields definition.
Code example
Set the
Get the
|
||||||||||||||
appointmentTooltips | Boolean | true | ||||||||||||
Sets or gets whether Scheduler appointments are with tooltips enabled. Code example
Set the
Get the
|
||||||||||||||
columnsHeight | Number | 30 | ||||||||||||
Sets or gets the Schedulers' columns height. Code example
Set the
Get the
Try it: columnsHeight is set to 40
|
||||||||||||||
contextMenu | Boolean | true | ||||||||||||
Sets or gets whether the Scheduler's context menu is enabled. Code example
Set the
Get the
Try it: contextMenu is set false
|
||||||||||||||
contextMenuOpen | Function | null | ||||||||||||
Sets or gets a function called when the context menu is opened. Code example
Set the <!DOCTYPE html><html lang="en"><head> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "George brings projector for presentations.", location: "", subject: "Quarterly Project Review Meeting", calendar: "Room 1", start: new Date(2016, 10, 23, 9, 0, 0), end: new Date(2016, 10, 23, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "IT Group Mtg.", calendar: "Room 2", start: new Date(2016, 10, 24, 10, 0, 0), end: new Date(2016, 10, 24, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Course Social Media", calendar: "Room 3", start: new Date(2016, 10, 27, 11, 0, 0), end: new Date(2016, 10, 27, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "New Projects Planning", calendar: "Room 2", start: new Date(2016, 10, 23, 16, 0, 0), end: new Date(2016, 10, 23, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Interview with James", calendar: "Room 1", start: new Date(2016, 10, 25, 15, 0, 0), end: new Date(2016, 10, 25, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Interview with Nancy", calendar: "Room 4", start: new Date(2016, 10, 26, 14, 0, 0), end: new Date(2016, 10, 26, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, view: 1, showLegend: true, /** * called when the context menu is created. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} settings - Object with the menu's initialization settings. */ contextMenuCreate: function(menu, settings) { var source = settings.source; source.push({ id: "delete", label: "Delete Appointment" }); source.push({ id: "status", label: "Set Status", items: [ { label: "Free", id: "free" }, { label: "Out of Office", id: "outOfOffice" }, { label: "Tentative", id: "tentative" }, { label: "Busy", id: "busy" } ] }); }, /** * called when the user clicks an item in the Context Menu. Returning true as a result disables the built-in Click handler. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected appointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the jqxMenu's itemclick event object. */ contextMenuItemClick: function (menu, appointment, event) { var args = event.args; switch (args.id) { case "delete": $("#scheduler").jqxScheduler('deleteAppointment', appointment.id); return true; case "free": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'free'); return true; case "outOfOffice": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'outOfOffice'); return true; case "tentative": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'tentative'); return true; case "busy": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'busy'); return true; } }, /** * called when the menu is opened. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected appointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the open event. */ contextMenuOpen: function (menu, appointment, event) { if (!appointment) { menu.jqxMenu('hideItem', 'delete'); menu.jqxMenu('hideItem', 'status'); } else { menu.jqxMenu('showItem', 'delete'); menu.jqxMenu('showItem', 'status'); } }, /** * called when the menu is closed. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected appointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the close event. */ contextMenuClose: function (menu, appointment, event) { }, ready: function () { $("#scheduler").jqxScheduler('ensureAppointmentVisible', 'id1'); }, resources: { colorScheme: "scheme02", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
contextMenuClose | Function | null | ||||||||||||
Sets or gets a function called when the context menu is closed. Code example
Set the <!DOCTYPE html><html lang="en"><head> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "George brings projector for presentations.", location: "", subject: "Quarterly Project Review Meeting", calendar: "Room 1", start: new Date(2016, 10, 23, 9, 0, 0), end: new Date(2016, 10, 23, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "IT Group Mtg.", calendar: "Room 2", start: new Date(2016, 10, 24, 10, 0, 0), end: new Date(2016, 10, 24, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Course Social Media", calendar: "Room 3", start: new Date(2016, 10, 27, 11, 0, 0), end: new Date(2016, 10, 27, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "New Projects Planning", calendar: "Room 2", start: new Date(2016, 10, 23, 16, 0, 0), end: new Date(2016, 10, 23, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Interview with James", calendar: "Room 1", start: new Date(2016, 10, 25, 15, 0, 0), end: new Date(2016, 10, 25, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Interview with Nancy", calendar: "Room 4", start: new Date(2016, 10, 26, 14, 0, 0), end: new Date(2016, 10, 26, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, view: 1, showLegend: true, /** * called when the context menu is created. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} settings - Object with the menu's initialization settings. */ contextMenuCreate: function(menu, settings) { var source = settings.source; source.push({ id: "delete", label: "Delete Appointment" }); source.push({ id: "status", label: "Set Status", items: [ { label: "Free", id: "free" }, { label: "Out of Office", id: "outOfOffice" }, { label: "Tentative", id: "tentative" }, { label: "Busy", id: "busy" } ] }); }, /** * called when the user clicks an item in the Context Menu. Returning true as a result disables the built-in Click handler. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the jqxMenu's itemclick event object. */ contextMenuItemClick: function (menu, appointment, event) { var args = event.args; switch (args.id) { case "delete": $("#scheduler").jqxScheduler('deleteAppointment', appointment.id); return true; case "free": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'free'); return true; case "outOfOffice": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'outOfOffice'); return true; case "tentative": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'tentative'); return true; case "busy": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'busy'); return true; } }, /** * called when the menu is opened. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the open event. */ contextMenuOpen: function (menu, appointment, event) { if (!appointment) { menu.jqxMenu('hideItem', 'delete'); menu.jqxMenu('hideItem', 'status'); } else { menu.jqxMenu('showItem', 'delete'); menu.jqxMenu('showItem', 'status'); } }, /** * called when the menu is closed. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the close event. */ contextMenuClose: function (menu, appointment, event) { }, ready: function () { $("#scheduler").jqxScheduler('ensureAppointmentVisible', 'id1'); }, resources: { colorScheme: "scheme02", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
contextMenuItemClick | Function | null | ||||||||||||
Sets or gets a function called when a context menu item is clicked. Code example
Set the <!DOCTYPE html><html lang="en"><head> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "George brings projector for presentations.", location: "", subject: "Quarterly Project Review Meeting", calendar: "Room 1", start: new Date(2016, 10, 23, 9, 0, 0), end: new Date(2016, 10, 23, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "IT Group Mtg.", calendar: "Room 2", start: new Date(2016, 10, 24, 10, 0, 0), end: new Date(2016, 10, 24, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Course Social Media", calendar: "Room 3", start: new Date(2016, 10, 27, 11, 0, 0), end: new Date(2016, 10, 27, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "New Projects Planning", calendar: "Room 2", start: new Date(2016, 10, 23, 16, 0, 0), end: new Date(2016, 10, 23, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Interview with James", calendar: "Room 1", start: new Date(2016, 10, 25, 15, 0, 0), end: new Date(2016, 10, 25, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Interview with Nancy", calendar: "Room 4", start: new Date(2016, 10, 26, 14, 0, 0), end: new Date(2016, 10, 26, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, view: 1, showLegend: true, /** * called when the context menu is created. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} settings - Object with the menu's initialization settings. */ contextMenuCreate: function(menu, settings) { var source = settings.source; source.push({ id: "delete", label: "Delete Appointment" }); source.push({ id: "status", label: "Set Status", items: [ { label: "Free", id: "free" }, { label: "Out of Office", id: "outOfOffice" }, { label: "Tentative", id: "tentative" }, { label: "Busy", id: "busy" } ] }); }, /** * called when the user clicks an item in the Context Menu. Returning true as a result disables the built-in Click handler. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the jqxMenu's itemclick event object. */ contextMenuItemClick: function (menu, appointment, event) { var args = event.args; switch (args.id) { case "delete": $("#scheduler").jqxScheduler('deleteAppointment', appointment.id); return true; case "free": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'free'); return true; case "outOfOffice": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'outOfOffice'); return true; case "tentative": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'tentative'); return true; case "busy": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'busy'); return true; } }, /** * called when the menu is opened. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the open event. */ contextMenuOpen: function (menu, appointment, event) { if (!appointment) { menu.jqxMenu('hideItem', 'delete'); menu.jqxMenu('hideItem', 'status'); } else { menu.jqxMenu('showItem', 'delete'); menu.jqxMenu('showItem', 'status'); } }, /** * called when the menu is closed. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the close event. */ contextMenuClose: function (menu, appointment, event) { }, ready: function () { $("#scheduler").jqxScheduler('ensureAppointmentVisible', 'id1'); }, resources: { colorScheme: "scheme02", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
contextMenuCreate | Function | null | ||||||||||||
Sets or gets a function called when the context menu is created. Code example
Set the <!DOCTYPE html><html lang="en"><head> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "George brings projector for presentations.", location: "", subject: "Quarterly Project Review Meeting", calendar: "Room 1", start: new Date(2016, 10, 23, 9, 0, 0), end: new Date(2016, 10, 23, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "IT Group Mtg.", calendar: "Room 2", start: new Date(2016, 10, 24, 10, 0, 0), end: new Date(2016, 10, 24, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Course Social Media", calendar: "Room 3", start: new Date(2016, 10, 27, 11, 0, 0), end: new Date(2016, 10, 27, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "New Projects Planning", calendar: "Room 2", start: new Date(2016, 10, 23, 16, 0, 0), end: new Date(2016, 10, 23, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Interview with James", calendar: "Room 1", start: new Date(2016, 10, 25, 15, 0, 0), end: new Date(2016, 10, 25, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Interview with Nancy", calendar: "Room 4", start: new Date(2016, 10, 26, 14, 0, 0), end: new Date(2016, 10, 26, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, view: 1, showLegend: true, /** * called when the context menu is created. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} settings - Object with the menu's initialization settings. */ contextMenuCreate: function(menu, settings) { var source = settings.source; source.push({ id: "delete", label: "Delete Appointment" }); source.push({ id: "status", label: "Set Status", items: [ { label: "Free", id: "free" }, { label: "Out of Office", id: "outOfOffice" }, { label: "Tentative", id: "tentative" }, { label: "Busy", id: "busy" } ] }); }, /** * called when the user clicks an item in the Context Menu. Returning true as a result disables the built-in Click handler. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the jqxMenu's itemclick event object. */ contextMenuItemClick: function (menu, appointment, event) { var args = event.args; switch (args.id) { case "delete": $("#scheduler").jqxScheduler('deleteAppointment', appointment.id); return true; case "free": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'free'); return true; case "outOfOffice": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'outOfOffice'); return true; case "tentative": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'tentative'); return true; case "busy": $("#scheduler").jqxScheduler('setAppointmentProperty', appointment.id, 'status', 'busy'); return true; } }, /** * called when the menu is opened. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the open event. */ contextMenuOpen: function (menu, appointment, event) { if (!appointment) { menu.jqxMenu('hideItem', 'delete'); menu.jqxMenu('hideItem', 'status'); } else { menu.jqxMenu('showItem', 'delete'); menu.jqxMenu('showItem', 'status'); } }, /** * called when the menu is closed. * @param {Object} menu - jqxMenu's jQuery object. * @param {Object} the selected jqxAppointment instance or NULL when the menu is opened from cells selection. * @param {jQuery.Event Object} the close event. */ contextMenuClose: function (menu, appointment, event) { }, ready: function () { $("#scheduler").jqxScheduler('ensureAppointmentVisible', 'id1'); }, resources: { colorScheme: "scheme02", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
changedAppointments | Array | [] | ||||||||||||
Gets an array with newly added, deleted or updated appointments. Each element in the Array is an Object which has:
Code example
Get the
Try it: gets the changedAppointments.
|
||||||||||||||
disabled | Boolean | false | ||||||||||||
Sets or gets whether the Scheduler is disabled. Code example
Set the
Get the
Try it: disabled is set true
|
||||||||||||||
date | jqxDate | new $.jqx.date('todayDate') | ||||||||||||
Sets or gets the Scheduler's Date. To learn how to use jqxDate, please look at the Scheduler's Getting Started help topic. Code example
Set the
Get the
Try it: date is set current date.
|
||||||||||||||
dayNameFormat | string | 'full' | ||||||||||||
Sets or gets the Schedulers' columns day formatting. Possible values: 'shortest', 'firstTwoLetters', 'firstLetter', 'abbr', 'full'. Code example
Set the
Get the
Try it: dayNameFormat is set to 'abbr'
|
||||||||||||||
enableHover | Boolean | true | ||||||||||||
Sets or gets whether cells hover is enabled. Code example
Set the
Get the
Try it: enableHover is set to false
|
||||||||||||||
editDialog | Boolean | true | ||||||||||||
Sets or gets whether Edit Dialog is enabled. Code example
Set the
Get the
Try it: editDialog is set to false
|
||||||||||||||
editDialogDateTimeFormatString | String | "dd/MM/yyyy hh:mm tt" | ||||||||||||
Sets or gets the DateTimeInput's formatString in the Scheduler's Edit Dialog when the appointment is not allDay appointment. Code example
Set the
Get the
|
||||||||||||||
editDialogDateFormatString | String | "dd/MM/yyyy" | ||||||||||||
Sets or gets the DateTimeInput's formatString in the Scheduler's Edit Dialog when the appointment is allDay appointment. Code example
Set the
Get the
|
||||||||||||||
editDialogOpen | Function | null | ||||||||||||
Sets or gets a function called when the Scheduler's Edit Dialog is opened. Code example
Set the <!DOCTYPE html><html lang="en"><head> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "George brings projector for presentations.", location: "", subject: "Fashion Expo", calendar: "East Coast Events", start: new Date(2016, 10, 15, 9, 0, 0), end: new Date(2016, 10, 18, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "Cloud Data Expo", calendar: "Middle West Events", start: new Date(2016, 10, 20, 10, 0, 0), end: new Date(2016, 10, 22, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Digital Media Conference", calendar: "West Coast Events", start: new Date(2016, 10, 23, 11, 0, 0), end: new Date(2016, 10, 28, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "Modern Software Development Conference", calendar: "West Coast Events", start: new Date(2016, 10, 10, 16, 0, 0), end: new Date(2016, 10, 12, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Marketing Future Expo", calendar: "Middle West Events", start: new Date(2016, 10, 5, 15, 0, 0), end: new Date(2016, 10, 6, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Future Computing", calendar: "East Coast Events", start: new Date(2016, 10, 13, 14, 0, 0), end: new Date(2016, 10, 20, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); var printButton = null; $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, view: 2, showLegend: true, // called when the dialog is created. editDialogCreate: function (dialog, fields, editAppointment) { // hide repeat option fields.repeatContainer.hide(); // hide status option fields.statusContainer.hide(); // hide timeZone option fields.timeZoneContainer.hide(); // hide color option fields.colorContainer.hide(); fields.subjectLabel.html("Title"); fields.locationLabel.html("Where"); fields.fromLabel.html("Start"); fields.toLabel.html("End"); fields.resourceLabel.html("Calendar"); // add custom print button. printButton = $("<button style='margin-left: 5px; float:right;'>Print</button>"); fields.buttons.append(printButton); printButton.jqxButton({ theme: this.theme }); printButton.click(function () { var appointment = editAppointment; if (!appointment) return; var appointmentContent = "<table class='printTable'>" + "<tr>" + "<td class='label'>Title</td>" + "<td>" + fields.subject.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Start</td>" + "<td>" + fields.from.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>End</td>" + "<td>" + fields.to.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Where</td>" + "<td>" + fields.location.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Calendar</td>" + "<td>" + fields.resource.val() + "</td>" + "</tr>" + "</table>"; var newWindow = window.open('', '', 'width=800, height=500'), document = newWindow.document.open(), pageContent = '<!DOCTYPE html>\n' + '<html>\n' + '<head>\n' + '<meta charset="utf-8" />\n' + '<title>jQWidgets Scheduler</title>\n' + '<style>\n' + '.printTable {\n' + 'border-color: #aaa;\n' + '}\n' + '.printTable .label {\n' + 'font-weight: bold;\n' + '}\n' + '.printTable td{\n' + 'padding: 4px 3px;\n' + 'border: 1px solid #DDD;\n' + 'vertical-align: top;\n' + '}\n' + '</style>' + '</head>\n' + '<body>\n' + appointmentContent + '\n</body>\n</html>'; document.write(pageContent); document.close(); newWindow.print(); }); }, /** * called when the dialog is opened. Returning true as a result disables the built-in handler. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. */ editDialogOpen: function (dialog, fields, editAppointment) { if (!editAppointment && printButton) { printButton.jqxButton({ disabled: true }); } else if (editAppointment && printButton) { printButton.jqxButton({ disabled: false }); } }, /** * called when the dialog is closed. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. */ editDialogClose: function (dialog, fields, editAppointment) { }, /** * called when a key is pressed while the dialog is on focus. Returning true or false as a result disables the built-in keyDown handler. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. * @param {jQuery.Event Object} the keyDown event. */ editDialogKeyDown: function (dialog, fields, editAppointment, event) { }, resources: { colorScheme: "scheme01", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
editDialogCreate | Function | null | ||||||||||||
Sets or gets a function called when the Scheduler's Edit Dialog is created. Code example
Set the <!DOCTYPE html><html lang="en"><head> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "George brings projector for presentations.", location: "", subject: "Fashion Expo", calendar: "East Coast Events", start: new Date(2016, 10, 15, 9, 0, 0), end: new Date(2016, 10, 18, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "Cloud Data Expo", calendar: "Middle West Events", start: new Date(2016, 10, 20, 10, 0, 0), end: new Date(2016, 10, 22, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Digital Media Conference", calendar: "West Coast Events", start: new Date(2016, 10, 23, 11, 0, 0), end: new Date(2016, 10, 28, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "Modern Software Development Conference", calendar: "West Coast Events", start: new Date(2016, 10, 10, 16, 0, 0), end: new Date(2016, 10, 12, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Marketing Future Expo", calendar: "Middle West Events", start: new Date(2016, 10, 5, 15, 0, 0), end: new Date(2016, 10, 6, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Future Computing", calendar: "East Coast Events", start: new Date(2016, 10, 13, 14, 0, 0), end: new Date(2016, 10, 20, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); var printButton = null; $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, view: 2, showLegend: true, // called when the dialog is created. editDialogCreate: function (dialog, fields, editAppointment) { // hide repeat option fields.repeatContainer.hide(); // hide status option fields.statusContainer.hide(); // hide timeZone option fields.timeZoneContainer.hide(); // hide color option fields.colorContainer.hide(); fields.subjectLabel.html("Title"); fields.locationLabel.html("Where"); fields.fromLabel.html("Start"); fields.toLabel.html("End"); fields.resourceLabel.html("Calendar"); // add custom print button. printButton = $("<button style='margin-left: 5px; float:right;'>Print</button>"); fields.buttons.append(printButton); printButton.jqxButton({ theme: this.theme }); printButton.click(function () { var appointment = editAppointment; if (!appointment) return; var appointmentContent = "<table class='printTable'>" + "<tr>" + "<td class='label'>Title</td>" + "<td>" + fields.subject.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Start</td>" + "<td>" + fields.from.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>End</td>" + "<td>" + fields.to.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Where</td>" + "<td>" + fields.location.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Calendar</td>" + "<td>" + fields.resource.val() + "</td>" + "</tr>" + "</table>"; var newWindow = window.open('', '', 'width=800, height=500'), document = newWindow.document.open(), pageContent = '<!DOCTYPE html>\n' + '<html>\n' + '<head>\n' + '<meta charset="utf-8" />\n' + '<title>jQWidgets Scheduler</title>\n' + '<style>\n' + '.printTable {\n' + 'border-color: #aaa;\n' + '}\n' + '.printTable .label {\n' + 'font-weight: bold;\n' + '}\n' + '.printTable td{\n' + 'padding: 4px 3px;\n' + 'border: 1px solid #DDD;\n' + 'vertical-align: top;\n' + '}\n' + '</style>' + '</head>\n' + '<body>\n' + appointmentContent + '\n</body>\n</html>'; document.write(pageContent); document.close(); newWindow.print(); }); }, /** * called when the dialog is opened. Returning true as a result disables the built-in handler. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. */ editDialogOpen: function (dialog, fields, editAppointment) { if (!editAppointment && printButton) { printButton.jqxButton({ disabled: true }); } else if (editAppointment && printButton) { printButton.jqxButton({ disabled: false }); } }, /** * called when the dialog is closed. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. */ editDialogClose: function (dialog, fields, editAppointment) { }, /** * called when a key is pressed while the dialog is on focus. Returning true or false as a result disables the built-in keyDown handler. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. * @param {jQuery.Event Object} the keyDown event. */ editDialogKeyDown: function (dialog, fields, editAppointment, event) { }, resources: { colorScheme: "scheme01", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
editDialogKeyDown | Function | null | ||||||||||||
Sets or gets a function called when the Scheduler's Edit Dialog is opened and is on focus and key is pressed. Code example
Set the <!DOCTYPE html><html lang="en"><head> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "George brings projector for presentations.", location: "", subject: "Fashion Expo", calendar: "East Coast Events", start: new Date(2016, 10, 15, 9, 0, 0), end: new Date(2016, 10, 18, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "Cloud Data Expo", calendar: "Middle West Events", start: new Date(2016, 10, 20, 10, 0, 0), end: new Date(2016, 10, 22, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Digital Media Conference", calendar: "West Coast Events", start: new Date(2016, 10, 23, 11, 0, 0), end: new Date(2016, 10, 28, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "Modern Software Development Conference", calendar: "West Coast Events", start: new Date(2016, 10, 10, 16, 0, 0), end: new Date(2016, 10, 12, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Marketing Future Expo", calendar: "Middle West Events", start: new Date(2016, 10, 5, 15, 0, 0), end: new Date(2016, 10, 6, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Future Computing", calendar: "East Coast Events", start: new Date(2016, 10, 13, 14, 0, 0), end: new Date(2016, 10, 20, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); var printButton = null; $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, view: 2, showLegend: true, // called when the dialog is created. editDialogCreate: function (dialog, fields, editAppointment) { // hide repeat option fields.repeatContainer.hide(); // hide status option fields.statusContainer.hide(); // hide timeZone option fields.timeZoneContainer.hide(); // hide color option fields.colorContainer.hide(); fields.subjectLabel.html("Title"); fields.locationLabel.html("Where"); fields.fromLabel.html("Start"); fields.toLabel.html("End"); fields.resourceLabel.html("Calendar"); // add custom print button. printButton = $("<button style='margin-left: 5px; float:right;'>Print</button>"); fields.buttons.append(printButton); printButton.jqxButton({ theme: this.theme }); printButton.click(function () { var appointment = editAppointment; if (!appointment) return; var appointmentContent = "<table class='printTable'>" + "<tr>" + "<td class='label'>Title</td>" + "<td>" + fields.subject.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Start</td>" + "<td>" + fields.from.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>End</td>" + "<td>" + fields.to.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Where</td>" + "<td>" + fields.location.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Calendar</td>" + "<td>" + fields.resource.val() + "</td>" + "</tr>" + "</table>"; var newWindow = window.open('', '', 'width=800, height=500'), document = newWindow.document.open(), pageContent = '<!DOCTYPE html>\n' + '<html>\n' + '<head>\n' + '<meta charset="utf-8" />\n' + '<title>jQWidgets Scheduler</title>\n' + '<style>\n' + '.printTable {\n' + 'border-color: #aaa;\n' + '}\n' + '.printTable .label {\n' + 'font-weight: bold;\n' + '}\n' + '.printTable td{\n' + 'padding: 4px 3px;\n' + 'border: 1px solid #DDD;\n' + 'vertical-align: top;\n' + '}\n' + '</style>' + '</head>\n' + '<body>\n' + appointmentContent + '\n</body>\n</html>'; document.write(pageContent); document.close(); newWindow.print(); }); }, /** * called when the dialog is opened. Returning true as a result disables the built-in handler. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. */ editDialogOpen: function (dialog, fields, editAppointment) { if (!editAppointment && printButton) { printButton.jqxButton({ disabled: true }); } else if (editAppointment && printButton) { printButton.jqxButton({ disabled: false }); } }, /** * called when the dialog is closed. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. */ editDialogClose: function (dialog, fields, editAppointment) { }, /** * called when a key is pressed while the dialog is on focus. Returning true or false as a result disables the built-in keyDown handler. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. * @param {jQuery.Event Object} the keyDown event. */ editDialogKeyDown: function (dialog, fields, editAppointment, event) { }, resources: { colorScheme: "scheme01", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
editDialogClose | Function | null | ||||||||||||
Sets or gets a function called when the Scheduler's Edit Dialog is closed. Code example
Set the <!DOCTYPE html><html lang="en"><head> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "George brings projector for presentations.", location: "", subject: "Fashion Expo", calendar: "East Coast Events", start: new Date(2016, 10, 15, 9, 0, 0), end: new Date(2016, 10, 18, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "Cloud Data Expo", calendar: "Middle West Events", start: new Date(2016, 10, 20, 10, 0, 0), end: new Date(2016, 10, 22, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Digital Media Conference", calendar: "West Coast Events", start: new Date(2016, 10, 23, 11, 0, 0), end: new Date(2016, 10, 28, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "Modern Software Development Conference", calendar: "West Coast Events", start: new Date(2016, 10, 10, 16, 0, 0), end: new Date(2016, 10, 12, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Marketing Future Expo", calendar: "Middle West Events", start: new Date(2016, 10, 5, 15, 0, 0), end: new Date(2016, 10, 6, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Future Computing", calendar: "East Coast Events", start: new Date(2016, 10, 13, 14, 0, 0), end: new Date(2016, 10, 20, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); var printButton = null; $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, view: 2, showLegend: true, // called when the dialog is created. editDialogCreate: function (dialog, fields, editAppointment) { // hide repeat option fields.repeatContainer.hide(); // hide status option fields.statusContainer.hide(); // hide timeZone option fields.timeZoneContainer.hide(); // hide color option fields.colorContainer.hide(); fields.subjectLabel.html("Title"); fields.locationLabel.html("Where"); fields.fromLabel.html("Start"); fields.toLabel.html("End"); fields.resourceLabel.html("Calendar"); // add custom print button. printButton = $("<button style='margin-left: 5px; float:right;'>Print</button>"); fields.buttons.append(printButton); printButton.jqxButton({ theme: this.theme }); printButton.click(function () { var appointment = editAppointment; if (!appointment) return; var appointmentContent = "<table class='printTable'>" + "<tr>" + "<td class='label'>Title</td>" + "<td>" + fields.subject.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Start</td>" + "<td>" + fields.from.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>End</td>" + "<td>" + fields.to.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Where</td>" + "<td>" + fields.location.val() + "</td>" + "</tr>" + "<tr>" + "<td class='label'>Calendar</td>" + "<td>" + fields.resource.val() + "</td>" + "</tr>" + "</table>"; var newWindow = window.open('', '', 'width=800, height=500'), document = newWindow.document.open(), pageContent = '<!DOCTYPE html>\n' + '<html>\n' + '<head>\n' + '<meta charset="utf-8" />\n' + '<title>jQWidgets Scheduler</title>\n' + '<style>\n' + '.printTable {\n' + 'border-color: #aaa;\n' + '}\n' + '.printTable .label {\n' + 'font-weight: bold;\n' + '}\n' + '.printTable td{\n' + 'padding: 4px 3px;\n' + 'border: 1px solid #DDD;\n' + 'vertical-align: top;\n' + '}\n' + '</style>' + '</head>\n' + '<body>\n' + appointmentContent + '\n</body>\n</html>'; document.write(pageContent); document.close(); newWindow.print(); }); }, /** * called when the dialog is opened. Returning true as a result disables the built-in handler. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. */ editDialogOpen: function (dialog, fields, editAppointment) { if (!editAppointment && printButton) { printButton.jqxButton({ disabled: true }); } else if (editAppointment && printButton) { printButton.jqxButton({ disabled: false }); } }, /** * called when the dialog is closed. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. */ editDialogClose: function (dialog, fields, editAppointment) { }, /** * called when a key is pressed while the dialog is on focus. Returning true or false as a result disables the built-in keyDown handler. * @param {Object} dialog - jqxWindow's jQuery object. * @param {Object} fields - Object with all widgets inside the dialog. * @param {Object} the selected appointment instance or NULL when the dialog is opened from cells selection. * @param {jQuery.Event Object} the keyDown event. */ editDialogKeyDown: function (dialog, fields, editAppointment, event) { }, resources: { colorScheme: "scheme01", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
exportSettings | Object | { serverURL: null, characterSet: null, fileName: "jqxScheduler", dateTimeFormatString: "S", resourcesInMultipleICSFiles: false} | ||||||||||||
Determines the Data Export settings used by jqxScheduler when
Code example
Set the
Get the
|
||||||||||||||
height | Number/String | 600 | ||||||||||||
Sets or gets the Scheduler's height. Code example
Set the
Get the
Try it: height is set to 700
|
||||||||||||||
legendPosition | String | "bottom" | ||||||||||||
Sets or gets the Scheduler's legendPosition. Possible values: "top" and "bottom". Code example
Set the
Get the
Try it: legendPosition is set to 'top'
|
||||||||||||||
legendHeight | Number | 34 | ||||||||||||
Sets or gets the Scheduler's legend height. Code example
Set the
Get the
Try it: legendHeight is set to 40
|
||||||||||||||
localization | Object | |||||||||||||
Sets or gets the Scheduler's localization. Default Localization:
Code example
Set the <!DOCTYPE html><html lang="en"><head> <title id='Description'>jqxScheduler first demo. </title> <link rel="stylesheet" href="../../jqwidgets/styles/jqx.base.css" type="text/css" /> <script type="text/javascript" src="../../scripts/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../../scripts/demos.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcore.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxbuttons.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscrollbar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdata.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdate.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxscheduler.api.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdatetimeinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxmenu.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcalendar.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxtooltip.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxwindow.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxcheckbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxlistbox.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxdropdownlist.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxnumberinput.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxradiobutton.js"></script> <script type="text/javascript" src="../../jqwidgets/jqxinput.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.js"></script> <script type="text/javascript" src="../../jqwidgets/globalization/globalize.culture.de-DE.js"></script> <script type="text/javascript"> $(document).ready(function () { var appointments = new Array(); var appointment1 = { id: "id1", description: "", location: "", subject: "Projektsitzung", calendar: "Zimmer 1", start: new Date(2016, 10, 23, 9, 0, 0), end: new Date(2016, 10, 23, 16, 0, 0) } var appointment2 = { id: "id2", description: "", location: "", subject: "IT Gruppentreffen", calendar: "Zimmer 2", start: new Date(2016, 10, 24, 10, 0, 0), end: new Date(2016, 10, 24, 15, 0, 0) } var appointment3 = { id: "id3", description: "", location: "", subject: "Soziale Treffen", calendar: "Zimmer 3", start: new Date(2016, 10, 27, 11, 0, 0), end: new Date(2016, 10, 27, 13, 0, 0) } var appointment4 = { id: "id4", description: "", location: "", subject: "Projekte Planung", calendar: "Zimmer 2", start: new Date(2016, 10, 23, 16, 0, 0), end: new Date(2016, 10, 23, 18, 0, 0) } var appointment5 = { id: "id5", description: "", location: "", subject: "Interveiw mit Jan", calendar: "Zimmer 1", start: new Date(2016, 10, 25, 15, 0, 0), end: new Date(2016, 10, 25, 17, 0, 0) } var appointment6 = { id: "id6", description: "", location: "", subject: "Interveiw mit Alberta", calendar: "Zimmer 4", start: new Date(2016, 10, 26, 14, 0, 0), end: new Date(2016, 10, 26, 16, 0, 0) } appointments.push(appointment1); appointments.push(appointment2); appointments.push(appointment3); appointments.push(appointment4); appointments.push(appointment5); appointments.push(appointment6); // prepare the data var source = { dataType: "array", dataFields: [ { name: 'id', type: 'string' }, { name: 'description', type: 'string' }, { name: 'location', type: 'string' }, { name: 'subject', type: 'string' }, { name: 'calendar', type: 'string' }, { name: 'start', type: 'date' }, { name: 'end', type: 'date' } ], id: 'id', localData: appointments }; var adapter = new $.jqx.dataAdapter(source); $("#scheduler").jqxScheduler({ date: new $.jqx.date(2016, 11, 23), width: 850, height: 600, source: adapter, showLegend: true, // called when the dialog is craeted. editDialogCreate: function (dialog, fields, editAppointment) { fields.timeZoneContainer.hide(); }, localization: { // separator of parts of a date (e.g. '/' in 11/05/1955) '/': "/", // separator of parts of a time (e.g. ':' in 05:44 PM) ':': ":", // the first day of the week (0 = Sunday, 1 = Monday, etc) firstDay: 1, days: { // full day names names: ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag"], // abbreviated day names namesAbbr: ["Sonn", "Mon", "Dien", "Mitt", "Donn", "Fre", "Sams"], // shortest day names namesShort: ["So", "Mo", "Di", "Mi", "Do", "Fr", "Sa"] }, months: { // full month names (13 months for lunar calendards -- 13th month should be "" if not lunar) names: ["Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", ""], // abbreviated month names namesAbbr: ["Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dez", ""] }, // AM and PM designators in one of these forms: // The usual view, and the upper and lower case versions // [standard,lowercase,uppercase] // The culture does not use AM or PM (likely all standard date formats use 24 hour time) // null AM: ["AM", "am", "AM"], PM: ["PM", "pm", "PM"], eras: [ // eras in reverse chronological order. // name: the name of the era in this culture (e.g. A.D., C.E.) // start: when the era starts in ticks (gregorian, gmt), null if it is the earliest supported era. // offset: offset in years from gregorian calendar { "name": "A.D.", "start": null, "offset": 0 } ], twoDigitYearMax: 2029, patterns: { // short date pattern d: "M/d/yyyy", // long date pattern D: "dddd, MMMM dd, yyyy", // short time pattern t: "h:mm tt", // long time pattern T: "h:mm:ss tt", // long date, short time pattern f: "dddd, MMMM dd, yyyy h:mm tt", // long date, long time pattern F: "dddd, MMMM dd, yyyy h:mm:ss tt", // month/day pattern M: "MMMM dd", // month/year pattern Y: "yyyy MMMM", // S is a sortable format that does not vary by culture S: "yyyy\u0027-\u0027MM\u0027-\u0027dd\u0027T\u0027HH\u0027:\u0027mm\u0027:\u0027ss", // formatting of dates in MySQL DataBases ISO: "yyyy-MM-dd hh:mm:ss", ISO2: "yyyy-MM-dd HH:mm:ss", d1: "dd.MM.yyyy", d2: "dd-MM-yyyy", d3: "dd-MMMM-yyyy", d4: "dd-MM-yy", d5: "H:mm", d6: "HH:mm", d7: "HH:mm tt", d8: "dd/MMMM/yyyy", d9: "MMMM-dd", d10: "MM-dd", d11: "MM-dd-yyyy" }, backString: "Vorhergehende", forwardString: "Nächster", toolBarPreviousButtonString: "Vorhergehende", toolBarNextButtonString: "Nächster", emptyDataString: "Nokeine Daten angezeigt", loadString: "Loading...", clearString: "Löschen", todayString: "Heute", dayViewString: "Tag", weekViewString: "Woche", monthViewString: "Monat", timelineDayViewString: "Zeitleiste Day", timelineWeekViewString: "Zeitleiste Woche", timelineMonthViewString: "Zeitleiste Monat", loadingErrorMessage: "Die Daten werden noch geladen und Sie können eine Eigenschaft nicht festgelegt oder eine Methode aufrufen . Sie können tun, dass, sobald die Datenbindung abgeschlossen ist. jqxScheduler wirft die ' bindingComplete ' Ereignis, wenn die Bindung abgeschlossen ist.", editRecurringAppointmentDialogTitleString: "Bearbeiten Sie wiederkehrenden Termin", editRecurringAppointmentDialogContentString: "Wollen Sie nur dieses eine Vorkommen oder die Serie zu bearbeiten ?", editRecurringAppointmentDialogOccurrenceString: "Vorkommen bearbeiten", editRecurringAppointmentDialogSeriesString: "Bearbeiten Die Serie", editDialogTitleString: "Termin bearbeiten", editDialogCreateTitleString: "Erstellen Sie Neuer Termin", contextMenuEditAppointmentString: "Termin bearbeiten", contextMenuCreateAppointmentString: "Erstellen Sie Neuer Termin", editDialogSubjectString: "Subjekt", editDialogLocationString: "Ort", editDialogFromString: "Von", editDialogToString: "Bis", editDialogAllDayString: "Den ganzen Tag", editDialogExceptionsString: "Ausnahmen", editDialogResetExceptionsString: "Zurücksetzen auf Speichern", editDialogDescriptionString: "Bezeichnung", editDialogResourceIdString: "Kalender", editDialogStatusString: "Status", editDialogColorString: "Farbe", editDialogColorPlaceHolderString: "Farbe wählen", editDialogTimeZoneString: "Zeitzone", editDialogSelectTimeZoneString: "Wählen Sie Zeitzone", editDialogSaveString: "Sparen", editDialogDeleteString: "Löschen", editDialogCancelString: "Abbrechen", editDialogRepeatString: "Wiederholen", editDialogRepeatEveryString: "Wiederholen alle", editDialogRepeatEveryWeekString: "woche(n)", editDialogRepeatEveryYearString: "Jahr (en)", editDialogRepeatEveryDayString: "Tag (e)", editDialogRepeatNeverString: "Nie", editDialogRepeatDailyString: "Täglich", editDialogRepeatWeeklyString: "Wöchentlich", editDialogRepeatMonthlyString: "Monatlich", editDialogRepeatYearlyString: "Jährlich", editDialogRepeatEveryMonthString: "Monate (n)", editDialogRepeatEveryMonthDayString: "Day", editDialogRepeatFirstString: "erste", editDialogRepeatSecondString: "zweite", editDialogRepeatThirdString: "dritte", editDialogRepeatFourthString: "vierte", editDialogRepeatLastString: "letzte", editDialogRepeatEndString: "Ende", editDialogRepeatAfterString: "Nach", editDialogRepeatOnString: "Am", editDialogRepeatOfString: "von", editDialogRepeatOccurrencesString: "Eintritt (e)", editDialogRepeatSaveString: "Vorkommen Speichern", editDialogRepeatSaveSeriesString: "Save Series", editDialogRepeatDeleteString: "Vorkommen löschen", editDialogRepeatDeleteSeriesString: "Series löschen", editDialogStatuses: { free: "Frei", tentative: "Versuchsweise", busy: "Beschäftigt", outOfOffice: "Ausserhaus" } }, ready: function () { $("#scheduler").jqxScheduler('ensureAppointmentVisible', 'id1'); }, resources: { colorScheme: "scheme05", dataField: "calendar", source: new $.jqx.dataAdapter(source) }, appointmentDataFields: { from: "start", to: "end", id: "id", description: "description", location: "place", subject: "subject", resourceId: "calendar" }, view: 'weekView', views: [ 'dayView', 'weekView', 'monthView' ] }); }); </script></head><body class='default'> <div id="scheduler"></div></body></html>
Get the
|
||||||||||||||
min | jqxDate | new $.jqx.date(0) | ||||||||||||
Sets or gets the Scheduler's minimum navigation date. To learn how to use jqxDate, please look at the Scheduler's Getting Started help topic. Code example
Set the
Get the
|
||||||||||||||
max | jqxDate | new $.jqx.date(9999, 12, 31), | ||||||||||||
Sets or gets the Scheduler's maximum navigation date. To learn how to use jqxDate, please look at the Scheduler's Getting Started help topic. Code example
Set the
Get the
|
||||||||||||||
ready | Function | null | ||||||||||||
Sets a function called when the Scheduler is rendered and ready for usage. Code example
Set the
|
||||||||||||||
renderAppointment | Function | null | ||||||||||||
Sets a function called when the Scheduler is rendering its appointments. The function has one parameter which is Object with the following members:
Code example
Set the
|
||||||||||||||
rendering | Function | null | ||||||||||||
Sets a function called by the Scheduler when the Scheduler's rendering function is called. Code example
Set the
|
||||||||||||||
rendered | Function | null | ||||||||||||
Sets a function called by the Scheduler when the Scheduler is rendered. Code example
Set the
|
||||||||||||||
rtl | Boolean | false | ||||||||||||
Sets or gets whether the Scheduler is displayed with Right to Left layout. Code example
Set the
Get the
Try it: rtl is set to true.
|
||||||||||||||
resources | Object | null | ||||||||||||
Sets or gets the Scheduler's resource object. The object can have the following members:
Code example
Set the
Get the
|
||||||||||||||
rowsHeight | Number | 27 | ||||||||||||
Sets or gets the Scheduler rows height. Code example
Set the
Get the
Try it: rowsHeight is set to 40.
|
||||||||||||||
showToolbar | Boolean | true | ||||||||||||
Sets or gets whether the Scheduler's navigation toolbar is displayed. Code example
Set the
Get the
Try it: showToolbar is set to false.
|
||||||||||||||
showLegend | Boolean | false | ||||||||||||
Sets or gets whether the Scheduler's legend bar is displayed. Code example
Set the
Get the
Try it: showLegend is set to false.
|
||||||||||||||
scrollBarSize | Number | 15 | ||||||||||||
Sets or gets the scrollbars size. Code example
Set the
Get the
Try it: scrollBarSize is set to 20.
|
||||||||||||||
source | Object | null | ||||||||||||
Sets or gets the Scheduler appointments data source. The property should point to dataAdapter instance. Code example
Set the
Get the
Try it: source is set to dataAdapter.
|
||||||||||||||
statuses | Object |
|
||||||||||||
Sets or gets the Scheduler appointments statuses. Code example
Set the
Get the
|
||||||||||||||
touchRowsHeight | Number | 37 | ||||||||||||
Sets or gets the Scheduler rows height on touch device. Code example
Set the
Get the
Try it: touchRowsHeight is set to 40.
|
||||||||||||||
theme | String | '' | ||||||||||||
Sets the widget's theme. jQWidgets uses a pair of css files - jqx.base.css and jqx.[theme name].css. The base stylesheet creates the styles related to the widget's layout like margin, padding, border-width, position. The second css file applies the widget's colors and backgrounds. The jqx.base.css should be included before the second CSS file. In order to set a theme, you need to do the following:
Try it: theme is set to 'energyblue'
|
||||||||||||||
touchAppointmentsMinHeight | Number | 27 | ||||||||||||
Sets or gets the minimum height of appointments on touch devices in the all day area, month view and timeline views. Code example
Set the
Get the
|
||||||||||||||
touchScrollBarSize | Number | 18 | ||||||||||||
Sets or gets the scrollbars size on touch devices. Code example
Set the
Get the
Try it: touchScrollBarSize is set to 25.
|
||||||||||||||
timeZone | String | |||||||||||||
Sets or gets the Scheduler's Time Zone. Possible values:
Code example
Set the
Get the
Try it: timeZone is set to 'UTC'.
|
||||||||||||||
touchDayNameFormat | String | 'abbr' | ||||||||||||
Sets or gets the Schedulers' columns day formatting. Possible values: 'shortest', 'firstTwoLetters', 'firstLetter', 'abbr', 'full'. Code example
Set the
Get the
|
||||||||||||||
toolBarRangeFormat | String | 'dd MMMM yyyy' | ||||||||||||
Sets or gets the toolbar's date format. Code example
Set the
Get the
|
||||||||||||||
toolBarRangeFormatAbbr | String | 'dd MM yyyy' | ||||||||||||
Sets or gets the toolbar's date format when the Scheduler's width is not enough for displaying the full format. Code example
Set the
Get the
|
||||||||||||||
toolbarHeight | Number | 54 | ||||||||||||
Sets or gets the Scheduler toolbar's height. Code example
Set the
Get the
Try it: toolbarHeight is set to 60.
|
||||||||||||||
views | Array | ['dayView', 'weekView', 'monthView'] | ||||||||||||
Sets or gets the Scheduler's views. Each view in the Array can be String or Object. Strings are: 'dayView', 'weekView', 'monthView', 'timelineDayView', 'timelineWeekView', 'timelineMonthView', 'agendaView'. If it is an object it can have the following members:
Code example
Set the
Get the
Try it: views is set to custom object.
|
||||||||||||||
view | Number/String | |||||||||||||
Sets or gets the Scheduler's view. Possible vales: 'dayView', 'weekView', 'monthView', 'timelineDayView', 'timelineWeekView' and 'timelineMonthView' or the view's Index in the views object. Code example
Set the
Get the
|
||||||||||||||
width | Number/String | 800 | ||||||||||||
Sets or gets the Scheduler's width. Code example
Set the
Get the
Try it: width is set to 850.
|
||||||||||||||
Events |
||||||||||||||
appointmentChange | Event | |||||||||||||
This event is triggered when an appointment is changed. event.args contains the event's arguments. This event has one argument: appointment - Object which has the appointmentDataFields. See appointmentDataFields property. Code example
Bind to the
|
||||||||||||||
appointmentClick | Event | |||||||||||||
This event is triggered when an appointment is clicked. event.args contains the event's arguments. This event has one argument: appointment - Object which has the appointmentDataFields. See appointmentDataFields property. Code example
Bind to the
|
||||||||||||||
appointmentDoubleClick | Event | |||||||||||||
This event is triggered when an appointment is double clicked. event.args contains the event's arguments. This event has one argument: appointment - Object which has the appointmentDataFields. See appointmentDataFields property. Code example
Bind to the
|
||||||||||||||
appointmentDelete | Event | |||||||||||||
This event is triggered when an appointment is deleted. event.args contains the event's arguments. This event has one argument: appointment - Object which has the appointmentDataFields. See appointmentDataFields property. Code example
Bind to the
|
||||||||||||||
appointmentAdd | Event | |||||||||||||
This event is triggered when an appointment is added. event.args contains the event's arguments. This event has one argument: appointment - Object which has the appointmentDataFields. See appointmentDataFields property. Code example
Bind to the
|
||||||||||||||
bindingComplete | Event | |||||||||||||
This event is triggered when the binding is completed. Code example
Bind to the
|
||||||||||||||
cellClick | Event | |||||||||||||
This event is triggered when a cell is clicked. event.args contains the event's arguments. This event has two arguments: cell - TD HTML Element. date - jqxDate object. Code example
Bind to the
|
||||||||||||||
cellDoubleClick | Event | |||||||||||||
This event is triggered when a cell is double clicked. event.args contains the event's arguments. This event has two arguments: cell - TD HTML Element. date - jqxDate object. Code example
Bind to the
|
||||||||||||||
contextMenuOpen | Event | |||||||||||||
This event is triggered when the context menu is opened. Event Arguments:
Code example
Bind to the
|
||||||||||||||
contextMenuClose | Event | |||||||||||||
This event is triggered when the context menu is closed. Event Arguments:
Code example
Bind to the
|
||||||||||||||
contextMenuItemClick | Event | |||||||||||||
This event is triggered when the context menu item is clicked. Event Arguments:
Code example
Bind to the
|
||||||||||||||
contextMenuCreate | Event | |||||||||||||
This event is triggered when the context menu item is created. Event Arguments:
Code example
Bind to the
|
||||||||||||||
dateChange | Event | |||||||||||||
This event is triggered when the date is changed. This event has three arguments: date, from and to - jqxDate objects. Code example
Bind to the
|
||||||||||||||
editRecurrenceDialogOpen | Event | |||||||||||||
This event is triggered when the recurrence dialog is opened. Event Arguments:
Code example
Bind to the
|
||||||||||||||
editRecurrenceDialogClose | Event | |||||||||||||
This event is triggered when the recurrence dialog is closed. Event Arguments:
Code example
Bind to the
|
||||||||||||||
editDialogCreate | Event | |||||||||||||
This event is triggered when the edit dialog is created. Event Arguments:
Code example
Bind to the
|
||||||||||||||
editDialogOpen | Event | |||||||||||||
This event is triggered when the edit dialog is opened. Event Arguments:
Code example
Bind to the
|
||||||||||||||
editDialogClose | Event | |||||||||||||
This event is triggered when the edit dialog is closed. Event Arguments:
Code example
Bind to the
|
||||||||||||||
viewChange | Event | |||||||||||||
This event is triggered when the view type is changed. This event has five arguments: date, from and to - jqxDate objects, oldViewType and newViewType - strings. Code example
Bind to the
|
||||||||||||||
Methods |
||||||||||||||
addAppointment | Method | |||||||||||||
Adds a new appointment.
None Code examples
Invoke the
Try it: adds a new appointment.
|
||||||||||||||
beginAppointmentsUpdate | Method | |||||||||||||
Begins an update process and stops the Scheduler's rendering and appointments rendering.
None Code examples
Invoke the
|
||||||||||||||
clearAppointmentsSelection | Method | |||||||||||||
Clears the appointments selection.
None Code examples
Invoke the
|
||||||||||||||
clearSelection | Method | |||||||||||||
Clears cells selection.
None Code examples
Invoke the
Try it: clearSelection is invoked.
|
||||||||||||||
closeMenu | Method | |||||||||||||
Closes the context menu.
None Code examples
Invoke the
Try it: closeMenu is invoked.
|
||||||||||||||
closeDialog | Method | |||||||||||||
Closes the edit dialog.
None Code examples
Invoke the
Try it: closeDialog is invoked.
|
||||||||||||||
deleteAppointment | Method | |||||||||||||
Deletes an appointment.
None Code examples
Invoke the
Try it: deleteAppointment is invoked.
|
||||||||||||||
destroy | Method | |||||||||||||
Destroys the Scheduler and removes it from the DOM.
None Code examples
Invoke the
Try it: destroy is invoked.
|
||||||||||||||
endAppointmentsUpdate | Method | |||||||||||||
Ends the update process and resumes the Scheduler's rendering. The method works together with the beginAppointmentsUpdate.
None Code examples
Invoke the
|
||||||||||||||
ensureAppointmentVisible | Method | |||||||||||||
Scrolls to an appointment if it is out of the visible area.
None Code examples
Invoke the
|
||||||||||||||
ensureVisible | Method | |||||||||||||
Scrolls to a Date.
None Code examples
Invoke the
Try it: ensureVisible is invoked.
|
||||||||||||||
exportData | Method | |||||||||||||
Exports jqxScheduler's data to ICS, Excel, HTML, XML, JSON, CSV or TSV. See also the
None Code example
Invoke the
Export to Excel works with the ExcelML format. ExcelML is XML-based file format. It complies to the Microsoft XMLSS specification and is supported in Microsoft Office 2003 and later. * When you open export to Excel, you may receive the following message: "The file you are trying to open, 'file_name.xls', is in a different format than specified by the file extension. Verify that the file is not corrupted and is from a trusted source before opening this file. Do you want to open the file now?" The reason of this warning message is explained in details in the following post: excel-2007-extension-warning.aspx |
||||||||||||||
focus | Method | |||||||||||||
Focuses the Scheduler.
None Code examples
Invoke the
Try it: focus is invoked.
|
||||||||||||||
getAppointmentProperty | Method | |||||||||||||
Gets the value of an Appointment property.
None Code examples
Invoke the
|
||||||||||||||
getSelection | Method | |||||||||||||
Gets the cells selection. Returns an object with the following members:
Object Code examples
Invoke the
Try it: getSelection is invoked.
|
||||||||||||||
getAppointments | Method | |||||||||||||
Gets the appointments loaded in jqxScheduler. The return value is an Array of Objects. Each Object has the appointmentDataFields. See appointmentDataFields property.
Array Code examples
Invoke the
Try it: getAppointments is invoked.
|
||||||||||||||
getDataAppointments | Method | |||||||||||||
Gets the appointments loaded in jqxScheduler. The return value is an Array of Objects. Each Object has the fields defined in the dataAdapter's source object.
Array Code examples
Invoke the
Try it: getDataAppointments is invoked.
|
||||||||||||||
hideAppointmentsByResource | Method | |||||||||||||
Hides appointments by given resourceId.
None Code examples
Invoke the
|
||||||||||||||
openMenu | Method | |||||||||||||
Opens the context menu.
None Code examples
Invoke the
Try it: openMenu is invoked.
|
||||||||||||||
openDialog | Method | |||||||||||||
Opens the edit dialog.
None Code examples
Invoke the
Try it: openDialog is invoked.
|
||||||||||||||
selectAppointment | Method | |||||||||||||
Selects an appointment.
None Code examples
Invoke the
Try it: selectAppointment is invoked.
|
||||||||||||||
setAppointmentProperty | Method | |||||||||||||
Sets the value of an appointment's property.
None Code examples
Invoke the
|
||||||||||||||
selectCell | Method | |||||||||||||
Selects a cell.
None Code examples
Invoke the
Try it: selectCell is invoked.
|
||||||||||||||
showAppointmentsByResource | Method | |||||||||||||
Shows appointments by given resourceId.
None Code examples
Invoke the
|
||||||||||||||
scrollWidth | Method | |||||||||||||
Returns the scrollbable width.
Number Code examples
Invoke the
Try it: scrollWidth is invoked.
|
||||||||||||||
scrollHeight | Method | |||||||||||||
Returns the scrollbable height.
Number Code examples
Invoke the
Try it: scrollHeight is invoked.
|
||||||||||||||
scrollLeft | Method | |||||||||||||
Scrolls horizontally to a given position.
None Code examples
Invoke the
Try it: scrollLeft is invoked.
|
||||||||||||||
scrollTop | Method | |||||||||||||
Scrolls vertically to a given position.
None Code examples
Invoke the
Try it: scrollTop is invoked.
|