1
1
mirror of https://github.com/Fabio286/antares.git synced 2025-06-05 21:59:22 +02:00

feat(UI): BaseSelect in table filters

This commit is contained in:
Giulio Ganci
2022-05-08 13:15:39 +02:00
parent 5582a12bbf
commit a037d0cc01
2 changed files with 18 additions and 21 deletions

View File

@ -128,12 +128,12 @@ export default defineComponent({
const getOptionValue = (opt) => {
const key = typeof props.optionTrackBy === 'function' ? props.optionTrackBy() : props.optionTrackBy;
return opt[key];
return key ? opt[key] : opt;
};
const getOptionLabel = (opt) => {
const key = typeof props.optionLabel === 'function' ? props.optionLabel() : props.optionLabel;
return opt[key];
return key ? opt[key] : opt;
};
const currentOptionLabel = computed(() => {
@ -221,7 +221,6 @@ export default defineComponent({
<style lang="scss" scoped>
.select {
position: relative;
width: 100%;
display: block;
&__search-input {