• ASP.NET ZERO 学习 JTable的使用子表闭合功能


    双击子表自动判定开闭功能

    //CHILD TABLE DEFINITION FOR "PHONE NUMBERS"
    Phones: {
        title: '',
         '5%',
        sorting: false,
        edit: false,
        create: false,
        display: function (studentData) {
    
            var $img = $('<img src="/Content/images/Misc/phone.png" title="Edit phone numbers" />'), //Create an image that will be used to open child table
                parentTable = $("#StudentTableContainer"); 
    
            //Open | Close child table when user clicks the image
            $img.click(function(){
    
                var tr = $(this).parents("tr"),
                    isChildRowOpen = parentTable.jtable("isChildRowOpen", tr );
    
                if( isChildRowOpen ){
                    $( parentTable.jtable("getChildRow", tr ) ).slideUp();
                    return;
                }
    
                // some another code
            }
        }
    }
  • 相关阅读:
    正向代理与反向代理
    uniapp
    js
    js
    uniapp
    uniapp
    uniapp
    uniapp
    关于资源获取(请把https改为http)
    uniapp
  • 原文地址:https://www.cnblogs.com/fanxingthink/p/6023845.html
Copyright © 2020-2023  润新知