feat: enable updating gottesdienste
This commit is contained in:
@@ -7,7 +7,7 @@ const props = withDefaults(defineProps<{
|
||||
label?: string,
|
||||
disabled?: boolean,
|
||||
type?: string,
|
||||
dateFormat?: "string" | "number",
|
||||
dateFormat?: "string" | "number" | "date",
|
||||
focus?: boolean
|
||||
}>(), {
|
||||
dateFormat: "string"
|
||||
@@ -45,10 +45,12 @@ function leading(val) {
|
||||
|
||||
function getValue(){
|
||||
if(props.type == "date" && props.dateFormat == "number") {
|
||||
console.log(props.value)
|
||||
const date = new Date(props.value)
|
||||
return leading(date.getFullYear()) + "-" + zeros(date.getMonth() + 1) + "-" + zeros(date.getDate())
|
||||
}else{
|
||||
} if(props.type == "date" && props.dateFormat == "date") {
|
||||
const date = new Date(props.value)
|
||||
return leading(date.getFullYear()) + "-" + zeros(date.getMonth() + 1) + "-" + zeros(date.getDate())
|
||||
} else {
|
||||
return props.value
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user