REST_Element_Settings_Controller::get_collection_params()

Retrieves the query params for the models collection.

Description

Return

(array) Collection parameters.

Source

File: src/db-objects/element-settings/rest-element-settings-controller.php

	public function get_collection_params() {
		$query_params = parent::get_collection_params();

		$query_params['per_page']['maximum'] = 500;

		$query_params['form_id'] = array(
			'description' => __( 'Limit result set to element settings associated with a specific form ID.', 'torro-forms' ),
			'type'        => 'integer',
			'minimum'     => 1,
		);

		$query_params['container_id'] = array(
			'description' => __( 'Limit result set to element settings associated with a specific container ID.', 'torro-forms' ),
			'type'        => 'integer',
			'minimum'     => 1,
		);

		$query_params['element_id'] = array(
			'description' => __( 'Limit result set to element settings associated with a specific element ID.', 'torro-forms' ),
			'type'        => 'integer',
			'minimum'     => 1,
		);

		return $query_params;
	}

Changelog

Changelog
Version Description
1.0.0 Introduced.