LLMS_Table_StudentManagement::set_columns()

Define the structure of the table


Return Return

(array)


Top ↑

Source Source

File: includes/admin/post-types/tables/class.llms.table.student.management.php

	public function set_columns() {
		$cols = array(
			'id'          => array(
				'sortable' => true,
				'title'    => __( 'ID', 'lifterlms' ),
			),
			'name'        => array(
				'sortable' => true,
				'title'    => __( 'Name', 'lifterlms' ),
			),
			'status'      => array(
				'filterable' => llms_get_enrollment_statuses(),
				'sortable'   => true,
				'title'      => __( 'Status', 'lifterlms' ),
			),
			'enrolled'    => array(
				'sortable' => true,
				'title'    => __( 'Enrollment Updated', 'lifterlms' ),
			),
			'progress'    => array(
				'sortable' => false,
				'title'    => __( 'Progress', 'lifterlms' ),
			),
			'grade'       => array(
				'sortable' => false,
				'title'    => __( 'Grade', 'lifterlms' ),
			),
			'last_lesson' => array(
				'sortable' => false,
				'title'    => __( 'Last Lesson', 'lifterlms' ),
			),
			'trigger'     => array(
				'sortable' => false,
				'title'    => __( 'Enrollment Trigger', 'lifterlms' ),
			),
			'actions'     => array(
				'sortable' => false,
				'title'    => ' ',
			),
		);
		$args = $this->get_args();
		if ( 'llms_membership' === get_post_type( $args['post_id'] ) ) {
			unset( $cols['grade'] );
			unset( $cols['progress'] );
			unset( $cols['last_lesson'] );
		}
		return $cols;
	}


Top ↑

Changelog Changelog

Changelog
Version Description
3.4.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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