1
我有一个portlet(只有一个portlet在页面上),并希望在用户等待请求时显示微调(或沙漏)。Liferay - 页面加载时显示微调
设置render-weight
到0
在liferay-portlet.xml
作品,但随后的CSS类没有加载和URL参数不再被解析。
有没有另一种解决方案呢?
[我跑的Liferay 6.1.20 EE]
由于提前, 没法比
我有一个portlet(只有一个portlet在页面上),并希望在用户等待请求时显示微调(或沙漏)。Liferay - 页面加载时显示微调
设置render-weight
到0
在liferay-portlet.xml
作品,但随后的CSS类没有加载和URL参数不再被解析。
有没有另一种解决方案呢?
[我跑的Liferay 6.1.20 EE]
由于提前, 没法比
通过使用jQuery,我可以设置cursor
到wait
每当用户点击一个链接:
jqueryBusy = function(){
$("a").click(function() {
$("*").css("cursor", "wait");
});
};
我调用这个函数在页面加载时和somethink simmelar,每当一个Ajax请求忙:
if (!window["busystatus"]) {
var busystatus = {};
}
busystatus.onStatusChange = function onStatusChange(data) {
var status = data.status;
jqueryBusy(); //set jquery event handler for all links
if (status === "begin") { // turn on busy indicator
document.body.style.cursor = 'wait';
} else { // turn off busy indicator, on either "complete" or "success"
document.body.style.cursor = 'auto';
}
};
jsf.ajax.addOnEvent(busystatus.onStatusChange);
适合我。