/// <summary> /// Called every time the customer wants to pay for something /// </summary> public void CreateMoneyOrders(decimal amount) { Amount = amount; MoneyOrders = new List <MoneyOrder>(); // for testing only var rnd = new Random(); // for testing only for (var i = 0; i < NumOrders; i++) { var testBytes = new byte[10]; rnd.NextBytes(testBytes); var uniquenessString = new Guid(); //var idPairs = CreateIdStringPairs(PersonalDataBytes); // TODO: once done testing, change back to use our personal data var idPairs = CreateIdStringPairs(testBytes); var currentMoneyOrder = new MoneyOrder(Amount, uniquenessString.ToByteArray(), idPairs); MoneyOrders.Add(currentMoneyOrder); } // store the transaction for later reference with a unique id Ledger.Add(new Guid(), MoneyOrders); }
/// <summary> /// Called every time the customer wants to pay for something /// </summary> public void CreateMoneyOrders(decimal amount) { Amount = amount; MoneyOrders = new List<MoneyOrder>(); // for testing only var rnd = new Random(); // for testing only for (var i = 0; i < NumOrders; i++) { var testBytes = new byte[10]; rnd.NextBytes(testBytes); var uniquenessString = new Guid(); //var idPairs = CreateIdStringPairs(PersonalDataBytes); // TODO: once done testing, change back to use our personal data var idPairs = CreateIdStringPairs(testBytes); var currentMoneyOrder = new MoneyOrder(Amount, uniquenessString.ToByteArray(), idPairs); MoneyOrders.Add(currentMoneyOrder); } // store the transaction for later reference with a unique id Ledger.Add(new Guid(), MoneyOrders); }