mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-16 01:44:03 +03:00
ask for confirmation before deleting event triggers (close #599)
This commit is contained in:
parent
4643458cf9
commit
ffa0938a86
@ -20,8 +20,12 @@ class Settings extends Component {
|
|||||||
)[0];
|
)[0];
|
||||||
triggerSchema = triggerSchema ? triggerSchema : {};
|
triggerSchema = triggerSchema ? triggerSchema : {};
|
||||||
|
|
||||||
const handleDeleteTrigger = () => {
|
const handleDeleteTrigger = e => {
|
||||||
|
e.preventDefault();
|
||||||
|
const isOk = confirm('Are you sure?');
|
||||||
|
if (isOk) {
|
||||||
dispatch(deleteTrigger(triggerName));
|
dispatch(deleteTrigger(triggerName));
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
Loading…
Reference in New Issue
Block a user