From d792678f89622023eaefeaedca2052230f278d1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B4=A4=E5=BF=83?= <3277200+sentsim@users.noreply.github.com> Date: Sun, 10 Sep 2023 20:19:42 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20table=20=E7=94=A8=E4=BE=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- examples/table-test.html | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/examples/table-test.html b/examples/table-test.html index dc1b4ffe..a0f69a0c 100644 --- a/examples/table-test.html +++ b/examples/table-test.html @@ -155,11 +155,13 @@ layui.use(['table', 'dropdown'], function(){ // escape: false, editTrigger: 'dblclick', // cellMaxWidth: 320 + // cellExpandedWidth: 160, // 单元格默认展开后的宽度 + // cellExpandedStyle: 'tips', // 单元格默认展开风格 cols: !1 ? test_cols : [[ {type: 'checkbox', fixed: 'left'}, // {type: 'numbers', fixed: 'left'}, {field:'id', title:'ID', width:80, fixed: 'left', unresize: true, sort: true, totalRowText: '合计:'}, - {field:'username', title:'用户名 ', width:120, edit: function(d){ + {field:'username', expandedStyle: 'tips', title:'用户名 ', width:120, edit: function(d){ return !d.LAY_DISABLED; }, templet: '#usernameTpl'}, {field:'xxx', title:'测试', edit: 'text'}, @@ -173,7 +175,7 @@ layui.use(['table', 'dropdown'], function(){ var td = obj.td(this.field); //获取当前 td return td.find('select').val(); }}, - {field:'sign', title:'签名', minWidth: 200, expandedWidth: 350, style:'color: #5FB878', edit: 'textarea'}, + {field:'sign', title:'签名', minWidth: 200, style:'color: #5FB878', edit: 'textarea'}, {field: 'experience', title: '积分', width: 100, sort: true, align:'center', totalRow: !1 ? true : '{{= d.TOTAL_NUMS }} 分 😊', templet: '
{{= d[d.LAY_COL.field] }}
'}, {field:'ip', title:'IP', width: 120, align: 'right'}, {field:'checkin', title:'打卡', width: 100, sort: true, totalRow: '{{= d.TOTAL_ROW.checkin }} 次'},