Page 1 of 1

Lookup Filtering

Posted: Mon Feb 24, 2014 11:51 pm
by Eppo
Hi There,

I have an Nubuilder system up and running in my network and on the customer page where you can see the products they bought in a subform. I now want to make an extra subform for possible repairs of those bought products. The problem is that on the repair page I want to select an product that the customer bought. Now I see all the Bought product including all product of all my other customers. How can I filter the lookup screen that I only see his products?

If you need more information please ask me.

Thanks for everything en Keep up the good work.

Jeroen

Re: Lookup Filtering

Posted: Tue Feb 25, 2014 5:44 am
by massiws
Jeroen,
have you seen this post?

Re: Lookup Filtering

Posted: Tue Feb 25, 2014 4:30 pm
by Eppo
To be honest: No.

And now I did I'm not happy about it. Because I am not familiar with Javascript.

So I hope there is another solution or You can give something more than a hint.

Thanks anyway.

Jeroen

Re: Lookup Filtering

Posted: Wed Feb 26, 2014 1:03 am
by massiws
Eppo, it's a relations problem, but nuBuilder can't manage subform of subform.

I suggest to build a middle-table to manage n:m relation between Customer and Product tables.
You could build a customer_product table like this:

Table: customer_product
- cpr_id
- cpr_customer_id
- cpr_product_id

This should be your subform on Customer form and also on Repair form.
Here you can find my solution to the same issue and here a test dev project (demo - demo).

Hope this helps

Re: Lookup Filtering

Posted: Thu Feb 27, 2014 10:36 pm
by Eppo
Hi Max,

Thanks. For your suggestion. I'm gonna try that very soon. Its a little bit more difficult then I expected. But we don't give up! :D

If it works I will let you know.

Jeroen

Re: Lookup Filtering

Posted: Fri Mar 07, 2014 4:20 am
by admin
.