Access to plugin settings syntax changed
This commit is contained in:
parent
87f7932052
commit
747c503331
@ -516,7 +516,7 @@ class DmsfController < ApplicationController
|
||||
recipients.each do |u|
|
||||
DmsfMailer.files_deleted(u, @project, deleted_files).deliver
|
||||
end
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
unless recipients.empty?
|
||||
to = recipients.collect{ |r| r.name }.first(DMSF_MAX_NOTIFICATION_RECEIVERS_INFO).join(', ')
|
||||
to << ((recipients.count > DMSF_MAX_NOTIFICATION_RECEIVERS_INFO) ? ',...' : '.')
|
||||
|
||||
@ -170,7 +170,7 @@ class DmsfFilesController < ApplicationController
|
||||
recipients.each do |u|
|
||||
DmsfMailer.files_updated(u, @project, [@file]).deliver
|
||||
end
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
unless recipients.empty?
|
||||
to = recipients.collect{ |r| r.name }.first(DMSF_MAX_NOTIFICATION_RECEIVERS_INFO).join(', ')
|
||||
to << ((recipients.count > DMSF_MAX_NOTIFICATION_RECEIVERS_INFO) ? ',...' : '.')
|
||||
@ -203,7 +203,7 @@ class DmsfFilesController < ApplicationController
|
||||
recipients.each do |u|
|
||||
DmsfMailer.files_deleted(u, @project, [@file]).deliver
|
||||
end
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
unless recipients.empty?
|
||||
to = recipients.collect{ |r| r.name }.first(DMSF_MAX_NOTIFICATION_RECEIVERS_INFO).join(', ')
|
||||
to << ((recipients.count > DMSF_MAX_NOTIFICATION_RECEIVERS_INFO) ? ',...' : '.')
|
||||
|
||||
@ -81,7 +81,7 @@ class DmsfWorkflowsController < ApplicationController
|
||||
:text_email_finished_approved,
|
||||
:text_email_to_see_history).deliver if user
|
||||
end
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
unless recipients.blank?
|
||||
to = recipients.collect{ |r| r.name }.first(DMSF_MAX_NOTIFICATION_RECEIVERS_INFO).join(', ')
|
||||
to << ((recipients.count > DMSF_MAX_NOTIFICATION_RECEIVERS_INFO) ? ',...' : '.')
|
||||
@ -104,7 +104,7 @@ class DmsfWorkflowsController < ApplicationController
|
||||
:text_email_to_see_history,
|
||||
action.note).deliver
|
||||
end
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
unless recipients.blank?
|
||||
to = recipients.collect{ |r| r.name }.first(DMSF_MAX_NOTIFICATION_RECEIVERS_INFO).join(', ')
|
||||
to << ((recipients.count > DMSF_MAX_NOTIFICATION_RECEIVERS_INFO) ? ',...' : '.')
|
||||
@ -125,7 +125,7 @@ class DmsfWorkflowsController < ApplicationController
|
||||
:text_email_finished_delegated,
|
||||
:text_email_to_proceed,
|
||||
action.note).deliver
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
flash[:warning] = l(:warning_email_notifications, :to => delegate.name)
|
||||
end
|
||||
end
|
||||
@ -156,7 +156,7 @@ class DmsfWorkflowsController < ApplicationController
|
||||
:text_email_finished_step_short,
|
||||
:text_email_to_see_status).deliver
|
||||
end
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
recipients = assignments.collect{ |a| a.user }
|
||||
recipients << to if to
|
||||
recipients.uniq!
|
||||
|
||||
@ -40,7 +40,7 @@ module DmsfUploadHelper
|
||||
file.project_id = project.id
|
||||
file.name = name
|
||||
file.dmsf_folder = folder
|
||||
file.notification = Setting.plugin_redmine_dmsf[:dmsf_default_notifications].present?
|
||||
file.notification = Setting.plugin_redmine_dmsf['dmsf_default_notifications'].present?
|
||||
new_revision.minor_version = 0
|
||||
new_revision.major_version = 0
|
||||
else
|
||||
@ -140,7 +140,7 @@ module DmsfUploadHelper
|
||||
recipients.each do |u|
|
||||
DmsfMailer.files_updated(u, project, files).deliver
|
||||
end
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
unless recipients.empty?
|
||||
to = recipients.collect{ |r| r.name }.first(DMSF_MAX_NOTIFICATION_RECEIVERS_INFO).join(', ')
|
||||
to << ((recipients.count > DMSF_MAX_NOTIFICATION_RECEIVERS_INFO) ? ',...' : '.')
|
||||
|
||||
@ -231,7 +231,7 @@ class DmsfWorkflow < ActiveRecord::Base
|
||||
:text_email_started,
|
||||
:text_email_to_proceed).deliver
|
||||
end
|
||||
if Setting.plugin_redmine_dmsf[:dmsf_display_notified_recipients] == '1'
|
||||
if Setting.plugin_redmine_dmsf['dmsf_display_notified_recipients'] == '1'
|
||||
unless recipients.blank?
|
||||
to = recipients.collect{ |r| r.name }.first(DMSF_MAX_NOTIFICATION_RECEIVERS_INFO).join(', ')
|
||||
to << ((recipients.count > DMSF_MAX_NOTIFICATION_RECEIVERS_INFO) ? ',...' : '.')
|
||||
|
||||
@ -53,7 +53,9 @@
|
||||
<% else %>
|
||||
<span class="icon"></span>
|
||||
<% end %>
|
||||
<% when DmsfWorkflow::STATE_APPROVED, DmsfWorkflow::STATE_REJECTED %>
|
||||
<% when DmsfWorkflow::STATE_APPROVED %>
|
||||
<span class="icon-only"></span>
|
||||
<% when DmsfWorkflow::STATE_REJECTED %>
|
||||
<span class="icon-only"></span>
|
||||
<% else %>
|
||||
<% if workflows_available %>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user