Commit 999d11a4
Changed files (64)
app
assets
images
cakes
template
javascripts
stylesheets
views
layouts
config
public
javascripts
public/images/cakes/Camouflage_Truck.jpg → app/assets/images/cakes/Camouflage_Truck.jpg
File renamed without changes
public/images/cakes/Couch_Cake.jpg → app/assets/images/cakes/Couch_Cake.jpg
File renamed without changes
public/images/cakes/eCompliance_cake.jpg → app/assets/images/cakes/eCompliance_cake.jpg
File renamed without changes
public/images/cakes/Haunted_House.jpg → app/assets/images/cakes/Haunted_House.jpg
File renamed without changes
public/images/cakes/Hellraiser_cake.jpg → app/assets/images/cakes/Hellraiser_cake.jpg
File renamed without changes
public/images/cakes/iPad_cake.JPG → app/assets/images/cakes/iPad_cake.JPG
File renamed without changes
public/images/cakes/Oyster_Cake.jpg → app/assets/images/cakes/Oyster_Cake.jpg
File renamed without changes
public/images/cakes/rubiks_cube_cake.jpg → app/assets/images/cakes/rubiks_cube_cake.jpg
File renamed without changes
public/images/cakes/THANKSGIVING_CAKE.JPG → app/assets/images/cakes/THANKSGIVING_CAKE.JPG
File renamed without changes
public/images/cakes/Wedding_Cake.jpg → app/assets/images/cakes/Wedding_Cake.jpg
File renamed without changes
public/images/template/body_top_shadow.jpg → app/assets/images/template/body_top_shadow.jpg
File renamed without changes
public/images/template/go.gif → app/assets/images/template/go.gif
File renamed without changes
public/images/template/header_bg.jpg → app/assets/images/template/header_bg.jpg
File renamed without changes
public/images/template/icon_tick.gif → app/assets/images/template/icon_tick.gif
File renamed without changes
public/images/template/logo.png → app/assets/images/template/logo.png
File renamed without changes
public/images/template/page_bg.gif → app/assets/images/template/page_bg.gif
File renamed without changes
public/images/template/photo.jpg → app/assets/images/template/photo.jpg
File renamed without changes
public/images/template/ribbon.gif → app/assets/images/template/ribbon.gif
File renamed without changes
public/images/template/search.gif → app/assets/images/template/search.gif
File renamed without changes
public/images/template/shop_1.jpg → app/assets/images/template/shop_1.jpg
File renamed without changes
public/images/template/shop_2.jpg → app/assets/images/template/shop_2.jpg
File renamed without changes
public/images/template/shop_3.jpg → app/assets/images/template/shop_3.jpg
File renamed without changes
public/images/template/shop_4.jpg → app/assets/images/template/shop_4.jpg
File renamed without changes
public/images/template/shop_5.jpg → app/assets/images/template/shop_5.jpg
File renamed without changes
public/images/template/slogan.png → app/assets/images/template/slogan.png
File renamed without changes
public/images/template/tag_bottom.gif → app/assets/images/template/tag_bottom.gif
File renamed without changes
public/images/template/tag_icon.gif → app/assets/images/template/tag_icon.gif
File renamed without changes
public/images/template/tag_line.gif → app/assets/images/template/tag_line.gif
File renamed without changes
public/images/template/tag_top.gif → app/assets/images/template/tag_top.gif
File renamed without changes
public/images/template/we_accept.gif → app/assets/images/template/we_accept.gif
File renamed without changes
public/images/facebook_64.png → app/assets/images/facebook_64.png
File renamed without changes
public/images/google_64.png → app/assets/images/google_64.png
File renamed without changes
public/images/google_apps_32.png → app/assets/images/google_apps_32.png
File renamed without changes
public/images/openid_64.png → app/assets/images/openid_64.png
File renamed without changes
public/images/rails.png → app/assets/images/rails.png
File renamed without changes
public/images/twitter_32.png → app/assets/images/twitter_32.png
File renamed without changes
public/images/twitter_64.png → app/assets/images/twitter_64.png
File renamed without changes
public/javascripts/libs/dd_belatedpng.js → app/assets/javascripts/libs/dd_belatedpng.js
File renamed without changes
public/javascripts/libs/modernizr-1.7.min.js → app/assets/javascripts/libs/modernizr-1.7.min.js
File renamed without changes
public/javascripts/template/hide-select.js → app/assets/javascripts/template/hide-select.js
File renamed without changes
public/javascripts/template/jquery.cycle.all.js → app/assets/javascripts/template/jquery.cycle.all.js
File renamed without changes
app/assets/javascripts/application.js
@@ -0,0 +1,9 @@
+// This is a manifest file that'll be compiled into including all the files listed below.
+// Add new JavaScript/Coffee code in separate files in this directory and they'll automatically
+// be included in the compiled file accessible from http://example.com/assets/application.js
+// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
+// the compiled file.
+//
+//= require jquery
+//= require jquery_ujs
+//= require_tree .
public/javascripts/jquery.js → app/assets/javascripts/jquery.js
File renamed without changes
public/javascripts/jquery.min.js → app/assets/javascripts/jquery.min.js
File renamed without changes
public/javascripts/jquery_ujs.js → app/assets/javascripts/jquery_ujs.js
File renamed without changes
public/javascripts/plugins.js → app/assets/javascripts/plugins.js
File renamed without changes
public/stylesheets/.gitkeep → app/assets/stylesheets/.gitkeep
File renamed without changes
app/assets/stylesheets/application.css
@@ -0,0 +1,7 @@
+/*
+ * This is a manifest file that'll automatically include all the stylesheets available in this directory
+ * and any sub-directories. You're free to add application-wide styles to this file and they'll appear at
+ * the top of the compiled file, but it's generally better to create a new file per style scope.
+ *= require_self
+ *= require_tree .
+*/
public/stylesheets/layout.css → app/assets/stylesheets/layout.css
File renamed without changes
public/stylesheets/styles.css → app/assets/stylesheets/styles.css
@@ -6,7 +6,7 @@ body {
margin: 0px;
padding: 0px;
color: #241a10;
- background:#c9e4ec url(/images/template/page_bg.gif);
+ background:#c9e4ec url(/assets/template/page_bg.gif);
}
a, a:link, a:active, a:visited {
color: #605646;
@@ -15,7 +15,7 @@ a:hover {
text-decoration:none;
}
#page_bg {
- background:url(/images/template/ribbon.gif) no-repeat center 108px;
+ background:url(/assets/template/ribbon.gif) no-repeat center 108px;
}
#container {
width:850px;
@@ -25,7 +25,7 @@ a:hover {
#header {
height: 108px;
padding: 0px;
- background-image:url(/images/template/header_bg.jpg);
+ background-image:url(/assets/template/header_bg.jpg);
background-position:top;
background-repeat:no-repeat;
}
@@ -43,7 +43,7 @@ a:hover {
}
#mainContent {
padding:0px;
- background:#fffdee url(/images/template/body_top_shadow.jpg);
+ background:#fffdee url(/assets/template/body_top_shadow.jpg);
background-repeat:repeat-x;
background-position:top;
min-height:400px;
@@ -166,7 +166,7 @@ ul#navigation ul.second-level li.hover a, ul#navigation ul.second-level li:hover
/*Tag Menu*/
.tag {
- background-image:url(/images/template/tag_bottom.gif);
+ background-image:url(/assets/template/tag_bottom.gif);
background-repeat:no-repeat;
background-position:0px bottom;
width:148px;
@@ -184,10 +184,10 @@ ul#navigation ul.second-level li.hover a, ul#navigation ul.second-level li:hover
padding:0 0 0 15px;
margin:0px 0px 0px 8px; /* used to center the menu on its bg image */
line-height:22px;
- background:url(/images/template/tag_line.gif) no-repeat 0 bottom;
+ background:url(/assets/template/tag_line.gif) no-repeat 0 bottom;
}
.tag a, .tag a:link, .tag a:visited {
- background-image:url(/images/template/tag_icon.gif);
+ background-image:url(/assets/template/tag_icon.gif);
background-position:left;
background-repeat:no-repeat;
display:block;
@@ -226,7 +226,7 @@ ul#navigation ul.second-level li.hover a, ul#navigation ul.second-level li:hover
border:0px;
padding:3px 0px 0px 6px;
margin:0px 0px 0px 5px;
- background-image:url(/images/template/search.gif);
+ background-image:url(/assets/template/search.gif);
background-repeat:no-repeat;
background-position:left;
width:105px;
@@ -238,7 +238,7 @@ ul#navigation ul.second-level li.hover a, ul#navigation ul.second-level li:hover
}
/*Shopping Cart On the Menu*/
#shopping_cart_summary {
- background:url(/images/template/we_accept.gif) no-repeat;
+ background:url(/assets/template/we_accept.gif) no-repeat;
width:142px;
height:71px;
color:#8f6637;
@@ -339,7 +339,7 @@ ul.ticklist {
}
ul.ticklist li {
list-style:none;
- background-image:url(/images/template/icon_tick.gif);
+ background-image:url(/assets/template/icon_tick.gif);
background-position:left 3px; /*the number here moves the tick down*/
background-repeat:no-repeat;
margin:0px 0px 5px 0px;
app/views/layouts/application.html.erb
@@ -8,8 +8,8 @@
<meta name="author" content="">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="shortcut icon" href="/favicon.ico">
- <script src="/javascripts/libs/modernizr-1.7.min.js"></script>
- <%= stylesheet_link_tag :all %>
+ <script src="/assets/libs/modernizr-1.7.min.js"></script>
+ <%= stylesheet_link_tag "application" %>
<%= csrf_meta_tag %>
<%= yield :head %>
</head>
@@ -29,8 +29,8 @@
</div>
<!-- start header -->
<div id="header">
- <div id="header_logo"> <a href="/"><img src="/images/template/logo.png" alt="Logo" width="322" height="56" border="0" /></a> </div>
- <div id="header_slogan"><img src="/images/template/slogan.png" alt="Gourmet Online Shop" width="213" height="40" /></div>
+ <div id="header_logo"> <a href="/"><img src="/assets/template/logo.png" alt="Logo" width="322" height="56" border="0" /></a> </div>
+ <div id="header_slogan"><img src="/assets/template/slogan.png" alt="Gourmet Online Shop" width="213" height="40" /></div>
</div>
<!-- end header -->
<div id="menu_container">
@@ -44,8 +44,8 @@
<!-- start body content -->
<div id="right_side">
<div id="s1" class="hidden">
- <img style="display: none;" src="/images/template/banner_cupcakes.jpg" alt="" width="666" height="226" />
- <img style="display: none;" src="/images/template/banner_weddings.jpg" alt="" width="666" height="226" />
+ <img style="display: none;" src="/assets/template/banner_cupcakes.jpg" alt="" width="666" height="226" />
+ <img style="display: none;" src="/assets/template/banner_weddings.jpg" alt="" width="666" height="226" />
</div>
<div id="body_text">
<!-- begin main page content -->
@@ -58,7 +58,7 @@
<!-- end body content -->
<div id="left_side">
<!-- start left menu -->
- <div style="position:relative; margin-top:-47px; width:147px; height:93px; background:url(/images/template/tag_top.gif);"></div>
+ <div style="position:relative; margin-top:-47px; width:147px; height:93px; background:url(/assets/template/tag_top.gif);"></div>
<div class="tag">
<ul>
<% Category.all.each do |category| %>
@@ -77,7 +77,7 @@
</div>
<!-- set padding-top:1px in IE 6 and 7 if statement -->
<div id="search_box_go">
- <input type="image" src="/images/template/go.gif" alt="Go!" style="margin:0px; padding:0px;" />
+ <input type="image" src="/assets/template/go.gif" alt="Go!" style="margin:0px; padding:0px;" />
<%# <%= submit_tag("search") %>
</div>
<% end %>
@@ -98,9 +98,9 @@
</div>
<!-- end content -->
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js"></script>
-<%= javascript_include_tag :all %>
-<script type="text/javascript" src="/javascripts/template/jquery.cycle.all.js"></script>
-<script type="text/javascript" src="/javascripts/template/hide-select.js"></script>
+<%= javascript_include_tag "application" %>
+<script type="text/javascript" src="/assets/template/jquery.cycle.all.js"></script>
+<script type="text/javascript" src="/assets/template/hide-select.js"></script>
<script type="text/javascript">
$(function() {
config/environments/development.rb
@@ -3,7 +3,7 @@ Cake::Application.configure do
# In the development environment your application's code is reloaded on
# every request. This slows down response time but is perfect for development
- # since you don't have to restart the webserver when you make code changes.
+ # since you don't have to restart the web server when you make code changes.
config.cache_classes = false
# Log error messages when you accidentally call methods on nil.
@@ -11,17 +11,20 @@ Cake::Application.configure do
# Show full error reports and disable caching
config.consider_all_requests_local = true
- config.action_view.debug_rjs = true
config.action_controller.perform_caching = false
# Don't care if the mailer can't send
config.action_mailer.raise_delivery_errors = false
- config.action_mailer.default_url_options = { :host => 'localhost:3000' }
# Print deprecation notices to the Rails logger
config.active_support.deprecation = :log
# Only use best-standards-support built into browsers
config.action_dispatch.best_standards_support = :builtin
-end
+ # Do not compress assets
+ config.assets.compress = false
+
+ # Expands the lines which load the assets
+ config.assets.debug = true
+end
config/application.rb
@@ -2,9 +2,12 @@ require File.expand_path('../boot', __FILE__)
require 'rails/all'
-# If you have a Gemfile, require the gems listed there, including any gems
-# you've limited to :test, :development, or :production.
-Bundler.require(:default, Rails.env) if defined?(Bundler)
+if defined?(Bundler)
+ # If you precompile assets before deploying to production, use this line
+ Bundler.require *Rails.groups(:assets => %w(development test))
+ # If you want your assets lazily compiled in production, use this line
+ # Bundler.require(:default, :assets, Rails.env)
+end
module Cake
class Application < Rails::Application
@@ -30,13 +33,16 @@ module Cake
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
# config.i18n.default_locale = :de
- # JavaScript files you want as :defaults (application.js is always included).
- # config.action_view.javascript_expansions[:defaults] = %w(jquery rails)
-
# Configure the default encoding used in templates for Ruby 1.9.
config.encoding = "utf-8"
# Configure sensitive parameters which will be filtered from the log file.
config.filter_parameters += [:password]
+
+ # Enable the asset pipeline
+ config.assets.enabled = true
+
+ # Version of your assets, change this if you want to expire all your assets
+ config.assets.version = '1.0'
end
end
config/boot.rb
@@ -1,13 +1,6 @@
require 'rubygems'
# Set up gems listed in the Gemfile.
-gemfile = File.expand_path('../../Gemfile', __FILE__)
-begin
- ENV['BUNDLE_GEMFILE'] = gemfile
- require 'bundler'
- Bundler.setup
-rescue Bundler::GemNotFound => e
- STDERR.puts e.message
- STDERR.puts "Try running `bundle install`."
- exit!
-end if File.exist?(gemfile)
+ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
+
+require 'bundler/setup' if File.exists?(ENV['BUNDLE_GEMFILE'])
public/javascripts/application.js
@@ -1,2 +0,0 @@
-// Place your application-specific JavaScript functions and classes here
-// This file is automatically included by javascript_include_tag :defaults
Gemfile.lock
@@ -1,45 +1,47 @@
GEM
remote: http://rubygems.org/
specs:
- RedCloth (4.2.7)
- abstract (1.0.0)
- actionmailer (3.0.9)
- actionpack (= 3.0.9)
- mail (~> 2.2.19)
- actionpack (3.0.9)
- activemodel (= 3.0.9)
- activesupport (= 3.0.9)
- builder (~> 2.1.2)
- erubis (~> 2.6.6)
- i18n (~> 0.5.0)
- rack (~> 1.2.1)
- rack-mount (~> 0.6.14)
- rack-test (~> 0.5.7)
- tzinfo (~> 0.3.23)
- activemodel (3.0.9)
- activesupport (= 3.0.9)
- builder (~> 2.1.2)
- i18n (~> 0.5.0)
- activerecord (3.0.9)
- activemodel (= 3.0.9)
- activesupport (= 3.0.9)
- arel (~> 2.0.10)
- tzinfo (~> 0.3.23)
- activeresource (3.0.9)
- activemodel (= 3.0.9)
- activesupport (= 3.0.9)
- activesupport (3.0.9)
+ RedCloth (4.2.8)
+ actionmailer (3.1.0)
+ actionpack (= 3.1.0)
+ mail (~> 2.3.0)
+ actionpack (3.1.0)
+ activemodel (= 3.1.0)
+ activesupport (= 3.1.0)
+ builder (~> 3.0.0)
+ erubis (~> 2.7.0)
+ i18n (~> 0.6)
+ rack (~> 1.3.2)
+ rack-cache (~> 1.0.3)
+ rack-mount (~> 0.8.2)
+ rack-test (~> 0.6.1)
+ sprockets (~> 2.0.0)
+ activemodel (3.1.0)
+ activesupport (= 3.1.0)
+ bcrypt-ruby (~> 3.0.0)
+ builder (~> 3.0.0)
+ i18n (~> 0.6)
+ activerecord (3.1.0)
+ activemodel (= 3.1.0)
+ activesupport (= 3.1.0)
+ arel (~> 2.2.1)
+ tzinfo (~> 0.3.29)
+ activeresource (3.1.0)
+ activemodel (= 3.1.0)
+ activesupport (= 3.1.0)
+ activesupport (3.1.0)
+ multi_json (~> 1.0)
addressable (2.2.4)
- arel (2.0.10)
- bcrypt-ruby (2.1.4)
- builder (2.1.2)
+ arel (2.2.1)
+ bcrypt-ruby (3.0.1)
+ builder (3.0.0)
capistrano (2.8.0)
highline
net-scp (>= 1.0.0)
net-sftp (>= 2.0.0)
net-ssh (>= 2.0.14)
net-ssh-gateway (>= 1.1.0)
- capybara (1.0.1)
+ capybara (1.1.1)
mime-types (>= 1.16)
nokogiri (>= 1.3.3)
rack (>= 1.0.0)
@@ -48,23 +50,22 @@ GEM
xpath (~> 0.1.4)
carrierwave (0.5.7)
activesupport (~> 3.0)
- childprocess (0.2.1)
+ childprocess (0.2.2)
ffi (~> 1.0.6)
- devise (1.4.2)
- bcrypt-ruby (~> 2.1.2)
+ devise (1.4.5)
+ bcrypt-ruby (~> 3.0)
orm_adapter (~> 0.0.3)
warden (~> 1.0.3)
- diff-lcs (1.1.2)
+ diff-lcs (1.1.3)
em-websocket (0.3.1)
addressable (>= 2.1.1)
eventmachine (>= 0.12.9)
- erubis (2.6.6)
- abstract (>= 1.0.0)
+ erubis (2.7.0)
eventmachine (0.12.10)
- excon (0.6.5)
- factory_girl (2.0.4)
- factory_girl_rails (1.1.0)
- factory_girl (~> 2.0.0)
+ excon (0.6.6)
+ factory_girl (2.1.0)
+ factory_girl_rails (1.2.0)
+ factory_girl (~> 2.1.0)
railties (>= 3.0.0)
faraday (0.6.1)
addressable (~> 2.2.4)
@@ -81,34 +82,35 @@ GEM
net-ssh (>= 2.1.4)
nokogiri (>= 1.4.4)
ruby-hmac
- formatador (0.2.0)
+ formatador (0.2.1)
growl (1.0.3)
growl_notify (0.0.1)
rb-appscript
- guard (0.6.1)
+ guard (0.7.0)
thor (~> 0.14.6)
- guard-livereload (0.3.0)
+ guard-livereload (0.3.1)
em-websocket (>= 0.2.0)
guard (>= 0.4.0)
multi_json (~> 1.0.3)
- guard-rspec (0.4.2)
+ guard-rspec (0.4.5)
guard (>= 0.4.0)
highline (1.6.2)
- i18n (0.5.0)
- jasmine (1.0.2.1)
- json_pure (>= 1.4.3)
+ hike (1.2.1)
+ i18n (0.6.0)
+ jasmine (1.1.0)
+ jasmine-core (>= 1.1.0)
rack (>= 1.1)
rspec (>= 1.3.1)
selenium-webdriver (>= 0.1.3)
- jquery-rails (1.0.13)
+ jasmine-core (1.1.0)
+ jquery-rails (1.0.14)
railties (~> 3.0)
thor (~> 0.14)
- json (1.5.3)
- json_pure (1.5.3)
+ json (1.6.0)
+ json_pure (1.6.0)
kaminari (0.12.4)
rails (>= 3.0.0)
- mail (2.2.19)
- activesupport (>= 2.3.6)
+ mail (2.3.0)
i18n (>= 0.4.0)
mime-types (~> 1.16)
treetop (~> 1.4.8)
@@ -121,7 +123,7 @@ GEM
net-ssh (>= 1.99.1)
net-sftp (2.0.5)
net-ssh (>= 2.0.9)
- net-ssh (2.1.4)
+ net-ssh (2.2.1)
net-ssh-gateway (1.1.0)
net-ssh (>= 1.99.1)
nokogiri (1.4.7)
@@ -166,33 +168,38 @@ GEM
pg (0.11.0)
polyglot (0.3.2)
pyu-ruby-sasl (0.0.3.3)
- rack (1.2.3)
- rack-mount (0.6.14)
+ rack (1.3.2)
+ rack-cache (1.0.3)
+ rack (>= 0.4)
+ rack-mount (0.8.3)
rack (>= 1.0.0)
rack-openid (1.3.1)
rack (>= 1.1.0)
ruby-openid (>= 2.1.8)
- rack-test (0.5.7)
+ rack-ssl (1.3.2)
+ rack
+ rack-test (0.6.1)
rack (>= 1.0)
- rails (3.0.9)
- actionmailer (= 3.0.9)
- actionpack (= 3.0.9)
- activerecord (= 3.0.9)
- activeresource (= 3.0.9)
- activesupport (= 3.0.9)
+ rails (3.1.0)
+ actionmailer (= 3.1.0)
+ actionpack (= 3.1.0)
+ activerecord (= 3.1.0)
+ activeresource (= 3.1.0)
+ activesupport (= 3.1.0)
bundler (~> 1.0)
- railties (= 3.0.9)
- railties (3.0.9)
- actionpack (= 3.0.9)
- activesupport (= 3.0.9)
+ railties (= 3.1.0)
+ railties (3.1.0)
+ actionpack (= 3.1.0)
+ activesupport (= 3.1.0)
+ rack-ssl (~> 1.3.2)
rake (>= 0.8.7)
rdoc (~> 3.4)
- thor (~> 0.14.4)
+ thor (~> 0.14.6)
rake (0.9.2)
rb-appscript (0.6.1)
- rb-fsevent (0.4.3)
- rdoc (3.9.2)
- rest-client (1.6.3)
+ rb-fsevent (0.4.3.1)
+ rdoc (3.9.4)
+ rest-client (1.6.7)
mime-types (>= 1.16)
riddle (1.4.0)
rmagick (2.13.1)
@@ -215,18 +222,23 @@ GEM
ruby-openid (>= 2.1.7)
rubyntlm (0.1.1)
rubyzip (0.9.4)
- selenium-webdriver (2.4.0)
+ selenium-webdriver (2.6.0)
childprocess (>= 0.2.1)
ffi (>= 1.0.7)
json_pure
rubyzip
+ sprockets (2.0.0)
+ hike (~> 1.2)
+ rack (~> 1.0)
+ tilt (~> 1.1, != 1.3.0)
sqlite3 (1.3.4)
sqlite3-ruby (1.3.3)
sqlite3 (>= 1.3.3)
- thinking-sphinx (2.0.5)
+ thinking-sphinx (2.0.7)
activerecord (>= 3.0.3)
riddle (>= 1.3.3)
thor (0.14.6)
+ tilt (1.3.3)
treetop (1.4.10)
polyglot
polyglot (>= 0.3.1)