You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
2.1 KiB

  1. @extends('layouts.app')
  2. @section('content')
  3. <div class="container">
  4. <div class="row">
  5. <div class="col-md-12">
  6. <table class="table scoreboard">
  7. <thead>
  8. <tr>
  9. <th>Team</th>
  10. @foreach($missions as $mission)
  11. <th class="score">
  12. <h3>{{ $mission->id }}</h3>
  13. <a href="{{ route('mission', $mission) }}">{{ $mission->hashtag }}</a>
  14. </th>
  15. @endforeach
  16. <th class="score">Score</th>
  17. </tr>
  18. </thead>
  19. <tbody>
  20. @foreach($teams as $team)
  21. <tr>
  22. <td>
  23. <div class="team">
  24. <span class="team-icon" style="background-color: #{{ $team->color }};"></span>
  25. <span class="team-name"><a href="{{ route('team', $team) }}">{{ $team->name }}</a></span>
  26. </div>
  27. <div class="players">
  28. @foreach($team->players as $player)
  29. <a href="https://twitter.com/{{ $player->twitter }}">{{ '@'.$player->twitter }}</a>
  30. @endforeach
  31. </div>
  32. </td>
  33. @foreach($missions as $mission)
  34. <td class="score">
  35. <div class="team-wrap">
  36. <div class="team">
  37. @if($mission->progress($team)[0] >= 1)
  38. <span class="team-icon outlined {{ $mission->complete($team) ? '' : 'empty' }}"
  39. style="background-color: #{{ $team->color }}; border-color: #{{ $team->color }};">
  40. @if(!Auth::guest())
  41. {{ $mission->score($team) }}
  42. @endif
  43. </span>
  44. @endif
  45. </div>
  46. </div>
  47. </td>
  48. @endforeach
  49. <td class="total score">
  50. <b>{{ $team->total_score() }}</b>
  51. </td>
  52. </tr>
  53. @endforeach
  54. </tbody>
  55. </table>
  56. </div>
  57. </div>
  58. </div>
  59. @endsection