Welcome to the nuBuilder Forums!

Register and log in to access exclusive forums and content available only to registered users.

The Lookup field of the lower lines are inactive in the subf

Questions related to using nuBuilder Forte.
ltrannoy
Posts: 19
Joined: Sat Jul 26, 2014 10:09 am
Location: France

Re: The Lookup field of the lower lines are inactive in the

Unread post by ltrannoy »

In the subform, I have 2 dependent Lookup fields: L1 and L2

In the parent field, I have a hidden field.
This hidden field is used to filter the search table of L2

I have assigned a Hover event on L2
The Hover event of L2 assigns the value of L1 to the hidden field

So when we click on L2, the query filters on on the value of the hidden field (corresponding to the value of L1 therefore)
The Hover event only works on the added line just after saving the form. This does not focus on the extra lines.

Max
toms
Posts: 785
Joined: Sun Oct 14, 2018 11:25 am

Re: The Lookup field of the lower lines are inactive in the

Unread post by toms »

Hi,
I have assigned a Hover event on L2
It remains unclear how the event is applied (Javascript code?) And I guess that you need to reset it whenever a new row is inserted.
ltrannoy
Posts: 19
Joined: Sat Jul 26, 2014 10:09 am
Location: France

Re: The Lookup field of the lower lines are inactive in the

Unread post by ltrannoy »

Hi,

My JavaScript code in the form :
$(document).ready(function () {

$("div[id$='customer_idbutton']").hover(
function () {
$('#delivery_id2').val(nuSubformValue(this,'delivery_id'));
}
);

delivery_id2 is an hidden field
toms
Posts: 785
Joined: Sun Oct 14, 2018 11:25 am

Re: The Lookup field of the lower lines are inactive in the

Unread post by toms »

I think you need to set the hover again after a new row has been added.

Check out the afterinsertrow event.
admin
Site Admin
Posts: 2814
Joined: Mon Jun 15, 2009 2:23 am
Been thanked: 25 times

Re: The Lookup field of the lower lines are inactive in the

Unread post by admin »

I concur.
ltrannoy
Posts: 19
Joined: Sat Jul 26, 2014 10:09 am
Location: France

Re: The Lookup field of the lower lines are inactive in the

Unread post by ltrannoy »

Thank you,

It's perfect like that!

Max
admin
Site Admin
Posts: 2814
Joined: Mon Jun 15, 2009 2:23 am
Been thanked: 25 times

Re: The Lookup field of the lower lines are inactive in the

Unread post by admin »

.
Locked