ParamQuery grid support forum

General Category => Help for ParamQuery Pro => Topic started by: queensgambit9 on November 20, 2019, 08:18:15 pm

Title: Display multiple spaces in a HTML Page
Post by: queensgambit9 on November 20, 2019, 08:18:15 pm
Hi

Have multiple spaces (indentation) in data which I would like to see reflected in grid (  or similiar). When you export though, it should be formatted back to what was returned from db in the beginning.
How can I accomplish in an effecient way?

Thanks in advance.
Title: Re: Display multiple spaces in a HTML Page
Post by: paramvir on November 20, 2019, 09:15:42 pm
It can be done by adding render callback to the column

Code: [Select]
render: function(ui){
return ui.cellData.replace(/\s/g," ");
}

or a css solution

Code: [Select]
.pq-grid-cell{
white-space:pre-wrap !important;
}