leandrogehlen / yii2-querybuilder

Extension for Yii2 Framework to work with jQuery QueryBuilder
42 stars 34 forks source link

Custom Input #7

Closed brianwong3 closed 7 years ago

brianwong3 commented 8 years ago

How do I implement the custom input in the filter? Do I pass in a php function or a string jquery function?

leandrogehlen commented 7 years ago

With the last changes, this will be possible.

use yii\web\JsExpression;

QueryBuilder::widget([
    'id' => 'query-builder',
    'pluginOptions' => [
        'someproperty' => new JsExpression('some string jquery function')
    ]
]);