[solved] QDate/QInput - Close on Selection
-
I have two date pickers on a form that I want to have close when someone selects a date. I found this post but couldn’t really understand the answer. Is there some way to set it up where it will close whichever one opened.
I am using Quasar v1. Here is the codepen from the original: https://codepen.io/trondulseth-me/pen/OJPqyeM
-
You don’t need to put a method in the input event, as
hide
is a method.https://codepen.io/smolinari/pen/GRNxrEM
Scott
-
This post is deleted! -
I figured it out.
<q-date v-model="enddate" mask="MM/DD/YYYY" @input="closeEndDate">
methods: { closeStartDate() { this.$refs.qStartProxy.hide(); },
You just have to give a ref to the proxy that is unique to each one, which I wasn’t doing.
-
-
Thanks @s-molinari I see you can do it right in line too. I appreciate it!