mirror of
https://github.com/lingble/chatwoot.git
synced 2025-11-01 19:48:08 +00:00
Chore: API Improvements (#3469)
This commit is contained in:
@@ -33,7 +33,7 @@ class Api::V1::Accounts::CannedResponsesController < Api::V1::Accounts::BaseCont
|
||||
|
||||
def canned_responses
|
||||
if params[:search]
|
||||
Current.account.canned_responses.where('short_code ILIKE ?', "#{params[:search]}%")
|
||||
Current.account.canned_responses.where('short_code ILIKE :search OR content ILIKE :search', search: "%#{params[:search]}%")
|
||||
else
|
||||
Current.account.canned_responses
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user