Hi,
If you open the Software category and start to edit a line, then try to click on the Hardware category, it won't open the folder.
Is this by design?
Ideally, I'd like it to save (or cancel) edits automatically and let the user go to whatever folder and item they click next. Or at least prompt them to save edits.
Thanks,
Mike
SmartClient Version: SC_SNAPSHOT-2011-01-06/LGPL Deployment (built 2011-01-06)
If you open the Software category and start to edit a line, then try to click on the Hardware category, it won't open the folder.
Is this by design?
Ideally, I'd like it to save (or cancel) edits automatically and let the user go to whatever folder and item they click next. Or at least prompt them to save edits.
Thanks,
Mike
Code:
var testData = [ {pk:0, orderID:8805, itemDescription:"Anti Virus Suite", category:"Software", shipDate:new Date(2009,10,20), quantity:2 , unitPrice:50 }, {pk:1, orderID:4833, itemDescription:"USB Ergonomic Keyboard", category:"Hardware", shipDate:new Date(2009,10,13), quantity:1 , unitPrice:99.99 }, {pk:2, orderID:9551, itemDescription:"Lumbar Support Cushion", category:"Hardware", shipDate:new Date(2010,1,2), quantity:1 , unitPrice:75 }, {pk:3, orderID:954, itemDescription:"USB Keyboard", category:"Hardware", shipDate:new Date(2009,10,20), quantity:12 , unitPrice:34.99 }, {pk:4, orderID:616, itemDescription:"Consulting Services", category:"Services", shipDate:new Date(2009,10,10), quantity:40 , unitPrice:100 }, {pk:5, orderID:8357, itemDescription:"Office Application Suite", category:"Software", shipDate:new Date(2010,2,5), quantity:14 , unitPrice:30 }, {pk:6, orderID:4582, itemDescription:"Anti Virus Suite", category:"Software", shipDate:new Date(2010,1,20), quantity:22 , unitPrice:50 }, {pk:7, orderID:9373, itemDescription:"On-site Training", category:"Services", shipDate:new Date(2009,10,20), quantity:20 , unitPrice:100 }, {pk:8, orderID:9311, itemDescription:"Software Development Kit", category:"Software", shipDate:new Date(2009,10,10), quantity:8 , unitPrice:249.99 }, {pk:9, orderID:7806, itemDescription:"15 inch flat panel monitor", category:"Hardware", shipDate:new Date(2009,11,12), quantity:4 , unitPrice:300 }, {pk:10, orderID:8620, itemDescription:"18 inch flat panel monitor", category:"Hardware", shipDate:new Date(2009,11,11), quantity:2 , unitPrice:375 }, {pk:11, orderID:629, itemDescription:"Office Productivity Suite", category:"Software", shipDate:new Date(2009,12,10), quantity:15 , unitPrice:64.99 }, {pk:12, orderID:1264, itemDescription:"Office Productivity Suite", category:"Software", shipDate:new Date(2009,12,20), quantity:2 , unitPrice:64.99 }, {pk:13, orderID:7100, itemDescription:"USB Ergonomic Keyboard", category:"Hardware", shipDate:new Date(2009,10,20), quantity:6 , unitPrice:99.99 }, {pk:14, orderID:9647, itemDescription:"Consulting Services", category:"Services", shipDate:new Date(2009,12,21), quantity:10 , unitPrice:100 }, {pk:15, orderID:8468, itemDescription:"USB Optical Mouse", category:"Hardware", shipDate:new Date(2009,10,10), quantity:5 , unitPrice:29.99 }, {pk:16, orderID:9496, itemDescription:"Off-site Training", category:"Services", shipDate:new Date(2010,1,1), quantity:35 , unitPrice:80 }, {pk:17, orderID:5124, itemDescription:"USB Stereo Headset", category:"Hardware", shipDate:new Date(2009,10,20), quantity:1 , unitPrice:69.99 }, {pk:18, orderID:1799, itemDescription:"Office Application Suite", category:"Software", shipDate:new Date(2009,11,2), quantity:22 , unitPrice:30 }, {pk:19, orderID:7020, itemDescription:"Consulting Services", category:"Services", shipDate:new Date(2009,12,20), quantity:100 , unitPrice:80 } ]; isc.DataSource.create({ ID:"orderItemLocalDS", clientOnly:true, testData:testData, fields:[ {name:"pk", type:"sequence", primaryKey:"true", hidden:"true"}, {name:"orderID", type:"integer", canEdit:false, title:"Order ID", pluralTitle:"Orders"}, {name:"itemDescription", type:"text", title:"Description"}, {name:"category", type:"text", title:"Category"}, {name:"shipDate", type:"date", title:"Ship Date"}, {name:"quantity", type:"integer", title:"Quantity"}, {name:"unitPrice", type:"float", title:"Price"} ] }); isc.ListGrid.create({ ID: "companyList", width:600, height:520, alternateRecordStyles:true, autoFetchData:true, dataSource:orderItemLocalDS, showAllRecords:true, groupByField:"category", groupStartOpen:"none", canEdit:true, editEvent:"click", fields:[ {name:"orderID", includeInRecordSummary:false, summaryFunction:"count"}, {name:"itemDescription"}, {name:"category", showGridSummary:true, getGridSummary:function (records, summaryField) { var seenCategories = {}; for (var i = 0; i < records.length; i++) { seenCategories[records[i].category] = true; } var totalCategories = isc.getKeys(seenCategories).length; return totalCategories + " Categories"; } }, {name:"shipDate", showGroupSummary:true, showGridSummary:false, summaryFunction:"max"}, {name:"quantity", showGroupSummary:false, showGridSummary:false}, {name:"unitPrice", showGroupSummary:false, showGridSummary:false, formatCellValue:function (value) { if (isc.isA.Number(value)) { return value.toCurrencyString("$"); } return value; } }, {name:"Total", type:"summary", recordSummaryFunction:"multiplier", summaryFunction:"sum", showGridSummary:true, showGroupSummary:true, align:"right", formatCellValue:function (value) { if (isc.isA.Number(value)) { return value.toCurrencyString("$"); } return value; } } ] });