# frozen_string_literal: true class DocumentReflex < ApplicationReflex include JurisprudenceSearch def render_index_table(results, document_id, doctrine_id) opts = { is_case_lists: true, doctrine_id: doctrine_id } morph "tbody#documentIndexTable", render(partial: "document_search_results_table", locals: { search_results: results, opts: opts }) end def render_years(results) morph "tbody#yearsIndex", render(DocumentsYearsComponent.new(current_user: current_user, years: results)) end def render_modal_document_search_table(results) morph "tbody#modalDocumentSearchTable", render(partial: "document_search_results_table", locals: { search_results: results, opts: { is_citing_document: true } }) end end