Skip to content
代码片段 群组 项目
提交 77c65f87 编辑于 作者: Lee Tickett's avatar Lee Tickett
浏览文件

Fix minor CRM contact related typos

上级 217cf364
No related branches found
No related tags found
无相关合并请求
...@@ -11,7 +11,7 @@ class ContactsResolver < BaseResolver ...@@ -11,7 +11,7 @@ class ContactsResolver < BaseResolver
type Types::CustomerRelations::ContactType, null: true type Types::CustomerRelations::ContactType, null: true
argument :sort, Types::CustomerRelations::ContactSortEnum, argument :sort, Types::CustomerRelations::ContactSortEnum,
description: 'Criteria to sort issues by.', description: 'Criteria to sort contacts by.',
required: false, required: false,
default_value: { field: 'last_name', direction: :asc } default_value: { field: 'last_name', direction: :asc }
......
...@@ -4,7 +4,7 @@ module Types ...@@ -4,7 +4,7 @@ module Types
module CustomerRelations module CustomerRelations
class ContactStateCountsType < Types::BaseObject class ContactStateCountsType < Types::BaseObject
graphql_name 'ContactStateCounts' graphql_name 'ContactStateCounts'
description 'Represents the total number of contacts for the represented statuses.' description 'Represents the total number of contacts for the represented states.'
authorize :read_crm_contact authorize :read_crm_contact
......
...@@ -220,7 +220,7 @@ class GroupType < NamespaceType ...@@ -220,7 +220,7 @@ class GroupType < NamespaceType
field :contact_state_counts, field :contact_state_counts,
Types::CustomerRelations::ContactStateCountsType, Types::CustomerRelations::ContactStateCountsType,
null: true, null: true,
description: 'Counts of contacts by status for the group.', description: 'Counts of contacts by state for the group.',
resolver: Resolvers::Crm::ContactStateCountsResolver resolver: Resolvers::Crm::ContactStateCountsResolver
field :work_item_types, Types::WorkItems::TypeType.connection_type, field :work_item_types, Types::WorkItems::TypeType.connection_type,
......
# frozen_string_literal: true # frozen_string_literal: true
module CustomerRelations module CustomerRelations
# Represents counts of each status or category of statuses
class ContactStateCounts class ContactStateCounts
include Gitlab::Utils::StrongMemoize include Gitlab::Utils::StrongMemoize
......
...@@ -10560,7 +10560,7 @@ Connection details for an Agent. ...@@ -10560,7 +10560,7 @@ Connection details for an Agent.
   
### `ContactStateCounts` ### `ContactStateCounts`
   
Represents the total number of contacts for the represented statuses. Represents the total number of contacts for the represented states.
   
#### Fields #### Fields
   
...@@ -12284,7 +12284,7 @@ four standard [pagination arguments](#connection-pagination-arguments): ...@@ -12284,7 +12284,7 @@ four standard [pagination arguments](#connection-pagination-arguments):
   
##### `Group.contactStateCounts` ##### `Group.contactStateCounts`
   
Counts of contacts by status for the group. Counts of contacts by state for the group.
   
Returns [`ContactStateCounts`](#contactstatecounts). Returns [`ContactStateCounts`](#contactstatecounts).
   
...@@ -12311,7 +12311,7 @@ four standard [pagination arguments](#connection-pagination-arguments): ...@@ -12311,7 +12311,7 @@ four standard [pagination arguments](#connection-pagination-arguments):
| ---- | ---- | ----------- | | ---- | ---- | ----------- |
| <a id="groupcontactsids"></a>`ids` | [`[CustomerRelationsContactID!]`](#customerrelationscontactid) | Filter contacts by IDs. | | <a id="groupcontactsids"></a>`ids` | [`[CustomerRelationsContactID!]`](#customerrelationscontactid) | Filter contacts by IDs. |
| <a id="groupcontactssearch"></a>`search` | [`String`](#string) | Search term to find contacts with. | | <a id="groupcontactssearch"></a>`search` | [`String`](#string) | Search term to find contacts with. |
| <a id="groupcontactssort"></a>`sort` | [`ContactSort`](#contactsort) | Criteria to sort issues by. | | <a id="groupcontactssort"></a>`sort` | [`ContactSort`](#contactsort) | Criteria to sort contacts by. |
| <a id="groupcontactsstate"></a>`state` | [`CustomerRelationsContactState`](#customerrelationscontactstate) | State of the contacts to search for. | | <a id="groupcontactsstate"></a>`state` | [`CustomerRelationsContactState`](#customerrelationscontactstate) | State of the contacts to search for. |
   
##### `Group.containerRepositories` ##### `Group.containerRepositories`
...@@ -232,7 +232,7 @@ ...@@ -232,7 +232,7 @@
create_list(:contact, 2, group: group, state: 'inactive') create_list(:contact, 2, group: group, state: 'inactive')
end end
it 'returns only active contacts' do it 'returns correct contact counts' do
counts = group.contacts.counts_by_state counts = group.contacts.counts_by_state
expect(counts['active']).to be(3) expect(counts['active']).to be(3)
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册