Ameliabooking_Helpers::get_event_staff( array $reservation = array() )

Method get_event_staff.


Parameters Parameters

$reservation

(Optional) The reservation array from Amelia Hook.

Default value: array()


Top ↑

Return Return

(string) The provider name.


Source Source

File: src/integrations/ameliabooking/helpers/ameliabooking-helpers.php

	public function get_event_staff( $reservation = array() ) {

		$providers = array();

		if ( ! empty( $reservation['event']['providers'] ) ) {

			foreach ( $reservation['event']['providers'] as $provider ) {

				$providers[] = implode(
					' ',
					array(
						$provider['firstName'],
						$provider['lastName'],
					)
				);

			}

			return implode( ', ', $providers );
		}

		return '';
	}