diff --git a/src/components/Modal/ClosePOModal.js b/src/components/PurchaseOrder/CloseOrder/CloseOrderModal.js
similarity index 85%
rename from src/components/Modal/ClosePOModal.js
rename to src/components/PurchaseOrder/CloseOrder/CloseOrderModal.js
index ad77b629e..0b1d93de5 100644
--- a/src/components/Modal/ClosePOModal.js
+++ b/src/components/PurchaseOrder/CloseOrder/CloseOrderModal.js
@@ -4,9 +4,9 @@ import PropTypes from 'prop-types';
import { Button } from '@folio/stripes/components';
-import ClosePOModalForm from './ClosePOModalForm';
+import CloseOrderModalForm from './CloseOrderModalForm';
-class ClosePOModal extends Component {
+class CloseOrderModal extends Component {
static propTypes = {
orderId: PropTypes.string.isRequired,
};
@@ -44,7 +44,7 @@ class ClosePOModal extends Component {
>
- {
- const cancelBtn = ;
- const submitBtn = ;
+const CloseOrderModalForm = ({ close, open, orderId }) => {
+ const cancelBtn = ;
+ const submitBtn = ;
const footer = (
{
return (
}
+ label={}
open={open}
>
}
+ label={}
name="reason"
/>
}
+ label={}
name="notes"
/>
@@ -53,14 +53,14 @@ const ClosePOModalForm = ({ close, open, orderId }) => {
);
};
-ClosePOModalForm.propTypes = {
+CloseOrderModalForm.propTypes = {
close: PropTypes.func.isRequired,
open: PropTypes.bool.isRequired,
orderId: PropTypes.string.isRequired,
};
export default stripesForm({
- form: 'closePOModalForm',
+ form: 'closeOrderModalForm',
navigationCheck: true,
enableReinitialize: true,
-})(ClosePOModalForm);
+})(CloseOrderModalForm);
diff --git a/src/components/PurchaseOrder/CloseOrder/index.js b/src/components/PurchaseOrder/CloseOrder/index.js
new file mode 100644
index 000000000..d06bcc5e1
--- /dev/null
+++ b/src/components/PurchaseOrder/CloseOrder/index.js
@@ -0,0 +1,4 @@
+import CloseOrderModal from './CloseOrderModal';
+import CloseOrderModalForm from './CloseOrderModalForm';
+
+export { CloseOrderModal, CloseOrderModalForm };
diff --git a/src/components/PurchaseOrder/PO.js b/src/components/PurchaseOrder/PO.js
index 6cdd30ab0..ae071c6de 100644
--- a/src/components/PurchaseOrder/PO.js
+++ b/src/components/PurchaseOrder/PO.js
@@ -27,7 +27,7 @@ import {
LayerPOLine,
} from '../LayerCollection';
import transitionToParams from '../Utils/transitionToParams';
-import ClosePOModal from '../Modal/ClosePOModal';
+import { CloseOrderModal } from './CloseOrder';
import { AdjustmentView } from './Adjustment';
import LineListing from './LineListing';
import { PODetailsView } from './PODetails';
@@ -187,7 +187,7 @@ class PO extends Component {
const lastMenu = (
-
+