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

网络提示问题 #10

Closed
429329513wanting opened this issue Mar 4, 2019 · 3 comments
Closed

网络提示问题 #10

429329513wanting opened this issue Mar 4, 2019 · 3 comments

Comments

@429329513wanting
Copy link

郭神你好!,这个架构,如果统一封装处理网络loading呢,看了半天不知道加在哪里.

@guolindev
Copy link
Owner

没太看明白你的意思。

@429329513wanting
Copy link
Author

就是请求时显示网络进度,请求结束时dismiss网络提示?是在每个viewmodel里处理?

@guolindev
Copy link
Owner

ui操作当然要放到activity或者fragment里面,viewmodel不会持有任何控件的引用,所以肯定不能放在viewmodel里面。你如果想统一封装的话,可以考虑放到BaseActivity里面。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants