You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This looks good.
Possible idea for future may be to bind these on initial page load and then never do it via pjax.
Pros: not sending unneeded js. No need to unbind \ rebind.
cons: if js changes it won't update till page reload - if current solution works, is it worth putting more time into it?
Also this is without going through any code to even see if it's possible.
All of these are already initialized on page load. The problem is you are overwriting content via pjax which destroys the jquery elements and as a result all its event bindings. Hence this has to be parsed in something like pjax:complete (as is done now) to ensure the element exists for reinitializing.
initPjax (client side) gets run on grid refresh. Which results in duplicate "pjax:complete" events being bound to grid object.
You can probably think of a better way to fix this. But attached below is a possible fix.
Located in yii2-grid\ColumnTrait.php line 311
The text was updated successfully, but these errors were encountered: