mirror of
https://github.com/inventree/inventree-app.git
synced 2026-10-06 23:32:11 +00:00
Stock transfer now works
This commit is contained in:
1 parent
af104717ab
commit
c4d8b5ce1c
2 files changed
+33
-4
No files matched your search
@@ -218,6 +218,20 @@ class InvenTreeStockItem extends InvenTreeModel {
|
||||
});
|
||||
}
|
||||
|
||||
Future<http.Response> transferStock(double q, int location, {String notes}) async {
|
||||
|
||||
if ((q == null) || (q > quantity)) q = quantity;
|
||||
|
||||
return api.post("/stock/transfer/", body: {
|
||||
"item": {
|
||||
"pk": "${pk}",
|
||||
"quantity": "${q}",
|
||||
},
|
||||
"location": "${location}",
|
||||
"notes": notes ?? '',
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user