Select Rented Referrals expiring in X days
(PTC Evolution Scripts)I've been using a javascript code to automatically select all RRs expiring in X days but it was kinda complicated to use so far, and required the user to open the console to insert the commands. Now I have simplified it again with a simple bookmark link.
You just need to set the days and the price variable to your liking.
Days: select all referrals in exactly or less than X days. Etc if the value is 14 then it will select referals expiring in 13 days, 14 days but it will not select those expiring in 15 days.
Price: insert the renewal price per referral for your preferred extension length.
To use the code simply copy it and paste it to notepad in order to set your own values.
Then copy the full code and paste it in a bookmark URL (name it as you wish).
Code (Javascript):javascript:(function(){
var days = 15; /*<-- Adjust this number to select referrals expiring in X days--*/
var price = 0.528; /*<-- Adjust this number to set the price per referral extension--*/
$('#tablelist > tr > td').filter(function(){ var pattern = / days/;
if(pattern.test($(this).text())){return $(this).text().replace(/ days/i, "") <= days}
}).parent().children().has('input').children().prop('checked', true);
$('#rentedbar').show();
var rrs = $('#tablelist > tr > td input:checked').length;
alert(rrs + ' RRs expiring in ' + days + ' days require $' + (rrs * price).toFixed(5) + ' to be extended.');
})();
Once in the RRs page, you can now click on the bookmark and it will automatically select all referrals based on your setting, and will throw a popup letting you know of the actual amount that you will need to pay for them, so it also saves you time by doing the math.
After clicking ok in the popup you can now select to renew them for your preferred duration at the bottom of the page just like you normally do.