Skip to content

Instantly share code, notes, and snippets.

@justinyost
Last active August 29, 2015 14:19
Show Gist options
  • Save justinyost/5a08abf94b214e6fbf07 to your computer and use it in GitHub Desktop.
Save justinyost/5a08abf94b214e6fbf07 to your computer and use it in GitHub Desktop.
Error Response for Serializers
{
"errors": {
"is_composite": "Is Composite? must be true or false.",
"pit_bin_location_slug": "Pit Bin Location Slug must not be empty.",
"analysis_customers": [
{
"sales_order": "Sales Order must not be empty."
},
{},
{
"net_weight": "Net Weight must not be empty."
}
]
}
}
{
"analysis": {
"process_stage_slug": "none",
"is_composite": "asdfasdfasdfasdfasdf",
"pit_bin_number_slug": "none",
"pit_bin_location_slug": "",
"wash_time": null,
"test_run_at": null,
"is_out_spec": false,
"is_out_int_spec": false,
"note": null,
"batch_number": "",
"lot_number": "",
"tons_per_hour": "",
"chemical": "",
"soda": "",
"analysis_sieves": [
{
"sieve_id": "1fce9410-d312-11e4-a747-000c29cc14f8",
"value": "asdfasdfasdf"
},
{
"sieve_id": "0bc5c001-d3cf-11e4-8290-fefd42e43bc9",
"value": "22"
},
{
"sieve_id": "asdfasdf",
"value": "asdfasdfasdfasdfasdf"
},
{
"sieve_id": "0bc5be54-d3cf-11e4-8290-fefd42e43bc9",
"value": "44"
}
],
"analysis_tests": [
{
"test_id": "55142a47-56b4-47c7-873e-096a0a00020f",
"value": null
}
],
"grade_id": "55008395-cf98-4c7b-8464-05b6c0a8d98c",
"lab_tech_id": "7d5b22bd-fc92-11e3-b153-080027dec79b",
"operator_id": "7d5b22bd-fc92-11e3-b153-080027dec79b",
"analysis_customers": [
{
"sales_order": "",
"net_weight": "1."
},
{
"net_weight": "1.2"
},
{
"net_weight": ""
}
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment