more f arg removal

This commit is contained in:
Mario
2024-07-19 11:55:21 +00:00
parent 663aeca2a7
commit 1861eeeb0a
2 changed files with 32 additions and 31 deletions

View File

@@ -1144,7 +1144,7 @@ function pageUpdate() {
bParam_page = 1;
}
update_url = baseurl + '/' + decodeURIComponent(page_query) + '/?aj=1&page=' + bParam_page + extra_args ;
update_url = baseurl + '/' + decodeURIComponent(page_query) + '?aj=1&page=' + bParam_page + extra_args ;
$("#page-spinner").show();
update_mode = 'append';

View File

@@ -41,36 +41,37 @@
var bParam_unseen = "{{$unseen}}";
function buildCmd() {
var udargs = ((page_load) ? "/load" : "");
var bCmd = bParam_cmd + udargs + "?f=" ;
if(bParam_uid) bCmd = bCmd + "&p=" + bParam_uid;
if(bParam_cmin != (-1)) bCmd = bCmd + "&cmin=" + bParam_cmin;
if(bParam_cmax != (-1)) bCmd = bCmd + "&cmax=" + bParam_cmax;
if(bParam_gid != 0) { bCmd = bCmd + "&gid=" + bParam_gid; } else
if(bParam_cid != 0) { bCmd = bCmd + "&cid=" + bParam_cid; }
if(bParam_star != 0) bCmd = bCmd + "&star=" + bParam_star;
if(bParam_liked != 0) bCmd = bCmd + "&liked=" + bParam_liked;
if(bParam_conv!= 0) bCmd = bCmd + "&conv=" + bParam_conv;
if(bParam_spam != 0) bCmd = bCmd + "&spam=" + bParam_spam;
if(bParam_new != 0) bCmd = bCmd + "&new=" + bParam_new;
if(bParam_wall != 0) bCmd = bCmd + "&wall=" + bParam_wall;
if(bParam_list != 0) bCmd = bCmd + "&list=" + bParam_list;
if(bParam_fh != 0) bCmd = bCmd + "&fh=" + bParam_fh;
if(bParam_dm != 0) bCmd = bCmd + "&dm=" + bParam_dm;
if(bParam_search != "") bCmd = bCmd + "&search=" + bParam_search;
if(bParam_xchan != "") bCmd = bCmd + "&xchan=" + bParam_xchan;
if(bParam_order != "") bCmd = bCmd + "&order=" + bParam_order;
if(bParam_file != "") bCmd = bCmd + "&file=" + bParam_file;
if(bParam_cats != "") bCmd = bCmd + "&cat=" + bParam_cats;
if(bParam_tags != "") bCmd = bCmd + "&tag=" + bParam_tags;
if(bParam_dend != "") bCmd = bCmd + "&dend=" + bParam_dend;
if(bParam_dbegin != "") bCmd = bCmd + "&dbegin=" + bParam_dbegin;
if(bParam_mid != "") bCmd = bCmd + "&mid=" + bParam_mid;
if(bParam_verb != "") bCmd = bCmd + "&verb=" + bParam_verb;
if(bParam_net != "") bCmd = bCmd + "&net=" + bParam_net;
if(bParam_page != 1) bCmd = bCmd + "&page=" + bParam_page;
if(bParam_pf != 0) bCmd = bCmd + "&pf=" + bParam_pf;
if(bParam_unseen != 0) bCmd = bCmd + "&unseen=" + bParam_unseen;
let udargs = ((page_load) ? "/load" : "");
let bCmd = bParam_cmd + udargs;
if(bParam_uid) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "p=" + bParam_uid;
if(bParam_cmin != (-1)) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "cmin=" + bParam_cmin;
if(bParam_cmax != (-1)) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "cmax=" + bParam_cmax;
if(bParam_gid != 0) { bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "gid=" + bParam_gid; } else
if(bParam_cid != 0) { bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "cid=" + bParam_cid; }
if(bParam_star != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "star=" + bParam_star;
if(bParam_liked != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "liked=" + bParam_liked;
if(bParam_conv!= 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "conv=" + bParam_conv;
if(bParam_spam != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "spam=" + bParam_spam;
if(bParam_new != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "new=" + bParam_new;
if(bParam_wall != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "wall=" + bParam_wall;
if(bParam_list != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "list=" + bParam_list;
if(bParam_fh != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "fh=" + bParam_fh;
if(bParam_dm != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "dm=" + bParam_dm;
if(bParam_search != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "search=" + bParam_search;
if(bParam_xchan != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "xchan=" + bParam_xchan;
if(bParam_order != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "order=" + bParam_order;
if(bParam_file != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "file=" + bParam_file;
if(bParam_cats != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "cat=" + bParam_cats;
if(bParam_tags != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "tag=" + bParam_tags;
if(bParam_dend != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "dend=" + bParam_dend;
if(bParam_dbegin != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "dbegin=" + bParam_dbegin;
if(bParam_mid != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "mid=" + bParam_mid;
if(bParam_verb != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "verb=" + bParam_verb;
if(bParam_net != "") bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "net=" + bParam_net;
if(bParam_page != 1) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "page=" + bParam_page;
if(bParam_pf != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "pf=" + bParam_pf;
if(bParam_unseen != 0) bCmd = bCmd + ((bCmd.includes('?')) ? '&' : '?') + "unseen=" + bParam_unseen;
return(bCmd);
}