就直接贴代码了
里边用了vue的v-for循环数据可以忽略不计,主要是css样式*
<table border="1" cellspacing="0" cellpadding="0" class="kcdata" height="500px">
<thead>
<tr>
<th>序号</th>
<th>名称</th>
<th>库存</th>
</tr>
</thead>
<tbody :style="{height:(h-200)+'px'}">//给tbody固定高
<tr v-for="(i,index) in 100" :key="index" class="cptr">
<td style="text-align:center">{
{index+1}}</td>
<td style="text-align:center">12345</td>
<td style="text-align: