diff --git a/app/views/dmsf/_dir.html.erb b/app/views/dmsf/_dir.html.erb
index dbce36b0..09335a85 100644
--- a/app/views/dmsf/_dir.html.erb
+++ b/app/views/dmsf/_dir.html.erb
@@ -39,73 +39,63 @@
<%= format_time(subfolder.modified) if subfolder %>
<% if locked_for_user %>
<% if subfolder.lock.reverse[0].user %>
- <%= link_to('',
+ <%= link_to(image_tag(link ? 'locked_gray.png' : 'locked.png', :plugin => 'redmine_dmsf'),
user_path(subfolder.lock.reverse[0].user),
- :title => l(:title_locked_by_user, :user => subfolder.lock.reverse[0].user),
- :class => 'icon icon-dmsf-locked') %>
+ :title => l(:title_locked_by_user, :user => subfolder.lock.reverse[0].user)) %>
<% else %>
- <%= content_tag(:span, '', :title => l(:notice_account_unknown_email),
- :class => 'icon icon-dmsf-locked') %>
+ <%= content_tag(:span, image_tag(link ? 'locked_gray.png' : 'locked.png', :plugin => 'redmine_dmsf'),
+ :title => l(:notice_account_unknown_email)) %>
<% end %>
<% elsif locked %>
- <%= content_tag(:span, '', :title => l(:title_locked_by_you),
- :class => 'icon icon-dmsf-lockedbycurrent') %>
+ <%= content_tag(:span, image_tag(link ? 'lockedbycurrent_gray.png' : 'lockedbycurrent.png', :plugin => 'redmine_dmsf'),
+ :title => l(:title_locked_by_you)) %>
<% end %>
|
|
|
<%= h(subfolder.user) if subfolder %> |
-
- <% if @folder_manipulation_allowed %>
-
- <% unless locked %>
- <%= link_to('',
- edit_dmsf_path(:id => project, :folder_id => subfolder),
- :title => l(:link_edit, :title => subfolder ? h(subfolder.title) : project.name),
- :class => 'icon icon-edit') %>
- <% if subfolder %>
- <%= link_to('',
- lock_dmsf_path(:id => project, :folder_id => subfolder),
- :title => l(:title_lock_file),
- :class => 'icon icon-dmsf-lock') %>
- <% else %>
-
- <% end %>
- <% if (subfolder && subfolder.notification) || (!subfolder && project.dmsf_notification) %>
- <%= link_to('',
- notify_deactivate_dmsf_path(:id => project, :folder_id => subfolder),
- :title => l(:title_notifications_active_deactivate),
- :class => 'icon icon-notification-on') %>
- <% else %>
- <%= link_to('',
- notify_activate_dmsf_path(:id => project, :folder_id => subfolder),
- :title => l(:title_notifications_not_active_activate),
- :class => 'icon icon-notification-off') %>
- <% end %>
- <% if link %>
- <%= link_to('',
- dmsf_link_path(link),
- :data => {:confirm => l(:text_are_you_sure)},
- :method => :delete,
- :title => l(:title_delete),
- :class => 'icon icon-del') %>
- <% else %>
- <%= link_to('',
- delete_dmsf_path(:id => project, :folder_id => subfolder),
- :data => {:confirm => l(:text_are_you_sure)},
- :title => l(:title_delete),
- :class => 'icon icon-del') %>
- <% end %>
- <% else %>
+
+ <% if @folder_manipulation_allowed %>
+ <% unless locked %>
+ <%= link_to(image_tag('edit.png'),
+ edit_dmsf_path(:id => project, :folder_id => subfolder),
+ :title => l(:link_edit, :title => subfolder ? h(subfolder.title) : project.name)) %>
+ <% if subfolder %>
+ <%= link_to(image_tag('lock.png', :plugin => 'redmine_dmsf'),
+ lock_dmsf_path(:id => project, :folder_id => subfolder),
+ :title => l(:title_lock_file)) %>
+ <% else %>
- <% if (!locked_for_user || @force_file_unlock_allowed) && subfolder.unlockable? %>
- <%= link_to('',
- unlock_dmsf_path(:id => project, :folder_id => subfolder),
- :title => l(:title_unlock_file),
- :class => 'icon icon-dmsf-unlock')%>
- <% end %>
- <% end %>
-
+ <% end %>
+ <% if (subfolder && subfolder.notification) || (!subfolder && project.dmsf_notification) %>
+ <%= link_to(image_tag('notify.png', :plugin => 'redmine_dmsf'),
+ notify_deactivate_dmsf_path(:id => project, :folder_id => subfolder),
+ :title => l(:title_notifications_active_deactivate)) %>
+ <% else %>
+ <%= link_to(image_tag('notifynot.png', :plugin => 'redmine_dmsf'),
+ notify_activate_dmsf_path(:id => project, :folder_id => subfolder),
+ :title => l(:title_notifications_not_active_activate)) %>
+ <% end %>
+ <% if link %>
+ <%= link_to(image_tag('delete.png'),
+ dmsf_link_path(link),
+ :data => {:confirm => l(:text_are_you_sure)},
+ :method => :delete,
+ :title => l(:title_delete)) %>
+ <% else %>
+ <%= link_to(image_tag('delete.png'),
+ delete_dmsf_path(:id => project, :folder_id => subfolder),
+ :data => {:confirm => l(:text_are_you_sure)},
+ :title => l(:title_delete)) %>
+ <% end %>
+ <% else %>
+
+ <% if (!locked_for_user || @force_file_unlock_allowed) && subfolder.unlockable? %>
+ <%= link_to(image_tag('unlock.png', :plugin => 'redmine_dmsf'),
+ unlock_dmsf_path(:id => project, :folder_id => subfolder),
+ :title => l(:title_unlock_file)) %>
+ <% end %>
+ <% end %>
<% end %>
|
0 |
diff --git a/app/views/dmsf/_dir_trash.html.erb b/app/views/dmsf/_dir_trash.html.erb
index e708653b..904592c5 100644
--- a/app/views/dmsf/_dir_trash.html.erb
+++ b/app/views/dmsf/_dir_trash.html.erb
@@ -39,19 +39,15 @@
|
|
<%= h(subfolder.user) %> |
-
- <% if @folder_manipulation_allowed %>
-
- <%= link_to('',
- restore_dmsf_path(:id => project, :folder_id => subfolder),
- :title => l(:title_restore),
- :class => 'icon icon-dmsf-restore') %>
- <%= link_to('',
- delete_dmsf_path(:id => project, :folder_id => subfolder, :commit => 'yes'),
- :data => {:confirm => l(:text_are_you_sure)},
- :title => l(:title_delete),
- :class => 'icon icon-dmsf-rev-delete') %>
-
+ |
+ <% if @folder_manipulation_allowed %>
+ <%= link_to(image_tag('restore.png', :plugin => 'redmine_dmsf'),
+ restore_dmsf_path(:id => project, :folder_id => subfolder),
+ :title => l(:title_restore)) %>
+ <%= link_to(image_tag('rev_delete.png', :plugin => 'redmine_dmsf'),
+ delete_dmsf_path(:id => project, :folder_id => subfolder, :commit => 'yes'),
+ :data => {:confirm => l(:text_are_you_sure)},
+ :title => l(:title_delete)) %>
<% end %>
|
0 |
diff --git a/app/views/dmsf/_file.html.erb b/app/views/dmsf/_file.html.erb
index 2d9e0058..c5636c69 100644
--- a/app/views/dmsf/_file.html.erb
+++ b/app/views/dmsf/_file.html.erb
@@ -41,18 +41,16 @@
<%= format_time(file.last_revision.updated_at) %>
<% if locked_for_user %>
<% if file.lock.reverse[0].user %>
- <%= link_to('',
+ <%= link_to(image_tag(link ? 'locked_gray.png' : 'locked.png', :plugin => 'redmine_dmsf'),
user_path(file.lock.reverse[0].user),
- :title => l(:title_locked_by_user, :user => file.lock.reverse[0].user),
- :class => 'icon icon-dmsf-locked') %>
+ :title => l(:title_locked_by_user, :user => file.lock.reverse[0].user)) %>
<% else %>
- <%= content_tag(:span, '',
- :title => l(:notice_account_unknown_email),
- :class => 'icon icon-dmsf-locked') %>
+ <%= content_tag(:span, image_tag(link ? 'locked_gray.png' : 'locked.png', :plugin => 'redmine_dmsf'),
+ :title => l(:notice_account_unknown_email)) %>
<% end %>
<% elsif locked %>
- <%= content_tag(:span, '', :title => l(:title_locked_by_you),
- :class => 'icon icon-dmsf-lockedbycurrent') %>
+ <%= content_tag(:span, image_tag(link ? 'lockedbycurrent_gray.png' : 'lockedbycurrent.png', :plugin => 'redmine_dmsf'),
+ :title => l(:title_locked_by_you)) %>
<% end %>
|
<%= file.last_revision.version %> |
@@ -71,124 +69,110 @@
<% end %>
<%= h(file.last_revision.user) %> |
-
- <% if @file_manipulation_allowed || @file_approval_allowed %>
-
- <% if @file_manipulation_allowed %>
- <% unless locked %>
- <%= link_to('',
- dmsf_file_path(:id => file),
- :title => l(:link_details, :title => h(file.last_revision.title)),
- :class => 'icon icon-dmsf-file-details') %>
- <%= link_to('',
- lock_dmsf_files_path(:id => file),
- :title => l(:title_lock_file),
- :class => 'icon icon-dmsf-lock') %>
- <% if file.notification %>
- <%= link_to('',
- notify_deactivate_dmsf_files_path(:id => file),
- :title => l(:title_notifications_active_deactivate),
- :class => 'icon icon-notification-on') %>
- <% else %>
- <%= link_to('',
- notify_activate_dmsf_files_path(:id => file),
- :title => l(:title_notifications_not_active_activate),
- :class => 'icon icon-notification-off') %>
- <% end %>
- <% if link %>
- <%= link_to('',
- dmsf_link_path(link),
- :data => {:confirm => l(:text_are_you_sure)},
+ |
+ <% if @file_manipulation_allowed || @file_approval_allowed %>
+ <% if @file_manipulation_allowed %>
+ <% unless locked %>
+ <%= link_to(image_tag('filedetails.png', :plugin => 'redmine_dmsf'),
+ dmsf_file_path(:id => file),
+ :title => l(:link_details, :title => h(file.last_revision.title))) %>
+ <%= link_to(image_tag('lock.png', :plugin => 'redmine_dmsf'),
+ lock_dmsf_files_path(:id => file),
+ :title => l(:title_lock_file)) %>
+ <% if file.notification %>
+ <%= link_to(image_tag('notify.png', :plugin => 'redmine_dmsf'),
+ notify_deactivate_dmsf_files_path(:id => file),
+ :title => l(:title_notifications_active_deactivate)) %>
+ <% else %>
+ <%= link_to(image_tag('notifynot.png', :plugin => 'redmine_dmsf'),
+ notify_activate_dmsf_files_path(:id => file),
+ :title => l(:title_notifications_not_active_activate)) %>
+ <% end %>
+ <% if link %>
+ <%= link_to(image_tag('delete.png'),
+ dmsf_link_path(:id => file),
+ :data => {:confirm => l(:text_are_you_sure)},
:method => :delete,
- :title => l(:title_delete),
- :class => 'icon icon-del') %>
- <% else %>
- <% if @file_delete_allowed %>
- <%= link_to('',
- dmsf_file_path(:id => file),
- :data => {:confirm => l(:text_are_you_sure)},
- :method => :delete,
- :title => l(:title_delete),
- :class => 'icon icon-del') unless locked_for_user %>
- <% else %>
-
- <% end %>
- <% end %>
+ :title => l(:title_delete)) %>
<% else %>
-
- <% if (!locked_for_user || @force_file_unlock_allowed) && file.unlockable? %>
- <%= link_to('',
- unlock_dmsf_files_path(:id => file),
- :title => l(:title_unlock_file),
- :class => 'icon icon-dmsf-unlock')%>
+ <% if @file_delete_allowed %>
+ <%= link_to(image_tag('delete.png'),
+ dmsf_file_path(:id => file),
+ :data => {:confirm => l(:text_are_you_sure)},
+ :method => :delete,
+ :title => l(:title_delete)) unless locked_for_user %>
<% else %>
<% end %>
-
+ <% end %>
+ <% else %>
+
+ <% if (!locked_for_user || @force_file_unlock_allowed) && file.unlockable? %>
+ <%= link_to(image_tag('unlock.png', :plugin => 'redmine_dmsf'),
+ unlock_dmsf_files_path(:id => file),
+ :title => l(:title_unlock_file))%>
+ <% else %>
<% end %>
+
+
+
<% end %>
- <% if @file_approval_allowed %>
- <% case file.last_revision.workflow %>
- <% when DmsfWorkflow::STATE_WAITING_FOR_APPROVAL %>
- <% if wf %>
- <% assignments = wf.next_assignments(file.last_revision.id) %>
- <% index = assignments.find_index{|assignment| assignment.user_id == User.current.id} if assignments %>
- <% if index %>
- <%= link_to('',
- action_dmsf_workflow_path(
- :project_id => project.id,
- :id => wf.id,
- :dmsf_workflow_step_assignment_id => assignments[index].id,
- :dmsf_file_revision_id => file.last_revision.id),
- :title => l(:title_waiting_for_approval),
- :class => 'icon icon-dmsf-waiting-for-approval',
- :remote => true) %>
- <% else %>
- <%= content_tag(:span, '',
- :title => "#{l(:label_dmsf_wokflow_action_approve)} #{l(:label_dmsf_wokflow_action_reject)} #{l(:label_dmsf_wokflow_action_delegate)}",
- :class => 'icon icon-dmsf-waiting-for-approval') %>
- <% end %>
- <% else %>
- <%= content_tag(:span, '',
- :title => "#{l(:label_dmsf_wokflow_action_approve)} #{l(:label_dmsf_wokflow_action_reject)} #{l(:label_dmsf_wokflow_action_delegate)}",
- :class => 'icon icon-dmsf-waiting-for-approval') %>
- <% end %>
- <% when DmsfWorkflow::STATE_APPROVED %>
- <%= content_tag(:span, '', :title => l(:title_approved),
- :class => 'icon icon-dmsf-approved') %>
- <% when DmsfWorkflow::STATE_ASSIGNED %>
- <% if User.current && (file.last_revision.dmsf_workflow_assigned_by == User.current.id) && wf %>
- <%= link_to('',
- start_dmsf_workflow_path(
- :id => file.last_revision.dmsf_workflow_id,
+ <% end %>
+ <% if @file_approval_allowed %>
+ <% case file.last_revision.workflow %>
+ <% when DmsfWorkflow::STATE_WAITING_FOR_APPROVAL %>
+ <% if wf %>
+ <% assignments = wf.next_assignments(file.last_revision.id) %>
+ <% index = assignments.find_index{|assignment| assignment.user_id == User.current.id} if assignments %>
+ <% if index %>
+ <%= link_to(image_tag('waiting_for_approval.png', :plugin => 'redmine_dmsf'),
+ action_dmsf_workflow_path(
+ :project_id => project.id,
+ :id => wf.id,
+ :dmsf_workflow_step_assignment_id => assignments[index].id,
:dmsf_file_revision_id => file.last_revision.id),
- :title => l(:label_dmsf_wokflow_action_start),
- :class => 'icon icon-dmsf-assigned') %>
- <% else %>
- <%= content_tag(:span, '',
- title => l(:label_dmsf_wokflow_action_start),
- :class => 'icon icon-dmsf-assigned') %>
+ :title => l(:title_waiting_for_approval),
+ :remote => true) %>
+ <% else %>
+ <%= content_tag(:span, image_tag('waiting_for_approval.png', :plugin => 'redmine_dmsf'),
+ :title => "#{l(:label_dmsf_wokflow_action_approve)} #{l(:label_dmsf_wokflow_action_reject)} #{l(:label_dmsf_wokflow_action_delegate)}") %>
<% end %>
- <% when DmsfWorkflow::STATE_REJECTED %>
- <%= content_tag(:span, '', :title => l(:title_rejected),
- :class => 'icon icon-dmsf-rejected') %>
- <% else %>
- <% if @workflows_available %>
- <%= link_to('',
- assign_dmsf_workflow_path(
- :project_id => project.id,
- :dmsf_file_revision_id => file.last_revision.id),
- :title => l(:label_dmsf_wokflow_action_assign),
- :class => 'icon icon-dmsf-none',
- :remote => true) %>
- <% end %>
- <% end %>
- <% end %>
-
+ <% else %>
+ <%= content_tag(:span, image_tag('waiting_for_approval.png', :plugin => 'redmine_dmsf'),
+ :title => "#{l(:label_dmsf_wokflow_action_approve)} #{l(:label_dmsf_wokflow_action_reject)} #{l(:label_dmsf_wokflow_action_delegate)}") %>
+ <% end %>
+ <% when DmsfWorkflow::STATE_APPROVED %>
+ <%= content_tag(:span, image_tag('approved.png', :plugin => 'redmine_dmsf'),
+ :title => l(:title_approved)) %>
+ <% when DmsfWorkflow::STATE_ASSIGNED %>
+ <% if User.current && (file.last_revision.dmsf_workflow_assigned_by == User.current.id) && wf %>
+ <%= link_to(image_tag('assigned.png', :plugin => 'redmine_dmsf'),
+ start_dmsf_workflow_path(
+ :id => file.last_revision.dmsf_workflow_id,
+ :dmsf_file_revision_id => file.last_revision.id),
+ :title => l(:label_dmsf_wokflow_action_start)) %>
+ <% else %>
+ <%= content_tag(:span, image_tag('assigned.png', :plugin => 'redmine_dmsf'),
+ title => l(:label_dmsf_wokflow_action_start)) %>
+ <% end %>
+ <% when DmsfWorkflow::STATE_REJECTED %>
+ <%= content_tag(:span, image_tag('assigned.png', :plugin => 'redmine_dmsf'),
+ :title => l(:title_rejected)) %>
+ <% else %>
+ <% if @workflows_available %>
+ <%= link_to(image_tag('none.png', :plugin => 'redmine_dmsf'),
+ assign_dmsf_workflow_path(
+ :project_id => project.id,
+ :dmsf_file_revision_id => file.last_revision.id),
+ :title => l(:label_dmsf_wokflow_action_assign),
+ :remote => true) %>
+ <% end %>
+ <% end %>
+ <% end %>
<% end %>
|
1 |
<%= file.last_revision.size %> |
<%= file.last_revision.updated_at.to_i %> |
-<%= file.last_revision.iversion %> |
+<%= file.last_revision.iversion %> |
\ No newline at end of file
diff --git a/app/views/dmsf/_file_trash.html.erb b/app/views/dmsf/_file_trash.html.erb
index b00d59cc..d4327977 100644
--- a/app/views/dmsf/_file_trash.html.erb
+++ b/app/views/dmsf/_file_trash.html.erb
@@ -1,4 +1,6 @@
<%#=
+# encoding: utf-8
+#
# Redmine plugin for Document Management System "Features"
#
# Copyright (C) 2011-15 Karel Pičman
@@ -35,20 +37,16 @@
<%= file.last_revision.workflow_str(false) %>
<%= h(file.last_revision.user) %> |
-
- <% if @file_manipulation_allowed %>
-
- <%= link_to('',
- restore_dmsf_file_path(:id => file),
- :title => l(:title_restore),
- :class => 'icon icon-dmsf-restore') %>
- <%= link_to('',
- dmsf_file_path(:id => file, :commit => 'yes'),
- :data => {:confirm => l(:text_are_you_sure)},
- :method => :delete,
- :title => l(:title_delete),
- :class => 'icon icon-dmsf-rev-delete') %>
-
+ |
+ <% if @file_manipulation_allowed %>
+ <%= link_to(image_tag('restore.png', :plugin => 'redmine_dmsf'),
+ restore_dmsf_file_path(:id => file),
+ :title => l(:title_restore)) %>
+ <%= link_to(image_tag('rev_delete.png', :plugin => 'redmine_dmsf'),
+ dmsf_file_path(:id => file, :commit => 'yes'),
+ :data => {:confirm => l(:text_are_you_sure)},
+ :method => :delete,
+ :title => l(:title_delete)) %>
<% end %>
|
1 |
diff --git a/app/views/dmsf/_path.html.erb b/app/views/dmsf/_path.html.erb
index 720314d4..1534f402 100644
--- a/app/views/dmsf/_path.html.erb
+++ b/app/views/dmsf/_path.html.erb
@@ -1,6 +1,9 @@
-<%# Redmine plugin for Document Management System "Features"
+<%
+# encoding: utf-8
#
-# Copyright (C) 2013 Karel Pičman
+# Redmine plugin for Document Management System "Features"
+#
+# Copyright (C) 2011-15 Karel Pičman
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
diff --git a/app/views/dmsf/_url.html.erb b/app/views/dmsf/_url.html.erb
index 15699e0b..e18ed728 100644
--- a/app/views/dmsf/_url.html.erb
+++ b/app/views/dmsf/_url.html.erb
@@ -33,26 +33,23 @@
|
|
<%= h(link.user) %> |
-
- <% if @file_manipulation_allowed %>
-
- <% if @file_manipulation_allowed %>
-
-
-
- <%= link_to('',
- dmsf_link_path(link),
- :data => {:confirm => l(:text_are_you_sure)},
- :method => :delete,
- :title => l(:title_delete),
- :class => 'icon icon-del') %>
- <% else %>
-
-
-
-
- <% end %>
-
+ |
+ <% if @file_manipulation_allowed %>
+ <% if @file_manipulation_allowed %>
+
+
+
+ <%= link_to('delete.png',
+ dmsf_link_path(link),
+ :data => {:confirm => l(:text_are_you_sure)},
+ :method => :delete,
+ :title => l(:title_delete)) %>
+ <% else %>
+
+
+
+
+ <% end %>
<% end %>
|
1 |
diff --git a/app/views/dmsf/_url_trash.html.erb b/app/views/dmsf/_url_trash.html.erb
index be7ebe7e..926e9bf7 100644
--- a/app/views/dmsf/_url_trash.html.erb
+++ b/app/views/dmsf/_url_trash.html.erb
@@ -23,32 +23,28 @@
<%= check_box_tag(name, id, false,
:title => l(:title_check_for_restore_or_delete)) %> |
- <%= link_to(h(title),
- link.external_url,
- :target => "_blank",
- :class => 'icon icon-link') %>
- <%= link.external_url %>
+ <%= link_to(h(title),
+ link.external_url,
+ :target => "_blank",
+ :class => 'icon icon-link') %>
+ <%= link.external_url %>
|
|
<%= format_time(link.updated_at) %> |
|
|
<%= h(link.user) %> |
-
- <% if @file_manipulation_allowed %>
-
- <%= link_to('',
- restore_dmsf_link_path(:id => link),
- :title => l(:title_restore),
- :class => 'icon icon-dmsf-restore') %>
- <%= link_to('',
- dmsf_link_path(:id => link, :commit => 'yes'),
- :data => {:confirm => l(:text_are_you_sure)},
- :method => :delete,
- :title => l(:title_delete),
- :class => 'icon icon-dmsf-rev-delete') %>
-
- <% end %>
+ |
+ <% if @file_manipulation_allowed %>
+ <%= link_to(image_tag('restore.png', :plugin => 'redmine_dmsf'),
+ restore_dmsf_link_path(:id => link),
+ :title => l(:title_restore)) %>
+ <%= link_to(image_tag('rev_delete.png', :plugin => 'redmine_dmsf'),
+ dmsf_link_path(:id => link, :commit => 'yes'),
+ :data => {:confirm => l(:text_are_you_sure)},
+ :method => :delete,
+ :title => l(:title_delete)) %>
+ <% end %>
|
1 |
|
diff --git a/app/views/dmsf_files/show.html.erb b/app/views/dmsf_files/show.html.erb
index aec16f88..bc1d05d8 100644
--- a/app/views/dmsf_files/show.html.erb
+++ b/app/views/dmsf_files/show.html.erb
@@ -72,20 +72,16 @@