searchOverview.graphql 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. query search(
  2. $search: String!
  3. $isAgent: Boolean!
  4. $onlyIn: EnumSearchableModels
  5. ) {
  6. search(search: $search, onlyIn: $onlyIn) {
  7. ... on Ticket {
  8. id
  9. internalId
  10. title
  11. number
  12. state {
  13. name
  14. }
  15. priority @include(if: $isAgent) {
  16. name
  17. defaultCreate
  18. uiColor
  19. }
  20. customer {
  21. id
  22. internalId
  23. fullname
  24. }
  25. updatedAt
  26. updatedBy @include(if: $isAgent) {
  27. id
  28. fullname
  29. }
  30. }
  31. ... on User {
  32. id
  33. internalId
  34. firstname
  35. lastname
  36. image
  37. organization {
  38. id
  39. internalId
  40. name
  41. }
  42. updatedAt
  43. updatedBy @include(if: $isAgent) {
  44. id
  45. fullname
  46. }
  47. ticketsCount {
  48. open
  49. closed
  50. }
  51. }
  52. ... on Organization {
  53. id
  54. internalId
  55. members(first: 2) {
  56. edges {
  57. node {
  58. id
  59. fullname
  60. }
  61. }
  62. totalCount
  63. }
  64. active
  65. name
  66. updatedAt
  67. updatedBy @include(if: $isAgent) {
  68. id
  69. fullname
  70. }
  71. ticketsCount {
  72. open
  73. closed
  74. }
  75. }
  76. }
  77. }