!7 cmodule MultiCommClient > DynMultiComm { switchable S password; transient S botID = #1026281; start { dm_reloadOnFieldChange('password); } enhanceFrame { minFrameSize(f, 300, 300); } visualize { if (empty(password) || !testPassword()) { JPasswordField pw = centerTextField(jpassword(password)); ret jfullcenter(withCenteredTitle("Please enter password:", onEnter(pw, r { setField(password := gtt(pw)); }))); } ret awtEveryAndNow(super.visualize(), 10.0, r loadCustomers); } bool testPassword() { S result = print(queryBackend("testAuth")); bool ok = startsWith(result, "OK"); if (!ok) infoBox("Password check failed: " + result); ret ok; } S queryBackend(S uri, O... params) { ret postPage(rawBotLink(botID, uri), paramsPlus(params, _pass := password)); } void loadCustomers q { importAllConceptsOfType(Customer, print("customers", unstructureList(queryBackend("activeCustomers"))), debug := true); } }