One of our customers brought into our attention this issue. They have a Party, and some time later they created the same one with different charactecistics, so they deactivated the former as it was no longer useful for them.
However, it seems that they have duplicated one of the sales with the deactivated party, and it has allowed them to create the sale, the shipments and the invoices without an issue. Otherwise they wouldn’'t have been able to create said sale and invoice (obviously).
We don’t believe this should be the expected behaviour when it comes to a deactivated party.
Any thoughts on this? Maybe there should be a warning when they duplicate something like a sale or an invoice with a deactivated party, for example?
I agree that this might be a solution in some cases, but in some others the customer might want to keep them separate for whatever reason. This will happen with products that are inactive as well.
I do think it should be the user’s responsibility to assure that the sale they are duplicating contains the correct data before following through. However, it might not be realistic to expect them to check absolutely everything, specially when there’s more than just one person working with Tryton, as it’s usually the case. For example, the person duplicating the sale might not be aware that the Party is no longer active, but they can’t be checking every single Party and every single product of the sales they’re duplicating to make sure everything is active.