Notification if OTRS notice & cv decline - fix #66

If there's an OTRS notice on the draft's talk page when a reviewer goes to decline it as a copyright violation, pop up a notice warning the reviewer about the OTRS notice.
This commit is contained in:
APerson 2016-03-07 23:02:06 -05:00
parent 1358745405
commit 0c5a356eb1

View File

@ -1675,6 +1675,20 @@
$afch.find( '#blankWrapper' ).add( '#csdWrapper' )
.removeClass( 'hidden' )
.children( 'input' ).prop( 'checked', true );
// Check if there's an OTRS notice
new AFCH.Page( 'Draft talk:' + afchSubmission.shortTitle ).getText( /* usecache */ true ).done( function ( text ) {
if ( /ConfirmationOTRS/.test( text ) ) {
$afch.find( '#declineInputWrapper' ).append(
$( '<div>' )
.addClass( 'warnings' )
.css( {
'max-width': '50%',
margin: '0px auto'
} )
.text( 'This draft has an OTRS template on the talk page. Verify that the copyright violation isn\'t covered by the template before marking this draft as a copyright violation.' ) );
}
} );
},
dup: function () {