<!-- Dashboard users start -->

<div id="dashboard-users">
	<div class="row">
		<div class="col s12">

			<!-- Users-->
			<div class="widget-holder hoverable fadeIn" id="dashboard-users-overview">
				<div class="widget-heading">
					<h2 class="widget-heading-thick"><?php echo Lang::get('dashboard.subscribers'); ?></h2>

					<div class="row filter-row">
						<div class="col s12">

							<div class="input-field right">
								<i class="material-icons prefix">search</i>
								<input id="icon_prefix" type="text" onkeyup="filterTable()">
								<label for="icon_prefix">Search...</label>
							</div>
						</div>
					</div>
				</div>
				<div class="widget-content">
					<div class="table-wrapper">
						<table class="bordered responsive-table">
							<thead>
							<tr>

								<th class="text-center"><?php echo Lang::get('usersList.header_id'); ?></th>
								<th><?php echo Lang::get('usersList.header_email'); ?></th>
								<th><?php echo Lang::get('usersList.header_name'); ?></th>

								<th class="text-center"><?php echo Lang::get('usersList.header_edit_user'); ?></th>
							</tr>
							</thead>

							<tbody  id="searchable">

							<?php foreach($users as $user): ?>
									<tr>
										<td><?php echo $user->id; ?></td>
										<td><?php echo $user->email; ?></td>
										<td><?php echo $user->first_name . ' ' . $user->last_name; ?></td>

										<td>
											<a href="<?php echo URL::route('deleteUserSubscription', array('id' => $user->id)); ?>" class="icon-btn icon-btn-delete" title="<?php echo Lang::get('dashboard.unsubscribe', array('name' => $user->first_name . ' ' . $user->last_name)); ?>"><i class="material-icons">delete</i></a>
										</td>
									</tr>
							<?php endforeach; ?>


							</tbody>
						</table>
					</div>
				</div>
			</div>
			<!--Users end-->

		</div>
	</div>
</div>

<!-- Dashboard users end -->