javascript - How to show loading message in mashup Qlik Sense
问题描述
im trying to show a loading message when mashup app is obtaining data from Qlik server but i don't get good result with my approach.
My approach is something like that:
First i get de current selections from getLists method and when selections change show the loading message. Then in the hypercube callback at the end of this method i hide the loading message.
The code is something like that:
In getList Method
app.getList("CurrentSelections", function (reply) {
if(selection_change()){
show_loading_message();
}
});
In every HyperCube:
app.createCube(config_cube, function (reply) {
//do stuff with reply data
hide_loading_message();
});
This code is inside of every hypercube in the panel and hide loading message() method wait for the finish of the execution of every cube like of join() method in python multiprocess package.
But my problem is getList and app.createCube method are asynchronous them sometimes the loading message is active after the execution of createcube method and dont back hide the message again.
Someone know how to improve this problem, I need to show the loading message because I'm working with large dataset and qlik sense engine is delayed to give the response data
Thank you!
解决方案
推荐阅读
- python - Django 表单是无效的有效返回且错误未知
- c++ - 如何理解“临时对象被销毁作为评估完整表达式的最后一步”?有人可以通过一些简单的例子说清楚吗?
- istio - 在 Istio 中定义通配符 ServiceEntry 时,VirtualService 的目的是什么?
- python - 如何创建一个启动 Python 脚本的 linux 后台进程(在 c 中)
- react-native - 有没有办法将状态传递给作为道具传递的组件?
- postgresql - Postgresql 无法连接到服务器(Postgresql 12.2,ubuntu 20.04)
- css - 在 CSS 中使框响应式
- reactjs - JWT 提供无效令牌
- node.js - args[0] = 数字。这个怎么做?
- out-of-memory - 使用 tf.GradientTape 进行全批梯度下降:OOM 错误