diff options
author | Star Rauchenberger <fefferburbia@gmail.com> | 2023-10-11 14:09:00 -0400 |
---|---|---|
committer | Star Rauchenberger <fefferburbia@gmail.com> | 2023-10-11 14:09:00 -0400 |
commit | 6e70f376d23c21a63ff4875a1f77e19f7961b7b4 (patch) | |
tree | a72208b6770064a2b193b23f2b41347c6126f67b /app | |
parent | eaa9e631550df4d590b5be1da98c51be430d7a0d (diff) | |
download | thoughts-6e70f376d23c21a63ff4875a1f77e19f7961b7b4.tar.gz thoughts-6e70f376d23c21a63ff4875a1f77e19f7961b7b4.tar.bz2 thoughts-6e70f376d23c21a63ff4875a1f77e19f7961b7b4.zip |
You can backdate posts now
Diffstat (limited to 'app')
-rw-r--r-- | app/controllers/admin/blogs_controller.rb | 2 | ||||
-rw-r--r-- | app/views/admin/blogs/_form.html.haml | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/app/controllers/admin/blogs_controller.rb b/app/controllers/admin/blogs_controller.rb index f17bce2..ea2c46c 100644 --- a/app/controllers/admin/blogs_controller.rb +++ b/app/controllers/admin/blogs_controller.rb | |||
@@ -56,7 +56,7 @@ class Admin::BlogsController < Admin::AdminController | |||
56 | private | 56 | private |
57 | 57 | ||
58 | def blog_params | 58 | def blog_params |
59 | params.require(:blog).permit(:title, :body, :slug, :published, :tag_list, records_attributes: [:description, :_destroy]) | 59 | params.require(:blog).permit(:title, :body, :slug, :published, :published_at, :tag_list, records_attributes: [:description, :_destroy]) |
60 | end | 60 | end |
61 | 61 | ||
62 | def set_section | 62 | def set_section |
diff --git a/app/views/admin/blogs/_form.html.haml b/app/views/admin/blogs/_form.html.haml index 021d1ed..625c85e 100644 --- a/app/views/admin/blogs/_form.html.haml +++ b/app/views/admin/blogs/_form.html.haml | |||
@@ -29,6 +29,9 @@ | |||
29 | .published-field | 29 | .published-field |
30 | = f.check_box :published | 30 | = f.check_box :published |
31 | = f.label :published | 31 | = f.label :published |
32 | .datetime-field | ||
33 | = f.label :published_at | ||
34 | = f.text_field :published_at | ||
32 | .details-module | 35 | .details-module |
33 | = f.fields_for :records, Record.new do |builder| | 36 | = f.fields_for :records, Record.new do |builder| |
34 | .should-create-record-field | 37 | .should-create-record-field |