{{{targetTypeField}}}
+
+
diff --git a/client/src/views/stream/modals/create-post.js b/client/src/views/stream/modals/create-post.js
index 7cfe19e763..c7104c1d74 100644
--- a/client/src/views/stream/modals/create-post.js
+++ b/client/src/views/stream/modals/create-post.js
@@ -30,7 +30,9 @@ import ModalView from 'views/modal';
class CreatePostModalView extends ModalView {
- templateContent = '
+
-
+
+
+ {{{attachmentsField}}}
+
-
- {{{usersField}}}
-
-
- {{{teamsField}}}
-
-
{{{portalsField}}}
+
+
+
+
+ {{{targetTypeField}}}
+
+
+ {{{usersField}}}
+
+
+ {{{teamsField}}}
+
+
{{{portalsField}}}
+ {{{record}}}
'
+ templateContent = `
+ {{{record}}}
+ `
shortcutKeys = {
'Control+Enter': 'post',
diff --git a/client/src/views/stream/record/edit.js b/client/src/views/stream/record/edit.js
index 77ec601822..7fbf4459e7 100644
--- a/client/src/views/stream/record/edit.js
+++ b/client/src/views/stream/record/edit.js
@@ -105,47 +105,11 @@ class EditStreamView extends BaseRecordView {
}
}
- data() {
- const data = super.data();
-
- data.interactiveMode = this.options.interactiveMode;
-
- return data;
- }
-
setup() {
super.setup();
this.seed = this.model.clone();
- if (this.options.interactiveMode) {
- this.events['focus textarea[data-name="post"]'] = () => {
- this.enablePostingMode();
- };
-
- this.addHandler('keydown', 'textarea[data-name="post"]', /** KeyboardEvent */e => {
- if (Espo.Utils.getKeyFromKeyEvent(e) === 'Control+Enter') {
- e.stopPropagation();
- e.preventDefault();
-
- this.post();
- }
-
- // Don't hide to be able to focus on the upload button.
- /*if (e.code === 'Tab') {
- let $text = $(e.currentTarget);
-
- if ($text.val() === '') {
- this.disablePostingMode();
- }
- }*/
- });
-
- this.events['click button.post'] = () => {
- this.post();
- };
- }
-
const optionList = ['self'];
this.model.set('type', 'Post');
@@ -280,17 +244,6 @@ class EditStreamView extends BaseRecordView {
afterSave() {
Espo.Ui.success(this.translate('Posted'));
-
- if (this.options.interactiveMode) {
- this.model.clear();
- this.model.set('targetType', 'self');
- this.model.set('type', 'Post');
-
- this.disablePostingMode();
- this.enablePostButton();
-
- this.getFieldView('post').$element.prop('rows', 1);
- }
}
afterNotValid() {