meixioacomponent 2.0.33 → 2.0.35

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": "meixioacomponent",
3
- "version": "2.0.33",
3
+ "version": "2.0.35",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -122,20 +122,29 @@ export default {
122
122
  },
123
123
 
124
124
  onChange(currentValue, ChangeSource) {
125
- if (currentValue >= this.max) {
126
- this.module = this.max;
127
- return;
125
+ if (this.max) {
126
+ if (currentValue >= this.max) {
127
+ this.module = this.max;
128
+ return;
129
+ }
128
130
  }
129
- if (currentValue === 0) {
130
- this.$nextTick(() => {
131
- this.module = this.$props.min;
132
- })
131
+
132
+ if (typeof this.min === 'number') {
133
+ if (this.module < this.min) {
134
+ this.module = this.min;
135
+ }
133
136
  } else if (!currentValue) {
134
137
  this.$nextTick(() => {
135
138
  this.module = this.$props.defaultValue;
136
139
  })
137
140
  }
138
- // this.$emit('onChange', this.module)
141
+
142
+ if (this.controls) {
143
+ this.$emit('onChange', this.module);
144
+ this.privateValue = this.module;
145
+ }
146
+
147
+ //
139
148
  },
140
149
 
141
150
  onBlue() {
@@ -150,20 +159,20 @@ export default {
150
159
  components: {BaseStoreSelect},
151
160
  watch: {
152
161
  min: {
153
- handler(newVal){
162
+ handler(newVal) {
154
163
  if (this.module < newVal) {
155
164
  this.onChange(newVal);
156
165
  }
157
166
  },
158
- deep:true
167
+ deep: true
159
168
  },
160
169
  max: {
161
- handler (newVal) {
170
+ handler(newVal) {
162
171
  if (this.module > newVal) {
163
172
  this.onChange(newVal);
164
173
  }
165
174
  },
166
- deep:true
175
+ deep: true
167
176
  }
168
177
  }
169
178
  }
@@ -530,6 +530,8 @@ export default {
530
530
  return timestampArray.map((item) => {
531
531
  return this.returnTimestamp(item)
532
532
  })
533
+ } else if (!timestampArray) {
534
+ return [];
533
535
  }
534
536
  return timestampArray
535
537
  },