Ecommerce API: some numbers have .0 where as others are rounded #2925

Closed
mattab opened this Issue Feb 13, 2012 · 1 comment

1 participant

@mattab
Piwik Open Source Analytics member

for example: index.php?module=API&method=Goals.getItemsName&format=XML&idSite=16&period=week&date=2012-02-12&expanded=1&idGoal=ecommerceOrder&filter_limit=100&token_auth=

returns:

<result>

<row><label>XXXXXX</label><revenue>76</revenue><quantity>4</quantity><orders>4</orders><avg_price>19</avg_price><avg_quantity>1</avg_quantity><conversion_rate>0%</conversion_rate></row>

<row><label>XXXX</label><revenue>64</revenue><quantity>2.00</quantity><orders>1</orders><avg_price>32</avg_price><avg_quantity>2</avg_quantity><conversion_rate>0%</conversion_rate></row>

One has quantity = 4 the other quantity = 2.0

This gets displayed this way in PDF/HTML/UI which is quite ugly/confusing.

@mattab
Piwik Open Source Analytics member

(In [5843]) Fixes #2925

@mattab mattab added this to the 1.7 Piwik 1.7 milestone Jul 8, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment