Jump to content

Nested portals


This topic is 8156 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Is it possible to nest portals within one another? I have a filed called Order Entry where you enter each PO with all of the parts in it in a portal to PartOrderJoin. I have a separate layout in Order Entry where I do the receiving for each PO. Right now, I have a repeating field that lets me enter 10 separate instances of receiving each part (I need the capability to receive each part on an order multiple times).

Since I set things up this way, I have learned the error of my ways (NEVER use repeating fields if you can avoid it!). I would like to be able to make the quantities received relational. To do this, I would have to nest a portal to a new file that would have a PO Number, Part Number, Date and Quantity Received WITHIN the portal in Order Entry. Is this possible? Is there another way I can set this up so that it will work and I can get rid of my repeating fields? Help!

Thanks for any suggestions.

Link to comment
Share on other sites

You can't nest portals, but you can get the results you want anyway. It's not unusual for a solution to require many-to-many-to-many relationships. E.g., a company has many contacts, each of which has many phone numbers. Here's one way to approach it:

1) Make a new file for Receiving and relate it to the Orders file and or the PartOrderJoin file.

2) Set up a layout in Orders with a portal to each of the related files.

3) Create a global field gPart and make a relation gPart::Receiving.

4) Now make a script that sets gPart to the POJ id, and attach it to a button in the POJ portal.

I.e., you go to an order, you see the Parts in the POJ portal. You click a part in one of the POJ rows, and in the Receiving portal you see the related items.

Hope that's enough to get you started.

Link to comment
Share on other sites

This topic is 8156 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.