-
<%= raw content.html_safe %>
+<%= raw content.html_safe %>
<% document_title = jurisprudence.short_title || jurisprudence.title %>
<% date_or_year = jurisprudence.docdate.present? ? jurisprudence.docdate.to_date.strftime("%B %d, %Y") : jurisprudence.year %>
-
<%= [document_title, jurisprudence.reference_number, date_or_year].join(", ") %>
+<%= [document_title, jurisprudence.reference_number, date_or_year].join(", ") %>
<% annotations.each do |annotation| %> -+
<% annotated_documents_title = [] %> <% annotation.documents.each do |annotated_document| %> <% ad_title = annotated_document.short_title || annotated_document.title %> @@ -21,7 +21,7 @@
<% if annotation.editor_notes.present? %> -
+
diff --git a/app/views/shared/_case_lists_search_results.html.erb b/app/views/shared/_case_lists_search_results.html.erb
index b15c354..fd36eff 100644
--- a/app/views/shared/_case_lists_search_results.html.erb
+++ b/app/views/shared/_case_lists_search_results.html.erb
@@ -5,6 +5,12 @@
Editors Note:
diff --git a/app/components/document_doctrine_show_component/document_doctrine_show_component.html.erb b/app/components/document_doctrine_show_component/document_doctrine_show_component.html.erb
index 6bbf831..9756e97 100644
--- a/app/components/document_doctrine_show_component/document_doctrine_show_component.html.erb
+++ b/app/components/document_doctrine_show_component/document_doctrine_show_component.html.erb
@@ -60,8 +60,14 @@
<%= text_field_tag :q, nil, class: "form-control", placeholder: "Search GR Number", data: { target: "document.input" } %>
-
+
diff --git a/app/javascript/controllers/document_controller.js b/app/javascript/controllers/document_controller.js
index 5432551..9f4454c 100644
--- a/app/javascript/controllers/document_controller.js
+++ b/app/javascript/controllers/document_controller.js
@@ -1,6 +1,6 @@
import ApplicationController from './application_controller'
export default class extends ApplicationController {
- static targets = ["input"]
+ static targets = ["input", "citation_finder"]
connect () {
super.connect()
@@ -8,13 +8,14 @@ export default class extends ApplicationController {
search () {
this.stimulate("DocumentReflex#render_case_lists_search_results",
- { q: this.inputTarget.value, page: 1 },
+ { q: this.inputTarget.value, citation_finder: this.element.dataset["citation_finder"], page: 1 },
this.element.dataset["doctrineId"])
}
paginate () {
this.stimulate("DocumentReflex#render_case_lists_search_results",
- { q: this.element.dataset["q"], page: this.element.dataset["page"] },
+ { q: this.element.dataset["q"], citation_finder: this.element.dataset["citation_finder"],
+ page: this.element.dataset["page"] },
this.element.dataset["doctrineId"])
}
diff --git a/app/reflexes/document_reflex.rb b/app/reflexes/document_reflex.rb
index 6d1c624..87f0e9b 100644
--- a/app/reflexes/document_reflex.rb
+++ b/app/reflexes/document_reflex.rb
@@ -6,7 +6,7 @@ class DocumentReflex < ApplicationReflex
def render_case_lists_search_results(search_params, doctrine_id)
search = document_search(search_params)
@documents = search.results
- opts = { doctrine_id: doctrine_id, current_page: search_params[:page], q: search_params[:q] }
+ opts = { doctrine_id: doctrine_id, current_page: search_params[:page], q: search_params[:q], citation_finder: search_params[:citation_finder] }
morph "#caseListsCollapse", render(partial: "/shared/case_lists_search_results", locals: { documents: @documents, opts: opts })
end
diff --git a/app/views/shared/_case_lists_no_results.html.erb b/app/views/shared/_case_lists_no_results.html.erb
index fca4fe6..a96e322 100644
--- a/app/views/shared/_case_lists_no_results.html.erb
+++ b/app/views/shared/_case_lists_no_results.html.erb
@@ -4,6 +4,12 @@
<%= button_tag "Search", class: "btn btn-success", data: { action: "click->document#search" } %>
+
+
+
+
+
+ <%= text_field_tag :citation_finder, nil, class: "form-control", placeholder: "Citation Finder", data: { target: "document.citation_finder" } %>
<%= button_tag "Search", class: "btn btn-success", data: { action: "click->document#search" } %>
+
+
+
+
+
+ <%= text_field_tag :citation_finder, nil, class: "form-control", placeholder: "Citation Finder", data: { target: "document.citation_finder" } %>
<%= button_tag "Search", class: "btn btn-success", data: { action: "click->document#search" } %>
+
+
+
+
+
+ <%= text_field_tag :citation_finder, opts[:citation_finder], class: "form-control", placeholder: "Citation Finder", data: { target: "document.citation_finder" } %>