Skip to content

Commit

Permalink
Merge pull request #155 from eugeniecln1/title
Browse files Browse the repository at this point in the history
Title
  • Loading branch information
svilder authored Jun 14, 2019
2 parents 10dae64 + 1523240 commit 244c3a7
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 3 deletions.
1 change: 1 addition & 0 deletions app/assets/stylesheets/components/_card_role_model.scss
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ hr {
object-fit: cover;
display: inline-block;
margin-bottom: 40px;
object-position: top;
}
.card_icon {
font-size: 20px;
Expand Down
1 change: 1 addition & 0 deletions app/assets/stylesheets/pages/_dashboard.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

.titles {
display: flex;
justify-content: space-between;
Expand Down
2 changes: 1 addition & 1 deletion app/controllers/participations_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ def create
@participation = Participation.new(challenge: @challenge, user: current_user)
if @participation.save
flash[:notice] = "YAASS Let's get challenged ! 🎉"
redirect_to dashboard_path
redirect_to dashboard_path(participation_id: @participation.id)
else
flash[:alert] = "Oops! 😱 a problem has occurred"
redirect_to dashboard_path
Expand Down
2 changes: 1 addition & 1 deletion app/views/pages/_non_done_card.html.erb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div class="follow" data-participation-id="<%= participation.id %>">
<div class="notification">
<div class="notification <%= 'animated fadeInLeft' if params[:participation_id].to_i == participation.id %> ">
<div class="notification-content align-items-center">
<p><strong><%= participation.challenge.title %></strong></p>
<p id="sub-description"><%= participation.challenge.description %></p>
Expand Down
7 changes: 6 additions & 1 deletion app/views/pages/dashboard.html.erb
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
<%= content_for(:page, "dashboard") %>

<div class="container" style="margin-top: 100px";>
<h4 class="title"><em>Stats</em></h4>
<div class="bottom-dash">
<div class="chart-space">
<canvas id="polarChart" data-daily="<%= @counter[:dailyactivities] %>" data-future="<%= @counter[:futureme] %>" data-interactions="<%= @counter[:interactions] %>" data-curiosity="<%= @counter[:curiosity] %>"></canvas>
</div>

<div class="container">
<h4><em>Rewards</em></h4>
<div class="rewards">
<% if @counter[:dailyactivities] >= 3 && @counter[:futureme] >= 3 && @counter[:interactions] >= 3 && @counter[:curiosity] >= 3 %>
<div class="reward">
Expand Down Expand Up @@ -65,11 +68,13 @@
<% end %>
</div>
</div>

<% end %>
<% end %>
</div>
</div>
</div>
</div>
</div>

<div class="container">
<div>
Expand Down

0 comments on commit 244c3a7

Please sign in to comment.