master -> develop #1
@ -1,48 +1,48 @@
|
||||
<main class="details fixed">
|
||||
<section class="flex flex-no-wrap">
|
||||
<div>
|
||||
<img class="cover" width="402" height="284" src="<?= $urlGenerator->assetUrl("images/anime/{$data['id']}.jpg") ?>" alt="" />
|
||||
<img class="cover" width="402" height="284" src="<?= $urlGenerator->assetUrl("images/anime/{$show_data['id']}.jpg") ?>" alt="" />
|
||||
<br />
|
||||
<br />
|
||||
<table class="media_details">
|
||||
<tr>
|
||||
<td class="align_right">Airing Status</td>
|
||||
<td><?= $data['status'] ?></td>
|
||||
<td><?= $show_data['status'] ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Show Type</td>
|
||||
<td><?= $data['show_type'] ?></td>
|
||||
<td><?= $show_data['show_type'] ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Episode Count</td>
|
||||
<td><?= $data['episode_count'] ?? '-' ?></td>
|
||||
<td><?= $show_data['episode_count'] ?? '-' ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Episode Length</td>
|
||||
<td><?= $data['episode_length'] ?> minutes</td>
|
||||
<td><?= $show_data['episode_length'] ?> minutes</td>
|
||||
</tr>
|
||||
<?php if ( ! empty($data['age_rating'])): ?>
|
||||
<?php if ( ! empty($show_data['age_rating'])): ?>
|
||||
<tr>
|
||||
<td>Age Rating</td>
|
||||
<td><abbr title="<?= $data['age_rating_guide'] ?>"><?= $data['age_rating'] ?></abbr></td>
|
||||
<td><abbr title="<?= $show_data['age_rating_guide'] ?>"><?= $show_data['age_rating'] ?></abbr></td>
|
||||
</tr>
|
||||
<?php endif ?>
|
||||
<tr>
|
||||
<td>Genres</td>
|
||||
<td>
|
||||
<?= implode(', ', $data['genres']) ?>
|
||||
<?= implode(', ', $show_data['genres']) ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div>
|
||||
<h2><a rel="external" href="<?= $data['url'] ?>"><?= array_shift($data['titles']) ?></a></h2>
|
||||
<?php foreach ($data['titles'] as $title): ?>
|
||||
<h2><a rel="external" href="<?= $show_data['url'] ?>"><?= array_shift($show_data['titles']) ?></a></h2>
|
||||
<?php foreach ($show_data['titles'] as $title): ?>
|
||||
<h3><?= $title ?></h3>
|
||||
<?php endforeach ?>
|
||||
<br />
|
||||
<p><?= nl2br($data['synopsis']) ?></p>
|
||||
<?php if (count($data['streaming_links']) > 0): ?>
|
||||
<p><?= nl2br($show_data['synopsis']) ?></p>
|
||||
<?php if (count($show_data['streaming_links']) > 0): ?>
|
||||
<hr />
|
||||
<h4>Streaming on:</h4>
|
||||
<table class="full_width invisible">
|
||||
@ -54,11 +54,11 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach($data['streaming_links'] as $link): ?>
|
||||
<?php foreach($show_data['streaming_links'] as $link): ?>
|
||||
<tr>
|
||||
<td class="align_left">
|
||||
<?php if ($link['meta']['link'] !== FALSE): ?>
|
||||
<a href="<?= $link['link'] ?>" title="Stream '<?= $data['title'] ?>' on <?= $link['meta']['name'] ?>">
|
||||
<a href="<?= $link['link'] ?>" title="Stream '<?= $show_data['title'] ?>' on <?= $link['meta']['name'] ?>">
|
||||
<img class="streaming-logo" width="50" height="50" src="<?= $urlGenerator->assetUrl('images', $link['meta']['image']) ?>" alt="<?= $link['meta']['name'] ?> logo" />
|
||||
<?= $link['meta']['name'] ?>
|
||||
</a>
|
||||
|
@ -253,10 +253,10 @@ class Anime extends BaseController {
|
||||
*/
|
||||
public function details(string $animeId)
|
||||
{
|
||||
$data = $this->model->getAnime($animeId);
|
||||
$show_data = $this->model->getAnime($animeId);
|
||||
$characters = [];
|
||||
|
||||
if (empty($data))
|
||||
if (empty($show_data))
|
||||
{
|
||||
$this->notFound(
|
||||
$this->config->get('whose_list') .
|
||||
@ -268,9 +268,9 @@ class Anime extends BaseController {
|
||||
return;
|
||||
}
|
||||
|
||||
if (array_key_exists('characters', $data['included']))
|
||||
if (array_key_exists('characters', $show_data['included']))
|
||||
{
|
||||
foreach($data['included']['characters'] as $id => $character)
|
||||
foreach($show_data['included']['characters'] as $id => $character)
|
||||
{
|
||||
$characters[$id] = $character['attributes'];
|
||||
}
|
||||
@ -280,10 +280,10 @@ class Anime extends BaseController {
|
||||
'title' => $this->formatTitle(
|
||||
$this->config->get('whose_list') . "'s Anime List",
|
||||
'Anime',
|
||||
$data['titles'][0]
|
||||
$show_data['titles'][0]
|
||||
),
|
||||
'characters' => $characters,
|
||||
'data' => $data,
|
||||
'show_data' => $show_data,
|
||||
]);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user