php-twinfield / twinfield

PHP 7.3+ Library for using the Twinfield API.
https://accounting.twinfield.com/webservices/documentation/#/
Other
33 stars 78 forks source link

Add support for transaction line match date #187

Closed axlon closed 3 years ago

axlon commented 3 years ago

The value of <matchdate> is currently not retrievable from transactions, this PR aims to fix this.

This PR adds getMatchDate() and setMatchDate() to PurchaseTransactionLine and SalesTransactionLine* This matchDate attribute may only be set on total lines (per documentation), and will throw if an attempt is made for it to be set on another line type.

*The documentation only mentions <matchdate> for the purchase transaction, however testing the actual API revealed that this element is also present in get responses on sales transactions.