This commit is contained in:
张磊 2018-10-23 12:44:26 +08:00
parent 22eddb22ea
commit f8e3474a04
3 changed files with 6 additions and 4 deletions

View File

@ -11,10 +11,10 @@
| ------ | ------ |------ |
| ~~el-button~~ | dntzhang |[Usage](https://github.com/Tencent/omi/blob/master/packages/omi-element-ui/src/elements/button/index.js#L19-L118) |
| ~~el-icon~~ | dntzhang | |
| el-radio| dntzhang | [Usage](https://github.com/Tencent/omi/blob/master/packages/omi-element-ui/src/elements/radio/index.js#L19-L34)|
| ~~el-radio~~| dntzhang | [Usage](https://github.com/Tencent/omi/blob/master/packages/omi-element-ui/src/elements/radio/index.js#L19-L34)|
| el-checkbox| | |
| el-input| | |
| el-input-number| dntzhang | |
| ~~el-input-number~~| dntzhang | [Usage](https://github.com/Tencent/omi/blob/master/packages/omi-element-ui/src/elements/input-number/index.js#L18-L22) |
| el-select| |
| el-cascader| |
| el-switch| |

View File

@ -19,7 +19,6 @@ class MyApp extends WeElement {
<div>
<el-input-number change={this.onChange} min={1} max={10} step={1} value={2} label="描述文字"></el-input-number>
</div>
</div>
)
}

View File

@ -8,6 +8,7 @@ class ElRadio extends WeElement {
}
install() {
this.data.checked = this.props.checked
this._initData()
}
@ -16,13 +17,15 @@ class ElRadio extends WeElement {
}
_initData() {
this.data.checked = this.props.checked
this.data.disabled = this.props.disabled
this.data.value = this.props.value
if (this.parentNode.nodeName === 'EL-RADIO-GROUP') {
if (this.parentNode.data.value === this.data.value) {
this.data.checked = true
} else {
this.data.checked = false
}
this._inInGroup = true
}