admin user able to create test txs
This commit is contained in:
@@ -722,6 +722,25 @@ class TxMetaController extends ChangeNotifier {
|
||||
_schedulePersist(invalidateLabels: false);
|
||||
}
|
||||
|
||||
/// Move per-tx annotations when an admin test transaction's id changes.
|
||||
Future<void> rekeyTransaction(String fromId, String toId) async {
|
||||
if (fromId == toId || fromId.isEmpty || toId.isEmpty) return;
|
||||
final stored = _byId.remove(fromId);
|
||||
if (stored != null) {
|
||||
_byId[toId] = stored;
|
||||
}
|
||||
_labelIdsByTxCache = null;
|
||||
_schedulePersist(invalidateLabels: true);
|
||||
}
|
||||
|
||||
/// Drop per-tx annotations for a deleted admin test transaction.
|
||||
Future<void> clearTransactionMeta(String txId) async {
|
||||
if (txId.isEmpty) return;
|
||||
if (_byId.remove(txId) == null) return;
|
||||
_labelIdsByTxCache = null;
|
||||
_schedulePersist(invalidateLabels: true);
|
||||
}
|
||||
|
||||
Future<void> setNotes(
|
||||
BankTransaction tx,
|
||||
String notes, {
|
||||
|
||||
Reference in New Issue
Block a user