Feature: Add ability to disable auto assignment of conversations (#513)

This commit is contained in:
Tim Lange
2020-02-19 10:10:03 +01:00
committed by GitHub
parent e0afb84502
commit 30e5edf6dc
15 changed files with 377 additions and 230 deletions

View File

@@ -151,6 +151,7 @@ class Conversation < ApplicationRecord
def run_round_robin
# return unless conversation.account.has_feature?(round_robin)
# return unless conversation.account.round_robin_enabled?
return unless inbox.enable_auto_assignment
return if assignee
inbox.next_available_agent.then { |new_assignee| update_assignee(new_assignee) }

View File

@@ -4,13 +4,14 @@
#
# Table name: inboxes
#
# id :integer not null, primary key
# channel_type :string
# name :string not null
# created_at :datetime not null
# updated_at :datetime not null
# account_id :integer not null
# channel_id :integer not null
# id :integer not null, primary key
# channel_type :string
# enable_auto_assignment :boolean default(TRUE)
# name :string not null
# created_at :datetime not null
# updated_at :datetime not null
# account_id :integer not null
# channel_id :integer not null
#
# Indexes
#