【问题标题】:columnGroupShow in vue of ag-grid mo found在 ag-grid mo 的 vue 中找到 columnGroupShow
【发布时间】:2021-05-27 08:30:07
【问题描述】:

我的html

              <ag-grid-vue style="height: 100%;"
                 class="ag-theme-alpine"
                 :columnDefs="columnDefs"
                 :rowData="records"
                 :gridOptions="gridOptions"
                 :defaultColDef="defaultColDef"
                 :debug="true"
                 >
             </ag-grid-vue>

我的 json 头文件

         this.columnDefs = [
                     {
            headerName:'Datos del productos',
            children:[
                {headerName:'Código Interno', columnGroupShow: 'open', field: 'internal_id',  },
                {headerName:'Unidad', columnGroupShow: 'open', field: 'unit_type_id', width: 120,suppressSizeToFit:true,  },
                {headerName:'Nombre', columnGroupShow: 'open', field: 'name',  },
                {headerName:'Ver',   columnGroupShow: 'open', filter:false , width: 80, suppressSizeToFit:true},
                {headerName:'Descripción ampliada',  columnGroupShow: 'open', field: 'description', width: 200, suppressSizeToFit:true},
                {headerName:'Código Barras', columnGroupShow: 'open', field: 'barcode'},
                {headerName:'Código SUNAT', columnGroupShow: 'open', field: 'item_code'},
                {headerName:'Código de importación', columnGroupShow: 'open', field: ''},
            ],
        },
      }

我想隐藏或显示我拥有的列,但是在设置配置时,打开或关闭的 columngroupshow 在 html 中不起作用

在栏目中找不到群展,请帮忙

【问题讨论】:

    标签: javascript html vue.js ag-grid ag-grid-vue


    【解决方案1】:

    问题是所有子列都有columnGroupShow:'open'。换句话说,这没有效果

    要解决此问题,请在 一个 列中包含 columnGroupShow:'closed' 或根本不包含该属性。

    【讨论】:

      猜你喜欢
      • 2023-01-20
      • 1970-01-01
      • 2020-04-02
      • 2017-09-16
      • 2020-04-17
      • 2019-07-28
      • 2020-07-26
      • 2019-06-29
      • 2021-01-09
      相关资源
      最近更新 更多