Файл: adultscript-2.0.3-pro/files/admin/templates/default/channel_manage.tpl.php
Строк: 286
<?php defined('_VALID') or die('Restricted Access!'); ?>
<?php echo $this->fetch('errors'); ?>
<?php echo $this->fetch('messages'); ?>
<?php echo $this->fetch('warnings'); ?>
<script type="text/javascript">
var lang_question_delete = "Are you sure you want to delete this channel?";
$(document).ready(function() {
$("a[id^='manage_channel_']").click(function(e) {
e.preventDefault();
var click_id = $(this).attr('id');
var click_arr = click_id.split('_');
var action = click_arr[2];
var channel_id = click_arr[3];
if (action == 'delete') {
var answer = confirm(lang_question_delete);
}
if (answer) {
$("input[name='action']").val(action);
$("input[name='channel_id']").val(channel_id);
$("#manage_channel_form").submit();
}
});
});
</script>
<div id="container" class="clearfix">
<div id="page">
<?php echo $this->fetch('channel_menu'); ?>
<div class="content clearfix">
<?php echo $this->fetch('channel_manage_menu'); ?>
<?php echo $this->fetch('channel_search'); ?>
<?php if ($this->channels): ?>
<form id="manage_channel_form" method="post" action="<?php echo CURRENT_URL; ?>">
<input name="action" type="hidden" value="" />
<input name="channel_id" type="hidden" value="" />
</form>
<form name="actionsForm" id="actionsForm" method="post" action="<?php echo CURRENT_URL; ?>">
<div class="box_menu">
<div class="box_menu_left">
<select name="action" id="actions_top">
<option value="suspend">Suspend</option>
<option value="activate">Activate</option>
<option value="delete">Delete</option>
</select>
<input name="submit_actions" type="submit" class="button butDef" value="Go!" />
</div>
<div class="box_menu_right">
<div class="barNav clearfix">Found <strong><?php echo $this->pagination['total_items']; ?></strong> channels, displaying page <strong><?php echo $this->pagination['page']; ?></strong> of <strong><?php echo $this->pagination['total_pages']; ?></strong> <strong>·</strong> <?php echo p('pagination', $this->pagination, CURRENT_URL); ?></div>
</div>
<div class="clear"></div>
</div>
<table cellpadding="0" cellspacing="0" border="0" id="table" class="uiTable">
<thead>
<tr>
<th class="nosort" style="width: 12px; text-align: center;"><input name="checkbox_all" type="checkbox" id="check_all" /></th>
<th><h3>Name</h3></th>
<th><h3>Network</h3></th>
<th><h3>Username</h3></th>
<th><h3>Statistics</h3></th>
<th><h3>Dates</h3></th>
<th><h3>Actions</h3></th>
</tr>
</thead>
<tbody>
<?php $count = count($this->channels); foreach ($this->channels as $channel): ?>
<tr id="row_<?php echo $channel['channel_id']; ?>">
<td><input name="checked[<?php echo $channel['channel_id']; ?>]" type="checkbox" id="checkbox_item_<?php echo $channel['channel_id']; ?>" /></td>
<td>
<strong><a href="<?php echo ADMIN_URL; ?>/index.php?q=channel/view&id=<?php echo $channel['channel_id']; ?>"><?php echo $channel['name']; ?><br />
<div class="channel">
<img src="<?php echo MEDIA_URL,'/channels/',$channel['channel_id'],'.thumb.',$channel['thumb']; ?>" alt="">
</div>
</td>
<td>
<?php echo e($channel['network']); ?>
</td>
<td>
<?php echo e($channel['username']); ?>
</td>
<td>
Views: <?php echo $channel['total_views']; ?><br />
Videos: <?php echo $channel['total_videos']; ?><br />
Likes: <?php echo $channel['total_likes']; ?><br />
Votes: <?php echo $channel['total_votes']; ?><br />
Duration: <?php echo $channel['total_duration']; ?><br />
Subscribers: <?php echo $channel['total_subscribers']; ?><br />
</td>
<td>
Added: <?php echo VDate::format($channel['add_time'], 'Y-m-d'); ?><br />
Updated: <?php echo VDate::format($channel['last_add_time'], 'Y-m-d'); ?>
</td>
<td>
<a href="<?php echo ADMIN_URL; ?>/index.php?q=channel/edit&id=<?php echo $channel['channel_id']; ?>" id="edit_user_<?php echo $channel['channel_id']; ?>"><img src="<?php echo TPL_REL; ?>/images/user_edit.png" alt="Edit" /></a>
<a href="<?php echo BASE_URL; ?>/channel/<?php echo e($channel['slug']); ?>/" target="_blank" title="Click to view this channel!"><img src="<?php echo TPL_REL; ?>/images/user_go.png" alt="" /></a> 
<a href="#delete" id="manage_channel_delete_<?php echo $channel['channel_id']; ?>" title="Click to delete this channel!"><img src="<?php echo TPL_REL; ?>/images/user_delete.png" alt="Delete" /></a>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
<div class="box_menu">
<div class="box_menu_left">
<select name="action" id="actions_bottom">
<option value="suspend">Suspend</option>
<option value="activate">Activate</option>
<option value="delete">Delete</option>
</select>
<input name="submit_actions" type="submit" class="button butDef" value="Go!" />
</div>
<div class="box_menu_right">
<div class="barNav clearfix">Found <strong><?php echo $this->pagination['total_items']; ?></strong> channels, displaying page <strong><?php echo $this->pagination['page']; ?></strong> of <strong><?php echo $this->pagination['total_pages']; ?></strong> <strong>·</strong> <?php echo p('pagination', $this->pagination, CURRENT_URL); ?></div>
</div>
<div class="clear"></div>
</div>
</form>
<?php else: ?>
<div class="none">No channels found!</div>
<?php endif; ?>
</div>
<div class="legend">
<img src="<?php echo TPL_REL; ?>/images/user.png" alt="link_view" /> View User
<img src="<?php echo TPL_REL; ?>/images/user_go.png" alt="" />View User Profile
<img src="<?php echo TPL_REL; ?>/images/user_edit.png" alt="user_edit" /> Edit User
<img src="<?php echo TPL_REL; ?>/images/user_delete.png" alt="user_delete" /> Delete User
<img src="<?php echo TPL_REL; ?>/images/accept.png" alt="accept" /> Active - Action Suspend
<img src="<?php echo TPL_REL; ?>/images/cancel.png" alt="cancel" /> Suspended - Action Activate
</div>
</div>
</div>