diff --git a/docs/content/02-tutorials/02-slurm-accounting.md b/docs/content/02-tutorials/02-slurm-accounting.md index c28e5202..fa8eee40 100644 --- a/docs/content/02-tutorials/02-slurm-accounting.md +++ b/docs/content/02-tutorials/02-slurm-accounting.md @@ -145,7 +145,7 @@ Choose a name for your job, a number of nodes to run under, choose to `Run a com ![Cluster Properties](accounting/submit-job-dialog.png) -## Step 5 - View the Accounting Tab +## Step 6 - View the Accounting Tab Once you've submitted a job, you can see the job information under the `Accounting tab` diff --git a/docs/content/02-tutorials/05-cloud9.md b/docs/content/02-tutorials/05-cloud9.md index f8429e2c..632164cd 100644 --- a/docs/content/02-tutorials/05-cloud9.md +++ b/docs/content/02-tutorials/05-cloud9.md @@ -1,5 +1,5 @@ +++ -title = "d. Cloud9 ☁️" +title = "e. Cloud9 ☁️" weight = 25 +++ diff --git a/docs/content/02-tutorials/06-downloading.md b/docs/content/02-tutorials/06-downloading.md index 20a7463b..6205f67b 100644 --- a/docs/content/02-tutorials/06-downloading.md +++ b/docs/content/02-tutorials/06-downloading.md @@ -1,7 +1,7 @@ +++ -title = "d. Downloading ⇓" -weight = 25 +title = "f. Downloading ⇓" +weight = 26 +++ This tutorial shows you how you can download a file from an external source at cluster start. diff --git a/frontend/src/components/FileChooser.tsx b/frontend/src/components/FileChooser.tsx index 9d3839b8..9837adbf 100644 --- a/frontend/src/components/FileChooser.tsx +++ b/frontend/src/components/FileChooser.tsx @@ -69,8 +69,7 @@ function FileUploadButton(props: any) { }; return (
- {/* @ts-expect-error TS(2322) FIXME: Type '"contained"' is not assignable to type 'Vari... Remove this comment to see the full error message */} - { - if(item) + const itemToOption = (item: ClusterInfoSummary) => { + if(item && item.clusterStatus != ClusterStatus.DeleteInProgress) return {label: item.clusterName, value: item.clusterName} else return {label: i18next.t('wizard.source.clusterSelect.placeholder')} diff --git a/frontend/src/old-pages/CustomImages/ImageBuildDialog.tsx b/frontend/src/old-pages/CustomImages/ImageBuildDialog.tsx index 46b6d64c..35ac9258 100644 --- a/frontend/src/old-pages/CustomImages/ImageBuildDialog.tsx +++ b/frontend/src/old-pages/CustomImages/ImageBuildDialog.tsx @@ -25,6 +25,7 @@ import { // Components import ValidationErrors from '../../components/ValidationErrors' +import FileUploadButton from '../../components/FileChooser' // State import { setState, useState, getState, clearState } from '../../store' @@ -52,36 +53,6 @@ function buildImageValidate(suppressUpload = false) { return valid; } -const FileUploadButton = (props: any) => { - const hiddenFileInput = React.useRef(null); - const handleClick = (event: any) => { - // @ts-expect-error TS(2531) FIXME: Object is possibly 'null'. - hiddenFileInput.current.click(); - }; - const handleChange = (event: any) => { - var file = event.target.files[0] - var reader = new FileReader(); - reader.onload = function(e) { - // @ts-expect-error TS(2531) FIXME: Object is possibly 'null'. - props.handleData(e.target.result) - } - reader.readAsText(file); - }; - return ( - <> - - - - ); -} - export default function ImageBuildDialog(props: any) { const open = useState([...imageBuildPath, 'dialog']); const imageConfig = useState([...imageBuildPath, 'config']) || "";