Skip to content
Snippets Groups Projects
Unverified Commit aa2afff4 authored by Gustavo Saiani's avatar Gustavo Saiani Committed by GitHub
Browse files

Do not offer to add model to dashboard once it's created and saved (#25828)

parent f4d3ea6c
No related branches found
No related tags found
No related merge requests found
......@@ -83,7 +83,11 @@ class QueryModals extends React.Component {
}}
onCreate={async card => {
await this.props.onCreate(card);
onOpenModal(MODAL_TYPES.SAVED);
if (question.isDataset()) {
onCloseModal();
} else {
onOpenModal(MODAL_TYPES.SAVED);
}
}}
onClose={onCloseModal}
/>
......
......@@ -22,8 +22,6 @@ describe("scenarios > models > create", () => {
cy.findByText("Save").click();
cy.findByText("Not now").click();
cy.findByText("Saved");
});
});
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