This is the editable datagrid example with virtual scrollview.
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>jQuery EasyUI Demo</title>
<link rel="stylesheet" type="text/css" href="https://www.jeasyui.com/easyui/themes/default/easyui.css">
<link rel="stylesheet" type="text/css" href="https://www.jeasyui.com/easyui/themes/icon.css">
<script type="text/javascript" src="https://www.jeasyui.com/easyui/jquery.min.js"></script>
<script type="text/javascript" src="https://www.jeasyui.com/easyui/jquery.easyui.min.js"></script>
<script type="text/javascript" src="https://www.jeasyui.com/easyui/jquery.edatagrid.js"></script>
<script type="text/javascript" src="https://www.jeasyui.com/easyui/datagrid-scrollview.js"></script>
<script type="text/javascript">
$(function(){
var rows = [];
for(var i=1; i<=8000; i++){
var amount = Math.floor(Math.random()*1000);
var price = Math.floor(Math.random()*1000);
rows.push({
inv: 'Inv No '+i,
date: $.fn.datebox.defaults.formatter(new Date()),
name: 'Name '+i,
amount: amount,
price: price,
cost: amount*price,
note: 'Note '+i
});
}
$('#dg').edatagrid({
columns: [[
{field:'inv',title:'Inv No',width:100,editor:'textbox'},
{field:'date',title:'Date',width:100,editor:'datebox'},
{field:'name',title:'Name',width:100,editor:'textbox'},
{field:'amount',title:'Amount',width:100,editor:{type:'numberbox',options:{precision:0}}},
{field:'price',title:'Price',width:100,editor:'numberbox'},
{field:'note',title:'Note',width:100,editor:'textbox'}
]],
data: rows,
view: scrollview,
fitColumns: true
});
});
</script>
</head>
<body>
<table id="dg" style="width:800px;height:400px"
title="Editable DataGrid"
singleSelect="true"></table>
</body>
</html>