- Timestamp:
- 2017-03-28T17:04:10+13:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone3/web/interfaces/default/js/javascript-global-functions.js
r31542 r31543 592 592 // behaviour of calling set-metadata-array. E.g. where=import|archives|index 593 593 // THIS METHOD IS SYNCHRONOUS 594 gs.functions.setMetadataArray = function(collection, site, docArray, metamode, where, responseFunction )594 gs.functions.setMetadataArray = function(collection, site, docArray, metamode, where, responseFunction, forceSync) 595 595 { 596 596 docArrayJSON = JSON.stringify(docArray); … … 610 610 } 611 611 612 613 var response = callMetadataServer("Setting metadata in "+where, "cgi-bin/metadata-server.pl?"+params, responseFunction); 612 // set operations are generally synchronous, but allow calling function to force ajax call 613 // to be synchronous or not. Default is synchronous, as it was for GS2 614 if(forceSync == null) { 615 forceSync = true; 616 } 617 618 var response = callMetadataServer("Setting metadata in "+where, "cgi-bin/metadata-server.pl?"+params, responseFunction, {"forceSync": forceSync}); 614 619 615 620 return response; … … 625 630 // See description for setMetadataArray above for information about the 'where' parameter. 626 631 // THIS METHOD IS SYNCHRONOUS BY DEFAULT. Set forceSync to false to override this default behaviour 627 gs.functions.getMetadataArray = function(collection, site, docArray, where, forceSync, responseFunction)632 gs.functions.getMetadataArray = function(collection, site, docArray, where, responseFunction, forceSync) 628 633 { 629 634 docArrayJSON = JSON.stringify(docArray);
Note:
See TracChangeset
for help on using the changeset viewer.