zoukankan      html  css  js  c++  java
  • easyui扩展数据表格点击加号拓展

    $(function(){
               $("#RepaymentInfoTab").datagrid({
                    view: detailview,
                 detailFormatter:function(index,row){
                         return '<div style="padding:2px"><table id="ddv-' + index + '"></table></div>'; 
                     }, 
                onExpandRow:function(index,row){ 
                    var repaymentNum = row.repaymentNum;
                    $('#ddv-'+index).datagrid({ 
                        url:'getSaleInfoData?repaymentNum=' + repaymentNum, 
                        fitColumns:true, 
                        singleSelect:true, 
                        height:'auto', 
                        columns:[[ 
                           
                            {field:'salesNum1',title:'计划消费流水',20}, 
                            {field:'salesMoney1',title:'计划消费金额',20}, 
                            {field:'difference1',title:'差额(消费-还款)',20}, 
                            {field:'status1',title:'计划消费状态',20,formatter:function(value){ 
                                if (value == 1) {return '<span style="color:red">初始化</span>'; } 
                                if (value == 2) {return '<span style="color:blue">消费完成</span>'; } 
                                if (value == 3) {return '<span style="color:blue">遗弃</span>'; } 
                            }}, 
                            {field:'transNo1',title:'交易流水号',20},
                            {field:'sendDate1',title:'交易时间',20}, 
                            {field:'creaetetime1',title:'添加时间',20},
                        ]], 
                        onResize:function(){ 
                            $('#RepaymentInfoTab').datagrid('fixDetailRowHeight',index); 
                        }, 
                        onLoadSuccess:function(){ 
                            setTimeout(function(){ 
                                $('#RepaymentInfoTab').datagrid('fixDetailRowHeight',index); 
                            },0); 
                        } 
                    }); 
                    $('#RepaymentInfoTab').datagrid('fixDetailRowHeight',index); 
                }
               })
         })
  • 相关阅读:
    C# String.Format格式说明
    jQuery.json.js
    禁止别人使用"另存为"保存你的网页
    组合问题的递归算法
    jQuery,contents()
    C#string,StringBuilder和Regex类的讲解
    jQuery性能优化指南
    加密算法的C#实现
    m,n组合算法
    jQuery插件—获取URL参数
  • 原文地址:https://www.cnblogs.com/bchange/p/9494857.html
Copyright © 2011-2022 走看看