adrema/resources/js/views/member/Filt.vue

44 lines
1.3 KiB
Vue
Raw Normal View History

2021-08-22 05:51:25 +02:00
<template>
<div class="px-6 py-2 flex border-b border-gray-600 space-x-3">
2022-02-12 14:52:37 +01:00
<f-switch v-show="hasModule('bill')" id="ausstand" @input="reload" v-model="inner.ausstand" label="Nur Ausstände" size="sm"></f-switch>
<f-select v-show="hasModule('bill')" id="billKinds" @input="reload" :options="billKinds" v-model="inner.bill_kind" label="Rechnung" size="sm"></f-select>
<f-select id="activity_id" @input="reload" :options="activities" v-model="inner.activity_id" label="Tätigkeit" size="sm"></f-select>
<f-select id="subactivity_id" @input="reload" :options="subactivities" v-model="inner.subactivity_id" label="Untertätigkeit" size="sm"></f-select>
2021-08-22 05:51:25 +02:00
</div>
</template>
<script>
import mergesQueryString from '../../mixins/mergesQueryString.js';
export default {
2022-02-12 14:52:37 +01:00
data: function() {
return {
inner: {}
};
},
2021-08-22 05:51:25 +02:00
mixins: [mergesQueryString],
props: {
value: {},
billKinds: {},
activities: {},
subactivities: {},
2021-08-22 05:51:25 +02:00
},
methods: {
reload() {
2022-02-12 14:52:37 +01:00
this.$inertia.visit(this.qs({filter: JSON.stringify(this.inner)}), {
2021-08-22 05:51:25 +02:00
preserveState: true
});
}
2022-02-12 14:52:37 +01:00
},
created() {
this.inner = this.value;
2021-08-22 05:51:25 +02:00
}
2022-02-12 14:52:37 +01:00
2021-08-22 05:51:25 +02:00
};
</script>