LLMS_Table_Student_Memberships::get_data( string $key, int $membership_id )

Retrieve data for the columns


Parameters Parameters

$key

(string) (Required) the column id / key

$membership_id

(int) (Required) ID of the membership


Top ↑

Return Return

(mixed)


Top ↑

Source Source

File: includes/admin/reporting/tables/llms.table.student.memberships.php

	public function get_data( $key, $membership_id ) {

		switch ( $key ) {

			case 'id':
				$value = $this->get_post_link( $membership_id );
				break;

			case 'name':
				$value = get_the_title( $membership_id );
				break;

			case 'status':
				$value = llms_get_enrollment_status_name( $this->student->get_enrollment_status( $membership_id ) );
				break;

			case 'enrolled':
				$value = $this->student->get_enrollment_date( $membership_id, 'enrolled' );
				break;

			default:
				$value = $key;

		}

		return $this->filter_get_data( $value, $key, $membership_id );

	}


Top ↑

Changelog Changelog

Changelog
Version Description
3.2.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.