Jump to content
Oyseka

Why are records not visible in portal

Recommended Posts

Hi All, When I add records to a quote they may be added in multiples until the Quote is accepted. When a quote is accepted I now have to change any multiple service Products to single products to allow for the creation of the barcodes,(serial numbers), used during the service so that any parts used on the product are recorded against that particular product. I created a script which checks for any service Products that are showing multiples and duplicates them the required number of times. The duplication works fine in the QuoteItems layout but unless after duplication, I select either the department or product, then the items do not show in the QuoteItems portal on the Quotes layout despite the Qty being reduced from whatever it was set at to 1 and the Quote Total is incorrect.

Screen Shot 2017-03-12 at 12.55.50.png

Screen Shot 2017-03-12 at 12.56.09.png

Screen Shot 2017-03-12 at 13.03.42.png

Screen Shot 2017-03-12 at 13.04.03.png

Screen Shot 2017-03-12 at 13.05.41.png

Edited by Oyseka
Attache missing images

Share this post


Link to post
Share on other sites

Exactly how are you duplicating them?  I can only assume when you create the records you are doing them thru the portal and the relationship is setting the proper key fields, and when you duplicate them, one of the key fields is not being set.

Maybe you can diagnose this by putting all key fields either in the portal or on the proper layout.  Then when you duplicate, see if those fields are properly populated.

Share this post


Link to post
Share on other sites

Hi Steve, the key field is the QuoteId and as you can see on the 4th screenshot, that field is populated correctly. Just to explain the screenshots; Image 1  shows  the Quote Layout denoting the QuoteId and the Products as viewed in the portal. note that items 4 and 5 have a Qty greater than 1, Image 2 shows the QuoteItems layout which contains the details of those Products with the corresponding Qty.

Image 3 shows the Quote Layout after the duplication has been run and Image 4 shows the QuoteItems layout after the duplication has run.

Image 5 shows the Quotation after any of the Portal rows have been selected and exited with no further input. At first I assumed it was a refresh or commit problem but I have committed all records on creation and refreshed the Quote window when the record is accessed 

This is the script used to duplicate the Products:

Set Error Capture [ On ]

Loop
Set Variable
[ $QuoteId; Value:Quotations::__QuoteId ] Go to Layout [ “dLayQuoteItems” (QuoteItems) ]

Enter Find Mode [ Specified Find Requests: Find Records; Criteria: QuoteItems::QTY: “>1” AND QuoteItems::_QuoteId: “$QuoteId” AND QuoteItems::ServiceFlag: “=1” ]
[ Restore ]

Perform Find [ ]
If [ Get (LastError) = 401 ]

Go to Layout [ original layout ]

Exit Script [ ] End If

Go to Record/Request/Page

[ First ]

Set Variable [ $QTY; Value:QuoteItems::QTY ]

Set Field [ QuoteItems::QTY_Count; $QTY ]

Set Variable [ $QTY_Count; Value:QuoteItems::QTY_Count ]

Insert Calculated Result [ QuoteItems::QTY; 1 ] [ Select ]

Commit Records/Requests

[ Skip data entry validation; No dialog; Force Commit ]

Loop

Duplicate Record/Request

Insert Calculated Result [ QuoteItems::QTY; 1 ] [ Select ]

Insert Calculated Result [ QuoteItems::QTY_Count; $QTY_Count-1 ] [ Select ]

Set Variable [ $QTY_Count; Value:QuoteItems::QTY_Count ] Commit Records/Requests

[ Skip data entry validation; No dialog ] Exit Loop If [ QuoteItems::QTY_Count = 1 ]

End Loop End Loop 

Edited by Oyseka
Wrong screenshot denoted

Share this post


Link to post
Share on other sites

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

  • Similar Content

    • By Oyseka
      Hi all, I have a requirement to re-create Quotations on a monthly basis that are fixed by a 12 month contract. On creation of the QuoteItems I want to automatically insert a fixed ID that stays with the item. Each month a new Quotation has to be produced which is then reviewed to potentially add to the contract in order to acquire a new Purchase Order  but I do not want to increment the ItemID on existing items. Any help appreciated
       
      Sorry everyone, I figured it out
  • Who Viewed the Topic

    5 members have viewed this topic:
    SupportGuys89  RadioSaigon  liltbrockie  Lee Smith  Mstenquist 
×

Important Information

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