diff --git a/app/assets/images/Thumbs.db b/app/assets/images/Thumbs.db deleted file mode 100644 index f9d32b5f6..000000000 Binary files a/app/assets/images/Thumbs.db and /dev/null differ diff --git a/lib/fraisier/images/Thumbs.db b/lib/fraisier/images/Thumbs.db deleted file mode 100755 index 5275e13b7..000000000 Binary files a/lib/fraisier/images/Thumbs.db and /dev/null differ diff --git a/vendor/built_in_modules/announcement/app/controllers/panel/announcement/back_end/bulletins_controller.rb b/vendor/built_in_modules/announcement/app/controllers/panel/announcement/back_end/bulletins_controller.rb index 47c97b294..cffe25855 100644 --- a/vendor/built_in_modules/announcement/app/controllers/panel/announcement/back_end/bulletins_controller.rb +++ b/vendor/built_in_modules/announcement/app/controllers/panel/announcement/back_end/bulletins_controller.rb @@ -13,7 +13,7 @@ class Panel::Announcement::BackEnd::BulletinsController < OrbitBackendController # @bulletins = Bulletin.search(params[:search], params[:category_id]) # @bulletins = Bulletin.all.order_by([params[:sort], params[:direction]]) - @bulletins = params[:sort] ? get_sorted_bulletins : Bulletin.all.desc("postdate").page(params[:page]).per(10) + @bulletins = params[:sort] ? get_sorted_bulletins : Bulletin.all @bulletin_categories = BulletinCategory.all @bulletin_link = BulletinLink.new diff --git a/vendor/built_in_modules/announcement/app/models/bulletin_file.rb b/vendor/built_in_modules/announcement/app/models/bulletin_file.rb index 058945158..c4d60b9b8 100644 --- a/vendor/built_in_modules/announcement/app/models/bulletin_file.rb +++ b/vendor/built_in_modules/announcement/app/models/bulletin_file.rb @@ -16,6 +16,15 @@ class BulletinFile belongs_to :bulletin # embedded_in :bulletin + before_save :set_key + + def filetitle + @filetitle ||= I18nVariable.first(:conditions => {:key => 'filetitle', :language_value_id => self.id, :language_value_type => self.class}) rescue nil + end + + def description + @description ||= I18nVariable.first(:conditions => {:key => 'description', :language_value_id => self.id, :language_value_type => self.class}) rescue nil + end protected diff --git a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletin_categorys/_bulletin_category.html.erb b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletin_categorys/_bulletin_category.html.erb index bf02b054e..7f1b56268 100644 --- a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletin_categorys/_bulletin_category.html.erb +++ b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletin_categorys/_bulletin_category.html.erb @@ -5,7 +5,6 @@
diff --git a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletin_categorys/quick_edit.js.erb b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletin_categorys/quick_edit.js.erb deleted file mode 100644 index 7db1d0f81..000000000 --- a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletin_categorys/quick_edit.js.erb +++ /dev/null @@ -1,3 +0,0 @@ -$.each($(".quick_edit"),function(obj){ $(this).remove(); }); -$("#<%= dom_id @bulletin_category %>").append("
<%= j render "form" %>
"); -//$("#form > form").replaceWith("<%= j render "form" %>"); 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 4496cdefc..59c2c92e7 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 @@ -132,60 +132,47 @@ <%= f.label :category %> <%= f.select :bulletin_category_id, @bulletin_categorys.collect{|t| [ t.i18n_variable[I18n.locale], t.id ]}, {}, :class => "input-medium" %> - + +
-
+ + <% @site_valid_locales.each_with_index do |locale, i| %> + +
"> +
- -
-
-
+ <%= f.label :title %> + <%= f.fields_for :title, (@bulletin.new_record? ? @bulletin.build_title : @bulletin.title ) do |f| %> + <%= I18nVariable.from_locale(locale) %> + <%= f.text_field locale, :class=>'post-title' %> + <% end %> +
+
- -
-
-
+ <%= f.label :subtitle %> + <%= f.fields_for :subtitle, (@bulletin.new_record? ? @bulletin.build_subtitle : @bulletin.subtitle ) do |f| %> + <%= I18nVariable.from_locale(locale) %> + <%= f.text_area locale, :style=>"width:100%" %> + <% end %> +
+ +
+ <%= f.label :text %> + <%= f.fields_for :text, (@bulletin.new_record? ? @bulletin.build_text : @bulletin.text ) do |f| %> + <%= I18nVariable.from_locale(locale) %> + <%= f.text_area locale, :style=>"width:100%" %> + <% end %> +
+
- -
- <%= f.label :title %> - <%= f.fields_for :title, (@bulletin.new_record? ? @bulletin.build_title : @bulletin.title ) do |f| %> - <% @site_valid_locales.each do |locale| %> - - <%= I18nVariable.from_locale(locale) %> - <%= f.text_field locale, :class=>'post-title' %> - - <% end %> - <% end %> -
- -
- <%= f.label :subtitle %> - <%= f.fields_for :subtitle, (@bulletin.new_record? ? @bulletin.build_subtitle : @bulletin.subtitle ) do |f| %> - <% @site_valid_locales.each do |locale| %> - - <%= I18nVariable.from_locale(locale) %> - <%= f.text_area locale, :style=>"width:100%", :class => 'tinymce_textarea' %> - - <% end %> - <% end %> -
- -
- <%= f.label :text %> - <%= f.fields_for :text, (@bulletin.new_record? ? @bulletin.build_text : @bulletin.text ) do |f| %> - <% @site_valid_locales.each do |locale| %> - - <%= I18nVariable.from_locale(locale) %> - <%= f.text_area locale, :style=>"width:100%", :class => 'tinymce_textarea' %> - - <% end %> <% end %> +
@@ -202,11 +189,7 @@ URL - <% @site_valid_locales.each do |locale| %> -
- Name - <%= I18nVariable.first(:conditions => {:key => locale})[I18n.locale] %> -
- <% end %> + Name diff --git a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form_bulletin_file.html.erb b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form_bulletin_file.html.erb index 65ac2fb81..0f332069a 100644 --- a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form_bulletin_file.html.erb +++ b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form_bulletin_file.html.erb @@ -8,29 +8,53 @@
- <%= f.fields_for :filetitle, (form_bulletin_file.new_record? ? form_bulletin_file.build_filetitle : form_bulletin_file.filetitle ) do |f| %> - <% @site_valid_locales.each do |locale| %> -
- -
- <%= f.text_field locale, :id => "link-#{locale}", :class => "input-xlarge" %> -
+ +
+ + <% @site_valid_locales.each_with_index do |locale, i| %> + +
"> + + <%= f.fields_for :filetitle, (form_bulletin_file.new_record? ? form_bulletin_file.build_filetitle : form_bulletin_file.filetitle ) do |f| %> +
+ +
+ <%= f.text_field locale, :id => "link-#{locale}", :class => "input-xlarge" %> +
+
+ <% end %> +
- <% end %> - <% end %> - - - <%= f.fields_for :description, (form_bulletin_file.new_record? ? form_bulletin_file.build_description : form_bulletin_file.description ) do |f| %> - <% @site_valid_locales.each do |locale| %> -
- -
- <%= f.text_field locale, :id => "link-#{locale}", :class => "input-xlarge" %> -
-
- <% end %> - <% end %> + + <% end %> + +
+ + + +
+ + <% @site_valid_locales.each_with_index do |locale, i| %> + +
"> + + <%= f.fields_for :description, (form_bulletin_file.new_record? ? form_bulletin_file.build_description : form_bulletin_file.description ) do |f| %> +
+ +
+ <%= f.text_field locale, :id => "link-#{locale}", :class => "input-xlarge" %> +
+
+ <% end %> + +
+ + <% end %> + +
+ + <% if form_bulletin_file.new_record? %> diff --git a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form_bulletin_link.html.erb b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form_bulletin_link.html.erb index 560e561d1..cfd913588 100644 --- a/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form_bulletin_link.html.erb +++ b/vendor/built_in_modules/announcement/app/views/panel/announcement/back_end/bulletins/_form_bulletin_link.html.erb @@ -8,19 +8,29 @@
- - <%= f.fields_for :i18n_variable, (form_bulletin_link.new_record? ? form_bulletin_link.build_i18n_variable : form_bulletin_link.i18n_variable) do |f| %> - <% @site_valid_locales.each do |locale| %> -
-
- <%= f.text_field locale, :id => "link-#{locale}", :class => "input-xlarge" %> -
-
- - + + + +
+ + <% @site_valid_locales.each_with_index do |locale, i| %> - <% end %> - <% end %> +
"> + + <%= f.fields_for :i18n_variable, (form_bulletin_link.new_record? ? form_bulletin_link.build_i18n_variable : form_bulletin_link.i18n_variable) do |f| %> +
+ +
+ <%= f.text_field locale, :id => "link-#{locale}", :class => "input-xlarge" %> +
+
+ <% end %> + +
+ + <% end %> + +
diff --git a/vendor/built_in_modules/announcement/config/routes.rb b/vendor/built_in_modules/announcement/config/routes.rb index 7ac33a900..fc1ef4f07 100644 --- a/vendor/built_in_modules/announcement/config/routes.rb +++ b/vendor/built_in_modules/announcement/config/routes.rb @@ -17,9 +17,7 @@ Rails.application.routes.draw do match "file_quick_edit/:bulletin_id" => "bulletins#file_quick_edit" ,:as => :file_quick_edit end - resources :bulletin_categorys, :controller => 'bulletin_categorys' do - match "quick_edit/:bulletin_category_id" => "bulletin_categorys#quick_edit" ,:as => :quick_edit - end + resources :bulletin_categorys resources :bulletin_links, :controller => 'bulletin_links' do match "link_quick_edit/:bulletin_link_id" => "bulletin_links#link_quick_edit" ,:as => :link_quick_edit diff --git a/vendor/built_in_modules/page_content/app/views/panel/page_content/back_end/page_contexts/_form.html.erb b/vendor/built_in_modules/page_content/app/views/panel/page_content/back_end/page_contexts/_form.html.erb index 3c734bb05..595973d31 100644 --- a/vendor/built_in_modules/page_content/app/views/panel/page_content/back_end/page_contexts/_form.html.erb +++ b/vendor/built_in_modules/page_content/app/views/panel/page_content/back_end/page_contexts/_form.html.erb @@ -9,16 +9,30 @@ <%= @page_context.page.i18n_variable[I18n.locale] %> -
- <%= f.label :context %> - <%= f.fields_for :context, (@page_context.new_record? ? @page_context.build_context : @page_context.context ) do |f| %> - <% @site_valid_locales.each do |locale| %> - + + +
+ + <% @site_valid_locales.each_with_index do |locale, i| %> + +
"> + +
+ <%= f.label :context %> + <%= f.fields_for :context, (@page_context.new_record? ? @page_context.build_context : @page_context.context ) do |f| %> <%= I18nVariable.from_locale(locale) %> <%= f.text_area locale, :style=>"width:100%", :class => 'tinymce_textarea' %> - - <% end %> + <% end %> +
+ +
+ <% end %> +
diff --git a/vendor/built_in_modules/web_resource/app/views/panel/web_resource/back_end/web_links/_form.html.erb b/vendor/built_in_modules/web_resource/app/views/panel/web_resource/back_end/web_links/_form.html.erb index de1630129..22c206886 100644 --- a/vendor/built_in_modules/web_resource/app/views/panel/web_resource/back_end/web_links/_form.html.erb +++ b/vendor/built_in_modules/web_resource/app/views/panel/web_resource/back_end/web_links/_form.html.erb @@ -44,51 +44,44 @@ <%= f.label :category %> <%= f.select :web_link_category_id, @web_link_categorys.collect {|t| [ t.i18n_variable[I18n.locale], t.id ]} %> - -
- - English - - - -
- -
- <%= f.label :name %> - <%= f.fields_for :name, (@web_link.new_record? ? @web_link.build_name : @web_link.name ) do |f| %> - <% @site_valid_locales.each do |locale| %> - - <%= I18nVariable.from_locale(locale) %> - <%= f.text_field locale, :class=>'post-title' %> - - <% end %> + + + +
+ + <% @site_valid_locales.each_with_index do |locale, i| %> + +
"> +
+ <%= f.label :name %> + <%= f.fields_for :name, (@web_link.new_record? ? @web_link.build_name : @web_link.name ) do |f| %> + <%= I18nVariable.from_locale(locale) %> + <%= f.text_field locale, :class=>'post-title' %> + <% end %> +
+ +
+ <%= f.label :describe %> + <%= f.fields_for :context, (@web_link.new_record? ? @web_link.build_context : @web_link.context ) do |f| %> + <%= I18nVariable.from_locale(locale) %> + <%= f.text_area locale, :style=>"width:100%" %> + <% end %> +
+ +
+ + <% end %> +
<%= f.label :url %> <%= f.text_field :url %>
- -
- <%= f.label :describe %> - <%= f.fields_for :context, (@web_link.new_record? ? @web_link.build_context : @web_link.context ) do |f| %> - <% @site_valid_locales.each do |locale| %> - - <%= I18nVariable.from_locale(locale) %> - <%= f.text_area locale, :style=>"width:100%" %> - - <% end %> - <% end %> -