perf: 日历组件更新

This commit is contained in:
Hefeng
2024-03-11 11:01:03 +08:00
parent 78a640179e
commit 2cf35a8842
3 changed files with 1547 additions and 4 deletions

View File

@ -1,5 +1,5 @@
<!--本文件由FirstUI授权予新疆天衡创新研究院有限公司手机号 1 86 1 40 72 549身份证尾号5A07X5专用请尊重知识产权勿私下传播违者追究法律责任-->
<template>
<!--本文件由FirstUI授权予新疆天衡创新研究院有限公司会员ID20 4 9营业执照号 9 1 65 0 1 04 MA7 9 5A 07 X5专用请尊重知识产权勿私下传播违者追究法律责任-->
<view class="fui-wrap">
<view class="fui-page__hd">
<view class="fui-page__title fui-align__center" @tap="vip">Calendar <image
@ -12,8 +12,8 @@
<fui-calendar @change="change"></fui-calendar>
<view class="fui-section__title">多个日期选择/显示农历</view>
<fui-calendar type="2" :isMultiple="false" showLunar @change="change1"></fui-calendar>
<view class="fui-section__title">设置自定义描述</view>
<fui-calendar :isMultiple="false" @change="change" @dateChange="dateChange"
<view class="fui-section__title">设置自定义描述/角标</view>
<fui-calendar badgeColor="#09BE4F" :isMultiple="false" @change="change" @dateChange="dateChange"
ref="calendarRef"></fui-calendar>
<view class="fui-section__title">设置默认值/范围/仅展示不可选择</view>
<fui-calendar type="2" :isMultiple="false" language="en" :value="value" disabled minDate="2021-01-01"
@ -61,15 +61,18 @@
}, 500)
},
onReady() {
if (!this.$refs.calendarRef) return;
//设置自定义描述数据
this.$refs.calendarRef.setDescr(this.getDescr)
//设置角标返回数组中数据判定为true则显示角标为false则不显示角标
this.$refs.calendarRef.setBadge(this.getDescr)
},
methods: {
vip() {
this.fui.href("/pages/my/qa/qa?index=2&title=VIP专属内容")
},
change(e) {
// console.log(e)
console.log(e)
this.fui.toast(e.value)
},
change1(e) {