aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/admin_public_body_controller.rb
diff options
context:
space:
mode:
authorDavid Cabo <david@calibea.com>2011-08-12 13:12:50 +0200
committerDavid Cabo <david@calibea.com>2011-08-12 13:12:50 +0200
commitdf1754847892bb6abce2681a42d8c50cf8d3a2da (patch)
tree73c518103906ad446cedd55c69690d8d91f0f362 /app/controllers/admin_public_body_controller.rb
parenta63e598b9e0ddfa7ac695b1be41aaace6c0eb628 (diff)
parent766df1c7de8f820bd6e451526787632a136bc635 (diff)
Merge branch 'master' of github.com:sebbacon/alaveteli into asktheeu
Conflicts: locale/cy/app.po locale/de/app.po locale/es/app.po locale/fr/app.po locale/sq/app.po locale/sr/app.po locale/sr@latin/app.po
Diffstat (limited to 'app/controllers/admin_public_body_controller.rb')
-rw-r--r--app/controllers/admin_public_body_controller.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/controllers/admin_public_body_controller.rb b/app/controllers/admin_public_body_controller.rb
index f88b25572..021122734 100644
--- a/app/controllers/admin_public_body_controller.rb
+++ b/app/controllers/admin_public_body_controller.rb
@@ -154,10 +154,10 @@ class AdminPublicBodyController < AdminController
else
raise "internal error, unknown button label"
end
-
+
# Try with dry run first
csv_contents = params[:csv_file].read
- en = PublicBody.import_csv(csv_contents, params[:tag], true, admin_http_auth_user())
+ en = PublicBody.import_csv(csv_contents, params[:tag], true, admin_http_auth_user(), I18n.available_locales)
errors = en[0]
notes = en[1]
@@ -166,7 +166,7 @@ class AdminPublicBodyController < AdminController
notes.push("Dry run was successful, real run would do as above.")
else
# And if OK, with real run
- en = PublicBody.import_csv(csv_contents, params[:tag], false, admin_http_auth_user())
+ en = PublicBody.import_csv(csv_contents, params[:tag], false, admin_http_auth_user(), available_locales)
errors = en[0]
notes = en[1]
if errors.size != 0