layui 隐藏某列


 
  $("[data-field='deviceTypeID']").css('display','none'); //关键代码
 
 
layui.table.render({
        elem: "#DeviceManageTable",
        cellMinWidth: 80,
        url: BASE_URL + "/Software/GetAllSoftware",
        cols: [
          [
            { type: "checkbox" },
            { field: "clientName", title: "客户名称", width: 200 },
            { field: "clientOfficeName", title: "科室名称", width: 201 },
            { field: "computerNo", title: "电脑号", width: 110 },
            { field: "softwareName", title: "软件名称", width: 216 },
            { field: "softwareExeName", title: "文件名", width: 213 },
            { field: "deviceName", title: "设备名称", width: 206 },
            {
              field: "deviceTypeID",
              title: "设备类型ID",
              width: 207,
              filter:true
            },
            { field: "deviceTypeName", title: "设备型号", width: 208 },
            { field: "softwareInfo", title: "软件信息", width: 214 },
            { field: "softwareDeveloper", title: "开发商", width: 212 },
            { field: "softwareLastVersion", title: "最新版本", width: 215 },

            {
              field: "lastUpdateTime",
              title: "最后一次更新维护时间",
              width: 209
            },
      
            { fixed: "right", width: 200, align: "center", toolbar: "#barDemo" }
          ]
        ],
        page: true,
        where: {
          selecteClientID: vvv.selectClient.clientId,
          selectState: vvv.selectState,
          selectDeviceTypeId: vvv.selectDeviceTypeId,
          selectSoftwareName: vvv.selectSoftwareName,
          selectDeviceName: vvv.selectDeviceName
        },
        done: function(res, curr, count) {
          vvv.statisticsStr = res.statisticsStr;
          $("[data-field='deviceTypeID']").css('display','none'); //关键代码
        }
      });


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM