hundeprofile sind jetzt öffentlich
All checks were successful
Build and push / Pulling repo on server (push) Successful in 3s
All checks were successful
Build and push / Pulling repo on server (push) Successful in 3s
This commit is contained in:
parent
46cf4dcd40
commit
4794f46add
@ -209,12 +209,12 @@ class Dogs extends Page {
|
|||||||
{
|
{
|
||||||
$dogid = $this->params[0];
|
$dogid = $this->params[0];
|
||||||
$d = new Dog();
|
$d = new Dog();
|
||||||
$res = new Result();
|
|
||||||
|
|
||||||
if(!$d->isMyDog($dogid))
|
//if(!$d->isMyDog($dogid))
|
||||||
return 'Not your dog :(';
|
// return 'Not your dog :(';
|
||||||
|
|
||||||
$d->load($dogid);
|
$d->load($dogid);
|
||||||
|
$this->set('ismydog',$d->isMyDog($dogid));
|
||||||
$this->set('results', $d->getResults());
|
$this->set('results', $d->getResults());
|
||||||
$this->set('dogdata', $d->data);
|
$this->set('dogdata', $d->data);
|
||||||
$this->set('dogid', $dogid);
|
$this->set('dogid', $dogid);
|
||||||
|
@ -37,11 +37,13 @@
|
|||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<?php if($ismydog===true): ?>
|
||||||
<div class="d-flex justify-content-end">
|
<div class="d-flex justify-content-end">
|
||||||
<button type="button" class="btn btn-secondary" hx-get="/dogs/edit/<?= $dogid; ?>" hx-target="#main">
|
<button type="button" class="btn btn-secondary" hx-get="/dogs/edit/<?= $dogid; ?>" hx-target="#main">
|
||||||
<i class="fas fa-edit"></i>
|
<i class="fas fa-edit"></i>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -68,71 +70,81 @@
|
|||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<?php foreach($results as $result) : ?>
|
<?php if(count($results) > 0): ?>
|
||||||
<?php
|
<?php foreach($results as $result) : ?>
|
||||||
$t = new Tournament();
|
<?php
|
||||||
$run = new Run();
|
$t = new Tournament();
|
||||||
|
$run = new Run();
|
||||||
|
|
||||||
$tname = $t->getField('name',$result['tournament']);
|
$tname = $t->getField('name',$result['tournament']);
|
||||||
$tdate = $t->getField('date',$result['tournament']);
|
$tdate = $t->getField('date',$result['tournament']);
|
||||||
$rname = $run->getField('name',$result['run']);
|
$rname = $run->getField('name',$result['run']);
|
||||||
|
|
||||||
$sdata['dates'][] = $tdate;
|
$sdata['dates'][] = $tdate;
|
||||||
|
|
||||||
$sdata['speed'][] = $result['speed'];
|
$sdata['speed'][] = $result['speed'];
|
||||||
$sdata['errors'][] = $result['errors'];
|
$sdata['errors'][] = $result['errors'];
|
||||||
$sdata['refusals'][] = $result['refusals'];
|
$sdata['refusals'][] = $result['refusals'];
|
||||||
$sdata['time'][] = $result['runtime'];
|
$sdata['time'][] = $result['runtime'];
|
||||||
$sdata['points'][] = $result['points'];
|
$sdata['points'][] = $result['points'];
|
||||||
$sdata['rating'][] = $result['rating'];
|
$sdata['rating'][] = $result['rating'];
|
||||||
|
|
||||||
//'Geschwindigkeit', 'Fehler', 'Verweigerungen', 'Zeit', 'Punkte','Platz'
|
//'Geschwindigkeit', 'Fehler', 'Verweigerungen', 'Zeit', 'Punkte','Platz'
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
<tr>
|
||||||
|
<td><a href="/tournaments/event/<?= $result['tournament']; ?>">
|
||||||
|
<?= $tname; ?>
|
||||||
|
</a></td>
|
||||||
|
<td><a href="/runs/overview/<?= $result['run']; ?>">
|
||||||
|
<?= $rname; ?>
|
||||||
|
</a></td>
|
||||||
|
<td>
|
||||||
|
<?= escape($result['ranking']); ?>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= $result['disqualified']?'Ja':'Nein'; ?>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= escape($result['refusals']); ?>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= escape($result['errors']); ?>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= escape($result['timefaults']); ?>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= escape($result['runtime']); ?>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= escape($result['penalties']); ?>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= escape($result['speed']); ?>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<?= escape($result['rating']); ?>
|
||||||
|
</td>
|
||||||
|
<td><a href="/dogs/overview/<?= $result['dog'] ?>">
|
||||||
|
<?= escape( (new Dog())->getField('name',$result['dog']) ); ?>
|
||||||
|
</a></td>
|
||||||
|
</tr>
|
||||||
|
<?php endforeach; ?>
|
||||||
|
<?php else: ?>
|
||||||
<tr>
|
<tr>
|
||||||
<td><a href="/tournaments/event/<?= $result['tournament']; ?>">
|
<td colspan="12">
|
||||||
<?= $tname; ?>
|
<div class="alert alert-info" role="alert">
|
||||||
</a></td>
|
<i class="fas fa-info-circle"></i> Dieser Hund hat noch keine Ergebnisse
|
||||||
<td><a href="/runs/overview/<?= $result['run']; ?>">
|
</div>
|
||||||
<?= $rname; ?>
|
|
||||||
</a></td>
|
|
||||||
<td>
|
|
||||||
<?= escape($result['ranking']); ?>
|
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<?php endif; ?>
|
||||||
<?= $result['disqualified']?'Ja':'Nein'; ?>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<?= escape($result['refusals']); ?>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<?= escape($result['errors']); ?>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<?= escape($result['timefaults']); ?>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<?= escape($result['runtime']); ?>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<?= escape($result['penalties']); ?>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<?= escape($result['speed']); ?>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<?= escape($result['rating']); ?>
|
|
||||||
</td>
|
|
||||||
<td><a href="/dogs/overview/<?= $result['dog'] ?>">
|
|
||||||
<?= escape( (new Dog())->getField('name',$result['dog']) ); ?>
|
|
||||||
</a></td>
|
|
||||||
</tr>
|
|
||||||
<?php endforeach; ?>
|
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<?php if(count($results) > 0): ?>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<div id="graph" data-bs-theme="light" class="card bg-light text-black" style="min-height: 400px;"></div>
|
<div id="graph" data-bs-theme="light" class="card bg-light text-black" style="min-height: 400px;"></div>
|
||||||
|
|
||||||
@ -214,6 +226,6 @@
|
|||||||
myChart.setOption(option);
|
myChart.setOption(option);
|
||||||
</script>
|
</script>
|
||||||
</div>
|
</div>
|
||||||
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
Reference in New Issue
Block a user