Bitcoin and Altcoin Wallets: Exchange 2.3.3

transactions.php

Helper functions that retrieve exchange transactions (trades).

Tags
author

Alexandros Georgiou info@dashed-slug.net

Table of Contents

save_exchange_trade_transactions()  : mixed
Saves all the transactions resulting from a trade.
send_trade_notification_emails()  : mixed
Emails the two users about their trade

Functions

save_exchange_trade_transactions()

Saves all the transactions resulting from a trade.

save_exchange_trade_transactions(array<string|int, mixed> $txs_and_tags_to_save) : mixed

Transactions are ordered and come in quadruplets. Every second tx must have the previous one as parent.

Parameters
$txs_and_tags_to_save : array<string|int, mixed>

Array of array tuples, consisting of: 'tx' => Transaction object 'tags' => array of tag slugs (strings).

Return values
mixed

send_trade_notification_emails()

Emails the two users about their trade

send_trade_notification_emails(array<string|int, mixed> $txns_and_tags_to_email) : mixed

The transactions must correspond to the same trade. The function parses the transactions, summarizes the data, renders the data using the email template and enqueues the emails.

Parameters
$txns_and_tags_to_email : array<string|int, mixed>
Return values
mixed

Search results