40 lines
1.9 KiB
Text
40 lines
1.9 KiB
Text
|
|
<% # accessed through My Assignment on challenge dashboard %>
|
||
|
|
<!--Descriptive page name, messages and instructions-->
|
||
|
|
<h2 class="heading"><%= ts("Assignment for") %> <%= @challenge_assignment.offer_byline %> <% if @challenge_assignment.collection.challenge.user_allowed_to_see_assignments?(current_user) %><%= challenge_assignment_email(@challenge_assignment) %><% end %></h2>
|
||
|
|
<!--/descriptions-->
|
||
|
|
|
||
|
|
<!--subnav-->
|
||
|
|
<% if !@challenge_assignment.fulfilled? && @challenge_assignment.try(:offering_pseud).try(:user) == current_user %>
|
||
|
|
<ul class="navigation actions" role="menu">
|
||
|
|
<li>
|
||
|
|
<% if @challenge_assignment.defaulted? %>
|
||
|
|
<span class="defaulted"><%= ts("Defaulted") %></span>
|
||
|
|
<% else %>
|
||
|
|
<%= link_to ts("Default"), default_collection_assignment_path(@challenge_assignment.collection, @challenge_assignment),
|
||
|
|
data: {confirm: ts("Are you sure? This will mark you as having defaulted and notify the collection maintainer! It cannot be undone.")} %>
|
||
|
|
<% end %>
|
||
|
|
</li>
|
||
|
|
<li><%= link_to ts("Fulfill"), new_collection_work_path(@challenge_assignment.collection, :assignment_id => @challenge_assignment.id) %></li>
|
||
|
|
</ul>
|
||
|
|
<% end %>
|
||
|
|
<!--/subnav-->
|
||
|
|
|
||
|
|
<!--main content-->
|
||
|
|
|
||
|
|
<% if @challenge_assignment.request_signup %>
|
||
|
|
<%= render "challenge_signups/show_requests", challenge_signup: @challenge_assignment.request_signup %>
|
||
|
|
<% else %>
|
||
|
|
<h3 class="heading"><%= ts("No request!") %></h3>
|
||
|
|
<p class="note"><%= ts("Contact challenge moderators for help.") %></p>
|
||
|
|
<% end %>
|
||
|
|
|
||
|
|
<% if @challenge_assignment.offer_signup %>
|
||
|
|
<%= render "challenge_signups/show_offers", :challenge_signup => @challenge_assignment.offer_signup %>
|
||
|
|
<% elsif @challenge_assignment.pinch_hitter %>
|
||
|
|
<p class="note"><%= ts("Pinch Hitter") %></p>
|
||
|
|
<% else %>
|
||
|
|
<p class="note"><%= ts("No assigned giver!") %></p>
|
||
|
|
<p class="note"><%= ts("Contact challenge moderators for help.") %></p>
|
||
|
|
<% end %>
|
||
|
|
<!--/content-->
|