Skip to content
Lukas Polak edited this page Jul 17, 2014 · 2 revisions

Notes

Now, we can support notes out of scope. Here are only changes you have to make to your code:

  1. Your theme has to load js/notes.js file (path to this file is automatically added to f3-minify by default)
  2. Add trait \Dsc\Tratis\Models\Notes to your model
  3. Modify your beforeSave() method and add this line of code $this->beforeSaveNotes();
  4. Notes require BootBox JS loaded
  5. Render HTML for notes using this line of code $this->renderLayout('SystemTheme/Views::notes/notes.php');
  6. Assign JS code to submit button using this line of code executed right after DOM is ready Notes.bindSaveButton( 'selector-to-your-submit-button' );
Clone this wiki locally