Class: Api::V1::NoteTypesController
- Inherits:
-
BaseController
- Object
- ActionController::Base
- BaseController
- Api::V1::NoteTypesController
- Defined in:
- app/controllers/api/v1/note_types_controller.rb
Instance Method Summary collapse
Instance Method Details
#index ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 |
# File 'app/controllers/api/v1/note_types_controller.rb', line 5 def index NoteType.include_root_in_json = false if params[:ids] render json: {note_types: NoteType.where(id: params[:ids].split(',')).all} else render json: {success: true, note_types: NoteType.all} end end |