@@ -74,10 +74,6 @@ class GridView extends Component {
7474 * @member {Boolean} isScrolling_=false
7575 */
7676 isScrolling_ : false ,
77- /**
78- * @member {Object} recordVnodeMap={}
79- */
80- recordVnodeMap : { } ,
8177 /**
8278 * @member {String} role='rowgroup'
8379 */
@@ -462,8 +458,6 @@ class GridView extends Component {
462458 trCls = me . getTrClass ( record , rowIndex ) ,
463459 config , column , endIndex , gridRow , i , startIndex ;
464460
465- me . recordVnodeMap [ id ] = rowIndex ;
466-
467461 if ( rowIndex % 2 !== 0 ) {
468462 trCls . push ( 'neo-even' )
469463 }
@@ -651,10 +645,20 @@ class GridView extends Component {
651645
652646 /**
653647 * @param {String } rowId
654- * @returns {Object }
648+ * @returns {Record }
655649 */
656650 getRecordByRowId ( rowId ) {
657- return this . store . getAt ( this . recordVnodeMap [ rowId ] )
651+ let recordId = rowId . split ( '__' ) [ 2 ] ,
652+ { store} = this ,
653+ { model} = store ,
654+ keyField = model ?. getField ( store . getKeyProperty ( ) ) ,
655+ keyType = keyField ?. type ?. toLowerCase ( ) ;
656+
657+ if ( keyType === 'int' || keyType === 'integer' ) {
658+ recordId = parseInt ( recordId )
659+ }
660+
661+ return store . get ( recordId )
658662 }
659663
660664 /**
@@ -663,7 +667,7 @@ class GridView extends Component {
663667 * @returns {String }
664668 */
665669 getRowId ( record , index ) {
666- return `${ this . id } __tr__${ record [ this . store . keyProperty ] } `
670+ return `${ this . id } __tr__${ record [ this . store . getKeyProperty ( ) ] } `
667671 }
668672
669673 /**
0 commit comments