5.7K Star 41.5K Fork 22.7K

GVP若依 / RuoYi

 / 详情

自己设置css样式后,冻结列高度还是未设置样式的高度

已完成
创建于  
2022-09-02 17:20

输入图片说明
输入图片说明

评论 (1)

Ab 创建了任务

测试是正常的,请提供出能复现问题的DEMO代码。

<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
	<th:block th:include="include :: header('冻结列')" />
	<style type="text/css">
		th{
			white-space: nowrap;
		}
		td{
			white-space: nowrap;
		}
	</style>
</head>
<body class="gray-bg">
     <div class="container-div">
		<div class="row">
			<div class="btn-group-sm" id="toolbar" role="group">
				<a class="btn btn-success">
	                <i class="fa fa-plus"></i> 新增
	            </a>
				<a class="btn btn-primary single disabled">
		            <i class="fa fa-edit"></i> 修改
		        </a>
				<a class="btn btn-danger multiple disabled">
		            <i class="fa fa-remove"></i> 删除
		        </a>
	        </div>
			<div class="col-sm-12 select-table table-striped">
				<table id="bootstrap-table"></table>
			</div>
		</div>
	</div>
    <div th:include="include :: footer"></div>
    <th:block th:include="include :: bootstrap-table-fixed-columns-js" />
    <script th:inline="javascript">
        var prefix = ctx + "demo/table";
        var datas = [[${@dict.getType('sys_normal_disable')}]];

        $(function() {
            var options = {
                url: prefix + "/list",
		        showSearch: false,
		        showRefresh: false,
		        showToggle: false,
		        showColumns: false,
		        fixedColumns: true,
    		    fixedNumber: 3,
    		    fixedRightNumber: 3,
    		    height: 300,
                columns: [{
		            checkbox: true
		        },
				{
					field : 'userId', 
					title : '用户ID'
				},
				{
					field : 'userCode', 
					title : '用户编号'
				},
				{
					field : 'userName', 
					title : '用户姓名'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userPhone', 
					title : '用户手机'
				},
				{
					field : 'userEmail', 
					title : '用户邮箱'
				},
				{
				    field : 'userBalance',
				    title : '用户余额'
				},
				{
                    field: 'status',
                    title: '用户状态',
                    align: 'center',
                    formatter: function(value, row, index) {
                    	return $.table.selectDictLabel(datas, value);
                    }
                },
				{
				    field : 'userBalance',
				    title : '测试1'
				},
				{
				    field : 'userBalance',
				    title : '测试2'
				},
				{
				    field : 'userBalance',
				    title : '测试3'
				},
				{
				    field : 'userBalance',
				    title : '测试4'
				},
				{
				    field : 'userBalance',
				    title : '测试5'
				},
				{
				    field : 'userBalance',
				    title : '测试6'
				},
				{
				    field : 'userBalance',
				    title : '测试7'
				},
				{
				    field : 'userBalance',
				    title : '测试8'
				},
				{
				    field : 'userBalance',
				    title : '测试9'
				},
				{
				    field : 'userBalance',
				    title : '测试10'
				},
				{
				    field : 'userBalance',
				    title : '测试11'
				},
				{
				    field : 'userBalance',
				    title : '测试12'
				},
				{
				    field : 'userBalance',
				    title : '测试13'
				},
				{
				    field : 'userBalance',
				    title : '测试14'
				},
				{
				    field : 'userBalance',
				    title : '测试15'
				},
				{
				    field : 'userBalance',
				    title : '测试16'
				}]
            };
            $.table.init(options);
        });
    </script>
</body>
</html>
若依 任务状态待办的 修改为已完成

登录 后才可以发表评论

状态
负责人
里程碑
Pull Requests
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
开始日期   -   截止日期
-
置顶选项
优先级
参与者(2)
1151004 y project 1578942802
Java
1
https://gitee.com/y_project/RuoYi.git
git@gitee.com:y_project/RuoYi.git
y_project
RuoYi
RuoYi

搜索帮助