Commit ef1937b7 authored by Project Open's avatar Project Open

- WIP

parent dfc48c49
......@@ -50,7 +50,20 @@ function launchTimesheetWeeklyLogging(){
// Row-Editor for the hour grid
var rowEditing = Ext.create('Ext.grid.plugin.RowEditing', {
clicksToMoveEditor: 2,
clicksToEdit: 1,
clicksToMoveEditor: 1,
listeners: {
edit: function(editor, context, eOpts) {
// Check that the endTime is later than startTime
context.record.save();
}
}
});
// Cell-Editor for the hour grid
var cellEditing = Ext.create('Ext.grid.plugin.CellEditing', {
clicksToEdit: 1,
clicksToMoveEditor: 1,
listeners: {
edit: function(editor, context, eOpts) {
// Check that the endTime is later than startTime
......@@ -114,13 +127,13 @@ function launchTimesheetWeeklyLogging(){
editor: { xtype: 'pocombotree', store: taskTreeStore, queryMode: 'local', displayField: 'project_name', valueField: 'id'}
},
// { text: "Date", xtype: 'datecolumn', dataIndex: 'day', renderer: Ext.util.Format.dateRenderer('Y-m-d'), editor: {xtype: 'datefield',allowBlank: true}},
{ text: "Mon", width: 50, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Tue", width: 50, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Wed", width: 50, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Thu", width: 50, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Fri", width: 50, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Sat", width: 50, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Sun", width: 50, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Mon", width: 60, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Tue", width: 60, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Wed", width: 60, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Thu", width: 60, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Fri", width: 60, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Sat", width: 60, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
{ text: "Sun", width: 60, dataIndex: 'hours', editor: { xtype: 'numberfield', minValue: 0 }},
// { text: "Note", flex: 1, dataIndex: 'note', editor: { allowBlank: true }}
]
});
......@@ -247,7 +260,7 @@ function launchTimesheetWeeklyLogging(){
*/
onGridBeforeEdit: function(editor, context, eOpts) {
console.log('GanttButtonController.onGridBeforeEdit');
console.log(context.record);
// console.log(context.record);
// Return true to indicate to the editor that it's OK to edit
return true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment