Open nus-pe-bot opened 1 week ago
Thank you for spotting the confusion. The list indexes of transactions do change while the transaction ID of each transaction do not changed.
This would be a documentation bug instead as we should have explained how the transaction ID is created. The transaction ID of a transaction will take the highest transaction ID that exist in the transaction list and increment it by 1. The transaction ID of a particular transaction in the list will always remain the same until the transaction is deleted from the transaction list.
Transaction ID is created when the transaction is being added into the Transaction List. This ID should not change no matter what happens to the list as it is similar to an Order ID or simply, NRIC, as it is an identifier to the transaction itself. This allows mark/unmark/remove of a transaction in a very long transaction list as the user did not have to check the indexing of the transaction, but rather just use the transaction ID that has been tied to the transaction.
--
in my list of transaction i removed 1 out of 2 transactions. i only had 1 left in the list. when i tried to mark the remaining transaction as complete, i wasnt able to, which made me realise that the transaction numbers were not automatically getting handled.
an expected output would be for 'TX2' to automatically revert to 'TX1' to avoid confusions when trying to mark, unmark, or delete transactions
[original: nus-cs2113-AY2425S1/pe-interim#63] [original labels: type.FeatureFlaw severity.VeryLow]