2 Replies Latest reply on Dec 7, 2011 12:22 PM by RMckeown

    two portals in report body

    RMckeown

      Title

      two portals in report body

      Post

      Hi all,

      I'm having a little trouble with creating a customer receipt.

      I have placed fields in the BODY from a portal called " Line Items " which is the items the customer bought. That works OK.

      I've added fields from a second portal called "payments" to show a list of their payments.

      The final result printed from the body should look like below - but the second portal just keeps printing the first related record....

      Help!

      --------------------------------

      10      product A    @     price

      20      product B     @    price

      On 01/01/2011    paid £100

      on 02/02/2011    paid £200

      -------------------

       

       

        • 1. Re: two portals in report body
          philmodjunk

          Presumably, this is a layout based on the LineItems table so you can print invoices in the same manner as the Invoices starter solution.

          The payment records, I assume, are not records in the LineItems table, but are recorded in a different table.

          Given that structure, you'll need to put a portal to the payments table on your layout in a trailing grand summary in order to display payments. You can set up the portal with more rows than you expect to ever need for a given invoice and then use "slide up" and "resize enclosing part" in the Inspector's sliding and visibility section to shrink the portal and trailing grand summary part down to just the number of rows needed for a given invoice. (And if you ever get more payment records than you have rows, the additional rows will not be visible until you change the layout to add more rows to your portal.)

          Key facts about sliding layout objects:

          1. It's only visible in preview mode and when you print/save as PDF...
          2. All layout objects below and in the same layout part as the slide/resize field need to also be set to slide up and resize.
          3. Objects in headers and footers will not slide.
          4. Portals will shrink/slide to fit the number of rows of records, but fields within the portal row will not shrink/slide.
          5. Container fields will slide only if Top, Left alignment is specified for it in the data formatting section of the Inspector's data tab.
          6. Consistent side borders are difficult to achieve with sliding fields.
          • 2. Re: two portals in report body
            RMckeown

             Excellent - that worked a treat.

            I placed the payment portal to the left, and an overview of the complete transaction to the right, so the payment portal has nothing below it.

            Many thanks