Explorar el Código

Merge branch 'wrdp' into 'develop'

Wrdp

See merge request o2oa/o2oa!2796
胡起 hace 5 años
padre
commit
2d2c217764
Se han modificado 1 ficheros con 2 adiciones y 2 borrados
  1. 2 2
      o2web/source/x_component_process_Xform/Org.js

+ 2 - 2
o2web/source/x_component_process_Xform/Org.js

@@ -246,8 +246,8 @@ MWF.xApplication.process.Xform.Org = MWF.APPOrg =  new Class(
                             var code = "return this.org.getDuty(\""+duty.name+"\", \""+uName+"\", true)";
                             var r = (!!uName) ? this.form.Macro.exec(code, this) : "";
 
-                            var rs = (o2.typeOf(r)=="array") ? r : [r];
-                            return Promise.all(rs).then(function(d){
+                            var m = (o2.typeOf(r)=="array") ? "all" : "resolve";
+                            return Promise[m](r).then(function(d){
                                 if (typeOf(d)!=="array") d = (d) ? [d.toString()] : [];
                                 var arr = [];
                                 d.each(function(dd){