NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: ccordes on September 29, 2010, 09:01:39 AM
-
I have a browse of invoices in the customer update form. These show as expected. I used conditional filter on the browse when it is a child of CustomerUpdate.
The problem is adding an invoice for the customer. The Invoice form does not prime the inv:cusId from the customer record.
I checked the session queue values and when the form opens, all the values for the customer record are cleared!
This happens in the sample browse in form example when adding an invoice to a customer as well.
I don't understand why or how the session values for the customerrecord are being cleared. every other record remains unchanged.
I thnk I can work around it with some hidden fields in the browse or form, but if anyone knows a better (more correct template) way, I could use some help.
Thanks,
chris
-
Hi Chris,
I might not be understanding your problem but here I go...
When I do what you mention, I get the Session Value of the primary key on Customer File and do a fetch based on this value in the pre-insert embed. I then have the customer record in buffer and can prime what ever values I need from the file rather than the Session Q.
Kev
-
>> The problem is adding an invoice for the customer. The Invoice form does not prime the inv:cusId from the customer record.
um - no it doesn't do this automatically. The UpdateInvoice form has no idea you are calling it from the UpdateCustomer form (via the BrowseInvoice browse) and so doesn't prime it.
To prime the field, go to the Priming tab and set
Inv:CusId to
p_web.GetSessionValue('Cus:CusId')
If that doesn't work - have a look and see if Customer is a child table in the InvoiceBrowse procedure - perhaps it is getting overridden there.
Cheers
Bruce
Cheers
Bruce
-
Thanks Bruce and Kevin.
I was interrupting the customer entry to add the order in the order browse control while creating a new customer. At the Order entry, the customer record didn't exist yet.
So I now hide the Order browse during an insert and jump to the order entry when the save button is clicked.
In the order, do what Kevin does and grab the customer rec in the pre-insert.
chris