Popup Editor - Save but not dismiss.

Popup Editor - Save but not dismiss.

rmeetinrmeetin Posts: 65Questions: 14Answers: 0

Is there the possibility of adding a second button within the popup editor that would do a Save but not dismiss the editor like Update does?

Replies

  • colincolin Posts: 9,822Questions: 0Answers: 1,629

    This thread should help, it's asking the same thing.

    Cheers,

    Colin

  • rmeetinrmeetin Posts: 65Questions: 14Answers: 0

    I looked at the thread and made this change to my buttons:

        buttons: [
          // { extend: 'create', editor: editor },
          { extend: "create", editor: editor,
            formButtons: [
              {
                label: 'Accept',
                fn: function () { this.submit(); this.create(); }
              }, {
                label: 'Save and close',
                fn: function () { this.submit(); this.close(); }
              }
          ] } ,
          { extend: 'edit', editor: editor },
          { extend: 'remove', editor: editor }
        ],
    

    commenting out the default create and replacing it with that from the other post. It does not solve the problem; the original Update button is still there and neither new button shows.

  • colincolin Posts: 9,822Questions: 0Answers: 1,629

    I suspect you missed Allan's reply:

    You can use the formOptions.main option to set the complete option to none. That will keep the Editor window open after submission and you would need to call close() to close it.

    See example here - hope that does the trick.

    Colin

Sign In or Register to comment.