Fix Uuids for select
This commit is contained in:
parent
89f5489e86
commit
4057f9fc8d
|
@ -8,12 +8,7 @@
|
||||||
<select :disabled="disabled" :name="name" :value="value" @change="trigger">
|
<select :disabled="disabled" :name="name" :value="value" @change="trigger">
|
||||||
<option v-if="placeholder" v-html="placeholder" :value="null"></option>
|
<option v-if="placeholder" v-html="placeholder" :value="null"></option>
|
||||||
|
|
||||||
<option
|
<option v-for="option in parsedOptions" :key="option.id" v-html="option.name" :value="option.id"></option>
|
||||||
v-for="option in parsedOptions"
|
|
||||||
:key="option.id"
|
|
||||||
v-html="option.name"
|
|
||||||
:value="option.id"
|
|
||||||
></option>
|
|
||||||
</select>
|
</select>
|
||||||
<div class="info-wrap">
|
<div class="info-wrap">
|
||||||
<div v-if="hint" v-tooltip="hint">
|
<div v-if="hint" v-tooltip="hint">
|
||||||
|
@ -95,10 +90,7 @@ export default {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
trigger(v) {
|
trigger(v) {
|
||||||
this.$emit(
|
this.$emit('input', /^[0-9]+$/.test(v.target.value) ? parseInt(v.target.value) : v.target.value ? v.target.value : null);
|
||||||
'input',
|
|
||||||
isNaN(parseInt(v.target.value)) ? (v.target.value ? v.target.value : null) : parseInt(v.target.value)
|
|
||||||
);
|
|
||||||
},
|
},
|
||||||
clear() {
|
clear() {
|
||||||
this.$emit('input', null);
|
this.$emit('input', null);
|
||||||
|
@ -119,12 +111,6 @@ export default {
|
||||||
|
|
||||||
<style scope>
|
<style scope>
|
||||||
.inset-bg {
|
.inset-bg {
|
||||||
background: linear-gradient(
|
background: linear-gradient(to bottom, hsl(247.5, 66.7%, 97.6%) 0%, hsl(247.5, 66.7%, 97.6%) 41%, hsl(0deg 0% 100%) 41%, hsl(180deg 0% 100%) 100%);
|
||||||
to bottom,
|
|
||||||
hsl(247.5, 66.7%, 97.6%) 0%,
|
|
||||||
hsl(247.5, 66.7%, 97.6%) 41%,
|
|
||||||
hsl(0deg 0% 100%) 41%,
|
|
||||||
hsl(180deg 0% 100%) 100%
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue