Empty commit

This commit is contained in:
Git 2012-02-27 08:00:22 +00:00
parent 014cd85f9c
commit 5c7a82260d
7 changed files with 98 additions and 67 deletions

View File

@ -1693,7 +1693,7 @@ function display_artists($Artists, $MakeLink = true, $IncludeHyphen = true, $Esc
$link .= 'Various Artists';
}
if(!empty($Guests) && (count($MainArtists) + count($Composers) > 0) && (count($MainArtists) + count($Composers) + count($Conductors) < 3)) {
/*if(!empty($Guests) && (count($MainArtists) + count($Composers) > 0) && (count($MainArtists) + count($Composers) + count($Conductors) < 3)) {
switch(count($Guests)) {
case 1:
$link .= ' with '.display_artist($Guests[0], $MakeLink, $Escape);
@ -1702,7 +1702,7 @@ function display_artists($Artists, $MakeLink = true, $IncludeHyphen = true, $Esc
$link .= ' with '.display_artist($Guests[0], $MakeLink, $Escape).$ampersand.display_artist($Guests[1], $MakeLink, $Escape);
break;
}
}
}*/
if ((count($Conductors) > 0) && (count($MainArtists) + count($Composers) > 0) && (count($Composers) < 3 || count($MainArtists) > 0)) {
$link .= ' under ';

View File

@ -219,6 +219,39 @@ function compare($X, $Y){
$NumLeechers = 0;
$NumSnatches = 0;
foreach ($TorrentList as $GroupID => $Group) {
$TagList = explode(' ',str_replace('_','.',$Group['TagList']));
$TorrentTags = array();
// $Tags array is for the sidebar on the right. Skip compilations and soundtracks.
if (!in_array($ReleaseType, array(7, 3))) {
foreach($TagList as $Tag) {
if(!isset($Tags[$Tag])) {
$Tags[$Tag] = array('name'=>$Tag, 'count'=>1);
} else {
$Tags[$Tag]['count']++;
}
}
}
$TorrentTags = implode(', ', $TorrentTags);
$TorrentTags = '<br /><div class="tags">'.$TorrentTags.'</div>';
foreach ($Group['Torrents'] as $TorrentID => $Torrent) {
$NumTorrents++;
$Torrent['Seeders'] = (int)$Torrent['Seeders'];
$Torrent['Leechers'] = (int)$Torrent['Leechers'];
$Torrent['Snatched'] = (int)$Torrent['Snatched'];
$NumSeeders+=$Torrent['Seeders'];
$NumLeechers+=$Torrent['Leechers'];
$NumSnatches+=$Torrent['Snatched'];
}
}
$OpenTable = false;
$ShowGroups = !isset($LoggedUser['TorrentGrouping']) || $LoggedUser['TorrentGrouping'] == 0;
$HideTorrents = ($ShowGroups ? '' : ' hidden');
@ -236,24 +269,6 @@ function compare($X, $Y){
$OldGroupID = $GroupID;
$OldReleaseType = $ReleaseType;
}
$TagList = explode(' ',str_replace('_','.',$TagList));
$TorrentTags = array();
// $Tags array is for the sidebar on the right. Skip compilations and soundtracks.
if (!in_array($ReleaseType, array(7, 3))) {
foreach($TagList as $Tag) {
if(!isset($Tags[$Tag])) {
$Tags[$Tag] = array('name'=>$Tag, 'count'=>1);
} else {
$Tags[$Tag]['count']++;
}
$TorrentTags[] = '<a href="torrents.php?taglist='.$Tag.'">'.$Tag.'</a>';
}
}
$TorrentTags = implode(', ', $TorrentTags);
$TorrentTags = '<br /><div class="tags">'.$TorrentTags.'</div>';
if (!empty($LoggedUser['DiscogView']) || (isset($LoggedUser['HideTypes']) && in_array($ReleaseType, $LoggedUser['HideTypes']))) {
$HideDiscog = ' hidden';
@ -261,6 +276,16 @@ function compare($X, $Y){
$HideDiscog = '';
}
$TagList = explode(' ',str_replace('_','.',$TagList));
$TorrentTags = array();
// $Tags array is for the sidebar on the right. Skip compilations and soundtracks.
foreach($TagList as $Tag) {
$TorrentTags[] = '<a href="torrents.php?taglist='.$Tag.'">'.$Tag.'</a>';
}
$TorrentTags = implode(', ', $TorrentTags);
$TorrentTags = '<br /><div class="tags">'.$TorrentTags.'</div>';
if($ReleaseType!=$LastReleaseType) {
switch($ReleaseTypes[$ReleaseType]) {
@ -358,32 +383,20 @@ function compare($X, $Y){
unset($FirstUnknown);
foreach ($Torrents as $TorrentID => $Torrent) {
$NumTorrents++;
if ($Torrent['Remastered'] && !$Torrent['RemasterYear']) {
$FirstUnknown = !isset($FirstUnknown);
}
if (in_array($TorrentID, $TokenTorrents) && empty($Torrent['FreeTorrent'])) {
$Torrent['PersonalFL'] = 1;
}
$Torrent['Seeders'] = (int)$Torrent['Seeders'];
$Torrent['Leechers'] = (int)$Torrent['Leechers'];
$Torrent['Snatched'] = (int)$Torrent['Snatched'];
$NumSeeders+=$Torrent['Seeders'];
$NumLeechers+=$Torrent['Leechers'];
$NumSnatches+=$Torrent['Snatched'];
if($Torrent['RemasterTitle'] != $LastRemasterTitle || $Torrent['RemasterYear'] != $LastRemasterYear ||
$Torrent['RemasterRecordLabel'] != $LastRemasterRecordLabel || $Torrent['RemasterCatalogueNumber'] != $LastRemasterCatalogueNumber || $FirstUnknown || $Torrent['Media'] != $LastMedia) {
$Torrent['RemasterRecordLabel'] != $LastRemasterRecordLabel || $Torrent['RemasterCatalogueNumber'] != $LastRemasterCatalogueNumber || $FirstUnknown || $Torrent['Media'] != $LastMedia) {
$EditionID++;
if($Torrent['Remastered'] && $Torrent['RemasterYear'] != 0) {
$RemasterName = $Torrent['RemasterYear'];
$AddExtra = " - ";
if($Torrent['RemasterRecordLabel']) { $RemasterName .= $AddExtra.display_str($Torrent['RemasterRecordLabel']); $AddExtra=' / '; }

View File

@ -1,26 +1,27 @@
<?
if ($ID = (int)($_GET['id'])) {
// Check if conversation belongs to user
$DB->query("SELECT UserID, Level, AssignedToUser FROM staff_pm_conversations WHERE ID=$ID");
list($UserID, $Level, $AssignedToUser) = $DB->next_record();
if ($UserID == $LoggedUser['ID'] || $IsFLS || $AssignedToUser == $LoggedUser['ID']) {
if($Level != 0 && $IsStaff == false) {
error(403);
}
// Conversation belongs to user or user is staff, unresolve it
$DB->query("UPDATE staff_pm_conversations SET Status='Unanswered' WHERE ID=$ID");
// Clear cache for user
$Cache->delete_value('num_staff_pms_'.$LoggedUser['ID']);
header('Location: staffpm.php');
} else {
// Conversation does not belong to user
error(403);
}
} else {
// No id
header('Location: staffpm.php');
}
?>
<?
if ($ID = (int)($_GET['id'])) {
// Check if conversation belongs to user
$DB->query("SELECT UserID, Level, AssignedToUser FROM staff_pm_conversations WHERE ID=$ID");
list($UserID, $Level, $AssignedToUser) = $DB->next_record();
if ($UserID == $LoggedUser['ID'] || ($IsFLS && $Level == 0) ||
$AssignedToUser == $LoggedUser['ID'] || ($IsStaff && $Level <= $LoggedUser['Class'])) {
/*if($Level != 0 && $IsStaff == false) {
error(403);
}*/
// Conversation belongs to user or user is staff, unresolve it
$DB->query("UPDATE staff_pm_conversations SET Status='Unanswered' WHERE ID=$ID");
// Clear cache for user
$Cache->delete_value('num_staff_pms_'.$LoggedUser['ID']);
header('Location: staffpm.php');
} else {
// Conversation does not belong to user
error(403);
}
} else {
// No id
header('Location: staffpm.php');
}
?>

View File

@ -188,8 +188,7 @@
req.FillerID,
um.Username,
req.TimeFilled
FROM requests AS req
LEFT JOIN torrents AS t ON t.GroupID=req.TorrentID
FROM requests AS req
JOIN users_main AS um ON um.ID=req.FillerID
AND req.TorrentID=$TorrentID");
$Requests = ($DB->record_count());
@ -197,7 +196,7 @@
while(list($RequestID, $FillerID, $FillerName, $FilledTime) = $DB->next_record()) {
?>
<div style="text-align: right;">
<a href="user.php?id=<?=$FillerID?>"><?=$FillerName?></a> used a torrent from this group to fill <a href="requests.php?action=viewrequest&amp;id=<?=$RequestID?>">this request</a> <?=time_diff($FilledTime)?>
<a href="user.php?id=<?=$FillerID?>"><?=$FillerName?></a> used this torrent to fill <a href="requests.php?action=viewrequest&amp;id=<?=$RequestID?>">this request</a> <?=time_diff($FilledTime)?>
</div>
<? }
}

View File

@ -258,7 +258,7 @@ function compare($X, $Y){
}
}
if (!empty($Artists[7]) && count($Artists[7]) > 0) {
print ' <li class="artists_procuder"><strong>Produced By:</strong></li>';
print ' <li class="artists_producer"><strong>Produced By:</strong></li>';
foreach($Artists[7] as $Artist) {
?>
<li class="artists_producer">
@ -467,7 +467,7 @@ function filelist($Str) {
if(!empty($BadTags)) { $ExtraInfo.=$AddExtra.'<strong>Bad Tags</strong>'; $AddExtra=' / '; }
if(!empty($BadFolders)) { $ExtraInfo.=$AddExtra.'<strong>Bad Folders</strong>'; $AddExtra=' / '; }
if(!empty($CassetteApproved)) { $ExtraInfo.=$AddExtra.'<strong>Cassette Approved</strong>'; $AddExtra=' / '; }
if(!empty($LossymasterApproved)) { $ExtraInfo.=$AddExtra.'<strong>Lossy master Approved</strong>'; $AddExtra=' / '; }
if(!empty($LossymasterApproved)) { $ExtraInfo.=$AddExtra.'<strong>Lossy Master Approved</strong>'; $AddExtra=' / '; }
if(!empty($BadFiles)) { $ExtraInfo.=$AddExtra.'<strong>Bad File Names</strong>'; $AddExtra=' / '; }
if($GroupCategoryID == 1

View File

@ -3,10 +3,18 @@
if (!is_number($GroupID)) { error(404); }
show_header("History for Group $GroupID");
$Groups = get_groups(array($GroupID), true, true, false);
if (!empty($Groups['matches'][$GroupID])) {
$Group = $Groups['matches'][$GroupID];
$Title = display_artists($Group['ExtendedArtists']).'<a href="torrents.php?id='.$GroupID.'">'.$Group['Name'].'</a>';
} else {
$Title = "Group $GroupID";
}
?>
<div class="thin">
<h2>History for Group <?=$GroupID?></h2>
<h2>History for <?=$Title?></h2>
<table>
<tr class="colhead">

View File

@ -143,6 +143,16 @@
</form>
</div>
<?
} elseif (!empty($LoggedUser['DisableInvites'])) {?>
<div class="box pad" style="text-align: center">
<strong class="important_text">Your invites have been disabled. Please read <a href="wiki.php?action=article&id=310">this article</a> for more information.</strong>
</div>
<?
} elseif ($LoggedUser['RatioWatch'] || !$CanLeech) { ?>
<div class="box pad" style="text-align:center">
<strong class="important_text">You may not send invites while on Ratio Watch or while your leeching privileges are disabled. Please read <a href="wiki.php?action=article&id=310">this article</a> for more information.</strong>
</div>
<?
}
if (!empty($Pending)) {