Hi there.
I'm wondering wether is possible to add a field, in purchase header, to post the date when the vendor invoice was received. I mean: A vendor invoice is received at company on 5th. January with 1st. January as its own document date. Invoice is received by the person who sign his approval on 10th January. Then, the invoice goes to account department and it's posted in NAV on 13th January. We have 3 dates: Posting Date, Document Date and Approval Date.
Is it possible to add "Approval Date" to Purchase Header to post this field or should I save it on more tables?
How could I do that?
Thank you so much.
*This post is locked for comments
I solved it creating a new field in tables 7000002 and 7000004 as Flowfield of table 122 where No. = Document No. and I got that date without any other code. ^_^
hi, if my answer also helped to find a solution please verify it too. thx.
Thank you both. I have almost done it. This approval method is manual so I set the new field on Prch. Header and Inv. Header and I got the field in posted invoices as I wanted. However, I need that this field also appears when I run Form "7000013 Playable Closed Cartera Docs" cause our payment periods are related to these dates.
Regards.
Hi ,
Yes, It is possible. As archer said, it is require to create the Approval date field on purchase header and purch. Inv. header. Please keep the field ID same in both the tables so when you post the invoice it will automatically flow to the Purch. Inv. Header and you need not require to code for it to transfer the value to purch. inv header.
For updating the Approval Date on purchase header. I am little confuse that you are going to put this date manually or if you are using the approval setup of NAV.
If it is manually then it is no need to code anything and only adding the field but if it is require to transfer when user do the approval in NAV through approval setup mechanism then on event of approval then you need to write code in codeunit 439 (Approval Management) under ApproveApprovalRequest Function. in this function at the end you will find the code of
IF PurchaseHeader.GET(ApprovalEntry."Document Type",ApprovalEntry."Document No.") THEN
ReleasePurchaseDoc.RUN(PurchaseHeader);
here you need to modify the code to update the Approval date in purchase header.
Regards,
Saurabh Shah
hi,
if you mean that the approval date is a date given by the vendor, then you need a new field in purchase header and also in purchase inv. header.
best regards
Hi
Yes, it is possible to add a new field in the purchase header, and you need to write the code to populate the new field for this you need developer license
Regards
Rajasekhar.Y
Sohail Ahmed
2
mmv
2
Amol Salvi
2