Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- initComponent : function() {
- var me = this;
- // Store holding all the resources
- var resourceStore = Ext.create('Sch.data.ResourceStore', {
- model : 'Sch.examples.eventtools.model.Resource',
- sortInfo : { field : 'name', direction : 'ASC' },
- data : [
- { Id : 'a', name : 'Rob' },
- { Id : 'b', name : 'Mike' },
- { Id : 'c', name : 'Kate'},
- { Id : 'd', name : 'Lisa'},
- { Id : 'e', name : 'Dave' },
- { Id : 'f', name : 'Arnold'},
- { Id : 'g', name : 'Lee'},
- { Id : 'x', name : 'Xxx'},
- ]
- });
- // Store holding all the events
- var eventStore = Ext.create('Sch.data.EventStore', {
- model : 'Sch.examples.eventtools.model.Event',
- data : [
- {
- Name : 'Room11',
- StartDate : '2017-06-21 18:40',
- EndDate : '2017-06-21 19:00',
- ResourceId : 'g',
- Draggable : true,
- Deletable : true
- },
- {
- Name : 'Room2',
- StartDate : '2017-06-21 10:00',
- EndDate : '2017-06-21 13:00',
- ResourceId : 'f',
- Draggable : true,
- Deletable : false
- },
- {
- Name : 'Room3',
- StartDate : '2017-06-21 11:00',
- EndDate : '2017-06-21 14:00',
- ResourceId : 'b',
- Draggable : true,
- Deletable : true
- },
- ]
- });
- Ext.apply(me, {
- resourceStore : resourceStore,
- eventStore : eventStore,
- });
- me.callParent();
- },});
Add Comment
Please, Sign In to add comment