summaryrefslogtreecommitdiff
path: root/opendc-web/opendc-web-ui/src/containers/modals/DeleteRackModal.js
diff options
context:
space:
mode:
Diffstat (limited to 'opendc-web/opendc-web-ui/src/containers/modals/DeleteRackModal.js')
-rw-r--r--opendc-web/opendc-web-ui/src/containers/modals/DeleteRackModal.js27
1 files changed, 0 insertions, 27 deletions
diff --git a/opendc-web/opendc-web-ui/src/containers/modals/DeleteRackModal.js b/opendc-web/opendc-web-ui/src/containers/modals/DeleteRackModal.js
deleted file mode 100644
index ca76fd04..00000000
--- a/opendc-web/opendc-web-ui/src/containers/modals/DeleteRackModal.js
+++ /dev/null
@@ -1,27 +0,0 @@
-import React from 'react'
-import { useDispatch, useSelector } from 'react-redux'
-import { closeDeleteRackModal } from '../../actions/modals/topology'
-import { deleteRack } from '../../actions/topology/rack'
-import ConfirmationModal from '../../components/modals/ConfirmationModal'
-
-const DeleteRackModal = (props) => {
- const visible = useSelector((state) => state.modals.deleteRackModalVisible)
- const dispatch = useDispatch()
- const callback = (isConfirmed) => {
- if (isConfirmed) {
- dispatch(deleteRack())
- }
- dispatch(closeDeleteRackModal())
- }
- return (
- <ConfirmationModal
- title="Delete this rack"
- message="Are you sure you want to delete this rack?"
- show={visible}
- callback={callback}
- {...props}
- />
- )
-}
-
-export default DeleteRackModal