From 782d38c6644361d5e470df99dbc4a0bde093e6c3 Mon Sep 17 00:00:00 2001 From: Karel Picman Date: Sat, 22 Feb 2014 07:36:05 +0100 Subject: [PATCH] HTML validation --- .../dmsf_files/_file_new_revision.html.erb | 24 ++++++------ .../dmsf_files/_revision_access.html.erb | 39 +++++++++---------- app/views/dmsf_files/show.html.erb | 7 ++-- 3 files changed, 34 insertions(+), 36 deletions(-) diff --git a/app/views/dmsf_files/_file_new_revision.html.erb b/app/views/dmsf_files/_file_new_revision.html.erb index c30ee1b1..b54214f5 100644 --- a/app/views/dmsf_files/_file_new_revision.html.erb +++ b/app/views/dmsf_files/_file_new_revision.html.erb @@ -69,14 +69,14 @@

<%= label_tag('file_upload', "#{l(:label_new_content)}:") %> -

- <%= file_field_tag('file_upload') %> -
- - (<%= l(:label_max_size) %>: <%= number_to_human_size(Setting.attachment_max_size.to_i.kilobytes) %>) - -
-

+

+
+ <%= file_field_tag('file_upload') %> +
+ + (<%= l(:label_max_size) %>: <%= number_to_human_size(Setting.attachment_max_size.to_i.kilobytes) %>) + +

@@ -87,12 +87,12 @@

<%= label_tag('dmsf_file_revision_comment', "#{l(:label_comment)}:") %> -

- <%= f.text_area(:comment, :rows=> 2, :style => 'width: 99%;') %> -

+
+ <%= f.text_area(:comment, :rows=> 2, :style => 'width: 99%;') %> +
-
+
<%= submit_tag(l(:submit_create)) %> <% end %> <% end %> diff --git a/app/views/dmsf_files/_revision_access.html.erb b/app/views/dmsf_files/_revision_access.html.erb index b7629009..a13a736c 100644 --- a/app/views/dmsf_files/_revision_access.html.erb +++ b/app/views/dmsf_files/_revision_access.html.erb @@ -19,25 +19,24 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. %> -

- - +
+
+ + + + + + + + + + <% revision.access_grouped.each do |access| %> - - - - + + + + - - - <% revision.access_grouped.each do |access| %> - - - - - - - <% end %> - -
<%= l(:field_user) %><%= l(:heading_access_downloads_emails) %><%= l(:heading_access_first) %><%= l(:heading_access_last) %>
<%= l(:field_user) %><%= l(:heading_access_downloads_emails) %><%= l(:heading_access_first) %><%= l(:heading_access_last) %><%= link_to_user(access.user) %><%= access['count'] %><%= format_time(DmsfHelper::to_time(access.first_at)) %><%= format_time(DmsfHelper::to_time(access.last_at)) %>
<%= link_to_user(access.user) %><%= access['count'] %><%= format_time(DmsfHelper::to_time(access.first_at)) %><%= format_time(DmsfHelper::to_time(access.last_at)) %>
-

+ <% end %> + + \ No newline at end of file diff --git a/app/views/dmsf_files/show.html.erb b/app/views/dmsf_files/show.html.erb index de20da44..e5ec47e0 100644 --- a/app/views/dmsf_files/show.html.erb +++ b/app/views/dmsf_files/show.html.erb @@ -142,13 +142,12 @@ <%= h(revision.comment) %>

-
" style="display:none"> - <%= render(:partial => 'revision_access', :locals => {:revision => revision}) if User.current.allowed_to?(:file_manipulation, @file.project) %> +
" style="display:none"> + <%= render(:partial => 'revision_access', :locals => {:revision => revision}) if User.current.allowed_to?(:file_manipulation, @file.project) %>
- +
<% end %>

<%= pagination_links_full @revision_pages, @file.revisions.visible.count %>