Project

General

Profile

« Previous | Next » 

Revision 9878

Move the "MultiSelector" JS from the entryForm.tmpl to the entryForm.js. This ensures that the JS will run after all the functions in entryForm.js are declared. This was causing JS bugs in the registry and metacatui.

View differences:

entryForm.js
1475 1475
function capitalize(word) {
1476 1476
    return word.charAt(0).toUpperCase() + word.substr(1).toLowerCase();
1477 1477
}
1478

  
1479
//Now execute all JS that needs to run after the entry form template and this JS file are loaded
1480
var multi_selector = new MultiSelector( document.getElementById( 'files_list' ), 10);
1481
multi_selector.addElement( document.getElementById( 'file_element' ) );

Also available in: Unified diff