Hi Tanya,
Good day!
How may I call or create the Documents modal view for creation?
I've seen the same functionality I want to happen in Quote Email to PDF functionality.
The snippet below call the Compose Email in the Quote where it automatically attaches the Attachment within the "attributes" object and map it in the compose email modal.
Now, I want to do the same thing but not on compose email modal, but on a Create Documents modal with the PDF attached.
I already tried the modals for Document entity below but it is not working:
Good day!
How may I call or create the Documents modal view for creation?
I've seen the same functionality I want to happen in Quote Email to PDF functionality.
Advanced:Views.Quote.Record.Detail
Code:
actionComposeEmail: function () { this.createView('pdfTemplate', 'views/modals/select-template', { entityType: this.model.name }, function (view) { view.render(); this.listenToOnce(view, 'select', function (model) { this.notify('Loading...'); this.ajaxPostRequest('Quote/action/getAttributesForEmail', { quoteId: this.model.id, templateId: model.id }).done(function (attributes) { var viewName = this.getMetadata().get('clientDefs.Email.modalViews.compose') || 'views/modals/compose-email'; // my line of concern this.createView('composeEmail', viewName, { attributes: attributes, keepAttachmentsOnSelectTemplate: true }, function (view) { view.render(); this.notify(false); }, this); }.bind(this)); }, this); }, this); }
I already tried the modals for Document entity below but it is not working:
crm:views/document/modals/select-records
views/modals/detail
views/modals/edit
Comment