siwapp / siwapp-ror

Online Invoice Management in Ruby On Rails.
http://www.siwapp.com
MIT License
327 stars 182 forks source link

Taxes attribute is bad formed in JSON response #346

Open javiquiros opened 4 years ago

javiquiros commented 4 years ago

When recovering an invoice via API, "taxes" attribute is bad formed:

"taxes": {
   "{\\"id\\"=>4, \\"name\\"=>\\"VAT 21%\\", \\"value\\"=>\\"21.0\\", \\"active\\"=>true, \\"default\\"=>true, \\"deleted_at\\"=>nil}":"1.89"
}

Expected value:

"taxes": [{
    "id": 4,
    "name": "VAT 21%",
    "value": 21.0,
    "active": true,
    "default": true
}]