Explorar el Código

修复下拉组件__setValue方法的BUG

unknown hace 4 años
padre
commit
018d42be2f
Se han modificado 1 ficheros con 4 adiciones y 2 borrados
  1. 4 2
      o2web/source/x_component_process_Xform/Select.js

+ 4 - 2
o2web/source/x_component_process_Xform/Select.js

@@ -330,8 +330,10 @@ MWF.xApplication.process.Xform.Select = MWF.APPSelect =  new Class(
 	__setValue: function(value){
 		if (!this.readonly && !this.json.isReadonly ) {
 			this._setBusinessData(value);
-			for (var i=0; i<this.node.options.length; i++){
-				var option = this.node.options[i];
+
+			var ops = this.node.getElements("option");
+			for (var i=0; i<ops.length; i++){
+				var option = ops[i];
 				if (option.value==value){
 					option.selected = true;
 					//	break;