added static pages

This commit is contained in:
nilsding 2014-08-01 11:47:25 +02:00
parent 97fe9a7cbc
commit 601b27d3b3
7 changed files with 24 additions and 66 deletions

View File

@ -0,0 +1,7 @@
class StaticController < ApplicationController
def index
end
def about
end
end

View File

@ -0,0 +1,2 @@
module StaticHelper
end

View File

@ -1,14 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<title>Justask2</title>
<%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true %>
<%= javascript_include_tag 'application', 'data-turbolinks-track' => true %>
<%= csrf_meta_tags %>
</head>
<body>
<%= yield %>
</body>
</html>

View File

@ -0,0 +1,9 @@
!!! 5
%html
%head
%title justask2
= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true
= javascript_include_tag 'application', 'data-turbolinks-track' => true
= csrf_meta_tags
%body
= yield

View File

@ -0,0 +1,2 @@
%h1 Static#about
%p Find me in app/views/static/about.html.haml

View File

@ -0,0 +1,2 @@
%h1 Static#index
%p Find me in app/views/static/index.html.haml

View File

@ -1,56 +1,6 @@
Rails.application.routes.draw do
# The priority is based upon order of creation: first created -> highest priority.
# See how all your routes lay out with "rake routes".
# You can have the root of your site routed with "root"
# root 'welcome#index'
root 'static#index'
# Example of regular route:
# get 'products/:id' => 'catalog#view'
# Example of named route that can be invoked with purchase_url(id: product.id)
# get 'products/:id/purchase' => 'catalog#purchase', as: :purchase
# Example resource route (maps HTTP verbs to controller actions automatically):
# resources :products
# Example resource route with options:
# resources :products do
# member do
# get 'short'
# post 'toggle'
# end
#
# collection do
# get 'sold'
# end
# end
# Example resource route with sub-resources:
# resources :products do
# resources :comments, :sales
# resource :seller
# end
# Example resource route with more complex sub-resources:
# resources :products do
# resources :comments
# resources :sales do
# get 'recent', on: :collection
# end
# end
# Example resource route with concerns:
# concern :toggleable do
# post 'toggle'
# end
# resources :posts, concerns: :toggleable
# resources :photos, concerns: :toggleable
# Example resource route within a namespace:
# namespace :admin do
# # Directs /admin/products/* to Admin::ProductsController
# # (app/controllers/admin/products_controller.rb)
# resources :products
# end
match '/about', to: 'static#about', via: 'get'
end