Closed hykelvinlee42 closed 2 years ago
master
[ 'attribute' => 'some_attribute', 'class' => 'kartik\grid\EditableColumn', 'refreshGrid' => true, 'filter'=>['1' => 'Yes', '0' => 'No'], 'filterWidgetOptions'=>[ 'pluginOptions'=>['allowClear'=>true], ], 'editableOptions' => [ 'inputType' => Editable::INPUT_SWITCH, 'options' => [ 'pluginOptions' => ['onText' => 'Yes', 'offText' => 'No'] ], 'formOptions' => ['action' => ['some_action/edit]], 'pjaxContainerId' => 'permission', 'format' => 'button', 'asPopover' => true, 'displayValueConfig' => [ '1' => '<span class="label label-success">Yes</span>', '0' => '<span class="label label-danger">No</span>', ], ], ],
When I follow those steps, I see no popover dialog is displayed on click after the refresh.
I was expecting the popover editing dialog will continue to be displayed and function on click.
If I set asPopover to false, the editing dialog is displayed in the grid cell and functions normally even after the grid refreshes.
asPopover
false
Resolved by reinitializing popoverButton. Reference: https://github.com/kartik-v/yii2-popover-x/issues/8
Prerequisites
master
branch of yii2-grid.Steps to reproduce the issue
Expected behavior and actual behavior
When I follow those steps, I see no popover dialog is displayed on click after the refresh.
I was expecting the popover editing dialog will continue to be displayed and function on click.
If I set
asPopover
tofalse
, the editing dialog is displayed in the grid cell and functions normally even after the grid refreshes.Environment
Browsers
Operating System
Libraries
Isolating the problem