MIGX icon indicating copy to clipboard operation
MIGX copied to clipboard

MIGX grid broken on 2.9.4+

Open pixelchutes opened this issue 9 years ago • 14 comments

Using MODX 2.4.0, MIGX Grid was working perfectly fine before 2.9.4 (e.g. 2.9.3 not impacted):

before_2_9_4

However, after installing 2.9.4, the grid display is mostly broken:

with_2_9_4

As you can see, only one column and one row is displayed... restored back to previous version until a fix can be identified.

NOTE: Tried clearing cache and testing in multiple browsers, but same result each time.

In case it helps, I am using raw JSON in the MIGX TV (Form Tabs, Grid Columns, Default Value), I am not using a configuration in this example.

pixelchutes avatar Aug 25 '15 02:08 pixelchutes

I've upgraded more than one installations to 2.4 with this version of MIGX, but never had seen that isssue. Just upgraded another one, to be sure. I can't think, what can cause it, actually.

Bruno17 avatar Aug 25 '15 04:08 Bruno17

Hmm, fwiw, I don't think it's a 2.4 issue, as older MIGX working fine on 2.4.0.

pixelchutes avatar Aug 25 '15 05:08 pixelchutes

Strange, any chance, I could have access to the installation?

Bruno17 avatar Aug 25 '15 05:08 Bruno17

I've had to revert, but I will see if I can duplicate on a MODX cloud instance.

pixelchutes avatar Aug 25 '15 05:08 pixelchutes

Isn't that a lexicon issue ? It's breaking the grid when I had some lexicon in french which contains ' I'm opening an issue for that

squarou avatar Sep 11 '15 09:09 squarou

Hmm... I'm not sure. Lexicons weren't being used in either case (separate sites.)

pixelchutes avatar Sep 13 '15 15:09 pixelchutes

@Bruno17 I have also tested this on migx-2.9.6 and migx-2.9.7, and am still running into the same issue :frowning:

Until we can identify the root cause, looks like we'll be stuck on MIGX <= 2.9.3

Not sure, possibly related to #202

pixelchutes avatar Feb 14 '16 15:02 pixelchutes

I still need to determine the exact issue, but should be related to one of these changes

pixelchutes avatar Feb 14 '16 16:02 pixelchutes

@Bruno17 I think I figured it out! The rendering issue above appears to be related to syncSize() being commented out (starting in migx-2.9.4)

    //this.syncSize();

Uncommenting the line above appears to fix the grid rendering, showing all columns / cells as expected.

What is the reason for disabling this call? Something to do with "custom grids" ?

pixelchutes avatar Feb 14 '16 16:02 pixelchutes

Can't remember, why this has been disabled. I'm sure, there was a reason. And I have still not seen your issues. But I can try to enable this line again, and see, if it has other side-effects.

Bruno17 avatar Feb 14 '16 18:02 Bruno17

Thanks, Bruno.

NOTE: There are two places in the file where syncSize() was commented out. The one I linked to was the first I tried, which corrected the issue.

pixelchutes avatar Feb 14 '16 18:02 pixelchutes

I also had sporadic issues with latest 2.13.0-pl. When opening a resource in manager, sometimes a table with 5 columns (all text-fields with text-editor) the grid will only show 2 columns. When double-clicking into the grid and pressing enter, the grid refreshes and all 5 columns were visible like expected.

I found a "workaround" for me by editing my grid.XXX.config.inc.php and using the "resetWinPosition" action-button for that. In case the grid-display is broken, a click on the button will fix it immediately.

I replaced this.setWinPosition(10,10); by this.getView().refresh(); :

$gridfunctions['this.resetWinPosition'] = "
resetWinPosition: function(btn,e) {
    // this.setWinPosition(10,10);
    this.getView().refresh();     
}";

I also tried a setTimeout() to call "this.getView().refresh()" after pageload, but it only works when the grid is visible in viewport when calling this function. Maybe there is a focus-event to trigger this refresh() when the grid becomes visible the first time?

Deesen avatar Jun 22 '21 16:06 Deesen

do you have a MIGX - config for me, that I can try to reproduce it?

Bruno17 avatar Jun 22 '21 16:06 Bruno17

Of course migx.zip

Deesen avatar Jun 22 '21 20:06 Deesen