Conditions | 1 |
Paths | 1 |
Total Lines | 17 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
25 | public function getPluginOptions($options = []) |
||
26 | { |
||
27 | return ArrayHelper::merge(parent::getPluginOptions($options), [ |
||
28 | 'select2Options' => [ |
||
29 | 'templateResult' => new JsExpression("function (data) { |
||
30 | if (data.loading) { |
||
31 | return data.text; |
||
32 | } |
||
33 | |||
34 | return data.client + '<small>@' + data.device + '</small>'; |
||
35 | }"), |
||
36 | 'escapeMarkup' => new JsExpression('function (markup) { |
||
37 | return markup; // Allows HTML |
||
38 | }'), |
||
39 | ], |
||
40 | ]); |
||
41 | } |
||
42 | } |
||
43 |