Give_API_Keys_Table::column_user PHP Method

column_user() public method

Renders the column for the user field
Since: 1.1
public column_user ( $item ) : void
return void
    public function column_user($item)
    {
        $actions = array();
        if (apply_filters('give_api_log_requests', true)) {
            $actions['view'] = sprintf('<a href="%s">%s</a>', esc_url(add_query_arg(array('view' => 'api_requests', 'post_type' => 'give_forms', 'page' => 'give-reports', 'tab' => 'logs', 's' => $item['email']), 'edit.php')), esc_html__('View API Log', 'give'));
        }
        $actions['reissue'] = sprintf('<a href="%s" class="give-regenerate-api-key">%s</a>', esc_url(wp_nonce_url(add_query_arg(array('user_id' => $item['id'], 'give_action' => 'process_api_key', 'give_api_process' => 'regenerate')), 'give-api-nonce')), esc_html__('Reissue', 'give'));
        $actions['revoke'] = sprintf('<a href="%s" class="give-revoke-api-key give-delete">%s</a>', esc_url(wp_nonce_url(add_query_arg(array('user_id' => $item['id'], 'give_action' => 'process_api_key', 'give_api_process' => 'revoke')), 'give-api-nonce')), esc_html__('Revoke', 'give'));
        $actions = apply_filters('give_api_row_actions', array_filter($actions));
        return sprintf('%1$s %2$s', $item['user'], $this->row_actions($actions));
    }