|
@@ -53,8 +53,8 @@ const ArchiveCreateModal = (props) => {
|
|
|
setHierarchyValue(hierarchyValue);
|
|
setHierarchyValue(hierarchyValue);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- async function done() {
|
|
|
|
|
|
|
|
|
|
|
|
+ async function done() {
|
|
|
try {
|
|
try {
|
|
|
await appContainer.apiv3Post('/page/archive', {
|
|
await appContainer.apiv3Post('/page/archive', {
|
|
|
rootPagePath: props.path,
|
|
rootPagePath: props.path,
|
|
@@ -66,6 +66,7 @@ const ArchiveCreateModal = (props) => {
|
|
|
hierarchyValue,
|
|
hierarchyValue,
|
|
|
});
|
|
});
|
|
|
toastSuccess(t('Submitted the request to create the archive'));
|
|
toastSuccess(t('Submitted the request to create the archive'));
|
|
|
|
|
+ closeModalHandler();
|
|
|
}
|
|
}
|
|
|
catch (e) {
|
|
catch (e) {
|
|
|
toastError(e);
|
|
toastError(e);
|
|
@@ -202,7 +203,7 @@ const ArchiveCreateModal = (props) => {
|
|
|
<div className="my-1 custom-control costom-control-inline">
|
|
<div className="my-1 custom-control costom-control-inline">
|
|
|
<input
|
|
<input
|
|
|
type="number"
|
|
type="number"
|
|
|
- min="0"
|
|
|
|
|
|
|
+ min="1"
|
|
|
max="10"
|
|
max="10"
|
|
|
disabled={hierarchyType === 'allSubordinatedPage'}
|
|
disabled={hierarchyType === 'allSubordinatedPage'}
|
|
|
value={hierarchyValue}
|
|
value={hierarchyValue}
|
|
@@ -238,7 +239,6 @@ ArchiveCreateModal.propTypes = {
|
|
|
path: PropTypes.string.isRequired,
|
|
path: PropTypes.string.isRequired,
|
|
|
totalPages: PropTypes.number,
|
|
totalPages: PropTypes.number,
|
|
|
errorMessage: PropTypes.string,
|
|
errorMessage: PropTypes.string,
|
|
|
-
|
|
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
export default withTranslation()(ArchiveCreateModalWrapper);
|
|
export default withTranslation()(ArchiveCreateModalWrapper);
|