Browse Source

Rename download path

pull/1408/head
Kat 3 years ago
parent
commit
a53f180524
  1. 2
      app/controllers/start_controller.rb
  2. 2
      app/views/layouts/_collection_resources.html.erb
  3. 2
      config/routes.rb

2
app/controllers/start_controller.rb

@ -5,7 +5,7 @@ class StartController < ApplicationController
end
end
def download_pdf
def download_23_24_sales_form
send_file(
Rails.root.join("public/files/2023_24_sales_paper_form.pdf"),
filename: "2023-24 Sales paper form.pdf",

2
app/views/layouts/_collection_resources.html.erb

@ -24,7 +24,7 @@
<%= render DocumentListComponent.new(items: [
{
name: "Sales log for buyers (2023/24)",
href: start_download_pdf_path,
href: download_23_24_sales_form_path,
metadata: "PDF, 421 KB, 8 pages",
},
]) %>

2
config/routes.rb

@ -35,7 +35,7 @@ Rails.application.routes.draw do
get "/accessibility-statement", to: "content#accessibility_statement"
get "/privacy-notice", to: "content#privacy_notice"
get "/data-sharing-agreement", to: "content#data_sharing_agreement"
get "start/download_pdf"
get "/download-23-24-sales-form", to: "start#download_23_24_sales_form"
resource :account, only: %i[show edit], controller: "users" do
get "edit/password", to: "users#edit_password"

Loading…
Cancel
Save