Build the trash half of a block move from its executed create ledger
ztBlockMoveTrash.RdReturns Trash rows for originals whose corresponding create-ledger entry is
marked "done" and records a new item key.
Arguments
- records
The
recordsgiven toztBlockMoveCreate().- createLedger
The
zotExecute()ledger of the create plan.- fromLibrary
Library holding the originals.
Examples
Records <- data.table::data.table(
itemKey = "OLD1", payload = list(list(title = "Reviewed book")),
hasFile = FALSE
)
Ledger <- list(items = list(`create-1` = list(status = "done", new = "NEW1")))
ztBlockMoveTrash(Records, createLedger = Ledger, fromLibrary = "user")
#> action library itemKey payload
#> <char> <char> <char> <list>
#> 1: trash user OLD1 <list[0]>