Skip to content
Snippets Groups Projects
Unverified Commit 6b54f753 authored by meskio's avatar meskio :tent:
Browse files

Disable inventary submit button if no inventary entries

parent 48e37b1d
No related branches found
No related tags found
No related merge requests found
......@@ -38,7 +38,7 @@ function CreateInventary() {
};
};
const disabled = !picks;
const disabled = picks.length == 0;
const supplierOptions = [<option key=""></option>].concat(
suppliers.map((s) => <option key={s.ID}>{s.name}</option>)
......@@ -77,7 +77,7 @@ function CreateInventary() {
<Form.Group as={Row}>
<Col>
<div className="text-right">
<Button type="submit" disabled={disabled}>
<Button variant="primary" type="submit" disabled={disabled}>
Añadir entrada
</Button>
</div>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment