First version of LeagueSwap
This commit is contained in:
parent
07ce7961c9
commit
8cc4e620ec
5 changed files with 78 additions and 23 deletions
|
|
@ -12,6 +12,7 @@
|
|||
<a style="font-weight:normal; font-color: blue; font-size: 22px;" href="/seasons">Saison</a>
|
||||
<a style="font-weight:normal; font-color: blue; font-size: 22px;" href="/rounds#{{\App\Round::getFirstIncompleteRound()}}">Runden</a>
|
||||
<a style="font-weight:normal; font-color: blue; font-size: 22px;" href="/users">Spieler</a>
|
||||
<a style="font-weight:normal; font-color: blue; font-size: 22px;" href="/league/swapform">Ligatausch</a>
|
||||
<a style="font-weight:normal; font-color: blue; font-size: 22px;" href="/roundmails">Rundmail</a>
|
||||
</div>
|
||||
</label>
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@
|
|||
<!-- Start Matchgruppen-Loop-->
|
||||
@foreach($playerTuples as $pos => $player)
|
||||
<tr class="table-bordered">
|
||||
<td><input id="{{$player[0]}}__{{$userNames[$player[0]]}}__{{$leagueNames[$leagueId]}}" type="checkbox"></td>
|
||||
<td><input id="{{$player[0]}}" type="checkbox"></td>
|
||||
<td style="width:50px;background-color:{{ $cols[$rankInfo[$player[0]]] }}"> {{$pos+1}} </td>
|
||||
<td> <a name="playerid_{{$player[0]}}" class="{{ $player[0]==Auth::user()->id ? 'blink_text' : '' }}" href="/league/showSingleUserMatches/user_id={{$player[0]}}"> {{$userNames[$player[0]]}} </a> </td>
|
||||
<td> {{$player[1]}} </td>
|
||||
|
|
@ -101,11 +101,11 @@
|
|||
method: 'post',
|
||||
credentials: "same-origin",
|
||||
body: JSON.stringify({
|
||||
user1: inputElems[0].id,
|
||||
user2: inputElems[1].id
|
||||
user1_id: selected_players[0],
|
||||
user2_id: selected_players[1]
|
||||
})
|
||||
}).then((data) => {
|
||||
window.location.href = redirect;
|
||||
location.reload();
|
||||
})
|
||||
.catch(function(error) {
|
||||
console.log(error);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue