Skip to content

Commit 7d22811

Browse files
feat: extjs-app-imapuser disables default MailAccountHandler
refs conjoon/conjoon#23
1 parent 92a1adc commit 7d22811

5 files changed

+80
-74
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
/**
2+
* conjoon
3+
* extjs-app-imapuser
4+
* Copyright (C) 022 Thorsten Suckow-Homberg https://github.com/conjoon/extjs-app-imapuser
5+
*
6+
* Permission is hereby granted, free of charge, to any person
7+
* obtaining a copy of this software and associated documentation
8+
* files (the "Software"), to deal in the Software without restriction,
9+
* including without limitation the rights to use, copy, modify, merge,
10+
* publish, distribute, sublicense, and/or sell copies of the Software,
11+
* and to permit persons to whom the Software is furnished to do so,
12+
* subject to the following conditions:
13+
*
14+
* The above copyright notice and this permission notice shall be included
15+
* in all copies or substantial portions of the Software.
16+
*
17+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
18+
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
19+
* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
20+
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
21+
* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
22+
* OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
23+
* USE OR OTHER DEALINGS IN THE SOFTWARE.
24+
*/
25+
26+
27+
/**
28+
* Custom styles for the AuthForm.
29+
*/
30+
Ext.define("conjoon.cn_imapuser.overrides.conjoon.cn_mail.view.mail.account.MailAccountHandler", {
31+
32+
override: "conjoon.cn_mail.view.mail.account.MailAccountHandler",
33+
34+
enabled () {
35+
return false;
36+
}
37+
});
38+
39+

tests/groups.config.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@
2626
export default [{
2727
group: "overrides",
2828
items: [
29-
"overrides/coon.user.view.authentication.AuthFormTest.js"
29+
"overrides/coon.user.view.authentication.AuthFormTest.js",
30+
"overrides/conjoon.cn_mail.view.mail.account.MailAccountHandlerTest.js"
3031
]
3132
}, {
3233
group: "universal",

tests/overrides/conjoon.cn_mail.data.mail.account.proxy.MailAccountProxyTest.js

-73
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
/**
2+
* conjoon
3+
* extjs-app-imapuser
4+
* Copyright (C) 2022 Thorsten Suckow-Homberg https://github.com/conjoon/extjs-app-imapuser
5+
*
6+
* Permission is hereby granted, free of charge, to any person
7+
* obtaining a copy of this software and associated documentation
8+
* files (the "Software"), to deal in the Software without restriction,
9+
* including without limitation the rights to use, copy, modify, merge,
10+
* publish, distribute, sublicense, and/or sell copies of the Software,
11+
* and to permit persons to whom the Software is furnished to do so,
12+
* subject to the following conditions:
13+
*
14+
* The above copyright notice and this permission notice shall be included
15+
* in all copies or substantial portions of the Software.
16+
*
17+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
18+
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
19+
* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
20+
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
21+
* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
22+
* OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
23+
* USE OR OTHER DEALINGS IN THE SOFTWARE.
24+
*/
25+
26+
StartTest(t => {
27+
28+
29+
t.requireOk(
30+
"conjoon.cn_imapuser.overrides.conjoon.cn_mail.view.mail.account.MailAccountHandler", () => {
31+
32+
t.expect(Ext.create("conjoon.cn_mail.view.mail.account.MailAccountHandler").enabled()).toBe(false);
33+
34+
});
35+
36+
});

tests/tests.config.js

+3
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,13 @@ export default {
3838
"conjoon.cn_imapuser": "../src",
3939

4040
"conjoon.cn_imapuser.overrides.coon.user.view.authentication.AuthForm": "../classic/overrides/coon.user.view.authentication.AuthForm.js",
41+
"conjoon.cn_imapuser.overrides.conjoon.cn_mail.view.mail.account.MailAccountHandler": "../classic/overrides/conjoon.cn_mail.view.mail.account.MailAccountHandler.js",
4142

4243
"coon.user.view.authentication.AuthWindow": "../../node_modules/@coon-js/extjs-app-user/src/view/authentication/AuthWindow.js",
4344

4445
"conjoon.cn_mail": "../../node_modules/@conjoon/extjs-app-webmail/src/",
46+
"conjoon.cn_mail.view.mail.account.MailAccountHandler": "../../node_modules/@conjoon/extjs-app-webmail/classic/src/view/mail/account/MailAccountHandler.js",
47+
"conjoon.cn_mail.view.mail.account.MailAccountWizard": "../../node_modules/@conjoon/extjs-app-webmail/classic/src/view/mail/account/MailAccountWizard.js",
4548

4649
"coon.user": "../../node_modules/@coon-js/extjs-app-user/src/",
4750
"coon.user.view": "../../node_modules/@coon-js/extjs-app-user/classic/src/view",

0 commit comments

Comments
 (0)