Hi community. I think this isn't an issue for many NB devs, but recently i've been struggling with that.
Details: Have 2 distinct forms (conventional 'Contracts' and 'Payments') where the Contract has 'contract_num' among its objects and
a button which opens (popup or new breadcrumb) 'Payments' form. And that Payments in turn must have its 'contract' field auto-filled with the '#contract_num#' if opened via 'Contracts' button (& not editable) and just empty (& editable) otherwise.
So i thought i have done something similar using .parent method in past, but here it seems not working, maybe 'Contracts' not considered a parent for the 'Payments' and its just the context needs to be passed somehow..
What's the standart or recommended ways to share context (pass variables) between forms appwide ?
Welcome to the nuBuilder Forums!
Join our community by registering and logging in.
As a member, you'll get access to exclusive forums, resources, and content available only to registered users.
Join our community by registering and logging in.
As a member, you'll get access to exclusive forums, resources, and content available only to registered users.
Pass variables between forms (frontend)
-
- nuBuilder Team
- Posts: 4587
- Joined: Sun Oct 14, 2018 6:43 pm
- Has thanked: 76 times
- Been thanked: 536 times
- Contact:
Re: Pass variables between forms (frontend)
As long as “Payments” is opened as a popup, all fields can be accessed from its parent form “Contracts.”
Otherwise, use nuSetProperty() to set a global hash cookie (set the third parameter to true) and retrieve it with nuGetProperty()
Otherwise, use nuSetProperty() to set a global hash cookie (set the third parameter to true) and retrieve it with nuGetProperty()