自定义脚本的parse问题
This commit is contained in:
parent
b2d48c5017
commit
85f196c867
@ -1421,7 +1421,10 @@ MotaActionFunctions.workspace = function(){return workspace}
|
|||||||
|
|
||||||
MotaActionFunctions.parse = function(obj,type) {
|
MotaActionFunctions.parse = function(obj,type) {
|
||||||
try {
|
try {
|
||||||
obj = JSON.parse(MotaActionFunctions.replaceToName(JSON.stringify(obj)));
|
obj = obj.map(function (e) {
|
||||||
|
if (e.type == "function") return e;
|
||||||
|
else return JSON.parse(MotaActionFunctions.replaceToName(JSON.stringify(e)));
|
||||||
|
});
|
||||||
} catch (e) { }
|
} catch (e) { }
|
||||||
MotaActionFunctions.workspace().clear();
|
MotaActionFunctions.workspace().clear();
|
||||||
xml_text = MotaActionFunctions.actionParser.parse(obj, type || 'event');
|
xml_text = MotaActionFunctions.actionParser.parse(obj, type || 'event');
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user