fix: use vue3 v-model bindings
see: https://v3.vuejs.org/guide/migration/v-model.html
This commit is contained in:
@ -15,6 +15,7 @@ import Filters from '../../../components/list/partials/filters'
|
||||
|
||||
export default {
|
||||
name: 'filter-popup',
|
||||
emits: ['update:modelValue', 'change'],
|
||||
data() {
|
||||
return {
|
||||
params: null,
|
||||
@ -31,7 +32,7 @@ export default {
|
||||
document.removeEventListener('click', this.hidePopup)
|
||||
},
|
||||
watch: {
|
||||
value: {
|
||||
modelValue: {
|
||||
handler(value) {
|
||||
this.params = value
|
||||
},
|
||||
@ -42,7 +43,7 @@ export default {
|
||||
},
|
||||
},
|
||||
props: {
|
||||
value: {
|
||||
modelValue: {
|
||||
required: true,
|
||||
},
|
||||
visible: {
|
||||
@ -53,7 +54,7 @@ export default {
|
||||
methods: {
|
||||
change() {
|
||||
this.$emit('change', this.params)
|
||||
this.$emit('input', this.params)
|
||||
this.$emit('update:modelValue', this.params)
|
||||
},
|
||||
hidePopup(e) {
|
||||
if (this.visibleInternal) {
|
||||
|
@ -254,12 +254,13 @@ export default {
|
||||
this.filters.requireAllFilters = this.params.filter_concat === 'and'
|
||||
},
|
||||
props: {
|
||||
value: {
|
||||
modelValue: {
|
||||
required: true,
|
||||
},
|
||||
},
|
||||
emits: ['update:modelValue', 'change'],
|
||||
watch: {
|
||||
value: {
|
||||
modelValue: {
|
||||
handler(value) {
|
||||
this.params = value
|
||||
this.prepareFilters()
|
||||
@ -293,7 +294,7 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
change() {
|
||||
this.$emit('input', this.params)
|
||||
this.$emit('update:modelValue', this.params)
|
||||
this.$emit('change', this.params)
|
||||
},
|
||||
prepareFilters() {
|
||||
|
Reference in New Issue
Block a user