feat: Introduce the crm_v2 feature flag for CRM changes (#12014)

Introduce crm_v2 feature flag for our upcoming optimisations for CRM

---------

Co-authored-by: Sojan Jose <sojan@pepalo.com>
This commit is contained in:
Tanmay Deep Sharma
2025-07-23 17:07:02 +04:00
committed by GitHub
parent e5ee6027b4
commit 286e3a449d
8 changed files with 120 additions and 7 deletions

View File

@@ -95,7 +95,9 @@ class SearchService
@contacts = current_account.contacts.where(
"name ILIKE :search OR email ILIKE :search OR phone_number
ILIKE :search OR identifier ILIKE :search", search: "%#{search_query}%"
).resolved_contacts.order_on_last_activity_at('desc').page(params[:page]).per(15)
).resolved_contacts(
use_crm_v2: current_account.feature_enabled?('crm_v2')
).order_on_last_activity_at('desc').page(params[:page]).per(15)
end
def filter_articles