About API search transaction

Any issue about Cyclos 4 scripting and Webservices

Moderators: hugo, alexandre, rmvanarkel

Post Reply
trustpay
Posts: 70
Joined: Mon Aug 03, 2015 10:19 am

About API search transaction

Post by trustpay »

Dear Cyclos team,

Currently, i am using Cyclos\TransactionService (PHP), function search($query) to search transactions. I using direction "DEDIT", it's ok, but when i've changed direction to "CREDIT", It does not return data, even though there was a transaction

Pls help, Thanks!

luis
Posts: 186
Joined: Fri Feb 17, 2006 11:01 am

Re: About API search transaction

Post by luis »

I've just tested here, and both {"direction": "CREDIT"} and {"direction": "DEBIT"} works as expected.
Are you sure you're using the correct strings? Can you send the full query object?
Luis Fernando Planella Gonzalez
Cyclos development team

trustpay
Posts: 70
Joined: Mon Aug 03, 2015 10:19 am

Re: About API search transaction

Post by trustpay »

Here's my code:

Code: Select all

$params = new stdclass();
$params->owner = $user;
$params->direction = 'DEBIT';
$data = $transactionService->search($params);
This code return list transations DEBIT for me, but when i've changed 'DEBIT' to 'CREDIT', it return empty list (i have data for Credit).
Note: when i delete 'direction', it's still return list DEBIT


Thanks for your reply!

luis
Posts: 186
Joined: Fri Feb 17, 2006 11:01 am

Re: About API search transaction

Post by luis »

As the transaction is not returned even when no direction filter is set, probably it is excluded by another filter, such as group visibility for admins.
Luis Fernando Planella Gonzalez
Cyclos development team

Post Reply