Skip to content

Commit ca1ecfe

Browse files
Merge branch 'extjs-app-webmail#255' into dev
2 parents 5ed4f8d + c09e4cf commit ca1ecfe

File tree

56 files changed

+10289
-9044
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+10289
-9044
lines changed

.babelrc

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"sourceType": "script",
3+
"presets": [
4+
[
5+
"@babel/preset-env",
6+
{
7+
"useBuiltIns": "entry",
8+
"corejs": "3.22"
9+
}
10+
]
11+
]
12+
}

.deloreanrc.json

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"map" : [
3+
"sencha.classpath",
4+
"sencha.overrides",
5+
"classpath",
6+
"overrides"
7+
],
8+
"toolkits": [
9+
"modern", "classic"
10+
],
11+
"builds": [
12+
"desktop", "shared"
13+
]
14+
}

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,5 @@
44
/node_modules/
55
*.env
66
/.extjs-link.conf.json
7+
/.deloreanbuild/
8+
/package.json.delorean

classic/src/view/mail/message/editor/HtmlEditor.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* conjoon
33
* extjs-app-webmail
4-
* Copyright (C) 2019-2021 Thorsten Suckow-Homberg https://github.com/conjoon/extjs-app-webmail
4+
* Copyright (C) 2019-2022 Thorsten Suckow-Homberg https://github.com/conjoon/extjs-app-webmail
55
*
66
* Permission is hereby granted, free of charge, to any person
77
* obtaining a copy of this software and associated documentation
@@ -107,12 +107,12 @@ Ext.define("conjoon.cn_mail.view.mail.message.editor.HtmlEditor", {
107107

108108
// Destroying the component during initialization cancels initialization.
109109
if (me.destroying || me.destroyed) {
110-
return me.callParent(arguments);
110+
return me.superclass.initFrameDoc.apply(me, arguments);
111111
}
112112

113113
me.editorHtmlTemplateTxt = await me.loadMarkup();
114114

115-
return me.callParent(arguments);
115+
return me.superclass.initFrameDoc.apply(me, arguments);
116116
},
117117

118118

classic/src/view/mail/message/grid/feature/PreviewTextLazyLoad.js

Lines changed: 34 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,16 @@ Ext.define("conjoon.cn_mail.view.mail.message.grid.feature.PreviewTextLazyLoad",
4646
"l8",
4747
"conjoon.cn_mail.data.mail.message.CompoundKey",
4848
"coon.core.data.pageMap.PageMapUtil",
49-
"coon.core.data.pageMap.RecordPosition"
49+
"coon.core.data.pageMap.RecordPosition",
50+
"coon.core.data.request.Configurator"
5051
],
5152

53+
statics: {
54+
required: {
55+
requestConfigurator: "coon.core.data.request.Configurator"
56+
}
57+
},
58+
5259
/**
5360
* @type {Object} pendingLazies
5461
* @private
@@ -59,6 +66,11 @@ Ext.define("conjoon.cn_mail.view.mail.message.grid.feature.PreviewTextLazyLoad",
5966
* @private
6067
*/
6168

69+
/**
70+
* @type {coon.core.data.request.Configurator} requestConfigurator
71+
* @private
72+
*/
73+
6274

6375
/**
6476
* Inits this plugin.
@@ -447,16 +459,32 @@ Ext.define("conjoon.cn_mail.view.mail.message.grid.feature.PreviewTextLazyLoad",
447459
store = grid.getStore(),
448460
proxy = store.getProxy();
449461

450-
Ext.Ajax.request({
462+
Ext.Ajax.request(me.requestConfigurator.configure(
463+
464+
me.getDefaultRequestCfg({
465+
url,
466+
idsToLoad,
467+
options: proxy.getDefaultParameters("ListMessageItem.options")
468+
})
469+
470+
471+
)).then(me.processLoadedPreviewText.bind(me));
472+
},
473+
474+
475+
/**
476+
* @private
477+
*/
478+
getDefaultRequestCfg ({url, idsToLoad, options}) {
479+
return {
451480
method: "get",
452481
url: url,
453-
headers: proxy.headers,
454482
params: {
455483
attributes: "previewText",
456-
options: proxy.getDefaultParameters("ListMessageItem.options"),
484+
options: options,
457485
filter: JSON.stringify([{"property": "id", "operator": "in", "value": idsToLoad}])
458486
}
459-
}).then(me.processLoadedPreviewText.bind(me));
487+
};
460488
}
461489

462-
});
490+
});

classic/src/view/mail/message/reader/MessageViewIframe.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* conjoon
33
* extjs-app-webmail
4-
* Copyright (C) 2019-2021 Thorsten Suckow-Homberg https://github.com/conjoon/extjs-app-webmail
4+
* Copyright (C) 2019-2022 Thorsten Suckow-Homberg https://github.com/conjoon/extjs-app-webmail
55
*
66
* Permission is hereby granted, free of charge, to any person
77
* obtaining a copy of this software and associated documentation
@@ -93,7 +93,7 @@ Ext.define("conjoon.cn_mail.view.mail.message.reader.MessageViewIframe", {
9393
me.publishState("imagesAllowed", me.imagesAllowed);
9494

9595
if (!value) {
96-
return me.callParent([value]);
96+
return me.superclass.setSrcDoc.apply(me, [value]);
9797
}
9898

9999
const
@@ -105,9 +105,12 @@ Ext.define("conjoon.cn_mail.view.mail.message.reader.MessageViewIframe", {
105105
),
106106
tpl = await coon.core.Template.load(tplPath);
107107

108-
value = tpl.render({theme: themeConfig ? themeConfig : {}, reader: {body: value, imagesAllowed: me.imagesAllowed}});
108+
value = tpl.render({
109+
theme: themeConfig ? themeConfig : {},
110+
reader: {body: value, imagesAllowed: me.imagesAllowed}
111+
});
109112

110-
return me.callParent([value]);
113+
return me.superclass.setSrcDoc.apply(me, [value]);
111114
},
112115

113116

0 commit comments

Comments
 (0)