Currently ERPNext doesn’t support blanket orders for sales or purchase orders. According to [New Feature] Blanket Sales Order and Blanket Purchase Order discussion here is my Proposal of Implementation
A blanket order is an order a customer places with it’s supplier to allow for a total quantity over multiple delivery dates over a period of time, to take advantage of predetermined, set pricing, to possibly negotiate different payment or delivery terms from their normal account or to include legal agreements that are not part of normal orders. Blanket orders are legally binding contracts.
Blanket orders can either be a blanket purchase order or a blanket sales order.
A blanket order differs from a normal order that you would not be able to create a delivery note or a production order from it. The only thing you would be able to do is to create a purchase or sales order respectively.
Naming
According to Wikipedia other naming options are “Blanket Purchase Agreement” or “Call-off Order” (Blanket order - Wikipedia), We have chosen “Blanket Order” as the most popular and well known in the market. This will work internationally with British and American English.
How to do it in ERPNext
We need two new doctypes, one for Blanket Sales Order (BSO-) and one for Blanket Purchase Order (BPO-) to store the information of this type of orders. The reason for creating two new Doctypes is because the Blanket Order is a layer above the orders. It’s not simply an order-type but different layer with different permissions and co-dependency. From this layer users can create normal orders (SO or PO). Additionally, we have the listings of blanket orders ready (because of the build-in functionality of frappe) without extra filtering etc.
The extra data as compared to a normal sales order or purchase order we need are:
Header
- Due Date: A date by which the blanket order has to be fulfilled by the company and by the customer. We need to also track if a blanket order is overdue and inform the user.
Blanket Order Lines
- Price: the negotiated price the customer pays remains constant during this period, even if the item’s price changes for the supplier. This must overwrite any pricing rule or price list.
- Quantity : the total quantity of the Item over the period
- Batch size: The minimum amount of the item to be placed in each individual SO or PO
- Security Stock: This is the minimum stock the supplier must keep for the items in Blanket Order. The user must be informed if the security stock is not there.
In SO/PO, there is one extra field for reference to BSO/BPO, which is the main indicator of a normal SO from a SO who belongs to a BSO, as shown in below picture (for SO)
Some functionalities and fields which exist in SO or PO must be removed from the Blanket Order. These are:
- For SO: Under the Make menu, only the “Project” will be kept and a new option of “New Sales Order” will be added
- For PO: Under the Make menu, only the “New Purchase Order” will be shown.
Quotation
In the Quotation (talking for Sales Orders) we add a new Quotation Type = “Blanket Sales Order” with the extra fields:
- Due Date: A date by which the blanket order has to be fulfilled by the company and by the customer. We need to also track if a blanket order is overdue and inform the user.
- Batch size: The minimum amount of the item to be placed in each individual SO or PO
- Security Stock.This is the minimum stock the supplier must keep for the items in Blanket Order. The user must be informed if the security stock is not there.
The menu Make has the “New blanket Order” option, when the Quotation type = “Blanket Sales Order”
When user creates a new Blanket Order from the Quotation, all data (including the extra fields) are transferred to the Blanket Order
Usage
A Blanket Sales Order can be created manually or from a Quotation with Order Type = Blanket Sales Order.
A submitted Blanket Order (BSO or BPO) gives information about the status of the order in its dashboard, including any associated SO or PO, delivery notes, sales invoices or purchase receipts and purchase invoices accordingly. It shows what is already delivered, as well as the remaining quantity to be delivered until the end of blanket order period.
As soon as a new SO or PO is created, all data are retrieved from Blanket Order’s data. The header information such as delivery address, payment terms etc are pulled from the blanket order instead of from the customer. The Item(s) to be ordered and their prices are also fetched from BSO (or BPO) and the quantity is by default the Batch Size. The user can change it only by multiplies of the Batch Size.
All the other functionality of ERPNext remains as is. From a SO (whether it belongs or not to a BSO), a new production order can be opened, or a new Purchase Receipt can be created from a PO that belongs to a BPO, etc. In the Blanket Sales Order list, users may have a quick overview of active BSOs and their remaining quantities.
A sample workflow of Blanket Sales Order is shown below