Package: | Ext.ensible.cal |
Defined In: | EventRecord.js |
Class: | EventRecord |
Extends: | Object |
This is the Record specification for calendar event data used by the CalendarPanel's underlying store. It can be overridden as necessary to customize the fields supported by events, although the existing field definition names should not be altered. If your model fields are named differently you should update the mapping configs accordingly.
The only required fields when creating a new event record instance are StartDate and EndDate. All other fields are either optional or will be defaulted if blank.
Here is a basic example for how to create a new record of this type:
rec = new Ext.ensible.cal.EventRecord({
StartDate: '2101-01-12 12:00:00',
EndDate: '2101-01-12 13:30:00',
Title: 'My cool event',
Notes: 'Some notes'
});
If you have overridden any of the record's data mappings via the EventMappings object
you may need to set the values using this alternate syntax to ensure that the field names match up correctly:var M = Ext.ensible.cal.EventMappings,
rec = new Ext.ensible.cal.EventRecord();
rec.data[M.StartDate.name] = '2101-01-12 12:00:00';
rec.data[M.EndDate.name] = '2101-01-12 13:30:00';
rec.data[M.Title.name] = 'My cool event';
rec.data[M.Notes.name] = 'Some notes';
Property | Defined By | |
---|---|---|
animDuration : Number The animation duration in seconds -
MUST BE less than Ext.dd.ScrollManager.frequency! (defaults to .4) | EventRecord | |
animate : Boolean True to animate the scroll (defaults to true) | EventRecord | |
frequency : Number The frequency of scrolls in milliseconds (defaults to 500) | EventRecord | |
hthresh : Number The number of pixels from the right or left edge of a container the pointer needs to be to
trigger scrolling (default... The number of pixels from the right or left edge of a container the pointer needs to be to
trigger scrolling (defaults to 25) | EventRecord | |
increment : Number The number of pixels to scroll in each scroll increment (defaults to 50) | EventRecord | |
vthresh : Number The number of pixels from the top or bottom edge of a container the pointer needs to be to
trigger scrolling (default... The number of pixels from the top or bottom edge of a container the pointer needs to be to
trigger scrolling (defaults to 25) | EventRecord |
Method | Defined By | |
---|---|---|
EventRecord( [Object data ], [Object id ] )
Parameters:
| EventRecord | |
create()
:
Function <static> Reconfigures the default record definition based on the current EventMappings
object. See the header documentation fo... <static> Reconfigures the default record definition based on the current EventMappings
object. See the header documentation for Ext.ensible.cal.EventMappings for complete details and
examples of reconfiguring an EventRecord. Parameters:
| EventRecord | |
refreshCache()
:
void Manually trigger a cache refresh. Manually trigger a cache refresh. Parameters:
| EventRecord | |
register( Mixed/Array el )
:
voidRegisters new overflow element(s) to auto scroll Registers new overflow element(s) to auto scroll Parameters:
| EventRecord | |
unregister( Mixed/Array el )
:
voidUnregisters overflow element(s) so they are no longer scrolled Unregisters overflow element(s) so they are no longer scrolled Parameters:
| EventRecord |