固定表头,左右滑动条
Posted zhangwensi
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了固定表头,左右滑动条相关的知识,希望对你有一定的参考价值。
<div style="width:100%; height:350px; overflow-x:scroll;overflow-y:auto;">
<table class="table table-bordered" border="1" rules="all" style="width:100%; height:200px; text-align:center; table-layout: fixed;word-break: break-all; word-wrap: break-word;">
<tr>
<th style="width:150px;color: white;background: #4F81BD;">版本编码</th>
<th style="width:150px;color: white;background: #4F81BD;">本次预测时间</th>
<th style="width:150px;color: white;background: #4F81BD;">预测月份</th>
<th style="width:150px;color: white;background: #4F81BD;">工作天数</th>
<th style="width:150px;color: white;background: #4F81BD;">高温津贴</th>
<th style="width:150px;color: white;background: #4F81BD;">部门</th>
<th style="width:150px;color: white;background: #4F81BD;">课别</th>
<th style="width:150px;color: white;background: #4F81BD;">系别</th>
<th style="width:150px;color: white;background: #4F81BD;">工程属性</th>
<th style="width:150px;color: white;background: #4F81BD;">车间代码</th>
<th style="width:150px;color: white;background: #4F81BD;">预测类别</th>
<th style="width:150px;color: white;background: #4F81BD;">生产台数(制管计算) </th>
<th style="width:150px;color: white;background: #4F81BD;">生产产值(千元) </th>
<th style="width:150px;color: white;background: #4F81BD;">PSI版本 </th>
<th style="width:150px;color: white;background: #4F81BD;">班次</th>
<th style="width:150px;color: white;background: #4F81BD;">编制人员数量</th>
<th style="width:150px;color: white;background: #4F81BD;">人均加班1.5倍工时数 </th>
<th style="width:150px;color: white;background: #4F81BD;">人均加班2倍工时数 </th>
<th style="width:150px;color: white;background: #4F81BD;">出勤率(%) </th>
<th style="width:150px;color: white;background: #4F81BD;">跨月调假(H)(调入+,调出-)</th>
<th style="width:150px;color: white;background: #4F81BD;">中间入职或离职无出勤扣减(H) </th>
<th style="width:150px;color: white;background: #4F81BD;">借入借出(H)(借入+,借出-)</th>
<th style="width:150px;color: white;background: #4F81BD;">合理化前工时(H) </th>
<th style="width:150px;color: white;background: #4F81BD;">合理化后工时(H) </th>
<th style="width:150px;color: white;background: #4F81BD;">基本工资(千元) </th>
<th style="width:150px;color: white;background: #4F81BD;">加班费(千元) </th>
<th style="width:150px;color: white;background: #4F81BD;">社保、福利费(千元) </th>
<th style="width:150px;color: white;background: #4F81BD;">合理化前_BP RATE</th>
<th style="width:150px;color: white;background: #4F81BD;">规定内损失时间(H)</th>
<th style="width:150px;color: white;background: #4F81BD;">理论出勤计算比率(%) </th>
<th style="width:150px;color: white;background: #4F81BD;">创建时间</th>
</tr>
<tbody id="tContain">
<!-- <tr>
<td>1</td>
<td>这是一篇标题很长的文章用来测试表格的测试标题</td>
<td>这是一篇标题很长的文章用来测试表格不被太多列挤得变形的描述...</td>
<td>管理员</td>
<td>3000</td>
<td>120.68</td>
<td>1200</td>
<td>测试啊测试test</td>
<td>123</td>
<td>20</td>
<td>17</td>
<td>5</td>
<td>2018-03-06 12:00:00</td>
<td>2018-03-07 15:00:00</td>
</tr> -->
</tbody>
</table>
</div>
以上是关于固定表头,左右滑动条的主要内容,如果未能解决你的问题,请参考以下文章