From c33a723a2a122861c5352cd0e693c8df55cd0840 Mon Sep 17 00:00:00 2001 From: chris Date: Wed, 16 Jan 2013 02:37:49 +0800 Subject: [PATCH 01/20] Fix css bug when precompile --- app/assets/stylesheets/admin/default_widget_setting.css | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/assets/stylesheets/admin/default_widget_setting.css b/app/assets/stylesheets/admin/default_widget_setting.css index 8bbe4a50..6db0cc82 100644 --- a/app/assets/stylesheets/admin/default_widget_setting.css +++ b/app/assets/stylesheets/admin/default_widget_setting.css @@ -29,3 +29,7 @@ label{ margin: 0 0 0 -25px; white-space: normal; } + +label{ + white-space: nowrap !important ; +} From 87a89f81ce91eb3f72cfb58d0207f3bbd7f96e18 Mon Sep 17 00:00:00 2001 From: chris Date: Wed, 16 Jan 2013 08:14:42 +0800 Subject: [PATCH 02/20] Fix bug for mobile app routes --- app/controllers/application_controller.rb | 2 +- app/controllers/mobile_controller.rb | 2 +- app/views/mobile/_footer.mobile.erb | 4 ++-- app/views/mobile/_header.mobile.erb | 2 +- app/views/mobile/_menu.mobile.erb | 6 ++--- app/views/mobile/announcement.mobile.erb | 2 +- app/views/mobile/index.mobile.erb | 2 +- app/views/mobile/page.mobile.erb | 2 +- config/routes.rb | 28 +++++++++++------------ 9 files changed, 25 insertions(+), 25 deletions(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index b0fc4adb..7f4ea0fa 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -130,7 +130,7 @@ class ApplicationController < ActionController::Base respond_to do |format| format.html { render :text => parse_page_content(@item), :layout => 'page_layout' } format.rss { render_main_rss } - format.mobile { redirect_to mobile_path } + format.mobile { redirect_to mobile_path(:app => params[:app]) } end else render :text => '404 Not Found' diff --git a/app/controllers/mobile_controller.rb b/app/controllers/mobile_controller.rb index d07e9a87..369bfa22 100644 --- a/app/controllers/mobile_controller.rb +++ b/app/controllers/mobile_controller.rb @@ -54,7 +54,7 @@ class MobileController < ApplicationController protected def no_footer_for_app - @no_footer = true if request.path.starts_with?("/app") + @no_footer = true if request.path =~ /app/ end end diff --git a/app/views/mobile/_footer.mobile.erb b/app/views/mobile/_footer.mobile.erb index 8bff0fa0..17a38e90 100644 --- a/app/views/mobile/_footer.mobile.erb +++ b/app/views/mobile/_footer.mobile.erb @@ -7,12 +7,12 @@ <% end %>
  • - <%= link_to mobile_map_path, {"data-transition" => "flip"} do %> + <%= link_to mobile_map_path(:app => params[:app]), {"data-transition" => "flip"} do %> <% end %>
  • - <%= link_to mobile_dialog_contact_path, {"data-rel" => "dialog"} do %> + <%= link_to mobile_dialog_contact_path(:app => params[:app]), {"data-rel" => "dialog"} do %> <% end %>
  • diff --git a/app/views/mobile/_header.mobile.erb b/app/views/mobile/_header.mobile.erb index 428d689b..3e0df561 100644 --- a/app/views/mobile/_header.mobile.erb +++ b/app/views/mobile/_header.mobile.erb @@ -3,7 +3,7 @@ <%= image_tag asset_path('mobile/logo.png') %> - <%= link_to mobile_dialog_language_path, {:class => "ui-btn-right language", "data-iconpos" => "notext", "data-icon" => "search", "data-rel" => "dialog"} do %> + <%= link_to mobile_dialog_language_path(:app => params[:app]), {:class => "ui-btn-right language", "data-iconpos" => "notext", "data-icon" => "search", "data-rel" => "dialog"} do %> <% end %> \ No newline at end of file diff --git a/app/views/mobile/_menu.mobile.erb b/app/views/mobile/_menu.mobile.erb index eecc8226..ec92ea84 100644 --- a/app/views/mobile/_menu.mobile.erb +++ b/app/views/mobile/_menu.mobile.erb @@ -1,7 +1,7 @@ \ No newline at end of file diff --git a/app/views/mobile/announcement.mobile.erb b/app/views/mobile/announcement.mobile.erb index 247ca214..ff2ea10f 100644 --- a/app/views/mobile/announcement.mobile.erb +++ b/app/views/mobile/announcement.mobile.erb @@ -1,7 +1,7 @@