dimmitri / yii2-expand-row-column

Expand row column for the Yii 2.0 GridView widget.
8 stars 1 forks source link

Adding afterSuccess event? #5

Open sandor-molnar opened 5 years ago

sandor-molnar commented 5 years ago

Please add the ability to call js code on succes.
It's currently need on my message system, when if someone expand the row, in ajax it make it "readed". I want to do it on client side to (removing the class from tr)
Like:

success: function (data) {
    tr.find('td').html(data);
    tr.removeClass('new-message');// need this to be called if success.
},

PHP example:

'afterSuccess' => new \yii\web\JsExpression('tr.removeClass("new-message")'),