fix: enforce mandatory chart name on save and edit (#10482)

* fix: show empty charts as empty in chart list view

* migrate ControlLabel to FormLabel and enforce requred fields

* lint

* reorder buttons
This commit is contained in:
Ville Brofeldt
2020-07-31 19:30:02 +03:00
committed by GitHub
parent 6243a46ca6
commit 9eab29aeaa
2 changed files with 13 additions and 8 deletions

View File

@@ -262,18 +262,18 @@ function PropertiesModal({ slice, onHide, onSave }: InternalProps) {
</Row>
</Modal.Body>
<Modal.Footer>
<Button type="button" bsSize="sm" onClick={onHide}>
{t('Cancel')}
</Button>
<Button
type="submit"
bsSize="sm"
bsStyle="primary"
className="m-r-5"
disabled={!owners || submitting}
disabled={!owners || submitting || !name}
>
{t('Save')}
</Button>
<Button type="button" bsSize="sm" onClick={onHide}>
{t('Cancel')}
</Button>
<Dialog ref={errorDialog} />
</Modal.Footer>
</form>