Subform entries are not saved on third subform

Questions related to using nuBuilder Forte.

Re: Subform entries are not saved on third subform

Postby kev1n » Tue Jul 09, 2019 2:09 am

Well, this is just a shot in the dark. Try increasing max input vars to a higher value:
https://wolfthemes.ticksy.com/article/11675/
kev1n
 
Posts: 191
Joined: Mon Oct 15, 2018 2:13 am

Re: Subform entries are not saved on third subform

Postby fpdragon » Tue Jul 09, 2019 4:50 pm

kev1n wrote:Well, this is just a shot in the dark. Try increasing max input vars to a higher value:
https://wolfthemes.ticksy.com/article/11675/


Thank you very much.

I changed my php.ini
max_input_vars = 10000

Same as before. Same problem.

Any other idea?
fpdragon
 
Posts: 23
Joined: Wed May 29, 2019 10:20 pm

Re: Subform entries are not saved on third subform

Postby fpdragon » Tue Jul 09, 2019 4:59 pm

also doubled
max_input_nesting_level = 128
fpdragon
 
Posts: 23
Joined: Wed May 29, 2019 10:20 pm

Re: Subform entries are not saved on third subform

Postby fpdragon » Tue Jul 09, 2019 7:10 pm

I'm working in parallel on an alternative solution

I'm thinking of using a Browse and Edit form inside an Run.iFrame.

Currently it looks promising but I'm having troubles in moving information from the main form and filling default values in the iFrame form. I still need a foreign key in the iFrame form that is filled somehow automatically with the main form element id.
fpdragon
 
Posts: 23
Joined: Wed May 29, 2019 10:20 pm

Re: Subform entries are not saved on third subform

Postby fpdragon » Tue Jul 09, 2019 9:09 pm

I found out that I can send a default value in the iFrame form with the following code:

Code: Select all
if (nuIsNewRecord())
{
    $('#dml_prj_project_id').val("5cecec3995904fb").change();
}

In the javascript section of the iFrame form.

Currently "5cecec3995904fb" is just a testing constant. Here I need to fill the id of the main form but I havn't figured out how to grab this value in the javascript context of the iFrame form.

If this is solved then I guess I have found a working solution for my application.
fpdragon
 
Posts: 23
Joined: Wed May 29, 2019 10:20 pm

Re: Subform entries are not saved on third subform

Postby kev1n » Tue Jul 09, 2019 9:30 pm

Code: Select all
parent.nuCurrentProperties().form_id
gives you the id of the parent form.
kev1n
 
Posts: 191
Joined: Mon Oct 15, 2018 2:13 am

Re: Subform entries are not saved on third subform

Postby fpdragon » Tue Jul 09, 2019 9:36 pm

kev1n wrote:
Code: Select all
parent.nuCurrentProperties().form_id
gives you the id of the parent form.


Cool thank you.

I came to this solution:
Code: Select all
if (nuIsNewRecord())
{
    $('#dml_prj_project_id').val(parent.document.getElementById('dl_projects_id').value).change();
}


By the way:
Is there a documentation or a list of all nuBuilder commands and variables that can be used in javascript or php?
fpdragon
 
Posts: 23
Joined: Wed May 29, 2019 10:20 pm

Re: Subform entries are not saved on third subform

Postby kev1n » Tue Jul 09, 2019 9:48 pm

Most functions are documented in the Wiki: https://wiki.nubuilder.net/nubuilderfor ... Javascript

nuCurrentProperties() is useful to view all properties of the current form
kev1n
 
Posts: 191
Joined: Mon Oct 15, 2018 2:13 am

Previous

Return to General