Bitcoin Shrooms
Inscription #715
use super::*; #[derive(Boilerplate)] pub(crate) struct TransactionHtml { blockhash: Option<BlockHash>, chain: Chain, etching: Option<Rune>, inscription: Option<InscriptionId>, transaction: Transaction, txid: Txid, } impl TransactionHtml { pub(crate) fn new( transaction: Transaction, blockhash: Option<BlockHash>, inscription: Option<InscriptionId>, chain: Chain, etching: Option<Rune>, ) -> Self { Self { txid: transaction.txid(), blockhash, chain, etching, inscription, transaction, } } } impl PageContent for TransactionHtml { fn title(&self) -> String { format!("Transaction {}", self.txid) } } #[cfg(test)] mod tests { use { super::*, bitcoin::{blockdata::script, locktime::absolute::LockTime, TxOut}, }; #[test] fn html() { let transaction = Transaction { version: 0, lock_time: LockTime::ZERO, input: vec![TxIn { sequence: Default::default(), previous_output: Default::default(),
ID
9c1ab886ed...7acadb85i0
Detail
History
Sign Up for our Newsletter
And be the first to know about any updates!