Show
Ignore:
Timestamp:
20.02.2012 15:21:04 (8 years ago)
Author:
sjm84
Message:

Store the orignal value of a cell so that we can find it. Also fixed a few things

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/oran/js/documentmaker_scripts_util.js

    r25096 r25099  
    189189            var name = nameCell.innerHTML; 
    190190 
    191             gs.functions.setArchivesMetadata(gs.cgiParams.p_c /*bad*/, "localsite" /*bad*/, docID, name, null, changedElem.innerHTML, function(){console.log("SAVED ARCHIVES");}); 
    192             gs.functions.setIndexMetadata(gs.cgiParams.p_c /*bad*/, "localsite" /*bad*/, docID, name, null, changedElem.innerHTML, function(){alert("SAVED INDEX");}); 
     191            gs.functions.setArchivesMetadata(gs.cgiParams.p_c /*bad*/, "localsite" /*bad*/, docID, name, null, changedElem.innerHTML, changedElem.originalValue, function(){console.log("SAVED ARCHIVES");}); 
     192            changedElem.originalValue = changedElem.innerHTML; 
     193            addCollectionToBuild(gs.cgiParams.p_c); 
    193194        } 
    194195        //Save content 
     
    537538{ 
    538539    //This registering can cause a sizeable delay so we'll thread it (effectively) so the browser is not paused 
     540    cell.originalValue = cell.innerHTML; 
    539541    setTimeout(function(){de.doc.registerEditSection(cell)}, 0); 
    540542}