Jon Erickson Posted July 18, 2018 Posted July 18, 2018 I am building a document model that features the ability to build a template beforehand and then insert it into a new document CKEditor. Within the document form, there is a node selector for choosing the template. How can I observe a selection of the node selector 'documents_template', and on selection, insert text into the editor 'documents_content'? Thanks! $form->add(new \IPS\Helpers\Form\Node('documents_template', $this->id ? $this->template : 0, TRUE, array('class' => 'IPS\perscom\Documents\Template', 'subnodes' => FALSE, 'zeroVal' => 'templates_none'))); $form->add(new \IPS\Helpers\Form\Editor('documents_content', $this->id ? $this->content : NULL, TRUE, array('app' => 'perscom', 'key' => 'Document', 'autoSaveKey' => 'document', 'attachIds' => array($this->id), 'allowAttachments' => TRUE, 'editorId' => 'perscom_editor_document')));
Recommended Posts
Archived
This topic is now archived and is closed to further replies.