mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-24 03:57:22 +08:00
inbox count cache etc.
This commit is contained in:
+1
-1
@@ -33,7 +33,7 @@ if (!$row) {
|
||||
stderr($lang_details['std_error'], $lang_details['std_no_torrent_id']);
|
||||
} elseif (
|
||||
($row['banned'] == 'yes' && !user_can('seebanned') && $row['owner'] != $CURUSER['id'])
|
||||
|| (!can_access_torrent($row) && $row['owner'] != $CURUSER['id'])
|
||||
|| (!can_access_torrent($row, $CURUSER['id']) && $row['owner'] != $CURUSER['id'])
|
||||
) {
|
||||
permissiondenied();
|
||||
} else {
|
||||
|
||||
+1
-1
@@ -110,7 +110,7 @@ if (filesize($fn) == 0) {
|
||||
$approvalNotAllowed = $row['approval_status'] != \App\Models\Torrent::APPROVAL_STATUS_ALLOW && get_setting('torrent.approval_status_none_visible') == 'no';
|
||||
$allowOwnerDownload = $row['owner'] == $CURUSER['id'];
|
||||
$canSeedBanned = user_can('seebanned');
|
||||
$canAccessTorrent = can_access_torrent($row);
|
||||
$canAccessTorrent = can_access_torrent($row, $CURUSER['id']);
|
||||
if ((($row['banned'] == 'yes' || ($approvalNotAllowed && !$allowOwnerDownload)) && !$canSeedBanned) || !$canAccessTorrent) {
|
||||
do_log("[DENY_DOWNLOAD], user: {$CURUSER['id']}, approvalNotAllowed: $approvalNotAllowed, allowOwnerDownload: $allowOwnerDownload, canSeedBanned: $canSeedBanned, canAccessTorrent: $canAccessTorrent", 'error');
|
||||
denyDownload();
|
||||
|
||||
+11
-11
@@ -968,7 +968,7 @@ else stdhead($lang_torrents['head_special']);
|
||||
print("<table width=\"97%\" class=\"main\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td class=\"embedded\">");
|
||||
|
||||
displayHotAndClassic();
|
||||
|
||||
$searchBoxRightTdStyle = 'padding: 1px;padding-left: 10px;white-space: nowrap';
|
||||
if ($allsec != 1 || $enablespecial != 'yes'){ //do not print searchbox if showing bookmarked torrents from all sections;
|
||||
?>
|
||||
<form method="get" name="searchbox" action="?">
|
||||
@@ -1085,56 +1085,56 @@ if ($allsec != 1 || $enablespecial != 'yes'){ //do not print searchbox if showin
|
||||
</tr>
|
||||
<?php }?>
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<font class="medium"><?php echo $lang_torrents['size_range'] ?></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<input type="number" min="1" name="size_begin" style="width: <?php echo $filterInputWidth?>px" value="<?php echo htmlspecialchars($_GET['size_begin'] ?? '') ?>"/> ~ <input type="number" min="1" name="size_end" style="width: <?php echo $filterInputWidth?>px" value="<?php echo htmlspecialchars($_GET['size_end'] ?? '') ?>"/>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<font class="medium"><?php echo $lang_torrents['seeders_range'] ?></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<input type="number" min="1" name="seeders_begin" style="width: <?php echo $filterInputWidth?>px" value="<?php echo htmlspecialchars($_GET['seeders_begin'] ?? '') ?>"/> ~ <input type="number" min="1" name="seeders_end" style="width: <?php echo $filterInputWidth?>px" value="<?php echo htmlspecialchars($_GET['seeders_end'] ?? '') ?>"/>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<font class="medium"><?php echo $lang_torrents['leechers_range'] ?></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<input type="number" min="1" name="leechers_begin" style="width: <?php echo $filterInputWidth?>px" value="<?php echo htmlspecialchars($_GET['leechers_begin'] ?? '') ?>"/> ~ <input type="number" min="1" name="leechers_end" style="width: <?php echo $filterInputWidth?>px" value="<?php echo htmlspecialchars($_GET['leechers_end'] ?? '') ?>"/>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<font class="medium"><?php echo $lang_torrents['times_completed_range'] ?></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<input type="number" min="1" name="times_completed_begin" style="width: <?php echo $filterInputWidth?>px" value="<?php echo htmlspecialchars($_GET['times_completed_begin'] ?? '') ?>"/> ~ <input type="number" min="1" name="times_completed_end" style="width: <?php echo $filterInputWidth?>px" value="<?php echo htmlspecialchars($_GET['times_completed_end'] ?? '') ?>"/>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<font class="medium"><?php echo $lang_torrents['added_range'] ?></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="bottom" style="padding: 1px;padding-left: 10px">
|
||||
<td class="bottom" style="<?php echo $searchBoxRightTdStyle ?>">
|
||||
<?php echo sprintf(
|
||||
'%s ~ %s',
|
||||
datetimepicker_input('added_begin', htmlspecialchars($_GET['added_begin'] ?? ''), '', ['require_files' => true, 'format' => 'Y-m-d', 'style' => 'width: '.$filterInputWidth.'px']),
|
||||
|
||||
Reference in New Issue
Block a user