roojs-bootstrap.js
authorEdward <edward@roojs.com>
Fri, 25 Apr 2014 11:19:00 +0000 (19:19 +0800)
committerEdward <edward@roojs.com>
Fri, 25 Apr 2014 11:19:00 +0000 (19:19 +0800)
roojs-bootstrap-debug.js

roojs-bootstrap-debug.js
roojs-bootstrap.js

index 1aa68c5..d882800 100644 (file)
@@ -4299,9 +4299,7 @@ Roo.extend(Roo.bootstrap.Input, Roo.bootstrap.Component,  {
     },
     
     getGroupValue : function(){
-        
-        Roo.log(this.parent());
-        return this.parent().child('input[name='+this.el.dom.name+']:checked', true).value;
+        return this.inputEL().up('form').child('input[name='+this.el.dom.name+']:checked', true).value;
     },
     
     onClick : function(){
index 000d4df..205964a 100644 (file)
@@ -99,7 +99,7 @@ i.setAttribute('disabled','true');},initEvents:function(){this.inputEl().on("key
 this.hasFocus=false;if(this.validationEvent!==false&&this.validateOnBlur&&this.validationEvent!="blur"){this.validate();}var v=this.getValue();if(String(v)!==String(this.startValue)){this.fireEvent('change',this,v,this.startValue);}
 this.fireEvent("blur",this);},reset:function(){this.setValue(this.originalValue);this.clearInvalid();},getName:function(){return this.name;},getValue:function(){var v=this.inputEl().getValue();return v;},getRawValue:function(){var v=this.inputEl().getValue();return v;},setRawValue:function(v){return this.inputEl().dom.value=(v===null||v===undefined?'':v);},selectText:function(A,B){var v=this.getRawValue();if(v.length>0){A=A===undefined?0:A;B=B===undefined?v.length:B;var d=this.inputEl().dom;if(d.setSelectionRange){d.setSelectionRange(A,B);}else if(d.createTextRange){var C=d.createTextRange();C.moveStart("character",A);C.moveEnd("character",v.length-B);C.select();}}},setValue:function(v){this.value=v;if(this.rendered){this.inputEl().dom.value=(v===null||v===undefined?'':v);this.validate();}},preFocus:function(){if(this.selectOnFocus){this.inputEl().dom.select();}},filterKeys:function(e){var k=e.getKey();if(!Roo.isIE&&(e.isNavKeyPress()||k==e.BACKSPACE||(k==e.DELETE &&e.button==-1))){return;}var c=e.getCharCode(),cc=String.fromCharCode(c);if(Roo.isIE&&(e.isSpecialKey()||!cc)){return;}if(!this.maskRe.test(cc)){e.stopEvent();}},clearInvalid:function(){if(!this.el||this.preventMark){return;}
 this.el.removeClass(this.invalidClass);this.fireEvent('valid',this);},markInvalid:function(A){if(!this.el||this.preventMark){return;}
-this.el.addClass(this.invalidClass);this.fireEvent('invalid',this,A);},SafariOnKeyDown:function(A){var B=false;if(this.inputEl().dom.selectionEnd>0){B=(this.inputEl().dom.selectionEnd-this.inputEl().dom.selectionStart-this.getValue().length==0)?true:false;}if(((A.getKey()==8||A.getKey()==46)&&this.getValue().length==1)){A.preventDefault();this.setValue('');return;}if(B){A.preventDefault();var cc=String.fromCharCode(A.getCharCode());this.setValue(A.shiftKey?cc:cc.toLowerCase());}},getGroupValue:function(){Roo.log(this.parent());return this.parent().child('input[name='+this.el.dom.name+']:checked',true).value;},onClick:function(){Roo.log('got');if(this.inputType!='checkbox'&&this.inputType!='radio'){return;}
+this.el.addClass(this.invalidClass);this.fireEvent('invalid',this,A);},SafariOnKeyDown:function(A){var B=false;if(this.inputEl().dom.selectionEnd>0){B=(this.inputEl().dom.selectionEnd-this.inputEl().dom.selectionStart-this.getValue().length==0)?true:false;}if(((A.getKey()==8||A.getKey()==46)&&this.getValue().length==1)){A.preventDefault();this.setValue('');return;}if(B){A.preventDefault();var cc=String.fromCharCode(A.getCharCode());this.setValue(A.shiftKey?cc:cc.toLowerCase());}},getGroupValue:function(){return this.inputEL().up('form').child('input[name='+this.el.dom.name+']:checked',true).value;},onClick:function(){Roo.log('got');if(this.inputType!='checkbox'&&this.inputType!='radio'){return;}
 Roo.log('run set Checked');this.setChecked(!this.checked);},setChecked:function(A,B){this.checked=A;if(B!==true){this.fireEvent('check',this,A);}
 this.el.dom.value=A?this.value:this.valueOff;}});
 //Roo/bootstrap/TextArea.js