import { shortcut, Widget } from "@/core"; @shortcut() export class Func extends Widget { static xtype = "demo.calendar"; props = { baseCls: "demo-func" }; render() { const self = this; const date = new Date(); return { type: "bi.calendar", ref() { self.calendar = this; }, logic: { dynamic: false, }, year: date.getFullYear(), month: date.getMonth(), day: date.getDate(), }; } mounted() { const date = new Date(); this.calendar.setValue({ year: date.getFullYear(), month: date.getMonth(), day: date.getDate(), }); } }