Google doc integration

- fix to prevent document upload freezing when documents large
  


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@20344 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Roy Wetherall
2010-05-21 17:26:39 +00:00
parent 24e435a11e
commit 50f445aeee
2 changed files with 20 additions and 28 deletions

View File

@@ -49,6 +49,8 @@ import org.alfresco.repo.thumbnail.CreateThumbnailActionExecuter;
import org.alfresco.repo.thumbnail.ThumbnailDefinition;
import org.alfresco.repo.thumbnail.ThumbnailRegistry;
import org.alfresco.repo.thumbnail.script.ScriptThumbnail;
import org.alfresco.repo.transaction.AlfrescoTransactionSupport;
import org.alfresco.repo.transaction.TransactionUtil;
import org.alfresco.repo.version.VersionModel;
import org.alfresco.repo.workflow.jscript.JscriptWorkflowInstance;
import org.alfresco.scripts.ScriptException;
@@ -1953,6 +1955,17 @@ public class ScriptNode implements Serializable, Scopeable, NamespacePrefixResol
return workingCopy;
}
/**
* Performs a check-out of this document for the purposes of an upload
*
* @return
*/
public ScriptNode checkoutForUpload()
{
AlfrescoTransactionSupport.bindResource("checkoutforupload", Boolean.TRUE.toString());
return checkout();
}
/**
* Perform a check-out of this document into the specified destination space.
*