In our business case, we hire third party trnsporter to deliver our orders to custmers. Some orders sent to transporter, may not be accepted by the transporter as the vehicle doesn’t have enough space or vehicle has already left. Therefore, the orders are returned to our warehouse to be delivered on the next day. Upon receiving these orders to warehouse, we want to record that information in ERPNext. I thought of making a sales return and then creating a delivery note again for the next day. However, that is not working as expected where, the newly created delivery note status become ‘To bill’ regardless of having an invoice created on previous day. I tried this in two ways.
- Creating an invoice through sales order
- Creating an invoice through delivery note
In both instances, the delivery note status become ‘To bill’ regarless of having a sales invoice for full order quantity. Am I doing anything wrong here?
Below are the two scenarios tested.
Scenario 1 - creating an invoice through sales order
- Created SO - Status - to deliver and bill
- Create a delivery note (Sales order status changed to ‘To bill’)
- Create an invoice by opening sales order (Sales order status changed to ‘completed’, sales invoice is ‘unpaid’)
- Made a sales return against above delivery note (Sales order status changed to ‘to deliver’)
- Created a delivery note again from sales order (Sales order status became ‘completed’)
- The new delivery note status is ‘to bill’
Scenario 2 - Creating an invoice through delivery note
- Created SO - Status - to deliver and bill
- Create a delivery note (Sales order status changed to ‘To bill’)
- Create an invoice by opening delivery note (Sales order status changed to ‘completed’, sales invoice is ‘unpaid’)
- Made a sales return against above delivery note (Sales order status changed to ‘to deliver’)
- Created a delivery note again from sales order (Sales order status became ‘completed’)
- The new delivery note status is ‘to bill’
In both cases the the sales invoice is not cancelled. Since the sales order already has an invoice for all the quantity the new delivery note status should be ‘completed’. Am I doing anything wrong here or is it how it should work. Please explain.