Page 1 of 1

[Solved] Save and Close Form

Posted: Wed Sep 01, 2021 3:31 pm
by MacWomble
Is there a way to close the edit form after saving automatically?

Re: Save and Close Form

Posted: Wed Sep 01, 2021 4:27 pm
by kev1n
Adding this JavaScript code to the form's Custom Code will take you to the previous breadcrumb after saving the form.

Code: Select all

function nuAfterSave() {
  nuOpenPreviousBreadcrumb();
}

Re: Save and Close Form

Posted: Wed Sep 01, 2021 6:57 pm
by MacWomble
Thanks a lot, I'll give it a try tomorrow.

Re: Save and Close Form

Posted: Thu Sep 02, 2021 7:38 am
by MacWomble
This did not solve it. Nothing happens also after refreshing the form. :(

Re: Save and Close Form

Posted: Thu Sep 02, 2021 8:00 am
by kev1n
Check out the "Close after Save" Demo @ https://test.nubuilder.cloud/

Re: Save and Close Form

Posted: Thu Sep 02, 2021 9:42 am
by MacWomble
Hi Kev1n,

It's not active in the demo, but it is exactly what I am looking for ;)
I copied the code from Demo to my form, but it still does nothing except
saving the data. There is also no entry in the debug list.

Is it possible that something is missing on my system? Any idea? :roll:

Re: Save and Close Form

Posted: Thu Sep 02, 2021 10:47 am
by kev1n
What version are you using (see version.txt)?

Re: Save and Close Form

Posted: Fri Sep 03, 2021 11:58 am
by MacWomble
Hi, there is no version.txt. I installed with

git clone https://github.com/steven-copley/nubuilder4.git

on monday.

But that is a good point to start search for. I knew what I'll do on weekend ;-)

Re: Save and Close Form

Posted: Mon Sep 06, 2021 9:25 am
by MacWomble
Ok, you're right. I used a wrong URL. :shock:

With
git clone https://github.com/nuBuilder/nuBuilder-4.5
it now works great. Thank You ! :D