frappe / erpnext

Free and Open Source Enterprise Resource Planning (ERP)
https://erpnext.com
GNU General Public License v3.0
20.71k stars 7.13k forks source link

Company >> Delete Transactions #42568

Open thida-bcn opened 1 month ago

thida-bcn commented 1 month ago

Information about bug

go to company click delete transactions when delete transactions for company , batch data didn't reset (batch must be deleted)

Module

stock

Version

ERPNext: v14.65.8 (version-14)

Frappe Framework: v14.68.2 (version-14)

POS Awesome: v6.1.3 (version-14)

Installation method

manual install

Relevant log output / Stack trace / Full Error Message.

No response

Nihantra-Patel commented 1 month ago

A batch is counted in a master record, not in a transaction. Additionally, a batch is not limited to one company; it can be associated with multiple companies. For example, you might create a stock entry in one company using Batch-One, and then use the same batch in another company.

If you create a stock entry and then need to delete the transaction for one company, you cannot delete the batch because it is linked to transactions in two different companies. This issue occurs because the batch is not counted in the transaction itself.

thida-bcn commented 1 month ago

A batch is counted in a master record, not in a transaction. Additionally, a batch is not limited to one company; it can be associated with multiple companies. For example, you might create a stock entry in one company using Batch-One, and then use the same batch in another company.

If you create a stock entry and then need to delete the transaction for one company, you cannot delete the batch because it is linked to transactions in two different companies. This issue occurs because the batch is not counted in the transaction itself.

thanks but what i found is there was also batch qty i will prepare video and upload here, thanks