From 2a51723b3f17f0d48a78dd854ff2573c69cd1aa8 Mon Sep 17 00:00:00 2001 From: chiu Date: Tue, 1 Oct 2019 20:27:51 +0800 Subject: [PATCH] Update _form_file.html.erb avoid the file to being deleted by js --- app/views/admin/announcements/_form_file.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/admin/announcements/_form_file.html.erb b/app/views/admin/announcements/_form_file.html.erb index 981ddf4..d6bb736 100644 --- a/app/views/admin/announcements/_form_file.html.erb +++ b/app/views/admin/announcements/_form_file.html.erb @@ -1,7 +1,7 @@ <% if form_file.new_record? %>
<% else %> -
+
<% if form_file.file.blank? %> <%= t(:no_file) %> <% else %>