I've seen some strange stuff but this one takes the cake. This app works fine in Val 5.2. I only have one version of source code for app for both 5.2 and 6, the app runs directly on source code (no build).
This is that technique when you return store data from server and build in properties. The most common is the "totalProperty" where you send total records to paging toolbar.
In this case, I return some totals to display at top of grid. So store has the keepRawData parameter. I use the onload event to fetch those properties and display in fields on toolbar of grid. Works fine in 5.2, I get a null object error is Val 6 (extjs 7). It fails on statement below, saying totalCULbs can't be retrieved from null.
What makes no sense is that I use this technique in many apps and they all work, just this one does not. This app does have far more properties than other but I checked in debugger, the reply from server is fine. I don't get this one at all.
Line 66 of maingrid is below, along with definition in Store.
Uncaught TypeError: Cannot read property 'totalCULbs' of null
onLoad @ :7060/dev/FirmOrderInq/view/MainGrid.js?_dc=1600188842827:66
fire @ :7060/ext/build/ext-all.js:20
doFireEvent @ :7060/ext/build/ext-all.js:20
b.doFireEvent @ :7060/ext/build/ext-all.js:20
fireEventArgs @ :7060/ext/build/ext-all.js:20
fireEvent @ :7060/ext/build/ext-all.js:20
onProxyLoad @ :7060/ext/build/ext-all.js:20
triggerCallbacks @ :7060/ext/build/ext-all.js:20
setCompleted @ :7060/ext/build/ext-all.js:20
setSuccessful @ :7060/ext/build/ext-all.js:20
process @ :7060/ext/build/ext-all.js:20
processResponse @ :7060/ext/build/ext-all.js:20
(anonymous) @ :7060/ext/build/ext-all.js:20
callback @ :7060/ext/build/ext-all.js:20
onComplete @ :7060/ext/build/ext-all.js:20
onStateChange @ :7060/ext/build/ext-all.js:20
(anonymous) @ :7060/ext/build/ext-all.js:20
elevate @ :7060/ext/build/ext-all.js:20
(anonymous) @ :7060/ext/build/ext-all.js:20
a.<computed> @ :7060/resources/valence.js:1
D @ :7060/resources/valence.js:1
b @ :7060/resources/valence.js:1
b @ :7060/resources/valence.js:1
p @ :7060/resources/valence.js:1
h.onreadystatechange @ :7060/resources/valence.js:1
This is that technique when you return store data from server and build in properties. The most common is the "totalProperty" where you send total records to paging toolbar.
In this case, I return some totals to display at top of grid. So store has the keepRawData parameter. I use the onload event to fetch those properties and display in fields on toolbar of grid. Works fine in 5.2, I get a null object error is Val 6 (extjs 7). It fails on statement below, saying totalCULbs can't be retrieved from null.
What makes no sense is that I use this technique in many apps and they all work, just this one does not. This app does have far more properties than other but I checked in debugger, the reply from server is fine. I don't get this one at all.
Line 66 of maingrid is below, along with definition in Store.
Uncaught TypeError: Cannot read property 'totalCULbs' of null
onLoad @ :7060/dev/FirmOrderInq/view/MainGrid.js?_dc=1600188842827:66
fire @ :7060/ext/build/ext-all.js:20
doFireEvent @ :7060/ext/build/ext-all.js:20
b.doFireEvent @ :7060/ext/build/ext-all.js:20
fireEventArgs @ :7060/ext/build/ext-all.js:20
fireEvent @ :7060/ext/build/ext-all.js:20
onProxyLoad @ :7060/ext/build/ext-all.js:20
triggerCallbacks @ :7060/ext/build/ext-all.js:20
setCompleted @ :7060/ext/build/ext-all.js:20
setSuccessful @ :7060/ext/build/ext-all.js:20
process @ :7060/ext/build/ext-all.js:20
processResponse @ :7060/ext/build/ext-all.js:20
(anonymous) @ :7060/ext/build/ext-all.js:20
callback @ :7060/ext/build/ext-all.js:20
onComplete @ :7060/ext/build/ext-all.js:20
onStateChange @ :7060/ext/build/ext-all.js:20
(anonymous) @ :7060/ext/build/ext-all.js:20
elevate @ :7060/ext/build/ext-all.js:20
(anonymous) @ :7060/ext/build/ext-all.js:20
a.<computed> @ :7060/resources/valence.js:1
D @ :7060/resources/valence.js:1
b @ :7060/resources/valence.js:1
b @ :7060/resources/valence.js:1
p @ :7060/resources/valence.js:1
h.onreadystatechange @ :7060/resources/valence.js:1
Code:
var amt = st.getProxy().getReader().rawData.totalCULbs.toFixed(0); reader : { type : 'json', root : 'FIRMOPNDS', keepRawData: true, totalProperty: 'totalCount', totalCULbs: 'totalCULbs', totalCUAmt: 'totalCUAmt', totalZNAmt: 'totalZNAmt', totalZNLbs: 'totalZNLbs', totalCUDiff: 'totalCUDiff', prcDate: 'prcDate', stdCUPrc: 'stdCUPrc', stdZNPrc: 'stdZNPrc', totalZNDiff: 'totalZNDiff' },
Comment