Automattic\WooCommerce\Internal\Admin\ProductReviews

ReviewsListTable::column_type()protectedWC 1.0

Renders the type column.

Method of the class: ReviewsListTable{}

No Hooks.

Return

null. Nothing (null).

Usage

// protected - for code of main (parent) or child class
$result = $this->column_type( $item ) : void;
$item(WP_Comment|mixed) (required)
Review or reply being rendered.

ReviewsListTable::column_type() code WC 8.6.1

protected function column_type( $item ) : void {

	$type = 'review' === $item->comment_type
		? '☆ ' . __( 'Review', 'woocommerce' )
		: __( 'Reply', 'woocommerce' );

	echo $this->filter_column_output( 'type', esc_html( $type ), $item ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
}