feat: Use display_name instead of name of the agent (#1097)
* feat: Use display_name instead of name of the agent
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
json.payload do
|
||||
json.array! @agents do |agent|
|
||||
json.user_id agent.id
|
||||
json.name agent.name
|
||||
json.partial! 'api/v1/models/user.json.jbuilder', resource: agent
|
||||
end
|
||||
end
|
||||
|
||||
@@ -3,7 +3,11 @@ json.meta do
|
||||
json.partial! 'api/v1/models/contact.json.jbuilder', resource: conversation.contact
|
||||
end
|
||||
json.channel conversation.inbox.try(:channel_type)
|
||||
json.assignee conversation.assignee
|
||||
if conversation.assignee
|
||||
json.assignee do
|
||||
json.partial! 'api/v1/models/user.json.jbuilder', resource: conversation.assignee
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
json.id conversation.display_id
|
||||
|
||||
@@ -2,6 +2,7 @@ json.account_id resource.account.id
|
||||
json.availability_status resource.availability_status
|
||||
json.confirmed resource.confirmed?
|
||||
json.email resource.email
|
||||
json.available_name resource.available_name
|
||||
json.id resource.id
|
||||
json.name resource.name
|
||||
json.role resource.role
|
||||
|
||||
@@ -3,6 +3,7 @@ json.provider resource.provider
|
||||
json.uid resource.uid
|
||||
json.name resource.name
|
||||
json.display_name resource.display_name
|
||||
json.available_name resource.available_name
|
||||
json.email resource.email
|
||||
json.account_id resource.active_account_user&.account_id
|
||||
json.pubsub_token resource.pubsub_token
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
json.payload do
|
||||
json.array! @inbox_members do |inbox_member|
|
||||
json.id inbox_member.user.id
|
||||
json.name inbox_member.user.name
|
||||
json.name inbox_member.user.available_name
|
||||
json.avatar_url inbox_member.user.avatar_url
|
||||
json.availability_status inbox_member.user.availability_status
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user