Greasy Fork is available in English.

Sentry fast delete

Add button to quickly delete all found issues

Bu betiği kurabilmeniz için Tampermonkey, Greasemonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

You will need to install an extension such as Tampermonkey to install this script.

Bu betiği kurabilmeniz için Tampermonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği kurabilmeniz için Tampermonkey ya da Userscripts gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

You will need to install an extension such as Tampermonkey to install this script.

Bu komut dosyasını yüklemek için bir kullanıcı komut dosyası yöneticisi uzantısı yüklemeniz gerekecek.

(Zaten bir kullanıcı komut dosyası yöneticim var, kurmama izin verin!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Zateb bir user-style yöneticim var, yükleyeyim!)

// ==UserScript==
// @name         Sentry fast delete
// @namespace    http://tampermonkey.net/
// @version      1.1.6
// @description  Add button to quickly delete all found issues
// @author       Cáno
// @match        https://sentry.getprintbox.com/hiddendata/*
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

    var delAllSafe = function() {
        document.querySelector('.chk-select-all').click();
        document.querySelector('.action-delete').click();
    };

    var delAll = function() {
        document.querySelector('.chk-select-all').click();
        document.querySelector('.action-delete').click();
        document.querySelector('.modal-footer .btn-primary').click();
        location.reload();
    };

    var delSelected = function() {
        document.querySelector('.action-delete').click();
        //document.querySelector('.modal-footer .btn-primary').click();
    };

    setInterval(function(){
        if (document.querySelector('.delete-all')) {
        } else if (document.querySelector('.stream-actions-left')) {
            var div = document.createElement('div');
            var html = `
<div class="btn-group">
<a class="btn btn-default btn-sm delete-selected"><span class="icon icon-trash" style="margin-right: 5px"></span>Delete selected
</a>
</div>
`;
            div.innerHTML = html.trim();
            div = div.firstChild;
            document.querySelector('.stream-actions-left').appendChild(div);
            document.querySelector('.delete-selected').onclick = delSelected;

            var div = document.createElement('div');
            var html = `
<div class="btn-group">
<a class="btn btn-default btn-sm delete-all-safe"><span class="icon icon-trash" style="margin-right: 5px"></span>Delete all
</a>
</div>
`;
            div.innerHTML = html.trim();
            div = div.firstChild;

            document.querySelector('.stream-actions-left').appendChild(div);
            document.querySelector('.delete-all-safe').onclick = delAllSafe;

            var div = document.createElement('div');
            var html = `
<div class="btn-group">
<a class="btn btn-default btn-sm delete-all"><span class="icon icon-trash" style="color: red; margin-right: 1px"></span></a>
</div>
`;
            div.innerHTML = html.trim();
            div = div.firstChild;

            document.querySelector('.stream-actions-left').appendChild(div);
            document.querySelector('.delete-all').onclick = delAll;
        }
    },1000);
})();