View:
Covers |
List
- Check all:
+ Check all:
With Selected:
", {'action': SERVERROOT + 'getnzb?zip=1', 'method':'post', 'target': '_top', 'id':newFormName});
- $("INPUT[type='checkbox']:checked").each( function(i, row) {
- if ($(row).val()!="on")
- $("", {'name':'id[]', 'value':$(row).val(), 'type':'hidden'}).appendTo(newForm);
- });
- newForm.appendTo($('body'));
- console.log(newForm)
- $('#'+newFormName).submit();
- });
-
- $('input.nntmux_multi_operations_cart').click(function(){
- var guids = new Array();
- $("INPUT[type='checkbox']:checked").each( function(i, row) {
- var guid = $(row).val();
- var $cartIcon = $(row).parent().parent().children('td.icons').children('.icon_cart');
- if (guid && !$cartIcon.hasClass('icon_cart_clicked')){
- $cartIcon.addClass('icon_cart_clicked').attr('title','Added to Cart'); // consider doing this only upon success
- guids.push(guid);
- PNotify.prototype.options.styling = "fontawesome";
- PNotify.desktop.permission();
- (new PNotify({
- title: 'Release added to your Download Basket!',
- type: 'success',
- icon: 'fa fa-info fa-3x',
- animate: {
- animate: true,
- in_class: 'bounceInLeft',
- out_class: 'bounceOutRight'
- },
- desktop: {
- desktop: true
- }})
- );
- }
- $(this).attr('checked', false);
- });
- $.post( SERVERROOT + "cart?add", { 'add': guids });
- });
-
- $('input.nntmux_multi_operations_sab').click(function(){
- $("INPUT[type='checkbox']:checked").each( function(i, row) {
- var $sabIcon = $(row).parent().parent().children('td.icons').children('.icon_sab');
- var guid = $(row).val();
- if (guid && !$sabIcon.hasClass('icon_sab_clicked')) {
- var nzburl = SERVERROOT + "sendtoqueue/" + guid;
- $.post( nzburl, function(resp){
- $sabIcon.addClass('icon_sab_clicked').attr('title','Added to Queue');
- PNotify.prototype.options.styling = "fontawesome";
- PNotify.desktop.permission();
- (new PNotify({
- title: 'Release added to your download queue!',
- type: 'success',
- icon: 'fa fa-info fa-3x',
- animate: {
- animate: true,
- in_class: 'bounceInLeft',
- out_class: 'bounceOutRight'
- },
- desktop: {
- desktop: true
- }})
- );
- });
- }
- $(this).attr('checked', false);
- });
- });
-
- $('input.nntmux_multi_operations_nzbget').click(function(){
- $("INPUT[type='checkbox']:checked").each( function(i, row) {
- var $nzbgetIcon = $(row).parent().parent().children('td.icons').children('.icon_nzbget');
- var guid = $(row).val();
- if (guid && !$nzbgetIcon.hasClass('icon_nzbget_clicked')) {
- var nzburl = SERVERROOT + "sendtoqueue/" + guid;
- $.post( nzburl, function(resp){
- $nzbgetIcon.addClass('icon_nzbget_clicked').attr('title','Added to Queue');
- PNotify.prototype.options.styling = "fontawesome";
- PNotify.desktop.permission();
- (new PNotify({
- title: 'Release added to your download queue!',
- type: 'success',
- icon: 'fa fa-info fa-3x',
- animate: {
- animate: true,
- in_class: 'bounceInLeft',
- out_class: 'bounceOutRight'
- },
- desktop: {
- desktop: true
- }})
- );
- });
- }
- $(this).attr('checked', false);
- });
- });
-
- $('input.nntmux_multi_operations_delete').click(function(){
- var ids = "";
- $("INPUT[type='checkbox']:checked").each( function(i, row) {
- if ($(row).val()!="on")
- ids += '&id[]='+$(row).val();
- });
- if (ids)
- {
- PNotify.prototype.options.styling = "fontawesome";
- (new PNotify({
- title: 'Confirmation Needed',
- text: 'Are you sure you want to delete the selected releases?',
- icon: 'glyphicon glyphicon-question-sign',
- hide: false,
- confirm: {
- confirm: true
- },
- buttons: {
- closer: false,
- sticker: false
- },
- history: {
- history: false
- }
- })).get().on('pnotify.confirm', function() {
- $.post( SERVERROOT + "ajax_release-admin?action=dodelete"+ids, function(resp){
- location.reload(true);
- });
- }).on('pnotify.cancel', function() {
- alert('Cancelled');
- });
- }
- });
-
- $('input.nntmux_multi_operations_deletereport').click(function(){
- var ids = "";
- //var rids = "";
- $("INPUT[type='checkbox']:checked").each( function(i, row) {
- if ($(row).val()!="on")
- ids += '&id[]='+$(row).val();
- // rids += '&id[]='+$(row).attr("id");
- });
- if (ids)
- if (confirm('Are you sure you want to delete the selected releases?')) {
- $.post(SERVERROOT + "ajax_release-admin?action=dodelete"+ids, function(resp){
- });
- $.post(SERVERROOT + "ajax_report-admin?action=dodelete"+ids, function(resp){
- // location.reload(true);
- });
- location.reload(true);
- }
- });
-
- $('input.nntmux_multi_operations_rebuild').click(function(){
- var ids = "";
- $("INPUT[type='checkbox']:checked").each( function(i, row) {
- if ($(row).val()!="on")
- ids += '&id[]='+$(row).val();
- });
- if (ids)
- if (confirm('Are you sure you want to rebuild the selected releases?')) {
- $.post(SERVERROOT + "ajax_release-admin?action=dorebuild"+ids, function(resp){
- location.reload(true);
- });
- }
- });
-
var vortexStates = new Array();
vortexStates[0] = 'Waiting';
vortexStates[1] = 'Downloading';