Skip to content

Instantly share code, notes, and snippets.

@Keqi
Created January 9, 2020 15:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Keqi/35a01bea30136b5aedf263f670337a96 to your computer and use it in GitHub Desktop.
Save Keqi/35a01bea30136b5aedf263f670337a96 to your computer and use it in GitHub Desktop.
<div class="row mt-3">
<div class="col-10">
<table class="table dashboard-daily-table">
<thead class="thead-light dashboard-daily-table-header">
<tr>
<th width="18%" scope="col"><%= Date.today.strftime("%A") %></th>
<th width="64%" scope="col"></th>
<th width="18%" scope="col"></th>
</tr>
</thead>
<tbody>
<% @schedule.each do |slot| %>
<tr>
<td class="dashboard-daily-table-text"><%= slot[:interval_text] %></td>
<td class="dashboard-daily-table-text">
<% if today_with_timezone(@timezone).between?(slot[:interval].first, slot[:interval].second) %>
<span class="dashboard-daily-dot-icon-green"></span>
<% else %>
<span class="dashboard-daily-dot-icon-transparent"></span>
<% end %>
<%= slot[:activity] %>
<% if slot[:icon_link] %>
<a href="https://microverse.pathwright.com/library/microverse-onboarding/86777/path/step/55314027/">
<i class="fas fa-info-circle"></i>
</a>
<% end %>
</td>
<td class="dashboard-daily-table-text text-right">
<% if slot[:link] && today_with_timezone(@timezone).between?(slot[:interval].first, slot[:interval].second) %>
<%= link_to "Join Call", slot[:link], target: '_blank', class: "btn btn-primary" %>
<% end %>
</td>
</tr>
<% end %>
</tbody>
</table>
</div>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment