Skip to content

Commit

Permalink
Functionality Done Almost
Browse files Browse the repository at this point in the history
  • Loading branch information
Liam F. Doran (ldoran) committed May 8, 2013
1 parent 32c4851 commit 513cb1e
Show file tree
Hide file tree
Showing 104 changed files with 1,432 additions and 340 deletions.
Binary file added app/assets/images/avatar1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar10.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar2.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar3.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar4.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar5.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar6.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar7.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar8.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar9.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/avatar_default.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/homeSplash.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions app/assets/javascripts/daily_exercises.js.coffee
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Place all the behaviors and hooks related to the matching controller here.
# All this logic will automatically be available in application.js.
# You can use CoffeeScript in this file: http://jashkenas.github.com/coffee-script/
3 changes: 3 additions & 0 deletions app/assets/javascripts/exercise_plans.js.coffee
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Place all the behaviors and hooks related to the matching controller here.
# All this logic will automatically be available in application.js.
# You can use CoffeeScript in this file: http://jashkenas.github.com/coffee-script/
61 changes: 60 additions & 1 deletion app/assets/stylesheets/application.css.scss
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,49 @@ h1, h2, h3, h4, h5, h6{
font-family: 'Lobster', cursive;
}

div #home_image
{
width:940px;
height:400px;
margin-left:auto;
margin-right:auto;
margin-top:30px;
background-image: url('homeSplash.jpg');
}

$overlay_height:120px;
div #home_overlay
{
width:600px;
height:$overlay_height;

position:relative;
top:50%;
left:50%;
margin-top:$overlay_height/-2px;
margin-left:-300px;

background-color:rgba(0,0,0,.7);
h1{
font-size:65px;
color:$headerBackground;
text-align:center;
opacity:1;
}
h2{
font-family: 'Lobster', cursive;
color:#dddddd;
text-align:center;
font-size:35px;
margin-top:-10px;
a {
font-family:inherit;
color:#bC3C9B;
text-decoration:none;
}
}
}

#headerWrapper{
width:100%;
position:absolute;
Expand Down Expand Up @@ -190,7 +233,7 @@ h4{
}
}

.minorProgBar{
.mediumProgBar{
@include progBar;
height:26px;
width:400px;
Expand All @@ -200,6 +243,21 @@ h4{
}
}

.button_to{
margin-left:200px;
margin-top:9px;
}

.minorProgBar{
@include progBar;
height:20px;
width:300px;
.innerBar{
margin-left:-150px;
margin-top:-10px;
}
}

.innerBar{
position:absolute;
background-color:#449944;
Expand All @@ -209,6 +267,7 @@ h4{
top:50%;
z-index:3;
}

@mixin spots{
float:left;
overflow:hidden;
Expand Down
3 changes: 3 additions & 0 deletions app/assets/stylesheets/daily_exercises.css.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
// Place all the styles related to the DailyExercises controller here.
// They will automatically be included in application.css.
// You can use Sass (SCSS) here: http://sass-lang.com/
3 changes: 3 additions & 0 deletions app/assets/stylesheets/exercise_plans.css.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
// Place all the styles related to the ExercisePlans controller here.
// They will automatically be included in application.css.
// You can use Sass (SCSS) here: http://sass-lang.com/
10 changes: 10 additions & 0 deletions app/assets/stylesheets/home.css.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
// Place all the styles related to the home controller here.
// They will automatically be included in application.css.
// You can use Sass (SCSS) here: http://sass-lang.com/

div #home_overlay
{
position:relative;
top:20px;
left:20px;
background-color:#000000;
color:#dddddd;
opacity:.5;
}
8 changes: 7 additions & 1 deletion app/controllers/articles_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,13 @@ def show
# GET /articles/new.json
def new
@article = Article.new
@article.watcher = params[:watcher_id]

if(params.has_key?(:watcher_id))
@this_watcher_id = params[:watcher_id]
else
@this_watcher_id = 0
end
@article.watcher_id = @this_watcher_id

respond_to do |format|
format.html # new.html.erb
Expand Down
90 changes: 90 additions & 0 deletions app/controllers/articles_controller.rb~
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
class ArticlesController < ApplicationController
# GET /articles
# GET /articles.json
def index
@articles = Article.all

respond_to do |format|
format.html # index.html.erb
format.json { render json: @articles }
end
end

# GET /articles/1
# GET /articles/1.json
def show
@article = Article.find(params[:id])

respond_to do |format|
format.html # show.html.erb
format.json { render json: @article }
end
end

# GET /articles/new
# GET /articles/new.json
def new
@article = Article.new

if(params.has_key?(:watcher_id))
@this_watcher_id = params[:watcher_id]
else
@this_watcher_id = 0
end
@article.watcher_id = @this_watcher_id

respond_to do |format|
format.html # new.html.erb
format.json { render json: @article }
end
end

# GET /articles/1/edit
def edit
@article = Article.find(params[:id])
end

# POST /articles
# POST /articles.json
def create
@article = Article.new(params[:article])

respond_to do |format|
if @article.save
format.html { redirect_to @article, notice: 'Article was successfully created.' }
format.json { render json: @article, status: :created, location: @article }
else
format.html { render action: "new" }
format.json { render json: @article.errors, status: :unprocessable_entity }
end
end
end

# PUT /articles/1
# PUT /articles/1.json
def update
@article = Article.find(params[:id])

respond_to do |format|
if @article.update_attributes(params[:article])
format.html { redirect_to @article, notice: 'Article was successfully updated.' }
format.json { head :no_content }
else
format.html { render action: "edit" }
format.json { render json: @article.errors, status: :unprocessable_entity }
end
end
end

# DELETE /articles/1
# DELETE /articles/1.json
def destroy
@article = Article.find(params[:id])
@article.destroy

respond_to do |format|
format.html { redirect_to articles_url }
format.json { head :no_content }
end
end
end
1 change: 1 addition & 0 deletions app/controllers/daily_diets_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ def show
# GET /daily_diets/new.json
def new
@daily_diet = DailyDiet.new
@daily_diet.day_made = Date.current

respond_to do |format|
format.html # new.html.erb
Expand Down
83 changes: 83 additions & 0 deletions app/controllers/daily_exercises_controller.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
class DailyExercisesController < ApplicationController
# GET /daily_exercises
# GET /daily_exercises.json
def index
@daily_exercises = DailyExercise.all

respond_to do |format|
format.html # index.html.erb
format.json { render json: @daily_exercises }
end
end

# GET /daily_exercises/1
# GET /daily_exercises/1.json
def show
@daily_exercise = DailyExercise.find(params[:id])

respond_to do |format|
format.html # show.html.erb
format.json { render json: @daily_exercise }
end
end

# GET /daily_exercises/new
# GET /daily_exercises/new.json
def new
@daily_exercise = DailyExercise.new

respond_to do |format|
format.html # new.html.erb
format.json { render json: @daily_exercise }
end
end

# GET /daily_exercises/1/edit
def edit
@daily_exercise = DailyExercise.find(params[:id])
end

# POST /daily_exercises
# POST /daily_exercises.json
def create
@daily_exercise = DailyExercise.new(params[:daily_exercise])

respond_to do |format|
if @daily_exercise.save
format.html { redirect_to @daily_exercise, notice: 'Daily exercise was successfully created.' }
format.json { render json: @daily_exercise, status: :created, location: @daily_exercise }
else
format.html { render action: "new" }
format.json { render json: @daily_exercise.errors, status: :unprocessable_entity }
end
end
end

# PUT /daily_exercises/1
# PUT /daily_exercises/1.json
def update
@daily_exercise = DailyExercise.find(params[:id])

respond_to do |format|
if @daily_exercise.update_attributes(params[:daily_exercise])
format.html { redirect_to @daily_exercise, notice: 'Daily exercise was successfully updated.' }
format.json { head :no_content }
else
format.html { render action: "edit" }
format.json { render json: @daily_exercise.errors, status: :unprocessable_entity }
end
end
end

# DELETE /daily_exercises/1
# DELETE /daily_exercises/1.json
def destroy
@daily_exercise = DailyExercise.find(params[:id])
@daily_exercise.destroy

respond_to do |format|
format.html { redirect_to daily_exercises_url }
format.json { head :no_content }
end
end
end
Loading

0 comments on commit 513cb1e

Please sign in to comment.