yusijie
2025-03-18 2c6bb6767480df59530cc1afe442a642c053178c
WebTM/layuiadmin/modules/tableSelect.js
@@ -23,9 +23,9 @@
        opt.searchKey = opt.searchKey || 'keyword';//可多个用,分割
        opt.table.page = opt.table.page || false;
        opt.table.height = opt.table.height || 290;
        elem.off('click').on('click', function(e) {
        elem.off('keyup').on('keyup', function(e) {
            e.stopPropagation();
            if($('div.tableSelect').length >= 1){
            if ($('div.tableSelect').length >= 1 || elem.val().length<=2) {
                return false;
            }
@@ -43,7 +43,7 @@
            //渲染TABLE
            opt.table.elem = "#"+tableName;
            opt.table.id = tableName;
            //若没有where表示为前端分页
            //若没有url表示为前端分页
            if (opt.table.url != undefined) {
                opt.table.where['sWhere'] = opt.sWhere
            } else {
@@ -247,7 +247,13 @@
            //按钮选中
            tableBox.find('.tableSelect_btn_select').on('click', function() {
                var checkStatus = table.checkStatus(tableName);
                selectDone(checkStatus);
                if (checkStatus.data.length > 0) {
                    selectDone(checkStatus);
                } else {
                    tableBox.remove();
                    delete table.cache[tableName];
                }
            })
            //写值回调和关闭