IDEMPIERE-988 Failed to process script In Advanced search for any window.

This commit is contained in:
Heng Sin Low 2013-06-24 17:45:25 +08:00
parent 079d1afa21
commit 788d932239
2 changed files with 4 additions and 2 deletions

View File

@ -911,6 +911,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
getComponent().getParent().appendChild(win);
showBusyMask(win);
LayoutUtils.openOverlappedWindow(getComponent(), win, "middle_center");
win.focus();
}
public void onChat()
@ -2607,7 +2608,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
if (mask != null && mask.getParent() != null) {
mask.detach();
StringBuilder script = new StringBuilder("var w=zk.Widget.$('#");
script.append(getComponent().getParent().getUuid()).append("');w.busy=false;");
script.append(getComponent().getParent().getUuid()).append("');if(w) w.busy=false;");
Clients.response(new AuScript(script.toString()));
}
}

View File

@ -13,11 +13,12 @@ zk.override(zk.Widget.prototype, "canActivate",
}
var wgt = this;
while (wgt) {
if (wgt.busy) {
if (wgt.busy) {
if (wgt.busy.className == 'zul.wnd.Window') {
if (zUtl.isAncestor(wgt.busy, this)) {
return true;
} else {
jq.focusOut();
wgt.busy.focus(0);
return false;
}