Rename eventSlug prop
This commit is contained in:
parent
64caad9aef
commit
c55bb174c2
|
@ -46,7 +46,7 @@ const props = defineProps({
|
|||
required: true,
|
||||
type: String,
|
||||
},
|
||||
event: {
|
||||
visibleEventSlug: {
|
||||
required: false,
|
||||
type: String,
|
||||
},
|
||||
|
@ -58,8 +58,8 @@ const visibleEvent = ref(null);
|
|||
async function reloadEvents() {
|
||||
const results = await axios.get('/api/form');
|
||||
events.value = results.data.data;
|
||||
if (props.event) {
|
||||
visibleEvent.value = events.value.find((event) => event.slug === props.event);
|
||||
if (props.visibleEventSlug) {
|
||||
visibleEvent.value = events.value.find((event) => event.slug === props.visibleEventSlug);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue