Open clj opened 1 year ago
I can't just replace this with what I had before, since the parameters returned do not return the template_detail.
GET /api/part/31/?parameters=1
"parameters": [
{
"pk": 127,
"part": 31,
"template": 50,
"data": "SK33A-LTP"
},
GET /api/part/parameter/?part=31
[
{
"pk": 127,
"part": 31,
"template": 50,
"template_detail": {
"pk": 50,
"name": "Value",
"units": "",
"description": ""
},
"data": "SK33A-LTP"
},
This might be ok, as long as I pre-fetch the templates. The templates are probably not updated a lot, so it is probably not necessary to re-fetch them. One could do that if a new ID that is not in the cache is encountered.
e.g.:
https://inventree.server/api/part/123/?parameters=1