Hi there,
We are getting a js-error working with a datasource.
We can reproduce it by scrolling at the listgrid till it begans to redraw.
Then we call a "invalidateCache()" on the listgrid which results in 2 seperate datasource-requests to laod the visible objects.
After this we are getting this error:
ISC_DataBinding.js line: 44354
I could not create a example, which reproduces this issue, becaue it seems there is the need for large dataset which could be requested by the datasource.
In my case the first call of this the loop interates over the localdata, where the localData.length is 60 so it iterates through 0-59.
Even after the scrolling down the listGrid.data.localData.length is 60. But after invalidateCache() localData.length is 100, and the iteration stops.
There seems to be something wrong, i don't know since when this js-error occured. We are working with the latest nightly SmartClient_v100p_2015-03-09_Pro and it happens in all browsers.
Best Regards
Simon
This is the console-debug
We are getting a js-error working with a datasource.
We can reproduce it by scrolling at the listgrid till it begans to redraw.
Then we call a "invalidateCache()" on the listgrid which results in 2 seperate datasource-requests to laod the visible objects.
After this we are getting this error:
ISC_DataBinding.js line: 44354
Code:
TypeError: localData[i] is undefined for (i = 0; i < localData.length; i++) localData[i]._localDataIndex = i;
In my case the first call of this the loop interates over the localdata, where the localData.length is 60 so it iterates through 0-59.
Even after the scrolling down the listGrid.data.localData.length is 60. But after invalidateCache() localData.length is 100, and the iteration stops.
There seems to be something wrong, i don't know since when this js-error occured. We are working with the latest nightly SmartClient_v100p_2015-03-09_Pro and it happens in all browsers.
Best Regards
Simon
This is the console-debug
Code:
12:09:20.779:XRP9:INFO:ListGrid:translationsListGrid_4:Dropping explicitly-named field translationsListGridGeneratedIndex because it is marked canView: false 12:09:20.851:XRP9:DEBUG:RPCManager:Grabbed prompt from first request that defined one: Suche Datensätze die den Kriterien entsprechen... 12:09:20.853:XRP9:INFO:RPCManager:sendQueue[1]: 1 RPCRequest(s); transport: xmlHttpRequest; target: ScListGridTransport?viewNumber=4&id=translationsListGrid 12:09:20.854:XRP9:DEBUG:RPCManager:XMLHttpRequest GET from ScListGridTransport?viewNumber=4&id=translationsListGrid with fields: {operationType: "fetch", sortBy: Array[1], start: 0, end: 40, sessionId: "B1CF005FC361236392640048C7C23141FF445061"} full URL string: ScListGridTransport?viewNumber=4&id=translationsListGrid&operationType=fetch&sortBy=translationIdGridField&start=0&end=40&sessionId=B1CF005FC361236392640048C7C23141FF445061 12:09:20.889:XRP9:INFO:RPCManager:sendQueue called with no current queue, ignoring 12:09:20.902:XRP9:DEBUG:ListGrid:translationsListGrid_4:delaying adjustOverflow: child resize 12:09:21.614:XRP2:INFO:RPCManager:transaction 1 arrived after 759ms 12:09:21.615:XRP2:DEBUG:RPCManager:Result string for transaction 1: "{ "totalRows":60, "endRow":40, "startRow":0, "resultData": [ { "translationIdGridField":"firstKey", "translationsListGridGeneratedIndex":"1", "translationGridField":"Meine Übersetzung", "translationTimeStampGridField":"17.04.14 11:37" }, //shortened { "translationIdGridField":"lastKey", "translationsListGridGeneratedIndex":"60", "translationGridField":"Meine Übersetzung", "translationTimeStampGridField":"03.12.13 10:44" } ] } " 12:09:21.620:XRP2:INFO:RPCManager:rpcResponse(unstructured) results -->"{ "totalRows":60, "endRow":40, "startRow":0, "resultData": [ { "translationIdGridField":"firstKey", "translationsListGridGeneratedIndex":"1", "translationGridField":"Meine Übersetzung", "translationTimeStampGridField":"17.04.14 11:37" }, // shortened { "translationIdGridField":"lastKey", "translationsListGridGeneratedIndex":"60", "translationGridField":"Meine Übersetzung", "translationTimeStampGridField":"03.12.13 10:44" } ] } "<-- 12:09:21.775:TMR4:DEBUG:ListGrid:translationsListGrid_4:delaying adjustOverflow: childDraw 12:09:28.462:IFCS9:DEBUG:ListGrid:languageComboBoxItem_4_separateValuesList:setRect: {left: null, top: null, width: "100%", height: null} 12:09:30.218:IFCS9:INFO:RPCManager:sendQueue called with no current queue, ignoring 12:09:30.247:IBLR0:INFO:RPCManager:sendQueue[2]: 1 RPCRequest(s); transport: xmlHttpRequest; target: ScEventTransport 12:09:30.248:IBLR0:DEBUG:RPCManager:XMLHttpRequest POST to ScEventTransport contentType: application/x-www-form-urlencoded; charset=UTF-8 with body -->eventParameters={"rowNum":null,"colNum":null,"value":"1"}&sessionId=B1CF005FC361236392640048C7C23141FF445061&viewNumber=4&eventNumber=3&grids={"translationsListGrid_4":{"sortSpecifier":[{"property":"translationIdGridField","direction":"ascending","normalizer":"text","primarySort":true}],"clwDataSourceSelectedRecords":null,"selectedGeneratedIndexes":[]}}&trees={}&forms={"toolStripForm_4":{"showTranslationIdsCheckboxItem_4":{"value":false},"languageComboBoxItem_4":{"value":"1"},"prefixComboBoxItem_4":{"value":1},"onlyCurrentViewCheckboxItem_4":{"value":true}},"buttonForm_4":{},"slideshowToolStripForm_4":{"slideshowLanguageComboBoxItem_4":{"value":2},"slideshowComboBoxItem_4":{"value":1}},"helpToolStripForm_4":{"helpLanguageComboBoxItem_4":{"value":2},"helpViewComboBoxItem_4":{"value":185}}}&richTextEditors={"helpRichTextEditor_4":{"value":"<p>Klicken Sie auf die noch offenen Aufgaben. Die Aufgaben sind nach den Rollen, die Sie in HRworks haben, gruppiert.</p><p>Wenn Sie auf die Aufgabe klicken, werden Sie direkt in das Menü geführt, in dem Sie die noch offenen Arbeiten durchführen und beenden können.</p><p>Mit den Buttons “Neue Reise”, “Neue Belegmappe” und “Neue Abwesenheit” gelangen Sie direkt in das entsprechende Menü, um eine neue Reise/Belegmappe/Abwesenheit zu erfassen.</p><p><strong>Hinweis:</strong><br />Wenn Sie zum ersten Mal Reisekosten in HRworks erfassen oder dies sehr selten tun, hilft Ihnen der Assistent. Klicken Sie auf den Button "Assistent", um diesen zu starten. Wählen Sie aus, durch welchen Vorgang Sie geleitet werden möchten und folgen Sie den Anweisungen.<br />Schauen Sie sich auch die Videos im Lerncenter an. </p>","changed":false},"slideshowAceEditor_4":{"value":"<style>\n.hrw-slide-introtext{padding:10px 0px 20px 0px;font-size:13px;}\n.hrw-slide-head{text-align:center;padding-bottom:20px}\n.hrw-slide-head img{border:1px solid #AAA;box-shadow: 5px 5px 5px #888;}\n.hrw-slide-caption{vertical-align:top;font-size:13px;}\n.hrw-slide-table{border-spacing: 10px;border-collapse: separate;}\n</style>\n<h1>Willkommen in HRworks</h1>\n<div class='hrw-slide-introtext'>Im Folgenden erhalten Sie in 40 Sekunden die Grundlagen für Ihren erfolgreichen Einstieg in HRworks.</div>\n<div class='hrw-slide-head'>\n\t<img src='%DISTRI%/HRworks/images/slideshow/slideshow1_de.png'>\n</div>\n<div class='hrw-slide-caption'>\n<b>Zu erledigen:</b> Erinnert Sie an offene ToDo’s und führt Sie durch Klick auf die Aufgabe ins entsprechende Menü.\n</div>","changed":null}}<-- 12:09:30.325:XRP4:INFO:RPCManager:transaction 2 arrived after 76ms 12:09:30.326:XRP4:DEBUG:RPCManager:Result string for transaction 2: "translationsListGrid_4.setShowFilterEditor(false);translationsListGrid_4.invalidateCache();transportEventsBak=transportEvents;transportEvents=true;translationsListGrid_4.fetchData();transportEvents=transportEventsBak;toolStripForm_4.markForRedraw();helpRichTextEditor_4.setUnchanged();durationStaticText_1.setValue("0 ms");" 12:09:30.326:XRP4:INFO:RPCManager:rpcResponse(unstructured) results -->"translationsListGrid_4.setShowFilterEditor(false);translationsListGrid_4.invalidateCache();transportEventsBak=transportEvents;transportEvents=true;translationsListGrid_4.fetchData();transportEvents=transportEventsBak;toolStripForm_4.markForRedraw();helpRichTextEditor_4.setUnchanged();durationStaticText_1.setValue("0 ms");"<-- 12:09:30.332:XRP4:DEBUG:ListGrid:translationsListGrid_4:Setting filter to: { } 12:09:30.336:XRP4:DEBUG:RPCManager:Grabbed prompt from first request that defined one: Suche Datensätze die den Kriterien entsprechen... 12:09:30.337:XRP4:INFO:RPCManager:sendQueue[3]: 1 RPCRequest(s); transport: xmlHttpRequest; target: ScListGridTransport?viewNumber=4&id=translationsListGrid 12:09:30.339:XRP4:DEBUG:RPCManager:XMLHttpRequest GET from ScListGridTransport?viewNumber=4&id=translationsListGrid with fields: {operationType: "fetch", sortBy: Array[1], start: 40, end: 80, sessionId: "B1CF005FC361236392640048C7C23141FF445061"} full URL string: ScListGridTransport?viewNumber=4&id=translationsListGrid&operationType=fetch&sortBy=translationIdGridField&start=40&end=80&sessionId=B1CF005FC361236392640048C7C23141FF445061 12:09:30.461:TMR5:DEBUG:ListGrid:translationsListGrid_4:delaying adjustOverflow: childMoved 12:09:30.769:TMR1:DEBUG:RPCManager:Grabbed prompt from first request that defined one: Suche Datensätze die den Kriterien entsprechen... 12:09:30.769:TMR1:INFO:RPCManager:sendQueue[4]: 1 RPCRequest(s); transport: xmlHttpRequest; target: ScListGridTransport?viewNumber=4&id=translationsListGrid 12:09:30.770:TMR1:DEBUG:RPCManager:XMLHttpRequest GET from ScListGridTransport?viewNumber=4&id=translationsListGrid with fields: {operationType: "fetch", sortBy: Array[1], start: 0, end: 40, sessionId: "B1CF005FC361236392640048C7C23141FF445061"} full URL string: ScListGridTransport?viewNumber=4&id=translationsListGrid&operationType=fetch&sortBy=translationIdGridField&start=0&end=40&sessionId=B1CF005FC361236392640048C7C23141FF445061 12:09:31.005:XRP2:INFO:RPCManager:transaction 3 arrived after 666ms 12:09:31.006:XRP2:DEBUG:RPCManager:Result string for transaction 3: "{ "totalRows":60, "endRow":60, "startRow":40, "resultData": [ { "translationIdGridField":"firstKey", "translationsListGridGeneratedIndex":"41", "translationGridField":"My Translation", "translationTimeStampGridField":"16.07.12 17:06" }, // shorten { "translationIdGridField":"lastKey", "translationsListGridGeneratedIndex":"100", "translationGridField":"My Translation", "translationTimeStampGridField":"11.02.11 17:45" } ] } " 12:09:31.008:XRP2:INFO:RPCManager:rpcResponse(unstructured) results -->"{ "totalRows":60, "endRow":60, "startRow":40, "resultData": [ { "translationIdGridField":"firstKey", "translationsListGridGeneratedIndex":"41", "translationGridField":"My Translation", "translationTimeStampGridField":"16.07.12 17:06" }, // shortened { "translationIdGridField":"lastKey", "translationsListGridGeneratedIndex":"100", "translationGridField":"My Translation", "translationTimeStampGridField":"11.02.11 17:45" } ] } "<-- 12:09:31.018:XRP2:WARN:Log:Attempt to sort array by property hit null entry where a record should be. Array:[Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, Obj, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef, undef ] 12:09:31.044:XRP2:INFO:RPCManager:sendQueue[5]: 1 RPCRequest(s); transport: xmlHttpRequest; target: HrwScJavaScriptErrorTransport 12:09:31.045:XRP2:DEBUG:RPCManager:XMLHttpRequest POST to HrwScJavaScriptErrorTransport contentType: application/x-www-form-urlencoded; charset=UTF-8 with body -->errorMsg=TypeError: localData[i] is undefined&url=http://localhost/isomorphic/system/modules/ISC_DataBinding.js&lineNumber=44357&sessionId=null&viewNumber=null&clwVersion=3.2.69&clwDate=16.02.2015&scVersion=v10.0p_2015-03-09<-- 12:09:31.221:XRP3:INFO:RPCManager:transaction 5 arrived after 175ms 12:09:31.222:XRP3:DEBUG:RPCManager:Result string for transaction 5: "alert("Error in JavaScript - press F5 to reload");" 12:09:31.222:XRP3:INFO:RPCManager:rpcResponse(unstructured) results -->"alert("Error in JavaScript - press F5 to reload");"<-- 12:09:31.620:XRP5:INFO:RPCManager:transaction 4 arrived after 850ms 12:09:31.622:XRP5:DEBUG:RPCManager:Result string for transaction 4: "{ "totalRows":60, "endRow":40, "startRow":0, "resultData": [ { "translationIdGridField":"firstKey", "translationsListGridGeneratedIndex":"1", "translationGridField":"My Translation", "translationTimeStampGridField":"16.07.12 17:06" }, // shortened { "translationIdGridField":"lastKey", "translationsListGridGeneratedIndex":"60", "translationGridField":"My Translation", "translationTimeStampGridField":"11.02.11 17:45" } ] } " 12:09:31.627:XRP5:INFO:RPCManager:rpcResponse(unstructured) results -->"{ "totalRows":60, "endRow":40, "startRow":0, "resultData": [ { "translationIdGridField":"firstKey", "translationsListGridGeneratedIndex":"1", "translationGridField":"My Translation", "translationTimeStampGridField":"16.07.12 17:06" }, //shortened { "translationIdGridField":"lastKey", "translationsListGridGeneratedIndex":"60", "translationGridField":"My Translation", "translationTimeStampGridField":"11.02.11 17:45" } ] } "<--
Comment