Эх сурвалжийг харах

oops; should have been committed with 657d270

raylu 14 жил өмнө
parent
commit
ae45ae42ab

+ 33 - 0
views/elements/animetable.html.php

@@ -0,0 +1,33 @@
+<?= $this->Paginator->paginate(array('separator' => '')) ?>
+
+<table>
+<th>Title</th>
+<th>Date</th>
+<th>Type</th>
+<?php foreach ($content as $anime): ?>
+	<tr>
+		<td>
+			<a href="/anime/view/<?= $anime->special_id ?>"><?= $anime->title ?></a>
+			<?php if ($anime->foreign_titles || $anime->alternative_titles): ?>
+				<span class="alt_titles">
+				<?php if ($anime->foreign_titles): ?>
+					<?= $anime->foreign_titles[0] ?>
+				<?php endif ?>
+				<?php if ($anime->alternative_titles): ?>
+					&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
+					<?= $anime->alternative_titles[0] ?>
+				<?php endif ?>
+				</span>
+			<?php endif ?>
+		</td>
+		<td>
+			<?= $anime->aired ?>
+		</td>
+		<td>
+			<?= $anime->view_type ?>
+		</td>
+	</tr>
+<?php endforeach ?>
+</table>
+
+<?= $this->Paginator->paginate(array('separator' => '')) ?>

+ 8 - 0
views/elements/search.html.php

@@ -0,0 +1,8 @@
+<?= $this->form->create(null, array('method' => 'get')); ?>
+	<?= $this->form->text('q'); ?>
+	<?= $this->form->select('type', array(''  => 'All',
+								  		  'anime'  => 'Anime',
+								  		  'manga'  => 'Manga',
+								  		  'kdrama' => 'Kdrama')); ?>
+	<?= $this->form->submit('Search'); ?>
+<?= $this->form->end(); ?>