Prace s mapu, zobrazeni GPX, editace kopilota, skeletony

This commit is contained in:
Michal Kváček
2023-08-07 23:22:28 +02:00
parent 09d2f25523
commit c4603cf090
55 changed files with 891 additions and 408 deletions
+13 -4
View File
@@ -10,8 +10,11 @@ const props = defineProps({
type: [String, Boolean],
required: false,
default: FORMAT_DATETIME_LONG
},
minDate: {
type: [String, Date],
required: false
}
})
let dateModel = ref("");
@@ -36,6 +39,7 @@ onMounted(() => {
emitModelUpdate();
}
});
// TODO: ^^ by asi slo prepsat do watchera, viz ComboboxInput
const publicModel = computed(() => {
@@ -92,7 +96,12 @@ const myLocale = {
pluralDay: 'dny'
}
// https://quasar.dev/vue-composables/use-form-child - mozna resi ohack s onMounted()?
const isDateValid = (date) => {
if (!props.minDate) return true;
const minDate = formatDatetime(props.minDate, "YYYY/MM/DD");
return date >= minDate;
}
</script>
@@ -107,10 +116,10 @@ const myLocale = {
<div class="proxy-wrapper">
<div class="row">
<div class="col-12 col-sm-6" v-if="showDatePicker">
<q-date square v-model="dateModel" :today-btn="true" flat mask="YYYY-MM-DD" :locale="myLocale"/>
<q-date square v-model="dateModel" :options="isDateValid" :today-btn="true" flat mask="YYYY-MM-DD" :locale="myLocale"/>
</div>
<div class="col-12 col-sm-6" v-if="showTimePicker">
<q-time square v-model="timeModel" format24h flat mask="HH:mm"/>
<q-time square v-model="timeModel" format24h flat mask="HH:mm:ss"/>
</div>
</div>
<div class="row q-mb-sm">