Merge pull request #2133 from SchrodingersGat/convert-out-of-stock

Allow conversion of out-of-stock items
This commit is contained in:
Oliver 2021-10-11 12:00:09 +11:00 committed by GitHub
commit e45f50acd3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -583,16 +583,6 @@ $("#stock-delete").click(function () {
);
});
{% if item.in_stock %}
$("#stock-assign-to-customer").click(function() {
launchModalForm("{% url 'stock-item-assign' item.id %}",
{
reload: true,
}
);
});
{% if item.part.can_convert %}
$("#stock-convert").click(function() {
launchModalForm("{% url 'stock-item-convert' item.id %}",
@ -603,6 +593,16 @@ $("#stock-convert").click(function() {
});
{% endif %}
{% if item.in_stock %}
$("#stock-assign-to-customer").click(function() {
launchModalForm("{% url 'stock-item-assign' item.id %}",
{
reload: true,
}
);
});
$("#stock-move").click(function() {
itemAdjust("move");
});