【问题标题】:Data table modify column css on inline edit数据表在线编辑修改列css
【发布时间】:2016-04-19 00:47:08
【问题描述】:

我的数据表上的列很少,内容很长,当它们出现在数据表上时会显示它们,

我想做的是当它触发“内联编辑”时,它应该在一行中显示未包装的列内容。目前,它显示类似,

当内联编辑事件触发时,是否可以将列的 css 修改为“不换行”?

【问题讨论】:

    标签: jquery datatables


    【解决方案1】:

    如果我明白你的意思,你为什么不这样做:

    //when event "inline_edit" is triggered in an td
    $( "td" ).on("inline_edit", function (){
        //change the CSS values for that td
        $( this ).css( "white-space", "nowrap" );
    });
    

    【讨论】:

    • 谢谢,这不会像数据表事件触发那样起作用。
    猜你喜欢
    • 2019-12-07
    • 2016-11-26
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多