Colspan problem on Datatable with hidden columns and rowExpansion

UI Components for Vue
Post Reply
bodnarlajos
Posts: 19
Joined: 05 Jun 2020, 10:59
Location: Hungary

02 Sep 2021, 22:42

Hello there,

I have the same problem in PrimeVue 3.6.0 which is described (and solved in PrimeFaces) in the links below, described as:

I have a table with :hidden="true" columns, because I use those to Export Data not displayed,
but when I expand a row, then the columns shrink.

https://github.com/primefaces/primefaces/issues/1037
which has a followup:
https://github.com/primefaces/primefaces/issues/2937
and see also:
https://github.com/primefaces/primefaces/issues/5211

Can you please fix it?

Is there any workaround till?

Thanks in advance,
Lajos

bodnarlajos
Posts: 19
Joined: 05 Jun 2020, 10:59
Location: Hungary

02 Sep 2021, 23:02

I've found a workaround, but that is not a clear way to do it:

Instead of using hidden columns, I made them to dynamic:

Code: Select all

          
         <Column v-for="col of exportColumns1" :field="col.field" :header="col.header" :key="col.field" :hidden="true">
And my exportCSV function looks like:

Code: Select all

        
        exportCSV() {
            this.exportColumns1 = [{field:"order_date", header:"Order date"}, {field:"fulfil_date", header:"Fulfil date"}]
            this.$refs.dt.exportCSV()
            this.exportColumns1 = []
        },
In addition, I didn't find any docs also for customizing DataTable.exportCSV() function to avoid adding hidden columns only for Export. Is there any way to avoid ot or this should be the correct use?

tugce.kucukoglu
Posts: 560
Joined: 23 Oct 2020, 09:28

16 Nov 2021, 15:50

Hello,

Could you create a ticket so that we can work on it again.

Thank you.

bodnarlajos
Posts: 19
Joined: 05 Jun 2020, 10:59
Location: Hungary

16 Nov 2021, 23:40

Okay, but what does it mean to make a ticket?

Post Reply

Return to “PrimeVue”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 7 guests