mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-07-13 03:27:39 +03:00
Added domain matcher test for #689
This commit is contained in:
parent
d468bac551
commit
08baff9e64
4 changed files with 57 additions and 14 deletions
|
|
@ -11,10 +11,26 @@ import { DomainAliasPopupView } from 'View/Popup/DomainAlias';
|
|||
export class AdminSettingsDomains /*extends AbstractViewSettings*/ {
|
||||
constructor() {
|
||||
this.domains = DomainAdminStore;
|
||||
|
||||
this.username = ko.observable('');
|
||||
this.domainForDeletion = ko.observable(null).askDeleteHelper();
|
||||
}
|
||||
|
||||
testUsername() {
|
||||
// TODO: find domain matching username
|
||||
Remote.request('AdminDomainMatch',
|
||||
(iError, oData) => {
|
||||
if (oData?.Result?.domain) {
|
||||
alert('Matched domain: ' + oData.Result.domain.name);
|
||||
} else {
|
||||
alert('No domain match');
|
||||
}
|
||||
},
|
||||
{
|
||||
username: this.username()
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
createDomain() {
|
||||
showScreenPopup(DomainPopupView);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue