代码生成优化

This commit is contained in:
xiangheng
2024-06-17 22:29:30 +08:00
parent a700a39992
commit 9de418ce1d
20 changed files with 1228 additions and 361 deletions

View File

@@ -0,0 +1,31 @@
<template>
<view style="flex: 1" @click="calendarsRef.open()">
<uv-input :modelValue="title" :readonly="true" placeholder="请选择时间">
</uv-input>
</view>
<uv-calendars ref="calendarsRef" :date="props.time" @confirm="Confirm" />
</template>
<script setup>
import { ref, computed } from "vue";
const emit = defineEmits(["update:time"]);
const props = defineProps({
time: {
type: String,
default: "",
},
});
let calendarsRef = ref(null);
function Confirm(e) {
console.log(e);
emit("update:time", e.fulldate);
// emit("update:endTime", e.range.after);
}
const title = computed(() => {
return props.time;
});
</script>
<style lang="scss" scoped></style>