From f9db5c5890696fda476c9b0e39369c7017f53ee1 Mon Sep 17 00:00:00 2001 From: alexdbondoc17 Date: Mon, 14 Feb 2022 05:52:48 +0000 Subject: [PATCH] Improve routes --- config/routes.rb | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/config/routes.rb b/config/routes.rb index baf4df1..193a577 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -32,10 +32,16 @@ Rails.application.routes.draw do end namespace :api, defaults: { format: :json } do - resources :doctrines, only: %i[index show] + resources :doctrines, only: %i[index show] do + scope module: :doctrine do + resources :annotations + end + end resources :documents, only: %i[index show] + resources :subjects, only: %i[index] + resources :jurisprudences, only: %i[index show] do get :years, on: :collection