Author Topic: Width attribute for the column of pivottable doesn't work.  (Read 167 times)

hyh888

  • Pro Enterprise
  • Full Member
  • *
  • Posts: 128
    • View Profile
Width attribute for the column of pivottable doesn't work.
« on: March 08, 2024, 06:58:20 am »
Dear,
In you demo for pivot grid,I change the width attribute of the first column("grp") to 300 in colM, and press "Edit and Run" button , but  it doesn't work.
It seems that firstly the attribute is functioned, but when the  summary  data is loaded , the atrribute is overrided with unknow reason. I can see the width of first column is wide and then shrinked.
I tried to change width of other column, it also doesn't work.
Here is the code:

        var colM = [
            //extra column to show grouping (for both pivot and row grouping mode, used along with groupModel.titleIndx )           
            {
                title: 'Group', tpHide: true, menuInHide: true,
                dataIndx: 'grp',
                  width:300,///////////////////////////////////////////////////// I made change here
                menuUI: {
                    tabs: ['hideCols'] //display only hide columns tab in menu.
                }
            },
« Last Edit: March 08, 2024, 07:05:34 am by hyh888 »

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6121
    • View Profile
Re: Width attribute for the column of pivottable doesn't work.
« Reply #1 on: March 08, 2024, 07:14:38 am »
it's working as expected because flex option is turned on in that example.

https://paramquery.com/pro/api#option-flex

hyh888

  • Pro Enterprise
  • Full Member
  • *
  • Posts: 128
    • View Profile
Re: Width attribute for the column of pivottable doesn't work.
« Reply #2 on: March 08, 2024, 08:23:11 am »
Thank you very much, it works.