Hi is first time I use Xero API module, well I was trying to use xero_make() for generate invoice structure just the same as the docs say:
$invoice = xero_make('invoice', 'recommended', array('name', 2));
Well the returned array is always the same minimal arrya, it just has type and contact, it returns the minimal $size, I tried changing the $size to 'all' but did not work, I did a dpm($size) in xero.make.inc in the function xero_make_invoice and the $size is always 'minimal'
so I had to hack the file and add 'recommended' as default instead of 'minimal'
Please how to fix this?
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | xero-2466443-fix-xero-make-argument-1.patch | 933 bytes | mradcliffe |
Comments
Comment #1
mradcliffeThank you for the bug report. It looks like there are two issues:
1. The documentation I wrote is incorrect and xero_make_invoice is only "all" or "minimal.
2. xero_make is always passing in minimal.
I need to run this patch through my automated tests, but this should work.
Comment #2
mradcliffePasses validation test. Could you apply the patch and see if it works for you, @ssoulless?
Comment #3
ssoulless commentedYup worked like a charm please commit it so I can delete my hacked solution jeje thanks!
Comment #5
mradcliffeCommitted and pushed.