Yesterday, I was explaining a customer how their credit control department can manage customers in NAV.
I showed them the credit limit warning, and of course the possibility to block a customer (for Invoice, Ship or for All).
While doing so, I ran into the following situation (giving customers a random name to keep things clear):
Customer Adrian is blocked for invoice, but customer Brandon is willing to pay for stock that is actually being bought by Adrian.
Then, I try to create a new Sales Order on customer Adrian, with "Bill-to Customer No." Adrian, but this is not possible.
The OnValidate-trigger of "Sell-to Customer No." contains the following code:
(OnValidate-trigger for "Bill-to Customer No." looks similar).
The function CheckBlockedCustOnDocs does the following:
CustBlockedErrorMessage does nothing more than throw the error:
One could say this is by design.
In my opinion, it's perfectly logical in my example to block Brandon for shipments - this whole company might be a buying group with an office the size of a large car.
It would also be perfectly possible to block Adrian for invoicing; this might be a company that always works with a buying group (in which situation making Adrian a Shipment Address is often not sufficient).
Right now, it's not even possible to make an order when either the bill-to or sell-to customer is Blocked for Ship, Invoice or All. To keep things in line with the credit limit functionality, I think it would be more fitting to show a warning when entering an order, or make this a setting in Sales & Receivables Setup.
My customer has already asked me to "fix" this, and I don't like it; there is no easy way around this (without actually modifying code in Table 36). The only decent way I can actually think of is to make a separate "Customer Status" field and catch all related triggers (OnValidates of Bill-to and Sell-to, OnPost for shipments and invoices).
What do you think? Is this a bug?