tenghui-ui 2.4.21 → 2.4.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tenghui-ui",
3
- "version": "2.4.21",
3
+ "version": "2.4.22",
4
4
  "description": "vue 2x, tenghui-ui",
5
5
  "files": [
6
6
  "dist",
@@ -417,7 +417,7 @@ export default {
417
417
  data() {
418
418
 
419
419
  let defaultModel = this.model;
420
- if (this.type == 'select') {
420
+ if (['select', 'radio'].includes(this.type)) {
421
421
  if (Array.isArray(this.model)) {
422
422
  defaultModel = this.model.map(v => v.toString());
423
423
  } else if (this.model || this.model === 0) {
@@ -670,7 +670,7 @@ export default {
670
670
  model(val) {
671
671
 
672
672
  let modelVal = val;
673
- if (this.type == 'select' && !this.multiple) {
673
+ if (['select', 'radio'].includes(this.type) && !this.multiple) {
674
674
  if (val || val === 0) {
675
675
  modelVal = val.toString();
676
676
  }