Explorar o código

修复流程表单中多选按钮最后一个值不能被取消的问题

unknown %!s(int64=6) %!d(string=hai) anos
pai
achega
7b5b912fde
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      o2web/source/x_component_process_Xform/Checkbox.js

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

@@ -123,7 +123,7 @@ MWF.xApplication.process.Xform.Checkbox = MWF.APPCheckbox =  new Class({
 
                 radio.addEvent("click", function(){
                     this.validationMode();
-                    if (this.validation()) this._setBusinessData(this.getInputData("change"));
+                    if (this.validation()) this._setBusinessData(this.getInputData("change") || []);
                 }.bind(this));
 
                 Object.each(this.json.events, function(e, key){
@@ -190,7 +190,7 @@ MWF.xApplication.process.Xform.Checkbox = MWF.APPCheckbox =  new Class({
                 }
             });
         }
-        return (value.length) ? value : null;
+        return (value.length) ? value : [];
     },
     resetData: function(){
         this.setData(this.getValue());