findOrFail($CURUSER['id']); if ($CURUSER["uploadpos"] == 'no') stderr($lang_upload['std_sorry'], $lang_upload['std_unauthorized_to_upload'],false); if ($enableoffer == 'yes') $has_allowed_offer = get_row_count("offers","WHERE allowed='allowed' AND userid = ". sqlesc($CURUSER["id"])); else $has_allowed_offer = 0; $uploadfreely = user_can_upload("torrents"); $offerSkipApprovedCount = get_setting('main.offer_skip_approved_count'); $uploadDenyApprovalDenyCount = get_setting('main.upload_deny_approval_deny_count'); $approvalDenyCount = \App\Models\Torrent::query()->where('owner', $CURUSER['id'])->where('approval_status', \App\Models\Torrent::APPROVAL_STATUS_DENY)->count(); do_log("uploadfreely: $uploadfreely, has_allowed_offer: $has_allowed_offer, offerSkipApprovedCount: $offerSkipApprovedCount, uploadDenyApprovalDenyCount: $uploadDenyApprovalDenyCount, approvalDenyCount: $approvalDenyCount"); $allowtorrents = ($has_allowed_offer || $uploadfreely || ($userInfo->offer_allowed_count >= $offerSkipApprovedCount)); $allowspecial = user_can_upload("music"); if ($uploadDenyApprovalDenyCount > 0 && $approvalDenyCount >= $uploadDenyApprovalDenyCount) { stderr($lang_upload['std_sorry'],sprintf($lang_upload['approval_deny_reach_upper_limit'], $uploadDenyApprovalDenyCount),false); } if (!$allowtorrents && !$allowspecial) stderr($lang_upload['std_sorry'],$lang_upload['std_please_offer'],false); $allowtwosec = ($allowtorrents && $allowspecial); $brsectiontype = $browsecatmode; $spsectiontype = $specialcatmode; $showsource = (($allowtorrents && get_searchbox_value($brsectiontype, 'showsource')) || ($allowspecial && get_searchbox_value($spsectiontype, 'showsource'))); //whether show sources or not $showmedium = (($allowtorrents && get_searchbox_value($brsectiontype, 'showmedium')) || ($allowspecial && get_searchbox_value($spsectiontype, 'showmedium'))); //whether show media or not $showcodec = (($allowtorrents && get_searchbox_value($brsectiontype, 'showcodec')) || ($allowspecial && get_searchbox_value($spsectiontype, 'showcodec'))); //whether show codecs or not $showstandard = (($allowtorrents && get_searchbox_value($brsectiontype, 'showstandard')) || ($allowspecial && get_searchbox_value($spsectiontype, 'showstandard'))); //whether show standards or not $showprocessing = (($allowtorrents && get_searchbox_value($brsectiontype, 'showprocessing')) || ($allowspecial && get_searchbox_value($spsectiontype, 'showprocessing'))); //whether show processings or not $showteam = (($allowtorrents && get_searchbox_value($brsectiontype, 'showteam')) || ($allowspecial && get_searchbox_value($spsectiontype, 'showteam'))); //whether show teams or not $showaudiocodec = (($allowtorrents && get_searchbox_value($brsectiontype, 'showaudiocodec')) || ($allowspecial && get_searchbox_value($spsectiontype, 'showaudiocodec'))); //whether show languages or not $settingMain = get_setting('main'); $torrentRep = new \App\Repositories\TorrentRepository(); stdhead($lang_upload['head_upload']); ?>
0) { jQuery("tr[relation=mode_" + mode +"]").show(); } }) jQuery("tr[relation]").hide(); JS; \Nexus\Nexus::js($customFieldJs, 'footer', false); stdfoot();