diff --git a/app/controllers/organisations_controller.rb b/app/controllers/organisations_controller.rb
index 7caca1c..efc395f 100644
--- a/app/controllers/organisations_controller.rb
+++ b/app/controllers/organisations_controller.rb
@@ -59,6 +59,8 @@
if user_signed_in? && current_user.is_org_admin? then
@organisation = Organisation.find(params[:id])
+ @logo_max_height = Dragonfly::LOGO_MAX_HEIGHT
+ @logo_max_width = Dragonfly::LOGO_MAX_WIDTH
else
render(:file => File.join(Rails.root, 'public/403.html'), :status => 403, :layout => false)
end
@@ -80,8 +82,9 @@
format.html { redirect_to admin_show_organisation_path(params[:id]), notice: I18n.t("admin.org_updated_message") }
format.json { head :no_content }
else
- flash[:alert] = I18n.t("org_admin.org_logo_failed_message")
- format.html { render action: "admin_edit" }
+ flash[:alert] = @organisation.errors.full_messages.join("
").html_safe if @organisation.errors.any?
+
+ format.html { render action: "admin_edit" }
format.json { render json: @organisation.errors, status: :unprocessable_entity }
end
end
diff --git a/app/views/organisations/admin_edit.html.erb b/app/views/organisations/admin_edit.html.erb
index c03379c..37ed08f 100644
--- a/app/views/organisations/admin_edit.html.erb
+++ b/app/views/organisations/admin_edit.html.erb
@@ -1,13 +1,6 @@
<%= stylesheet_link_tag "admin" %>
<% javascript 'admin.js' %>
-<% if @organisation.errors.any? %>
-
- <% @organisation.errors.full_messages.each do |msg| %>
- - <%= msg %>
- <% end %>
-
-<% end %>
<%= t('org_admin.org_details_label') %>
diff --git a/config/locales/de.yml b/config/locales/de.yml
index 2090542..8650c18 100644
--- a/config/locales/de.yml
+++ b/config/locales/de.yml
@@ -107,6 +107,10 @@
user_text_html: "Folgend findet sich die Liste von Benutzern registriert bzgl. Ihrer Organisation. Sie können diese Liste bzgl. aller Felder sortieren."
org_name: "Name"
org_abbr: "Abkürzung"
+ org_logo_failed_message: "Logo Upload fehlgeschlagen."
+ org_logo: "Logo (160 x 160)"
+ new_org_logo: "Laden Sie ein neues Logo-Datei (160 x 160)"
+ remove_logo: "Wenn Sie die Standard DMPRoadmap Logo verwenden entscheiden , prüfen Sie bitte dieses Feld Ihre aktuelle Logo zu entfernen."
org_desc: "Beschreibung"
org_target_url: "Web-Seite"
org_type: "Organisationsart"
diff --git a/config/locales/en-UK.yml b/config/locales/en-UK.yml
index 0ee0ccd..0e94e1f 100644
--- a/config/locales/en-UK.yml
+++ b/config/locales/en-UK.yml
@@ -149,10 +149,10 @@
user_text_html: "Below is a list of users registered for your organisation. You can sort the data by each field."
org_name: "Name"
org_abbr: "Abbreviation"
- org_logo_failed_message: "Logo Upload Failed. "
- org_logo: "Logo"
- new_org_logo: "Upload a new logo file"
- remove_logo: "If you decide to use the default DCC logo, please check this box to remove your current logo."
+ org_logo_failed_message: "Logo Upload Failed."
+ org_logo: "Logo (160 x 160)"
+ new_org_logo: "Upload a new logo file (160 x 160)"
+ remove_logo: "If you decide to use the default DMPRoadmap logo, please check this box to remove your current logo."
org_desc: "Description"
org_banner_text: "Top banner text"
org_target_url: "Website"
diff --git a/config/locales/en-US.yml b/config/locales/en-US.yml
index 48e3742..bc2182c 100644
--- a/config/locales/en-US.yml
+++ b/config/locales/en-US.yml
@@ -141,6 +141,10 @@
user_text_html: "Below is a list of users registered for your organization. You can sort the data by each field."
org_name: "Name"
org_abbr: "Abbreviation"
+ org_logo_failed_message: "Logo Upload Failed."
+ org_logo: "Logo (160 x 160)"
+ new_org_logo: "Upload a new logo file (160 x 160)"
+ remove_logo: "If you decide to use the default DMPRoadmap logo, please check this box to remove your current logo."
org_desc: "Description"
org_banner_text: "Top banner text"
org_target_url: "Website"
diff --git a/config/locales/fr.yml b/config/locales/fr.yml
index 89f8880..ef30d5c 100644
--- a/config/locales/fr.yml
+++ b/config/locales/fr.yml
@@ -114,6 +114,10 @@
user_text_html: " Vous trouverez ci-dessous une liste des utilisateurs inscrits pour votre organisme. Vous pouvez trier les données par champ."
org_name: "Nom"
org_abbr: "Abréviation"
+ org_logo_failed_message: "Logo Échec de l'envoi."
+ org_logo: "Logo (160 x 160)"
+ new_org_logo: "Ajouter un nouveau fichier de logo (160 x 160)"
+ remove_logo: "Si vous décidez d'utiliser le logo de DMPRoadmap par défaut , s'il vous plaît cocher cette case pour supprimer votre logo actuel."
org_desc: "Description"
org_target_url: "Site Web"
org_type: "Type d'organisme"