This fix will change the invoice validation from verifying the company requirements according to the FD link on the Sales & Booking Summary screen, and move to Bill-to-Company on the order header
Create Invoice
Existing button
Type
Notes
Rules
Compulsory
Format
Edit
Size
Default
Error Message
button
Change existing function re PO Number validation.
Currently 1 & 2 references tran_funeralcompanyid.
This revision changes reference to orhe_billtocompanyid - Bill to Company
1. If Bill to Company is null - no action.
2. If Bill to Company is not null, then check Company record for Compulsory PO on Booking (comp_compulsoryponumber)
2a. If Compulsory PO number is null or 'N' - no action.
2b. If Company Compulsory PO number is Y and S&B PO Number (tran_purchaseorder) is not null - no action.
2c. If Company Compulsory PO number is Y and S&B PO Number (tran_purchaseorder) is null - do not proceed (abort invoice sequence).
No other change to existing Create Invoice rules.
N
Button
Yes
2c) use existing error message.
Invoice not created. The Booking's funeral company requires a PO number to be provided within the booking record.