We can set to deduct the inventory either after Invoice creation process or Delivery note creation process.

Steps:
1. Click on Setting tab
2. Click on Document button
3. Change the stock setting in the bottom right
4. Click on Save button to apply changes.