Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.x 调用 calendar 方法提示 undefined #213

Open
treadpit opened this issue Nov 17, 2019 · 0 comments
Open

1.x 调用 calendar 方法提示 undefined #213

treadpit opened this issue Nov 17, 2019 · 0 comments
Labels

Comments

@treadpit
Copy link
Owner

treadpit commented Nov 17, 2019

1.x 版本:

出现此问题请查看是否调用方法的时机是否有误,日历渲染完成才会绑定方法到页面实例上。

方法默认挂在当前页面实例对象上,即如果使用 this.calendar 调用方法,请确保 this 指向当前页面实例。

this.calendar 上的方法需要在 afterCalendarRender 后,在页面 onLoad 或 初次触发 onShow 的时候,日历可能还未渲染完成,所以此时调用日历方法会提示为 undefined

@treadpit treadpit changed the title 为什么调用日历方法提示方法为 undefined? 出现调用方法提示 undefined 的请看这里 👇👇👇 Nov 17, 2019
@treadpit treadpit changed the title 出现调用方法提示 undefined 的请看这里 👇👇👇 ❗️❗️❗️❗️❗️出现调用方法提示 undefined 的请看这里 ❗️❗️❗️❗️❗️ Nov 28, 2019
@treadpit treadpit pinned this issue Apr 15, 2020
Repository owner deleted a comment from chendaneve Jun 18, 2020
Repository owner deleted a comment from zhiouv Jun 18, 2020
Repository owner locked as resolved and limited conversation to collaborators Jun 18, 2020
@treadpit treadpit changed the title ❗️❗️❗️❗️❗️出现调用方法提示 undefined 的请看这里 ❗️❗️❗️❗️❗️ 调用 calendar 方法提示 undefined Jun 18, 2020
@treadpit treadpit changed the title 调用 calendar 方法提示 undefined 1.x 调用 calendar 方法提示 undefined Oct 26, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant