diff --git a/app/controllers/green_lanes/category_assessments_controller.rb b/app/controllers/green_lanes/category_assessments_controller.rb index 091bf871..0cae517f 100644 --- a/app/controllers/green_lanes/category_assessments_controller.rb +++ b/app/controllers/green_lanes/category_assessments_controller.rb @@ -5,7 +5,7 @@ class CategoryAssessmentsController < AuthenticatedController before_action :disable_service_switching! before_action :check_service def index - @category_assessments = GreenLanes::CategoryAssessment.all(page: current_page).fetch + @category_assessments = GreenLanes::CategoryAssessment.all(query: { exemption_code: params[:exemption_code], page: current_page}).fetch end def new diff --git a/app/views/green_lanes/category_assessments/index.html.erb b/app/views/green_lanes/category_assessments/index.html.erb index 24ea9cbf..931671df 100644 --- a/app/views/green_lanes/category_assessments/index.html.erb +++ b/app/views/green_lanes/category_assessments/index.html.erb @@ -4,6 +4,22 @@ <%= link_to 'Add a Category Assessment', new_green_lanes_category_assessment_path, class: 'govuk-button' %> +<%= form_with url: green_lanes_category_assessments_path, method: :get, class: "govuk-form-group" do |form| %> +
+<% end %> + <% if @category_assessments.any? %>