Admin_Apple_News_List_Table::column_cb PHP Method

column_cb() public method

Required IF using checkboxes or bulk actions. The 'cb' column gets special treatment when columns are processed. It ALWAYS needs to have it's own method.
public column_cb ( WP_Post $item ) : string
$item WP_Post
return string
    public function column_cb($item)
    {
        // Omit if the article is pending publish
        $pending = get_post_meta($item->ID, 'apple_news_api_pending', true);
        if (!empty($pending)) {
            return '';
        }
        return sprintf('<input type="checkbox" name="%1$s[]" value="%2$s">', esc_attr($this->_args['singular']), absint($item->ID));
    }