该方法允许根据给定的参数来检索值映射。
Description
integer/array valuemap.get(object **parameters**)
The method allows to retrieve value maps according to the given parameters.
参数
(object)
定义所需输出的参数。
该方法支持以下参数。
(integer/array)
Returns either:
the count of retrieved objects, if the
countOutput
parameter has been used.
Parameters
(object)
Parameters defining the desired output.
The method supports the following parameters.
Parameter | Type | Description |
---|---|---|
valuemapids | string/array | Return only value maps with the given IDs. |
selectMappings | query | Return the value mappings for current value map in the property. |
sortfield | string/array | Sort the result by the given properties. Possible values are: valuemapid , name . |
countOutput | boolean | These parameters being common for all get methods are described in detail in the . |
editable | boolean | |
excludeSearch | boolean | |
filter | object | |
limit | integer | |
output | query | |
preservekeys | boolean | |
search | object | |
searchByAny | boolean | |
searchWildcardsEnabled | boolean | |
sortorder | string/array | |
startSearch | boolean |
Return values
Returns either:
an array of objects;
Examples
Retrieving value maps
Request:
Response:
Retrieve one value map with its mappings.
Request:
Response:
来源
CValueMap::get() in frontends/php/include/classes/api/services/CValueMap.php.