/**
  * 渲染每一行数据
  * @param       $model  行数据
  * @param array $options   tr属性设置
  * @param array $tdOptions   特定td属性设置,以列名为key,如['name'=>[]
  */
 public function line($model, $options = [], $tdOptions = [])
 {
     if ($this->header) {
         $htmlContent = '';
         if ($this->checkbox) {
             $chxValue = '';
             if (isset($this->checkbox['value'])) {
                 if ($model instanceof ActiveRecord) {
                     $chxValue = $model->getAttribute($this->checkbox['value']);
                 } else {
                     $chxValue = $model[$this->checkbox['value']];
                 }
             }
             $htmlContent .= Html::tag('td', Html::input('checkbox', isset($this->checkbox['name']) ? $this->checkbox['name'] : '', $chxValue, ['class' => 'checkboxes']), []);
         }
         foreach ($this->keys as $key) {
             $val = '';
             $tdContent = '';
             if ($key === '') {
                 $tdContent = $tdOptions[''];
                 unset($tdOptions['']);
             } else {
                 if ($model instanceof ActiveRecord) {
                     $val = $model->hasAttribute($key) ? $model->getAttribute($key) : '';
                 } else {
                     $val = isset($model[$key]) ? $model[$key] : '';
                 }
                 if (isset($tdOptions[$key])) {
                     $tmpOptions = $tdOptions[$key];
                     if (isset($tmpOptions['href'])) {
                         //支持超链接
                         $tdContent .= Html::tag('a', $val, ['href' => $tmpOptions['href']]);
                     } elseif (isset($tmpOptions['img'])) {
                         //支持图片
                         if (isset($tmpOptions['img']['editable'])) {
                             $tdContent = Html::activeUploadFile($key, $tmpOptions['img']['data-url']);
                         }
                         $tdContent .= Html::tag('a', Html::tag('img', '', ArrayHelper::merge(['src' => $val], $tmpOptions['img'])), ['href' => $val]);
                         unset($tdOptions[$key]['img']);
                     } else {
                         $tdContent .= $val;
                     }
                 } else {
                     $tdContent .= $val;
                 }
             }
             $htmlContent .= Html::tag('td', $tdContent, isset($tdOptions[$key]) && is_array($tdOptions[$key]) ? $tdOptions[$key] : []);
             unset($tdContent);
         }
         return Html::tag('tr', $htmlContent, $options);
     }
     return '';
 }