From c856b4cdce15925bac4c5fe08860cbf4d9673342 Mon Sep 17 00:00:00 2001 From: Christophe Vilayphiou Date: Tue, 24 Apr 2012 12:41:28 +0800 Subject: [PATCH] Fix for upload image component in announcement --- app/views/admin/ad_images/_form.html.erb | 33 +++++++++---------- config/locales/en.yml | 1 + config/locales/zh_tw.yml | 1 + .../back_end/bulletins/_form.html.erb | 25 ++++++++++---- 4 files changed, 35 insertions(+), 25 deletions(-) diff --git a/app/views/admin/ad_images/_form.html.erb b/app/views/admin/ad_images/_form.html.erb index e9d60374..790f371b 100644 --- a/app/views/admin/ad_images/_form.html.erb +++ b/app/views/admin/ad_images/_form.html.erb @@ -75,27 +75,24 @@

Picture

-
-
- - <%= image_tag @ad_image.file rescue ''%> -
- 此區塊圖片尺寸請使用580px × 225px -
- - -
- - - -
+
+
+ + <%= image_tag @ad_image.file rescue ''%> +
+ 此區塊圖片尺寸請使用580px × 225px +
+ + +
+
+
diff --git a/config/locales/en.yml b/config/locales/en.yml index f34557ca..de58faa7 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -9,6 +9,7 @@ en: account_settings: Account settings add: Add back: Back + browse: Browse cancel: Cancel create: Create delete: Delete diff --git a/config/locales/zh_tw.yml b/config/locales/zh_tw.yml index 2615c99c..cc185ab5 100644 --- a/config/locales/zh_tw.yml +++ b/config/locales/zh_tw.yml @@ -6,6 +6,7 @@ zh_tw: account_settings: 帳號設定 add: 新增 back: 回上一步 + browse: 選擇檔案 cancel: 取消 create: 創建 delete: 刪除 diff --git a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form.html.erb b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form.html.erb index fe35d98d..d9c62078 100644 --- a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form.html.erb +++ b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form.html.erb @@ -4,23 +4,31 @@ <%= f.error_messages %>
-
+

Picture

- - -
-
+ +
@@ -281,6 +291,7 @@ <% content_for :page_specific_javascript do %> <%= javascript_include_tag "bulletin_form" %> + <%= javascript_include_tag "inc/jquery.imagesloaded" %>