mirror of
https://github.com/getrebuild/rebuild.git
synced 2025-02-25 14:54:44 +08:00
fixs field of BOOL
This commit is contained in:
parent
c1d1e0ec98
commit
19cf941711
1 changed files with 4 additions and 1 deletions
|
@ -4,7 +4,10 @@
|
||||||
class RbFormBool extends RbFormElement {
|
class RbFormBool extends RbFormElement {
|
||||||
constructor(props) {
|
constructor(props) {
|
||||||
super(props)
|
super(props)
|
||||||
this.state.value = props.value || 'F'
|
if (!props.onView) {
|
||||||
|
if (props.value === true || props.value === 'true') this.state.value = 'T'
|
||||||
|
else if (props.value === false || props.value === 'false') this.state.value = 'F'
|
||||||
|
}
|
||||||
this.changeValue = this.changeValue.bind(this)
|
this.changeValue = this.changeValue.bind(this)
|
||||||
}
|
}
|
||||||
renderElement() {
|
renderElement() {
|
||||||
|
|
Loading…
Reference in a new issue