Skip to content

Commit 12828b2

Browse files
committed
feat: Support custom drive to prevent using prefix in the file name
1 parent 61e1e85 commit 12828b2

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/scheduler/NotebookScheduler.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,9 @@ const NotebookSchedulerComponent = ({
9696
const currentTime = new Date().getTime();
9797
const formattedCurrentTime = formatTimestamp(currentTime);
9898
setJobNameSelected(`job_${formattedCurrentTime}`);
99-
setInputFileSelected(context.path);
99+
setInputFileSelected(
100+
app.serviceManager.contents.localPath(context.localPath)
101+
);
100102
}
101103
}, [notebookSelector]);
102104

src/scheduler/composer/CreateNotebookScheduler.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -541,7 +541,9 @@ const CreateNotebookScheduler = ({
541541
*/
542542
useEffect(() => {
543543
if (context !== '') {
544-
setInputFileSelected(context.path);
544+
setInputFileSelected(
545+
app.serviceManager.contents.localPath(context.localPath)
546+
);
545547
}
546548
setJobNameSelected('');
547549
if (!editMode) {

0 commit comments

Comments
 (0)