screenitem.get

Description

integer/array screenitem.get(object **parameters**)

The method allows to retrieve screen items according to the given parameters.

Parameters

(object) Parameters defining the desired output.

The method supports the following parameters.

ParameterTypeDescription
screenitemidsstring/arrayReturn only screen items with the given IDs.
screenidsstring/arrayReturn only screen items that belong to the given screen.
sortfieldstring/arraySort the result by the given properties.

Possible values are: screenitemid and screenid.
countOutputbooleanThese parameters being common for all get methods are described in detail in the reference commentary page page.
editableboolean
excludeSearchboolean
filterobject
limitinteger
outputquery
preservekeysboolean
searchobject
searchByAnyboolean
searchWildcardsEnabledboolean
sortorderstring/array
startSearchboolean

Return values

(integer/array) Returns either:

  • an array of objects;

  • the count of retrieved objects, if the countOutput parameter has been used.

Examples

Retrieving screen items from screen

Retrieve all screen items from the given screen.

Request:

  1. {
  2. "jsonrpc": "2.0",
  3. "method": "screenitem.get",
  4. "params": {
  5. "output": "extend",
  6. "screenids": "3"
  7. },
  8. "auth": "038e1d7b1735c6a5436ee9eae095879e",
  9. "id": 1
  10. }

Response:

  1. {
  2. "jsonrpc": "2.0",
  3. "result": [
  4. {
  5. "screenitemid": "20",
  6. "screenid": "3",
  7. "resourcetype": "0",
  8. "resourceid": "433",
  9. "width": "500",
  10. "height": "120",
  11. "x": "0",
  12. "y": "0",
  13. "colspan": "1",
  14. "rowspan": "1",
  15. "elements": "0",
  16. "valign": "1",
  17. "halign": "0",
  18. "style": "0",
  19. "url": "",
  20. "dynamic": "0",
  21. "sort_triggers": "0",
  22. "application": "",
  23. "max_columns": "3"
  24. },
  25. {
  26. "screenitemid": "21",
  27. "screenid": "3",
  28. "resourcetype": "0",
  29. "resourceid": "387",
  30. "width": "500",
  31. "height": "100",
  32. "x": "0",
  33. "y": "1",
  34. "colspan": "1",
  35. "rowspan": "1",
  36. "elements": "0",
  37. "valign": "1",
  38. "halign": "0",
  39. "style": "0",
  40. "url": "",
  41. "dynamic": "0",
  42. "sort_triggers": "0",
  43. "application": "",
  44. "max_columns": "3"
  45. },
  46. {
  47. "screenitemid": "22",
  48. "screenid": "3",
  49. "resourcetype": "1",
  50. "resourceid": "10013",
  51. "width": "500",
  52. "height": "148",
  53. "x": "1",
  54. "y": "0",
  55. "colspan": "1",
  56. "rowspan": "1",
  57. "elements": "0",
  58. "valign": "1",
  59. "halign": "0",
  60. "style": "0",
  61. "url": "",
  62. "dynamic": "0",
  63. "sort_triggers": "0",
  64. "application": "",
  65. "max_columns": "3"
  66. },
  67. {
  68. "screenitemid": "23",
  69. "screenid": "3",
  70. "resourcetype": "1",
  71. "resourceid": "22181",
  72. "width": "500",
  73. "height": "184",
  74. "x": "1",
  75. "y": "1",
  76. "colspan": "1",
  77. "rowspan": "1",
  78. "elements": "0",
  79. "valign": "1",
  80. "halign": "0",
  81. "style": "0",
  82. "url": "",
  83. "dynamic": "0",
  84. "sort_triggers": "0",
  85. "application": "",
  86. "max_columns": "3"
  87. }
  88. ],
  89. "id": 1
  90. }

Source

CScreenItem::get() in frontends/php/include/classes/api/services/CScreenItem.php.