1.0.1 Release
Date: Wednesday, June 1, 2016
- Add
callback
property to the Alert widget. Usage example:
echo \yii2mod\alert\Alert::widget([
'options' => [
'useSessionFlash' => false,
'timer' => null,
'type' => \yii2mod\alert\Alert::TYPE_WARNING,
'title' => 'Are you sure?',
'text' => 'You will not be able to recover this imaginary file!',
'confirmButtonText' => 'Yes, delete it!',
'closeOnConfirm' => false,
'showCancelButton' => true,
],
'callback' => new \yii\web\JsExpression('function() {
swal("Deleted!", "Your imaginary file has been deleted.", "success");
}')
]);
- Update docs