You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are implementing this codeset but are missing some features that we require for our project. The master branche does not provide a ProjectAPIConnector. We have created this module following the module structure of this project and are more than happy to have this code be added to the master branche.
Also we have discovered that there are some issues with the current SalesTransaction and SalesTransactionLine. According to the Twinfield API docs the project code can be set as the Dim3 property. The ThreeDimFiels provides a setDim3() but is not used on the TransactionMapper.
Modifing the TransactionMapper allowed us to nicely add the projectcode and have if stored into Twinfield. The response of Twinfield reports back success including the newly added SalesTransaction.
Unfortunatly php-twinfield lib fails on handling this succesful Twinfield response. After investigation we have discovered that Twinfield itself do not follow their own API documentation.
When a SalesTransactionLine has a project code (dim3) assigned it behaves more like a TOTAL line than an DETAIL line. For example, according to the API docs matchstatus can only be 'notmatchable' for DETAIL lines. However Twinfield XML response reports back with matcstatus 'available' on a DETAIL line causing php-twinfield to throw an exception while mapping the response. There are many other props like setMatchStatus that now throw exceptions on a succesfull XML response from Twinfield.
A suggestion for this issue could be to not check input that have been provided by Twinfield during mapping. An other could be to check the dim3 value and prevent exception throw when dim3 is set. Making it of course important that dim3 needs to be set first.
The text was updated successfully, but these errors were encountered:
Hai Willem,
I will prepare a pull request for the project API module. However I never
dit a pull request before.
Reading the docs I first have to create a new branch using the webinterface.
Browsing around I could not find functions that allow me to do that.
I’m probably missing the point here so any directions would be very welcome.
Regards,
E.
From: Willem Stuursma-Ruwen <[email protected]>
Sent: donderdag 4 juni 2020 16:34
To: php-twinfield/twinfield <[email protected]>
Cc: KBS-devs <[email protected]>; Mention <[email protected]>
Subject: Re: [php-twinfield/twinfield] Offer to add ProjectApiConnector to
master and issue on using dim3 (projectcode) SalesTransaction (#177)
Hi @KBS-devs <https://github.com/KBS-devs> . I'm open for pull requests.
Please be aware I am not a Twinfield employee and I maintain this library in
my free time.
Multiple small PRs have the best chance of landing.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#177 (comment)>
, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AP2VWEIEWME5VYXJHGXXNB3RU6WF3ANCNFSM4NSNF6YQ>
.
Hi Guys,
First of all thanks for this awesome code set.
We are implementing this codeset but are missing some features that we require for our project. The master branche does not provide a ProjectAPIConnector. We have created this module following the module structure of this project and are more than happy to have this code be added to the master branche.
Also we have discovered that there are some issues with the current SalesTransaction and SalesTransactionLine. According to the Twinfield API docs the project code can be set as the Dim3 property. The ThreeDimFiels provides a setDim3() but is not used on the TransactionMapper.
Modifing the TransactionMapper allowed us to nicely add the projectcode and have if stored into Twinfield. The response of Twinfield reports back success including the newly added SalesTransaction.
Unfortunatly php-twinfield lib fails on handling this succesful Twinfield response. After investigation we have discovered that Twinfield itself do not follow their own API documentation.
When a SalesTransactionLine has a project code (dim3) assigned it behaves more like a TOTAL line than an DETAIL line. For example, according to the API docs matchstatus can only be 'notmatchable' for DETAIL lines. However Twinfield XML response reports back with matcstatus 'available' on a DETAIL line causing php-twinfield to throw an exception while mapping the response. There are many other props like setMatchStatus that now throw exceptions on a succesfull XML response from Twinfield.
A suggestion for this issue could be to not check input that have been provided by Twinfield during mapping. An other could be to check the dim3 value and prevent exception throw when dim3 is set. Making it of course important that dim3 needs to be set first.
The text was updated successfully, but these errors were encountered: