找回密码
 立即注册

QQ登录

只需一步,快速开始

mtkj
金牌服务用户   /  发表于:2020-1-19 17:29  /   查看:2680  /  回复:1
beginningEdit: function (s, e) {
    e.cancel = true;//无效果
    var col = s.columns[e.col];
    debugger;
    var isEditable = true;
    var dom =  theGrid.cells.getCellElement(e.row, e.col);
    var oneColor = $(dom).attr("sd");
    if (oneColor == "ysh"){
        e.cancel = isEditable;
    }
    var inputtype = col.inputType;
    if (inputtype != undefined) {
        var type = inputtype.split("-");
        if (type[0] == "reference") {
            $("#row").val(e.row);
            $("#col").val(e.col);
            var sql = type[1];
            var w = $(window).width() - 100;
            var h = $(window).height() - 100;
            layer.open({
                type: 2,
                title: "参照数据",
                area: [w + 'px', h + 'px'],
                content: '/work/workshopmain/toReference?sql=' + sql
            });
        }
    }
}


1 个回复

倒序浏览
dexteryao讲师达人认证 悬赏达人认证 SpreadJS 开发认证
超级版主   /  发表于:2020-1-19 17:42:31
沙发
您好,没重现问题,调试确定没有进入下面这个逻辑吗? 建议给个完整的Demo
if (oneColor == "ysh"){
        e.cancel = isEditable;
    }
回复 使用道具 举报
您需要登录后才可以回帖 登录 | 立即注册
返回顶部