mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
. Fix to Alfresco JavaScript to correctly convert back multi-value list properties that have not been modified
. Change to use of Wrapper interface when returning Java values from JavaScript . Addition of final 1.4 icons from Linton for Dashboard and User Options screens git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@3492 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -37,9 +37,9 @@ import org.alfresco.service.cmr.repository.TemplateImageResolver;
|
||||
import org.alfresco.service.namespace.QName;
|
||||
import org.apache.log4j.Logger;
|
||||
import org.mozilla.javascript.Context;
|
||||
import org.mozilla.javascript.NativeJavaObject;
|
||||
import org.mozilla.javascript.Scriptable;
|
||||
import org.mozilla.javascript.ScriptableObject;
|
||||
import org.mozilla.javascript.Wrapper;
|
||||
|
||||
/**
|
||||
* Implementation of the ScriptService using the Rhino JavaScript engine.
|
||||
@@ -250,9 +250,9 @@ public class RhinoScriptService implements ScriptService
|
||||
Object result = cx.evaluateReader(scope, reader, "AlfrescoScript", 1, null);
|
||||
|
||||
// extract java object result if wrapped by rhinoscript
|
||||
if (result != null && result instanceof NativeJavaObject)
|
||||
if (result instanceof Wrapper)
|
||||
{
|
||||
result = Context.jsToJava(result, Object.class);
|
||||
result = ((Wrapper)result).unwrap();
|
||||
}
|
||||
|
||||
return result;
|
||||
|
Reference in New Issue
Block a user