Class: Renalware::Problems::NotesController
- Inherits:
-
BaseController
- Object
- ApplicationController
- ApplicationController
- BaseController
- Renalware::Problems::NotesController
- Defined in:
- app/controllers/renalware/problems/notes_controller.rb
Instance Method Summary collapse
Methods inherited from BaseController
Instance Method Details
#create ⇒ Object
19 20 21 22 23 24 25 26 27 28 |
# File 'app/controllers/renalware/problems/notes_controller.rb', line 19 def create load_problem note = @problem.notes.create(notes_params) if note.save render_index else render_form(note, url: patient_problem_notes_path(patient, @problem)) end end |
#index ⇒ Object
8 9 10 11 |
# File 'app/controllers/renalware/problems/notes_controller.rb', line 8 def index load_problem render_index end |
#new ⇒ Object
13 14 15 16 17 |
# File 'app/controllers/renalware/problems/notes_controller.rb', line 13 def new load_problem note = @problem.notes.new render_form(note, url: patient_problem_notes_path(patient, @problem)) end |