Renders a table body row.

@param int $row
434205
public function renderTableRow($row)
	{
		$change = false;
		if ($this->_changes && array_key_exists($row, $this->_changes)) {
			$change = $this->_changes[$row];
			//if change in extracolumns --> put extra row
			$columnsInExtra = array_intersect(array_keys($change['columns']), $this->extraRowColumns);
			if (count($columnsInExtra) > 0) {
				$this->renderExtraRow($row, $change, $columnsInExtra);
			}
		}

		// original CGridView code
		$htmlOptions = array();
		if ($this->rowHtmlOptionsExpression !== null) {
			$data = $this->dataProvider->data[$row];
			$options = $this->evaluateExpression(
				$this->rowHtmlOptionsExpression,
				array('row' => $row, 'data' => $data)
			);
			if (is_array($options)) {
				$htmlOptions = $options;
			}
		}

		if ($this->rowCssClassExpression !== null) {
			$data = $this->dataProvider->data[$row];
			$class = $this->evaluateExpression($this->rowCssClassExpression, array('row' => $row, 'data' => $data));
		} elseif (is_array($this->rowCssClass) && ($n = count($this->rowCssClass)) > 0) {
			$class = $this->rowCssClass[$row % $n];
		}

		if (!empty($class)) {
			if (isset($htmlOptions['class'])) {
				$htmlOptions['class'] .= ' ' . $class;
			} else {
				$htmlOptions['class'] = $class;
			}
		}

		echo CHtml::openTag('tr', $htmlOptions);
		if (!$this->_changes) { //standart CGridview's render
			foreach ($this->columns as $column) {
				$column->renderDataCell($row);
			}
		} else { //for grouping
			foreach ($this->columns as $column) {
				$isGroupColumn = property_exists($column, 'name') && in_array($column->name, $this->mergeColumns);
				if (!$isGroupColumn) {
					$column->renderDataCell($row);
					continue;
				}

				$isChangedColumn = $change && array_key_exists($column->name, $change['columns']);

				//for rowspan show only changes (with rowspan)
				switch ($this->mergeType) {
					case self::MERGE_SIMPLE:
					case self::MERGE_NESTED:
						if ($isChangedColumn) {
							$options = $column->htmlOptions;
							$column->htmlOptions['rowspan'] = $change['columns'][$column->name]['count'];
							$column->htmlOptions['class'] = 'merge';
							$style = isset($column->htmlOptions['style']) ? $column->htmlOptions['style'] : '';
							$column->htmlOptions['style'] = $style . ';' . $this->mergeCellCss;
							$column->renderDataCell($row);
							$column->htmlOptions = $options;
						}
						break;

					case self::MERGE_FIRSTROW:
						if ($isChangedColumn) {
							$column->renderDataCell($row);
						} else {
							echo '<td></td>';
						}
						break;
				}

			}
		}

		echo "</tr>\n";
	}
749818
public function renderRow()
    {
        $this->t_row->trySet($this->current_row);

        $this->t_row->trySet('_title', $this->model->getTitle());
        $this->t_row->trySet('_href', $this->url(['id'=>$this->current_id]));
        $this->t_row->trySet('_id', $this->current_id);

        $html = $this->t_row->render();
        if ($this->template->hasTag('rows')) {
            $this->template->appendHTML('rows', $html);
        } else {
            $this->template->appendHTML('_top', $html);
        }
    }
972338
protected function displayGroupHeader($row)
    {
        $tr_tag = new SwatHtmlTag('tr');
        $tr_tag->class = 'swat-table-view-group';
        $tr_tag->open();

        $td_tag = new SwatHtmlTag('td', $this->getTdAttributes());
        $td_tag->colspan = $this->view->getXhtmlColspan();
        $td_tag->open();
        $this->displayRenderersInternal($row);
        $td_tag->close();

        $tr_tag->close();
    }
775600
protected function renderBodyColumn($td, array $column, Result\Row $row)
    {
        switch ($column[ 'format' ]) {
            default:
                if (is_callable($column[ 'format' ])) {
                    if (is_array($column[ 'field' ])) {
                        foreach ($column[ 'field' ] as $field) {
                            $args[ $field ] = $row->offsetGet($field);
                        }
                        $textContent = call_user_func_array($column[ 'format' ], $args);
                    } elseif ($row->offsetExists($column[ 'field' ])) {
                        $textContent = call_user_func_array($column[ 'format' ],
                            [$row->offsetGet($column[ 'field' ])]);
                    }

                    $td->textContent->push($textContent);

                } elseif (strpos($column[ 'format' ], '{{') !== false) {
                    $textContent = str_replace(['{{', '}}'], '', $column[ 'format' ]);
                    if (is_array($column[ 'field' ])) {
                        foreach ($column[ 'field' ] as $field) {
                            if ($row->offsetExists($field)) {
                                $textContent = str_replace('$' . $field, $row->offsetGet($field), $textContent);
                            } else {
                                $textContent = str_replace('$' . $field, '', $textContent);
                            }
                        }
                    } elseif ($row->offsetExists($column[ 'field' ])) {
                        $textContent = str_replace('$' . $column[ 'field' ], $row->offsetGet($column[ 'field' ]),
                            $textContent);
                    }

                    $td->textContent->push($textContent);
                }
                break;

            case 'checkbox':
                $checkbox = new Ui\Components\Form\Elements\Checkbox([
                    'data-role' => 'table-crud-checkbox',
                ]);
                $td->childNodes->push($checkbox);
                break;

            case 'number':
            case 'txt':
            case 'text':
            case 'price':
            case 'number':
                if ($row->offsetExists($column[ 'field' ])) {
                    $td->textContent->push($row->offsetGet($column[ 'field' ]));
                }
                break;
            case 'date':
                if ($row->offsetExists($column[ 'field' ])) {
                    print_out('date');
                }
                break;

            case 'status':
                if ($row->offsetExists($column[ 'field' ])) {
                    $options = [
                        'PUBLISH'   => 'success',
                        'UNPUBLISH' => 'warning',
                        'DRAFT'     => 'default',
                        'ARCHIVE'   => 'info',
                        'DELETE'    => 'danger',
                    ];

                    $badge = new Ui\Components\Badge(
                        language()->getLine('TABLE_OPTION_' . $row->offsetGet($column[ 'field' ])),
                        $options[ $row->offsetGet($column[ 'field' ]) ]
                    );

                    $td->childNodes->push($badge);
                }

                break;

            case 'actions':

                $buttons = new Ui\Components\Buttons\Group();

                foreach ($this->actions as $key => $action) {

                    if ($action[ 'show' ] === false) {
                        continue;
                    }

                    if ($action[ 'label' ] === true) {
                        $button = $buttons->createButton(language()->getLine('TABLE_BUTTON_' . strtoupper($key)));
                        if ( ! empty($action[ 'icon' ])) {
                            $button->setIcon($action[ 'icon' ]);
                        }
                    } else {
                        $button = $buttons->createButton(new Ui\Contents\Icon($action[ 'icon' ]));
                        $button->attributes->addAttribute('data-toggle', 'tooltip');
                        $button->attributes->addAttribute('title',
                            language()->getLine('TABLE_BUTTON_' . strtoupper($key)));
                    }

                    if (isset($action[ 'attr' ])) {
                        foreach ($action[ 'attr' ] as $name => $value) {
                            $button->attributes->addAttribute($name, $value);
                        }
                    }

                    $button->setContextualClass($action[ 'contextual' ]);
                    $button->smallSize();
                    $button->attributes->addAttribute('data-action', $key);
                }

                $td->childNodes->push($buttons);

                break;
        }
    }
905685
function Render($rows=10)
	{
	global $ADODB_COUNTRECS;

		$this->rows = $rows;

		if ($this->db->dataProvider == 'informix') $this->db->cursorType = IFX_SCROLL;

		$savec = $ADODB_COUNTRECS;
		if ($this->db->pageExecuteCountRows) $ADODB_COUNTRECS = true;
		if ($this->cache)
			$rs = $this->db->CachePageExecute($this->cache,$this->sql,$rows,$this->curr_page);
		else
			$rs = $this->db->PageExecute($this->sql,$rows,$this->curr_page);
		$ADODB_COUNTRECS = $savec;

		$this->rs = $rs;
		if (!$rs) {
			print "<h3>Query failed: $this->sql</h3>";
			return;
		}

		if (!$rs->EOF && (!$rs->AtFirstPage() || !$rs->AtLastPage()))
			$header = $this->RenderNav();
		else
			$header = "&nbsp;";

		$grid = $this->RenderGrid();
		$footer = $this->RenderPageCount();

		$this->RenderLayout($header,$grid,$footer);

		$rs->Close();
		$this->rs = false;
	}
172178
protected function renderDataCellContent($row, $data)
    {
        /* @var $am CAuthManager|AuthBehavior */
        $am = Yii::app()->getAuthManager();

        $linkCssClass = $this->active || $am->hasParent($this->itemName, $data['name']) || $am->hasChild(
            $this->itemName,
            $data['name']
        ) ? 'active' : 'disabled';

        /* @var $controller AuthItemController */
        $controller = $this->grid->getController();

        echo CHtml::link(
            $data['item']->description,
            array('/auth/' . $controller->getItemControllerId($data['item']->type) . '/view', 'name' => $data['name']),
            array('class' => $linkCssClass)
        );
    }
329030
protected function onInput($row)
    {
        if (is_array($this->params)) {
            foreach ($this->params as $cName => $cMap) {
                if (isset($this->mapFuncs[$cName])) {
                    $row[$cName] = $this->mapFuncs[$cName]($row[$cName]);
                } else if (is_array($cMap)) {
                    $row[$cName] = Utility::get($cMap, $row[$cName], $row[$cName]);
                }

            }
        } else if (is_callable($this->params)) {
            $func = $this->params;
            $pos = 0;
            foreach ($row as $cName => $value) {
                $row[$cName] = $func($value, $cName, $this->metaData['columns'][$cName], $pos);
                $pos++;
            }
        }
        $this->next($row);
    }
1115899
protected function renderDataCellContent($row, $data)
	{
		$tr = array();
		ob_start();
		foreach ($this->buttons as $id => $button) {
			$this->renderButton($id, $button, $row, $data);
			$tr['{' . $id . '}'] = ob_get_contents();
			ob_clean();
		}
		ob_end_clean();
		echo "<div class='btn-group'>" . strtr($this->template, $tr) . "</div>";
	}
887815
public function render(\Magento\Framework\DataObject $row)
    {
        return ($row->getData($this->getColumn()->getIndex()) > 0) ? __('yes') : __('no');
    }
580831
protected function renderDataCellContent($row, $data)
	{
		$checked = $this->getCheckedState($row, $data);
		$label = $this->makeButtonLabel($checked);
		$icon = $this->makeButtonIcon($checked);
		$url = $this->makeButtonUrl($row, $data);

		if ($this->displayText)
			$this->renderButton($label, $icon, $url);
		else
			$this->renderLink($label, $icon, $url);
	}
320424
protected function renderDataCellContent($row, $data)
    {
        /* @var $am CAuthManager|AuthBehavior */
        $am = Yii::app()->getAuthManager();

        if ($am->hasParent($this->itemName, $data['name'])) {
            echo TbHtml::linkButton(
                TbHtml::icon(TbHtml::ICON_REMOVE),
                array(
                    'color' => TbHtml::BUTTON_COLOR_LINK,
                    'size' => TbHtml::BUTTON_SIZE_MINI,
                    'url' => array('removeParent', 'itemName' => $this->itemName, 'parentName' => $data['name']),
                    'rel' => 'tooltip',
                    'title' => Yii::t('AuthModule.main', 'Remove'),
                )
            );
        } else {
            if ($am->hasChild($this->itemName, $data['name'])) {
                echo TbHtml::linkButton(
                    TbHtml::icon(TbHtml::ICON_REMOVE),
                    array(
                        'color' => TbHtml::BUTTON_COLOR_LINK,
                        'size' => TbHtml::BUTTON_SIZE_MINI,
                        'url' => array('removeChild', 'itemName' => $this->itemName, 'childName' => $data['name']),
                        'rel' => 'tooltip',
                        'title' => Yii::t('AuthModule.main', 'Remove'),
                    )
                );
            }
        }
    }
927312
public function renderRows()
    {
        $this->odd_even = null;
        $this->total_rows = 0;
        $this->template->del($this->container_tag);

        // render data rows
        $iter = $this->getIterator();
        foreach ($iter as $this->current_id => $this->current_row) {
            if ($this->current_row instanceof Model || $this->current_row instanceof \atk4\data\Model) {
                $this->current_row = (array) $this->current_row->get();
            } elseif (!is_array($this->current_row) && !($this->current_row instanceof ArrayAccess)) {
                // Looks like we won't be abel to access current_row as array, so we will
                // copy it's value inside $this->current instead and produce an empty array
                // to be filled out by a custom iterators
                $this->current = $this->current_row;
                $this->current_row = get_object_vars($this->current);
            }

            $this->current_row_html = array();

            if (!empty($this->sep_html) && $this->total_rows) {
                $this->renderSeparator();
            }

            // calculate rows so far
            ++$this->total_rows;

            // if onRender totals enabled, then update totals
            if ($this->totals_type == 'onRender') {
                $this->updateTotals();
            }

            // render data row
            $this->renderDataRow();
        }

        // calculate grand totals if needed
        if ($this->totals_type == 'onRequest') {
            $this->updateGrandTotals();
        }

        // set total row count
        $this->totals['row_count'] = $this->total_rows;

        // render totals row
        $this->renderTotalsRow();
    }
131295
function Load(&$row)
    {
		$this->_phreezer->Observe("Loading " . get_class($this),OBSERVE_DEBUG);

		foreach (array_keys($row) as $prop)
		{
			$this->$prop = $row[$prop];
		}

        $this->OnLoad();
    }
991882
public function renderTableRow($row)
    {
        $htmlOptions = array();
        if ($this->rowHtmlOptionsExpression !== null) {
            $data = $this->dataProvider->data[$row];
            $options = $this->evaluateExpression(
                $this->rowHtmlOptionsExpression,
                array('row' => $row, 'data' => $data)
            );
            if (is_array($options)) {
                $htmlOptions = $options;
            }
        }

        if ($this->rowCssClassExpression !== null) {
            $data = $this->dataProvider->data[$row];
            $class = $this->evaluateExpression($this->rowCssClassExpression, array('row' => $row, 'data' => $data));
        } elseif (is_array($this->rowCssClass) && ($n = count($this->rowCssClass)) > 0) {
            $class = $this->rowCssClass[$row % $n];
        }

        if (!empty($class)) {
            if (isset($htmlOptions['class'])) {
                $htmlOptions['class'] .= ' ' . $class;
            } else {
                $htmlOptions['class'] = $class;
            }
        }

        echo TbHtml::openTag('tr', $htmlOptions);
        foreach ($this->columns as $column) {
            echo $this->displayExtendedSummary && !empty($this->extendedSummary['columns']) ? $this->parseColumnValue(
                $column,
                $row
            ) : $column->renderDataCell($row);
        }
        echo TbHtml::closeTag('tr');
    }
778103
private function renderRow(array $row, string $cellFormat)
    {
        $rowContent = $this->renderColumnSeparator(self::BORDER_OUTSIDE);
        $columns = $this->getRowColumns($row);
        $last = \count($columns) - 1;
        foreach ($columns as $i => $column) {
            $rowContent .= $this->renderCell($row, $column, $cellFormat);
            $rowContent .= $this->renderColumnSeparator($last === $i ? self::BORDER_OUTSIDE : self::BORDER_INSIDE);
        }
        $this->output->writeln($rowContent);
    }
377418
public function render(Row $row)
	{
		if (!$this->shouldBeRendered($row)) {
			return null;
		}

		try {
			// Renderer function may be used
			return $this->useRenderer($row);
		} catch (DataGridColumnRendererException $e) {
			// Do not use renderer
		}

		$link = $this->createLink(
			$this->grid,
			$this->href,
			$this->getItemParams($row, $this->params) + $this->parameters
		);

		$a = Html::el('a')->href($link);

		$this->tryAddIcon($a, $this->getIcon($row), $this->getName());

		if (!empty($this->data_attributes)) {
			foreach ($this->data_attributes as $key => $value) {
				$a->data($key, $value);
			}
		}

		if (!empty($this->attributes)) {
			$a->addAttributes($this->attributes);
		}

		$a->addText($this->translate($this->getName()));

		if ($this->title) {
			$a->title($this->translate($this->getTitle($row)));
		}

		if ($this->class) {
			$a->class($this->getClass($row));
		}

		if ($confirm = $this->getConfirm($row)) {
			$a->data(static::$data_confirm_attribute_name, $confirm);
		}

		if ($this->open_in_new_tab) {
			$a->addAttributes(['target' => '_blank']);
		}

		return $a;
	}
1146085
public function render(\Magento\Framework\DataObject $row)
    {
        $customerId = (int)$row->getData($this->getColumn()->getIndex());
        if($customerId > 0) {
            return '<a href="' . $this->getUrl('customer/index/edit', array('id' => $customerId)) . '" target="_blank">' . $customerId . '</a>';
        }

        return nl2br(htmlspecialchars($row->getData($this->getColumn()->getIndex())));
    }