From 9771d42587f1a6dbb117ea686a3fe2316806e36a Mon Sep 17 00:00:00 2001 From: chris Date: Mon, 4 Feb 2013 18:10:39 +0800 Subject: [PATCH] migrate for app config. fix panel style intro misplace --- .../page_parts/_default_widget_style_panel.html.erb | 2 +- lib/tasks/migrate.rake | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/app/views/admin/page_parts/_default_widget_style_panel.html.erb b/app/views/admin/page_parts/_default_widget_style_panel.html.erb index 49d40214..bc6fc89c 100644 --- a/app/views/admin/page_parts/_default_widget_style_panel.html.erb +++ b/app/views/admin/page_parts/_default_widget_style_panel.html.erb @@ -26,7 +26,7 @@ <%= radio_button_tag field_name,"typeB_style2",style_checked_value(object,"typeB_style2") %> 2 <%=image_tag 'module/default_widgets/style02.png'%> - <%= t("default_widget.caption.typeA") %> + <%= t("default_widget.caption.typeB_style2") %>
  • diff --git a/lib/tasks/migrate.rake b/lib/tasks/migrate.rake index 0d8b08d0..14516d93 100644 --- a/lib/tasks/migrate.rake +++ b/lib/tasks/migrate.rake @@ -431,4 +431,13 @@ namespace :migrate do end + task :clean_module_app_objects => :environment do + ModuleApp.all.each do |ma| + %w{intro widget_fields_link_method widgets get_default_widget app_pages author enable_frontend get_widget_style get_widget_style organization update_info using_default_widget version widget_fields version create_date}.each do |field| + ma.unset field + end + ma.save + end + end + end