title: Change background color in Yii2 gridview cell depend on its value
body: <p>I am trying to make background color that depending on the value calculation number in one cell. This is my code:</p>
  
  <pre><code>[
  'attribute' =&gt; 'coefTK',
  'label' =&gt; '&lt;abbr title="Koefisien Jumlah Tenaga Kerja"&gt;TK&lt;/abbr&gt;',
  'encodeLabel' =&gt; false,
  'headerOptions' =&gt; ['style'=&gt;'text-align:center'],
  'options' =&gt; [ 'style' =&gt; $dataProvider['coefTK']/$dataProvider['coefTK_se']&lt;2 ? 'background-color:red':'background-color:blue'],
          ],
  </code></pre>
  
  <p>but i got an error, that say "Cannot use object of type yii\data\ActiveDataProvider as array"</p>
  
  <p>So, How can i change the background gridview cell that have value from some calculation ?</p>