MediaWiki:Gadget-FormCheck.js: Difference between revisions

From Tsadra Foundation Advanced Contemplative Scholarships
((by SublimeText.Mediawiker))
((by SublimeText.Mediawiker))
Line 2: Line 2:
   
   
if( $('.MustField').filter(function() { return this.value === ''; }).length === 0 ) {
if( $('.MustField').filter(function() { return this.value === ''; }).length === 0 ) {
     console.log("All filled");
     console.log("All filled, setting status to 'Complete'.");
    $('input[name="status"]').val("Complete");
} else {
} else {
     console.log("All not filled");
     console.log("All not filled");

Revision as of 06:27, 20 May 2024

$(document).ready(function() {
 
if( $('.MustField').filter(function() { return this.value === ''; }).length === 0 ) {
    console.log("All filled, setting status to 'Complete'.");
    $('input[name="status"]').val("Complete");
} else {
    console.log("All not filled");
}

});