tippspiel/pfosten/resources/views/tipps/edit.blade.php
2017-06-26 17:21:30 +02:00

43 lines
No EOL
1.9 KiB
PHP

@extends('layouts.layout')
@section('content')
<div class="col-md-8">
<h1>Spieltipp:</h1>
<div style="float:left;width:250px" class="lead">{{ $game->team1 }} : {{ $game->team2 }}</div>
<div style="float:left;width:150px" >
<form method="POST" action="/tipps/store">
{{ csrf_field() }}
<div class="form-group">
<input style="float:left; width:50px;" type="text" class="lead" id="name" name="score1" value="{{ $tipp->score1==-1? '': $tipp->score1 }}" required>
<p style="float:left; width:25px;">&nbsp; : &nbsp;</p>
<input style="float:left; width:50px;" type="text" class="lead" id="name" name="score2" value="{{ $tipp->score2==-1? '': $tipp->score2 }}" required>
<label class="lead" style="float:left; width:50px;">Joker: &nbsp;</label>
<div style="float:left;width:300px;">
@if (App\Round::hasLockedGame($game->round_id))
{{ Form::checkbox('joker', 'yes', $tipp->joker, array('disabled') ) }} <!-- name, value, checked -->
<label style="float:left;width:500px;color:red;">Joker kann nicht verändert werden, weil die Runde bereits begonnen hat</label>
@else
{{ Form::checkbox('joker', 'yes', $tipp->joker) }} <!-- name, value, checked -->
@endif
</div>
<input type="hidden" name="id" value="{{ $tipp->id }}">
<input type="hidden" name="round_id" value="{{ $game->round_id }}">
</div>
<div class="form-group">
<button type="submit" class="btn btn-primary">Ok</button>
</div>
</form>
</div>
</div>
@endsection