4 Replies Latest reply on Apr 9, 2014 9:07 AM by CG_1

    Difficulty with portals



      Difficulty with portals


           Maybe it's because i'm too tired but I can't solve this.

           I have a table and layout called CONTACTS, that relates to another table and layout called INVOICES, through "id contact".

           So, a portal lists all invoices of the same contact, on the contact layout.

           Each invoice has a portal, with line items, related to a table called LINE ITEMS, through "id invoice", which is related to a table called PRODUCTS, through "id product".

           I would like to be able to list on the contact layout, through a portal, a mix of invoice ítems (which i already can do) and all the products bought (line items) and that are in the correspondent invoices of that contact.

        • 1. Re: Difficulty with portals

               It appears that you have these relationships:


               Thus, if you place a portal to LIneItems on your Contacts layout, you should see all lineitems for items the contact has purchased. But they will not be obviously grouped by the invoice to which they are linked. If you were to add another Tutorial: What are Table Occurrences? of Invoices like this:

               Contacts-----<Invoices------<LineItems>----Invoices 2

               You could add fields from Invoices 2 to the rows of your portal to line items to include information from the related invoices record.

               You could also set up a pair of "master-detail" portals where portal 1 lists all Invoices for the contact, and when you click a row of this portal, portal 2 lists only the lineitems for the invoice that you just selected in the first portal. See this thread for how to set that up if you are interested: Need layout solution for nested portals...

          • 2. Re: Difficulty with portals

                 Thank you.


            I've tried the LineItems portal but nothing shows up...

            The"master detail" solution isn't what i'm looking for, since i don't want to click rows... if possible

            • 3. Re: Difficulty with portals

                   If nothing shows up from LineItems, then there is something wrong with how you have set up your system. Either you do not have things set up correctly in Manage | Database | Relationships, do not have the correct values in a match field, or your layout is not set up based on Contacts with the portal referring to the correct Tutorial: What are Table Occurrences? of LineItems.

              • 4. Re: Difficulty with portals

                     Never mind, I got it.

                     There was a little error on a portal field. Thank you.

                     Your explanations made me see things in another perspective :)