mirror of
https://github.com/internetee/registry.git
synced 2025-05-18 18:29:40 +02:00
Contacts index view
This commit is contained in:
parent
b4602e701c
commit
1777a0e572
4 changed files with 43 additions and 0 deletions
|
@ -1,4 +1,10 @@
|
|||
class Admin::ContactsController < ApplicationController
|
||||
|
||||
def index
|
||||
@q = Contact.search(params[:q])
|
||||
@contacts = @q.result.page(params[:page])
|
||||
end
|
||||
|
||||
def search
|
||||
render json: Contact.search_by_query(params[:q])
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue