Created
October 24, 2017 16:49
-
-
Save otaavioo/5f3253b6257b324404d66dd2927c19cf to your computer and use it in GitHub Desktop.
Removes liked and mine MRs at GitLab
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
if (location.href.indexOf('gitlab.agenciasys.com/dashboard/merge_requests') < 0) { | |
return; | |
} | |
var sUser = 'otavio'; | |
$('.issues-other-filters').append('<div class="filter-item inline open-mr-filters" style="padding:7px"><a href="#" data-operand="filter">Para avaliar [Beta]</a></div>') | |
$(document).on('click', '[data-operand="filter"]', function() { | |
// Remove all WIP MR | |
$('.merge-request:contains(WIP)').hide(); | |
// Remove all dev-approved MR | |
$('.merge-request .fa-thumbs-up') | |
.closest('.controls > li:contains(2)') | |
.closest('.merge-request') | |
.hide(); | |
// Remove all your own MR | |
$('.merge-request [href="/' + sUser + '"]') | |
.closest('.merge-request') | |
.hide(); | |
}); | |
}()); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment